copied to new partition, UUIDs not correct

Issues Related to Hardware (Sound, Video, Printers, Scanners, Webcams, Touchpads, Keyboards, Sensors, Drives, GRUB, etc.)

Moderator: Moderators

copied to new partition, UUIDs not correct

Postby MALsPa » Sat Oct 27, 2012 20:18

I copied Sabayon to a new set of partitions. In the copied system, I have reinstalled grub2 and run grub-mkconfig -o /boot/grub/grub.cfg. But the UUIDs in grub.cfg are still not all correct.

I was trying to boot into the copied Sabayon with a chaniloader entry from Debian's grub2, which is on the MBR, but I don't think it will work with those incorrect UUIDs in Sabayon's grub.cfg. I don't know what to do with 10_linux in Sabayon to correct this part of its grub.cfg.

I can boot into the copied Sabayon fine with an entry in Debian's /etc/grub.d that boots me directly to the kernel, I just can't get a chainloader entry to work.

Here's what that part of Sabayon's grub.cfg looks like:

Code: Select all
### BEGIN /etc/grub.d/10_linux ###
menuentry 'Sabayon GNU/Linux' --class sabayon --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-simple-61f8a5a2-c28d-497f-a880-51f72ce4983f' {
   load_video
   insmod gzio
   insmod part_msdos
   insmod ext2
   set root='hd0,msdos11'
   if [ x$feature_platform_search_hint = xy ]; then
     search --no-floppy --fs-uuid --set=root --hint-bios=hd0,msdos11 --hint-efi=hd0,msdos11 --hint-baremetal=ahci0,msdos11 --hint='hd0,msdos11'  61f8a5a2-c28d-497f-a880-51f72ce4983f
   else
     search --no-floppy --fs-uuid --set=root 61f8a5a2-c28d-497f-a880-51f72ce4983f
   fi
   echo   'Loading Linux x86-3.4.0-sabayon ...'
   linux   /boot/kernel-genkernel-x86-3.4.0-sabayon ro  init=/linuxrc splash=silent,theme:sabayon video=vesafb:ywrap,mtrr:3 vga=791 console=tty1 quiet dokeymap keymap=us domdadm resume=swap:UUID=4a204219-2317-4943-a25d-6e854a432b9f real_resume=UUID=4a204219-2317-4943-a25d-6e854a432b9f root=UUID=1c7fc86e-d1f6-438f-bc67-e04cfa9c5957 docrypt
   echo   'Loading initial ramdisk ...'
   initrd   /boot/initramfs-genkernel-x86-3.4.0-sabayon
}


The "61f8a5a2-c28d-497f-a880-51f72ce4983f" is correct, but further down, "1c7fc86e-d1f6-438f-bc67-e04cfa9c5957" is not correct. Anyone know how to fix that part?
MALsPa
Baby Hen
 
Posts: 13
Joined: Tue Jun 26, 2012 15:57
Location: albuquerque

Re: copied to new partition, UUIDs not correct

Postby sabayonino » Sun Oct 28, 2012 0:16

try

Code: Select all
# grub2-mkconfig -o /boot/grub/grub.cfg
User avatar
sabayonino
Sagely Hen
 
Posts: 1577
Joined: Sun Sep 21, 2008 1:12
Location: Italy

Re: copied to new partition, UUIDs not correct

Postby MALsPa » Sun Oct 28, 2012 2:01

sabayonino wrote:try

Code: Select all
# grub2-mkconfig -o /boot/grub/grub.cfg


Thanks, I appreciate that reply. Didn't fix the UUIDs in grub.cfg, though. Don't the two commands do the same thing in Sabayon?
MALsPa
Baby Hen
 
Posts: 13
Joined: Tue Jun 26, 2012 15:57
Location: albuquerque

Re: copied to new partition, UUIDs not correct

Postby sabayonino » Sun Oct 28, 2012 8:29

MALsPa wrote:
sabayonino wrote:try

Code: Select all
# grub2-mkconfig -o /boot/grub/grub.cfg


Thanks, I appreciate that reply. Didn't fix the UUIDs in grub.cfg, though. Don't the two commands do the same thing in Sabayon?


check UUID's list
Code: Select all
# ls -lh /dev/disk/by-uuid


