[SOLVED] Volume group not found on boot after rename

This forum is dedicated to basic help and support :

Ask here your questions about basic installation and usage of Mageia. For example you may post here all your questions about getting Mageia isos and installing it, configuring your printer, using your word processor etc.

Try to ask your questions in the right sub-forum with as much details as you can gather. the more precise the question will be, the more likely you are to get a useful answer

[SOLVED] Volume group not found on boot after rename

Postby nickdegraeve » May 14th, '24, 18:24

Ok, I messed up my system by renaming my main LVM volume group and logical volumes. When I boot I get
Volume group "fedora" not found.
Cannot process volume group fedora


How did I get here?
When I got my new pc I installed Fedora ( :oops: ) and I created a volume group and 3 logical volumes with the default values.
I think my layout was like this:
- Volume group: fedora
    - Logical volume: 00 (=swap)
    - Logical volume: 01 (= /, BTRFS)
    - Logical volume: 02 (= /home, BTRFS)
I have a EXT4 /boot partition outside the LVM, and some Windows partitions.
I didn't like Fedora after all and I installed Mageia 9, keeping the disk layout, only formatting the Linux partitions.
After several months of being very happy with Mageia I wanted to rename the VG and LVs to something more logical.
I used the LVM tooling to rename the VG to "linux" and the LVs to "swap", "root" and "home" respectively, thus ending up with
    - /dev/linux/swap
    - /dev/linux/root
    - /dev/linux/home
I edited /etc/fstab and /boot/grub2.cfg to reflect the changes and, in MCC I went through the Boot wizard that I thought would update/regenerate everything necessary.

Alas, it was not meant to be.
After a reboot I was greeted with the stated error. After some time I got dropped to the dracut prompt, as you can see in the attached screenshot.
Also attached is the report generated by dracut.

So, how can I can get out of this mess?
Attachments
rdsosreport.txt
Dracut report
(86.58 KiB) Downloaded 301 times
20240514_161254.jpg
Screenshot
20240514_161254.jpg (275.22 KiB) Viewed 8583 times
Last edited by nickdegraeve on May 17th, '24, 18:20, edited 1 time in total.
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: Volume group not found on boot after rename

Postby doktor5000 » May 14th, '24, 19:04

nickdegraeve wrote:I used the LVM tooling to rename the VG to "linux" and the LVs to "swap", "root" and "home" respectively, thus ending up with

That means what commands in particular, and in what order? And did you do that from the booted Mageia system ?
In the end you would have at least needed to run
Code: Select all
dracut -f --regenerate-all
as root to update all initrds.

Currently you'd need at at least any running system, e.g. boot from DVD then chroot to your Mageia box
Then the output as root of
Code: Select all
pvs
lvs
vgs


----
edit doktor5000: Sorry didn't notice the rdsosreport, that already contains the information. The VG seems to have been renamed to "linux"
Maybe it's already sufficient if you boot from DVD then chroot to your Mageia box. Then afterwards:

Code: Select all
pvscan --cache -aay

Then the output from the above commands.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18045
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Volume group not found on boot after rename

Postby nickdegraeve » May 14th, '24, 21:19

Ok, I couldn't get the Live iso to run, I always got a kernel panic, even with editing the boot params as per the Errata.
But the Rescue Mode works.
I don't know how to use chroot, though. So you'll have guide me some more, I'm afraid.

I did try the "Mount your partitions under /mnt" option:
20240514_203901.jpg
Mounting
20240514_203901.jpg (254.33 KiB) Viewed 8551 times

And then I ran your command, from the rescue console:
20240514_204257.jpg
Rescue console
20240514_204257.jpg (177.03 KiB) Viewed 8551 times
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: Volume group not found on boot after rename

Postby morgano » May 15th, '24, 11:01

For answers to your questions: not my cup of tea so i leave it to others... but meanwhile:

nickdegraeve wrote:Ok, I couldn't get the Live iso to run

What is the symptom?
Maybe Live boots if your system drive is not attached, then attach it later?

But the Rescue Mode works.

The rescue mode on your installed system or on Live?
At home & work Mandriva since 2006, Mageia 2011. Thinkpad T40, T43, T60, T400, T510, Dell M4400, M6300, Acer Aspire 7. Workstation using LVM, LUKS, VirtualBox, BOINC
morgano
 
Posts: 1489
Joined: Jun 15th, '11, 17:51
Location: Kivik, Sweden

