0

So I've been running Ubuntu 16.04 on my Dell Precision 7510 (installed on my SATA SSD). I added in an M.2 SSD, and am trying to get a second Ubuntu installed on there so that I can dual boot them. To keep them completely separated, I took out my SATA drive, then installed the latest 16.04 on the M.2, and the install went fine and I was able to boot in no problem.

When I added the SATA back in, I was able to boot into the SATA, but not to the M.2. When I selected the M.2 to boot into via the boot order menu in the BIOS, I get a grub menu, then after proceeding, ubuntu prompts me for my Encrypted Drive password. After that, it defaults to emergency mode and I get command line access to my SATA. For sanity check, once I take out the SSD, I'm able to again boot into the M.2 without problems. They should both be UEFI.

These pictures show the BIOS boot settings for each of the drives, as well as the 'e' config of the grub for the M.2.

http://imgur.com/a/BOqJ2

After some help, this was determined: Based on screenshot #3, your GRUB install is trying to boot into (hd0,gpt2) which is /dev/sda2 in grubspeak. It also mentions UUID 9d26e3b5-607e-4b7c-a4a7-64ea41529385 a couple times, which lsblk confirms is /dev/sda2. So that's all cool. The problem is, the second last line in screenshot #3 says:

linux /vmlinuz-4.8.whatever.signed root=/dev/mapper/ubuntu--vg-root ro quiet splash $vt_handoff

According to parted, /dev/mapper/ubuntu--vg-root is your root filesystem on the LVM partion of /dev/sdb3. GRUB is looking in the wrong place.

Screenshot #3 was the GRUB edit screen. You can temporarly change options for boot, even though it's not permanent. Remove /dev/mapper/ubuntu--vg-root, and replace it with /dev/sda3.

After trying that, it got me past emergency mode, but dumped me into a BusyBox shell, and there's no grub under /etc/default. I tried fsck /dev/sda3 and it just spits out "fsck from util-linux 2.27.1". Some additional output from BusyBox: http://i.imgur.com/FUj4MGo.jpg

Stuck at this point. Appreciate the help!

Some output:

$ lsblk

NAME                  MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda                     8:0    0 489.1G  0 disk 
├─sda1                  8:1    0   512M  0 part 
├─sda2                  8:2    0   488M  0 part 
└─sda3                  8:3    0 488.1G  0 part 
sdb                     8:16   0 238.5G  0 disk 
├─sdb1                  8:17   0   512M  0 part /boot/efi
├─sdb2                  8:18   0   244M  0 part /boot
└─sdb3                  8:19   0 237.8G  0 part 
  ├─ubuntu--vg-root   252:0    0 221.8G  0 lvm  /
  └─ubuntu--vg-swap_1 252:1    0  15.9G  0 lvm  [SWAP]

$ sudo parted -l (Crucial is the M.2, SK hynix is the SATA)

Model: ATA Crucial_CT525MX3 (scsi)
Disk /dev/sda: 525GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size   File system  Name                  Flags
 1      1049kB  538MB   537MB  fat32        EFI System Partition  boot, esp
 2      538MB   1050MB  512MB  ext2
 3      1050MB  525GB   524GB


Model: ATA SK hynix SH920 2 (scsi)
Disk /dev/sdb: 256GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End    Size   File system  Name                  Flags
 1      1049kB  538MB  537MB  fat32        EFI System Partition  boot, esp
 2      538MB   794MB  256MB  ext2
 3      794MB   256GB  255GB                                     lvm


Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/ubuntu--vg-swap_1: 17.1GB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Disk Flags: 

Number  Start  End     Size    File system     Flags
 1      0.00B  17.1GB  17.1GB  linux-swap(v1)


Model: Linux device-mapper (linear) (dm)
Disk /dev/mapper/ubuntu--vg-root: 238GB
Sector size (logical/physical): 512B/512B
Partition Table: loop
Disk Flags: 

Number  Start  End    Size   File system  Flags
 1      0.00B  238GB  238GB  ext4

$ ls -l /dev/disk/by-uuid/

total 0
lrwxrwxrwx 1 root root 10 Feb 28 07:06 24CC-7E74 -> ../../sda1
lrwxrwxrwx 1 root root 10 Feb 28 07:06 349bd6fa-8cf6-45ec-a44f-dc1a87253858 -> ../../sda3
lrwxrwxrwx 1 root root 10 Feb 28 07:06 35E9-D32C -> ../../sdb1
lrwxrwxrwx 1 root root 10 Feb 28 07:06 7524a198-cd6a-42b7-a4a0-87f2fce687a9 -> ../../sdb2
lrwxrwxrwx 1 root root 10 Feb 28 07:06 814097ac-da83-456c-ad58-4bccf02bb249 -> ../../dm-0
lrwxrwxrwx 1 root root 10 Feb 28 07:06 9d26e3b5-607e-4b7c-a4a7-64ea41529385 -> ../../sda2
lrwxrwxrwx 1 root root 10 Feb 28 07:06 e57ebc2a-8d07-4348-84f5-a2961033721a -> ../../dm-1

