원문 : http://mongmio.tistory.com/17
  1. MBR (Master Boot Record) 삭제
    $ dd if=/dev/null of=/dev/sda bs=446 count=1

    이렇게 하면 MBR에 쓰레기 값이 써진다. 이 상태에서 재부팅 하면 골치 아파지니, 그런건 하지말자.

  2. GRUB 복구

    $ sudo -i
    $ fdisk -l


    Disk /dev/sda: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Sector size (logical/physical): 512 bytes / 512 bytes
    I/O size (minimum/optimal): 512 bytes / 512 bytes
    Disk identifier: 0xa0e4765c

       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1               1        6374    51199123+   7  HPFS/NTFS
    /dev/sda2            6375       60802   437186561    5  Extended
    /dev/sda5           59673       60802     9070592   82  Linux swap / Solaris
    /dev/sda6   *        6375       59672   428114944   83  Linux

    와 비슷한 메시지가 뜨면 이중에서 리눅스가 설치된 /dev/sda6를 mount 한다.

    $ mount /dev/sda6 /mnt
    $ mount --bind /dev /mnt/dev
    $ mount --bind /proc /mnt/proc

    resolv.conf 라는 파일을 mount 된 곳으로 복사한다.

    $ cp /etc/resolv.conf /mnt/etc/resolv.conf

    마운트된 파일 시스템의 루트로 들어간다.

    $ chroot /mnt

    이제 GRUB을 복구할 것이다.

    $ grub-install /dev/sda

    에러가 나면 다음과 같이 입력해 본다.
    $ grub-install --recheck /dev/sda

    설치가 끝났다. 리부팅 해보자.

    $ reboot
Posted by 눈누난나야
,