Re: Volume group not found on boot after rename

Postby nickdegraeve » May 15th, '24, 11:44

morgano wrote:
nickdegraeve wrote:Ok, I couldn't get the Live iso to run

What is the symptom?
Maybe Live boots if your system drive is not attached, then attach it later?

I get a kernel panic each and everytime, even when I edit the boot params or use the non-free NVIDIA version as suggested by the Errata.
The system just freezes and I have to power off/on the pc.
20240514_193408.jpg
Kernel panic
20240514_193408.jpg (372.33 KiB) Viewed 8501 times

morgano wrote:
But the Rescue Mode works.

The rescue mode on your installed system or on Live?

That of the normal install image or the network install. The Live one doesn't seem to have a rescue mode.
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: Volume group not found on boot after rename

Postby morgano » May 15th, '24, 15:26

The SQUASHFS error is probably as it say: data probably corrupt. (The system on Live)
You should verify the Live ISO image you used to create the stick.
If ISO file is OK but still problem booting the USB stick, then the stick, connector or other part is probably bad, so try another stick and/or port.

One way to repair it instead of download the whole again is to start downloading as bittorrent, stop it, replace the partly downloaded file with the full but damaged you have, and restart the download, it will then check, and replace only parts.
At home & work Mandriva since 2006, Mageia 2011. Thinkpad T40, T43, T60, T400, T510, Dell M4400, M6300, Acer Aspire 7. Workstation using LVM, LUKS, VirtualBox, BOINC
morgano
 
Posts: 1489
Joined: Jun 15th, '11, 17:51
Location: Kivik, Sweden

Re: Volume group not found on boot after rename

Postby doktor5000 » May 15th, '24, 17:02

nickdegraeve wrote:But the Rescue Mode works.
I don't know how to use chroot, though. So you'll have guide me some more, I'm afraid.

I did try the "Mount your partitions under /mnt" option:

That looks fine, you got your filesystems mounted it seems. You only need to mount some pseudo-filesystems from the "outside" system for the chroot to work.

Code: Select all
mount -t proc proc /mnt/proc
mount -t sysfs sys /mnt/sys
mount -o bind /dev /mnt/dev

After that you can chroot into the system mounted unter /mnt
Code: Select all
chroot /mnt

Then do as I suggested previously. Although the system is working at that point it might be sufficient if you simply regenerate all initrds via dracut.
Then logout from the chroot and unmount everything under /mnt
Code: Select all
umount /mnt/{proc,sys,dev}
umount /mnt

and reboot
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18045
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Volume group not found on boot after rename

Postby nickdegraeve » May 16th, '24, 15:46

Ok, not there but
1. the Live distribution works. It was a corrupt download.
2. I haven't got my system back yet. It still drops down to dracut.
I must be doing something wrong, that's why I created a typescript of what I've done. I also included an updated rdsosreport from the latest boot attempt.
Attachments
typescript.txt
(10.51 KiB) Downloaded 359 times
rdsosreport[1].txt
(87.42 KiB) Downloaded 341 times
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: Volume group not found on boot after rename

Postby doktor5000 » May 16th, '24, 17:27

The typescript is fine, although the outputs mentioned previously from pvs/lvs/vgs would still be required from the installed system.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18045
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Volume group not found on boot after rename

Postby nickdegraeve » May 16th, '24, 19:22

Ok, here they are:
Code: Select all
  pvscan[2425] PV /dev/nvme0n1p5 online, VG linux is complete.
  pvscan[2425] VG linux run autoactivation.
  3 logical volume(s) in volume group "linux" now active

Code: Select all
  VG    #PV #LV #SN Attr   VSize   VFree
  linux   1   3   0 wz--n- 728.64g    0

Code: Select all
  PV             VG    Fmt  Attr PSize   PFree
  /dev/nvme0n1p5 linux lvm2 a--  728.64g    0

Code: Select all
  LV   VG    Attr       LSize   Pool Origin Data%  Meta%  Move Log Cpy%Sync Convert
  home linux -wi-ao---- 565.84g                                                   
  root linux -wi-ao---- 150.00g                                                   
  swap linux -wi-a-----  12.80g                                                   
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: Volume group not found on boot after rename

Postby doktor5000 » May 17th, '24, 00:54

That looks about right. Can you post your /etc/fstab from the rescue system in the chroot ?
By default the fstab entries contain the VG name, which you also need to change. Afterwards run
Code: Select all
dracut -f --regenerate-all
again, that should do it.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18045
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Volume group not found on boot after rename