$ ls -l /dev/disk/by-partlabel/

total 0
lrwxrwxrwx 1 root root 10 Feb 28 07:13 EFI\x20System\x20Partition -> ../../sdb1
sdey:~$ ls -l /dev/disk/by-id
total 0
lrwxrwxrwx 1 root root  9 Feb 28 07:06 ata-Crucial_CT525MX300SSD4_1701154392C7 -> ../../sda
lrwxrwxrwx 1 root root 10 Feb 28 07:13 ata-Crucial_CT525MX300SSD4_1701154392C7-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Feb 28 07:13 ata-Crucial_CT525MX300SSD4_1701154392C7-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Feb 28 07:13 ata-Crucial_CT525MX300SSD4_1701154392C7-part3 -> ../../sda3
lrwxrwxrwx 1 root root  9 Feb 28 07:13 ata-SK_hynix_SH920_2.5_7MM_256GB_EJ5BN40911150B51A -> ../../sdb
lrwxrwxrwx 1 root root 10 Feb 28 07:13 ata-SK_hynix_SH920_2.5_7MM_256GB_EJ5BN40911150B51A-part1 -> ../../sdb1
lrwxrwxrwx 1 root root 10 Feb 28 07:13 ata-SK_hynix_SH920_2.5_7MM_256GB_EJ5BN40911150B51A-part2 -> ../../sdb2
lrwxrwxrwx 1 root root 10 Feb 28 07:13 ata-SK_hynix_SH920_2.5_7MM_256GB_EJ5BN40911150B51A-part3 -> ../../sdb3
lrwxrwxrwx 1 root root 10 Feb 28 07:13 dm-name-ubuntu--vg-root -> ../../dm-0
lrwxrwxrwx 1 root root 10 Feb 28 07:13 dm-name-ubuntu--vg-swap_1 -> ../../dm-1
lrwxrwxrwx 1 root root 10 Feb 28 07:13 dm-uuid-LVM-DHIY06XLJgS3c0I624EBEH6H5e38H3012iao3dBgZG2GLIgJy48SryddHVLjfDL4 -> ../../dm-1
lrwxrwxrwx 1 root root 10 Feb 28 07:13 dm-uuid-LVM-DHIY06XLJgS3c0I624EBEH6H5e38H301PYpfiZodyCm4oSiGtsdcSy0dVV8VSGkZ -> ../../dm-0
lrwxrwxrwx 1 root root 10 Feb 28 07:13 lvm-pv-uuid-TevrhJ-EFQ0-skBW-yhY5-roDS-6Z30-Nnv568 -> ../../sdb3
lrwxrwxrwx 1 root root  9 Feb 28 07:06 wwn-0x500a0751154392c7 -> ../../sda
lrwxrwxrwx 1 root root 10 Feb 28 07:13 wwn-0x500a0751154392c7-part1 -> ../../sda1
lrwxrwxrwx 1 root root 10 Feb 28 07:13 wwn-0x500a0751154392c7-part2 -> ../../sda2
lrwxrwxrwx 1 root root 10 Feb 28 07:13 wwn-0x500a0751154392c7-part3 -> ../../sda3
  • Once you have LVM you must boot that, not a partition. This would never be correct: Remove /dev/mapper/ubuntu--vg-root, and replace it with /dev/sda3. But have you tried changing all the hd0 to hd1? Normally boot drive is hd0 no matter where it is in SATA port order or Ubuntu drive order. Is sda also encrypted and LVM, so it system getting confused on which /dev/mapper is which? – oldfred Mar 1 '17 at 17:07
  • Yeah, the M2 (sda) is encrypted, but the SATA (sdb) is not. So in the grub settings you want me to switch all occurrences of hd0 to hd1? – S.D. Mar 2 '17 at 14:44
  • Which drive are you actually booting from and which menu then? Boot drive is hd0, but if UEFI on hd0 and you then have Ubuntu on hd1, you probably need to change. – oldfred Mar 2 '17 at 15:14
  • Unfortunately changing hd0 -> hd1 in the 3 spots it occurs in the grub boot parameters threw me back onto sda (SATA) in emergency mode. For the hell of it I then changed hd0 to hd1 AND changed /dev/mapper/ubuntu--vg-root to /dev/sda3 and again brought me back to the initramfs BusyBox prompt – S.D. Mar 3 '17 at 14:59

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.