Академический Документы
Профессиональный Документы
Культура Документы
Partners
Support
Community
Ubuntu.com
Login to edit
Insert your Ubuntu CD, reboot your computer and set it to boot from CD in the BIOS
and boot into a live session. You can also use a LiveUSB if you have created one in the
past.
* Open a terminal. As of Ubuntu 11.10 and 11.04, this can be done by opening the Unity Dash
(you can click the Ubuntu logo in the top panel or use the Windows key on your keyboard) and
typing in "Terminal", and clicking what comes up. On earlier versions, you can achieve this by
going to Applications -> Accessories -> Terminal.
1 of 3 6/4/2014 9:11 PM
RecoveringUbuntuAfterInstallingWindows - Community Help Wiki https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingW...
where XXX is the device of your Ubuntu install. (eg: grub-install /dev/sdb). Hint: You can
also use /dev/disk/by-label/ if the partition you installed on has a label. You can determine the
/dev node for such a device by running:
ls -l /dev/disk/by-label/
You can also use fdisk if you do not see the /dev/disk/by-label:
$ sudo fdisk -l
From here, find only the drive name, ignore the partition number, that is, for partitions
labeled "root", "data2", "fat", "home" and "swap" it's all still just sda. This is due to the fact
that GRUB is installed in the MBR of the drive, and not on a partition.
Trouble? If other things are messed up, e.g. if you have deleted the partition from where Grub
was previously installed, grub-install may return an error message such as "cannot find a
device for /... (is /dev mounted?)". You may have to do grub-install a bit differently. Refer to
the handy guide on fixing a broken system
Now reboot your system. The usual GRUB boot menu should appear. If it does not, hold Left
Shift while booting. You will be able to choose between Ubuntu and Windows.
When the Ubuntu splash screen comes up with the boot: prompt, type in rescue and
2 of 3 6/4/2014 9:11 PM
RecoveringUbuntuAfterInstallingWindows - Community Help Wiki https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingW...
press enter.
Choose your language, location (country) and then keyboard layout as if you were doing
a fresh install.
Enter a host name, or leave it with the default (Ubuntu).
At this stage you are presented with a screen where you can select which partition is
your root partition (there is a list of the partitions on your hard drive, so you are required
to know which partition number Ubuntu is on). This will be dev/discs/discY
/partX, where the X is a partition number and Y is the number of the drive.
GRUB2
3 of 3 6/4/2014 9:11 PM