Postby nickdegraeve » May 17th, '24, 06:44

I did edit /etc/fstab from the start so I thought this was ok:
Code: Select all
/dev/linux/root / btrfs noatime 1 1
# Entry for /dev/nvme0n1p6 :
UUID=92b3bed2-587e-45cd-b726-b0eb638b96b4 /boot ext4 defaults 1 2
# Entry for /dev/nvme0n1p1 :
UUID=12C2-B179 /boot/EFI vfat iocharset=utf8,umask=000 0 0
/dev/linux/home /home btrfs noatime 1 2
# Entry for /dev/nvme0n1p3 :
UUID=383EC3B83EC36E06 /media/windows ntfs-3g defaults,nofail,umask=000 0 0
192.168.1.2:/volume1/backups /mnt/ds/backups nfs _netdev,nosuid,wsize=8192,rsize=8192,soft,vers=4.0 0 0
192.168.1.2:/volume1/homes /mnt/ds/homes nfs _netdev,rsize=8192,nosuid,wsize=8192,soft,vers=4.0 0 0
192.168.1.2:/volume1/music /mnt/ds/music nfs _netdev,nosuid,wsize=8192,rsize=8192,soft,vers=4.0 0 0
192.168.1.2:/volume1/photo /mnt/ds/photo nfs _netdev,rsize=8192,nosuid,wsize=8192,soft,vers=4.0 0 0
192.168.1.2:/volume1/public /mnt/ds/public nfs _netdev,nosuid,rsize=8192,wsize=8192,soft,vers=4.0 0 0
192.168.1.2:/volume1/scans /mnt/ds/scans nfs _netdev,nosuid,wsize=8192,rsize=8192,soft,vers=4.0 0 0
192.168.1.2:/volume1/video /mnt/ds/video nfs _netdev,rsize=8192,nosuid,wsize=8192,soft,vers=4.0 0 0
none /proc proc defaults 0 0
/dev/linux/swap swap swap defaults 0 0

But obviously I must be missing something...
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: Volume group not found on boot after rename

Postby doktor5000 » May 17th, '24, 15:34

That looks fine for the VG.

Can you show your /boot/grub2/grub.cfg and /etc/dracut.conf.d/51-mageia-resume.conf from the installed system ?
Also from the installed system run the following and post the output here, although you manually need to mount /dev/nvme0n1p6 to /mnt/boot before you run chroot as you have a separate /boot partition
Code: Select all
lsinitrd /boot/initrd.img --unpack etc/cmdline.d/*
cat etc/cmdline.d/90lvm.conf
cat etc/cmdline.d/95root-dev.conf
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18045
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Volume group not found on boot after rename

Postby nickdegraeve » May 17th, '24, 18:19

ah, finally. Success!

51-mageia-resume.conf contained
Code: Select all
add_device+=" /dev/fedora/00 "

After I changed it to
Code: Select all
add_device+=" /dev/linux/root "

and ran
Code: Select all
dracut -f --regenerate-all

again, rebooted and tadaa!

Thanks for your patience.
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01

Re: [SOLVED] Volume group not found on boot after rename

Postby morgano » May 17th, '24, 18:56

Good work both of you :)
At home & work Mandriva since 2006, Mageia 2011. Thinkpad T40, T43, T60, T400, T510, Dell M4400, M6300, Acer Aspire 7. Workstation using LVM, LUKS, VirtualBox, BOINC
morgano
 
Posts: 1489
Joined: Jun 15th, '11, 17:51
Location: Kivik, Sweden

Re: Volume group not found on boot after rename

Postby doktor5000 » May 17th, '24, 19:00

nickdegraeve wrote:ah, finally. Success!

51-mageia-resume.conf contained
Code: Select all
add_device+=" /dev/fedora/00 "



Yeah, that always contains the swap device by default.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18045
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: [SOLVED] Volume group not found on boot after rename

Postby nickdegraeve » May 17th, '24, 19:34

doktor5000 wrote:Yeah, that always contains the swap device by default.

Then I made a mistake: I have put my root there. I'd forgotten "00" used to be "swap".
Fixed it already, though. And I didn't try to hibernate yet, so everything should be okay.
nickdegraeve
 
Posts: 51
Joined: Mar 18th, '12, 08:01


Return to Basic support

Who is online

Users browsing this forum: No registered users and 1 guest

cron