0

I installed Ubuntu 16.04 on another SSD of my laptop. I have Windows 10 on hd1 and Ubuntu on hd0.

I wanted to dual boot using grub and I'm following a tutorial in order to add a Windows entry to the grub boot menu, but after I boot into Ubuntu the disk containing Windows 10 doesn't even appear.

output from lsblk:

NAME   FSTYPE   SIZE MOUNTPOINT LABEL
sda           447.1G            
├─sda4 vfat     191M /boot/efi  
├─sda2 ntfs   382.1G            
├─sda5 ext4    40.4G /home      
├─sda3 swap    14.9G [SWAP]     
└─sda1 ext4     9.5G /

sda is the disk of Ubuntu, another disk doesn't appear. What can I do to manually detect my Windows disk?

karel
  • 114,770

2 Answers2

0

I do not have experience with this particular issue but from the grub2 manual (assuming that is your boot-loader):

5.3.4 DOS/Windows 5.3 Some caveats on OS-specific issues

GRUB cannot boot DOS or Windows directly, so you must chain-load them (see Chain-loading). However, their boot loaders have some critical deficiencies, so it may not work to just chain-load them. To overcome the problems, GRUB provides you with two helper functions.

If you have installed DOS (or Windows) on a non-first hard disk, you have to use the disk swapping technique, because that OS cannot boot from any disks but the first one. The workaround used in GRUB is the command drivemap (see drivemap), like this:

drivemap -s (hd0) (hd1)

This performs a virtual swap between your first and second hard drive.

I do not know if the following will work out of the box but hopefully it may point you in the right direction. Best of luck.

menuentry "Windows" {  
    insmod chain  
    insmod ntfs  
    drivemap -s (hd0) (hd1) # swap hd1 for hdo  
    set root=(hd0,1)  
    chainloader +1  
}
karel
  • 114,770
sum1nil
  • 1
  • 2
0

Without you even giving hardware information, I'm pretty sure that your primary drive is a Cheap! Crap! Inc! no-brand SSD that only gets its compatibility with Windows through vendor-specific UEFI and Windows drivers and your second drive is a good brand-name product that just works out of the box. (We've been seeing them more often here lately)

If your computer is still under warranty, insist the vendor swap out the SSD to something that works out of the box or get a full refund and buy something after hands-on testing only.

If not under warranty: make frequent backups of your Windows because SSDs just die suddenly without warning like a heart attack and partition the new drive to have a FAT or NTFS partition that is readable under Windows so you can exchange information between Windows and Ubuntu.

Sorry! :-(

Fabby
  • 34,259