Jump to content

Boot back to Ubuntu after installing Windows 10?

Go to solution Solved by limegorilla,

Once you have done @tj_420's solution, you'll want to re-install GRUB as the deafult bootloader over Windows 10's.

You can also do that with this method from the official Ubuntu Forum - which was a simple Google search away. Try that first next time.

Quote

The graphical way

  • 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.
  • Install and run Boot-Repair

  • Click "Recommended Repair".
  • 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.

 

The terminal way

* 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. Alternately use the Keyboard Shortcut: CTRL + ALT + T.

For full details on using terminal to fix grub on hard drive from Live Installer DVD or Flash: https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal

  • You are then presented with a standard bash prompt, type - this only works to reinstall to MBR of a working system:

 


sudo grub-install /dev/XXX

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/

This will give the output of something like:


lrwxrwxrwx 1 root root 10 Oct 16 10:27 data -> ../../sdb2
lrwxrwxrwx 1 root root 10 Oct 16 10:27 data2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Oct 16 10:27 fat -> ../../sda6
lrwxrwxrwx 1 root root 10 Oct 16 10:27 home -> ../../sda7
lrwxrwxrwx 1 root root 10 Oct 16 10:27 root -> ../../sda1
lrwxrwxrwx 1 root root 10 Oct 16 10:27 swap -> ../../sda5
lrwxrwxrwx 1 root root 10 Oct 16 10:27 windows -> ../../sdb1

You can also use fdisk if you do not see the /dev/disk/by-label:


$ sudo fdisk -l

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 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: 0x0001bc54

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       18725   150403072   83  Linux
/dev/sda2           18725       19458     5884929    5  Extended
/dev/sda5           18725       19458     5884928   82  Linux swap / Solaris

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.

 

Using the Ubuntu Alternate CD

  • Boot your system from the Ubuntu Alternate CD.
  • When the Ubuntu splash screen comes up with the boot: prompt, type in rescue and 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.

  • Now proceed as described in "The terminal way" above.

Link to the above Forum page: https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows

Ok, so I have Windows 7 and Ubuntu but I wanted to triple boot it with Win 10 so my question is that can I boot back to Ubuntu after I install Windows 10.

 

If you can boot back to Ubuntu, please tell me how to do it.

 

P.S. I haven't install Windows 10

Link to comment
Share on other sites

Link to post
Share on other sites

Easy. Open your start menu, and hold SHIFT and click the Restart button. Keep holding it until you see the windows logo. You should now have a menu. Click on advanced options and boot from device. There should be a partition called ubuntu. Click on that and you should boot in.

hi.

Link to comment
Share on other sites

Link to post
Share on other sites

@tj_420 I'm not sure it will work. Because on Windows 7 I can't even see anything on the Ubuntu partitionimage.png.7c31c82c2cf705e3eef95b4b65a804e7.png

Link to comment
Share on other sites

Link to post
Share on other sites

Once you have done @tj_420's solution, you'll want to re-install GRUB as the deafult bootloader over Windows 10's.

You can also do that with this method from the official Ubuntu Forum - which was a simple Google search away. Try that first next time.

Quote

The graphical way

  • 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.
  • Install and run Boot-Repair

  • Click "Recommended Repair".
  • 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.

 

The terminal way

* 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. Alternately use the Keyboard Shortcut: CTRL + ALT + T.

For full details on using terminal to fix grub on hard drive from Live Installer DVD or Flash: https://help.ubuntu.com/community/Grub2/Installing#via_the_LiveCD_terminal

  • You are then presented with a standard bash prompt, type - this only works to reinstall to MBR of a working system:

 


sudo grub-install /dev/XXX

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/

This will give the output of something like:


lrwxrwxrwx 1 root root 10 Oct 16 10:27 data -> ../../sdb2
lrwxrwxrwx 1 root root 10 Oct 16 10:27 data2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Oct 16 10:27 fat -> ../../sda6
lrwxrwxrwx 1 root root 10 Oct 16 10:27 home -> ../../sda7
lrwxrwxrwx 1 root root 10 Oct 16 10:27 root -> ../../sda1
lrwxrwxrwx 1 root root 10 Oct 16 10:27 swap -> ../../sda5
lrwxrwxrwx 1 root root 10 Oct 16 10:27 windows -> ../../sdb1

You can also use fdisk if you do not see the /dev/disk/by-label:


$ sudo fdisk -l

Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 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: 0x0001bc54

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1       18725   150403072   83  Linux
/dev/sda2           18725       19458     5884929    5  Extended
/dev/sda5           18725       19458     5884928   82  Linux swap / Solaris

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.

 

Using the Ubuntu Alternate CD

  • Boot your system from the Ubuntu Alternate CD.
  • When the Ubuntu splash screen comes up with the boot: prompt, type in rescue and 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.

  • Now proceed as described in "The terminal way" above.

Link to the above Forum page: https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows

Bow down to me humans.

I can't help if you don't quote me. How am I supposed to know if you need my premium support? Now starting at £399.99 a year.

Also, be a sport and mark the correct answer as the correct answer. It will help pour souls in the future when they are stuck and need guidance.

"If it works, proceed to take it apart and 'make it work better.' Then cry for help when it breaks." - Me, about five minutes ago when my train of thought wandered.

Remember kids, A janky solution is still a solution.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×