by AngelEyra on February 18th, 2007

AngelEyra

Question

Help answer this question below.

How would I reinstall GRUB to my MBR if I've accidentally overwritten it?

  • Like
  • Report

Answers. 2 helpful answers below.

  • by maddogshug on February 20th, 2007

    maddogshug

    i have done it. i booted a gentoo minimal cd.
    mounted my boot partition to /mnt/gentoo/boot

    mounted my root partition to /mnt/gentoo and issued these commands

    mount -t proc none /mnt/gentoo/proc

    mount -o bind /dev /mnt/gentoo/dev

    chroot /mnt/gentoo /bin/bash

    grep -v rootfs /proc/mounts > /etc/mtab (no rootfs if no /boot partition)


    grub-install /dev/hda (your hardrive here)

    exit (to leave chroot)

    umount /mnt/gentoo/boot

    umount /mnt/gentoo

    reboot

    if your distro has an easier way do that, but this should work with any distro

    • Like
    • Report

    No comments. Post one | Permalink

  • by 8 Jan 2004-10 Dec 2009 on February 18th, 2007

    8 Jan 2004-10 Dec 2009

    Most install CD/DVDs have a recovery mode of some sort. How to access is depends on the distro, but it usually allows you to reinstall GRUB/LILO.

Want to attach an image to your answer? Click here.

Did this answer your question? If not, then ask a new question or create a poll.

More Questions. Additional questions in this category.

You're reading How would I reinstall GRUB to my MBR if I've accidentally overwritten it?

Follow us on Facebook!

Related Ads

ANSWERBAG BUZZ

Gentoo install grub
Gentoo grub install
Reinstall grub gentoo
Gentoo grub reinstall
Gentoo recover grub