example
Code: Select all
lrwxrwxrwx 1 root root 10 28 ott 06.50 0498f126-2531-4ccd-a4b9-d259ae3d2056 -> ../../sda5
lrwxrwxrwx 1 root root 10 28 ott 06.50 826c4a52-c965-49b5-bfd4-02cba85c8395 -> ../../sda7
lrwxrwxrwx 1 root root 10 28 ott 06.50 82fb8f00-9f81-4bd3-9ef4-ef9aaadfd026 -> ../../sda2
lrwxrwxrwx 1 root root 10 28 ott 06.50 95b711cf-6164-4305-93cb-d9677216fc94 -> ../../sda6
lrwxrwxrwx 1 root root 10 28 ott 05.50 ada3c3b4-d8c8-49aa-a1d7-160504c180d3 -> ../../sda1
lrwxrwxrwx 1 root root 10 28 ott 05.50 d3bf60a8-b130-4a21-a48e-61adfb79c42c -> ../../sda3


check sabyon-grub coomand line
Code: Select all
# cat /etc/default/sabayon-grub


make sure that "real_root" and "root" boot options are set with the same UUID (UUID root partiton)
User avatar
sabayonino
Sagely Hen
 
Posts: 1577
Joined: Sun Sep 21, 2008 1:12
Location: Italy

Re: copied to new partition, UUIDs not correct

Postby MALsPa » Sun Oct 28, 2012 10:21

sabayonino wrote:check sabyon-grub coomand line
Code: Select all
# cat /etc/default/sabayon-grub


make sure that "real_root" and "root" boot options are set with the same UUID (UUID root partiton)


Code: Select all
# cat /etc/default/sabayon-grub
# this file has been added by the Anaconda Installer
# containing default installer bootloader arguments.
# DO NOT EDIT NOR REMOVE THIS FILE DIRECTLY !!!
GRUB_CMDLINE_LINUX="${GRUB_CMDLINE_LINUX} init=/linuxrc splash=silent,theme:sabayon video=vesafb:ywrap,mtrr:3 vga=791 console=tty1 quiet dokeymap keymap=us domdadm resume=swap:UUID=4a204219-2317-4943-a25d-6e854a432b9f real_resume=UUID=4a204219-2317-4943-a25d-6e854a432b9f root=UUID=1c7fc86e-d1f6-438f-bc67-e04cfa9c5957 docrypt"


No "real_root" option in that file.

The UUID shown there for "root" is the wrong one -- it's from the original Sabayon, not for the copy.
MALsPa
Baby Hen
 
Posts: 13
Joined: Tue Jun 26, 2012 15:57
Location: albuquerque

Re: copied to new partition, UUIDs not correct

Postby sabayonino » Sun Oct 28, 2012 12:32

UUID changes when will be create new partitions.

please paste the output
Code: Select all
# ls -lh /dev/disk/by-uuid
User avatar
sabayonino
Sagely Hen
 
Posts: 1577
Joined: Sun Sep 21, 2008 1:12
Location: Italy

Re: copied to new partition, UUIDs not correct

Postby MALsPa » Sun Oct 28, 2012 14:48

sabayonino wrote:please paste the output
Code: Select all
# ls -lh /dev/disk/by-uuid


I showed what the correct UUID should be in my first post. Here it is again:

Code: Select all
lrwxrwxrwx 1 root root 11 Oct 27 18:54 61f8a5a2-c28d-497f-a880-51f72ce4983f -> ../../sda11


And the one from the partition of the original Sabayon root, which is also shown in the first post:

Code: Select all
lrwxrwxrwx 1 root root 10 Oct 27 18:54 1c7fc86e-d1f6-438f-bc67-e04cfa9c5957 -> ../../sda7
MALsPa
Baby Hen
 
Posts: 13
Joined: Tue Jun 26, 2012 15:57
Location: albuquerque

Re: copied to new partition, UUIDs not correct

Postby sabayonino » Sun Oct 28, 2012 16:41

Did you install grub from Debian or Sabayon ?
User avatar
sabayonino
Sagely Hen
 
Posts: 1577
Joined: Sun Sep 21, 2008 1:12
Location: Italy

Re: copied to new partition, UUIDs not correct

Postby MALsPa » Sun Oct 28, 2012 17:20

grub2 on /dev/sda11 was installed from within Sabayon.

grub2 on MBR was installed in Debian.
MALsPa
Baby Hen
 
Posts: 13
Joined: Tue Jun 26, 2012 15:57
Location: albuquerque

Re: copied to new partition, UUIDs not correct

Postby sabayonino » Sun Oct 28, 2012 18:54

MALsPa wrote:grub2 on /dev/sda11 was installed from within Sabayon.

grub2 on MBR was installed in Debian.



so try to update grub from debian.
User avatar
sabayonino
Sagely Hen
 
Posts: 1577
Joined: Sun Sep 21, 2008 1:12
Location: Italy

Next

Return to Hardware

Who is online

Users browsing this forum: cmost and 1 guest