I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing.
I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it?
Running vgscan returns:-
Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
On Thu, Mar 20, 2008 at 2:18 PM, Chris G cl@isbd.net wrote:
I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing.
I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it?
Running vgscan returns:-
Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
Could you try vgrename? "man vgrename" for more info.
From man page - vgrename /dev/vg02 /dev/my_volume_group renames existing
volume group "vg02" to "my_volume_group".
-- Chris Green
-- fedora-list mailing list fedora-list@redhat.com To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
On Thu, 2008-03-20 at 08:48 +0000, Chris G wrote:
I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing.
I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it?
Running vgscan returns:-
Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
-- Chris Green
Actually its a real pain the ***. Bee there, done that. For future reference- when installing change the name of the fs to the machine name. Saves these sorts of issues, I found this out the hard way and came across this gem on the net.
Forgive me for going into a taboo area, but the way I fixed it (vgrename won't work in this case I reckon- please try though) was to throw an Ubuntu live disk in the cdrom and boot, download lvm2 from the Ubuntu repo (Debian won't work- although if Debian make a live disk then use their repo). Run update software and run the vgrename from there. If you need root password then (it seems a little redundant but anyway... it works for me...) go to administration and users and change the root password there.
Seeing you can't have both disks with the same name at the same time, you'll need to change the name of your current disk. If you reboot it will fail once you've renamed, so make sure you change your grub, init file, and mount your main lvm partition and change your inittab file to match your new name.
This is very involved, I know, so ensure you have an instruction web page up there to follow from. Run a google search on how to use Ubuntu to rectify an lvm. If you find the right one, it'll have all the instructions you need- except for the inittab: found that out the hard way. If you don't fix that, you get a selinux error and it won't boot properly.
Good luck
On Thu, Mar 20, 2008 at 08:12:05PM +1000, Da Rock wrote:
On Thu, 2008-03-20 at 08:48 +0000, Chris G wrote:
I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing.
I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it?
Running vgscan returns:-
Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
-- Chris Green
Actually its a real pain the ***. Bee there, done that. For future reference- when installing change the name of the fs to the machine name. Saves these sorts of issues, I found this out the hard way and came across this gem on the net.
Forgive me for going into a taboo area, but the way I fixed it (vgrename won't work in this case I reckon- please try though) was to throw an Ubuntu live disk in the cdrom and boot, download lvm2 from the Ubuntu repo (Debian won't work- although if Debian make a live disk then use their repo). Run update software and run the vgrename from there. If you need root password then (it seems a little redundant but anyway... it works for me...) go to administration and users and change the root password there.
You can use the install/recovery disc for Fedora. On the command line, you'll have to prefix the lvm commands with lvm, like this:
lvm pvscan lvm vgscan lvm vgchange ...
Seeing you can't have both disks with the same name at the same time, you'll need to change the name of your current disk. If you reboot it will fail once you've renamed, so make sure you change your grub, init file, and mount your main lvm partition and change your inittab file to match your new name.
You mean: 1. edit grub.conf, change root= to the new name 2. edit etc/fstab, change swap, root, etc. to use new name 3. re-create initrd, as it has the vg name hardcoded: mkinitrd -f -v /boot/initrd-`uname -r`.img `uname -r`
You can do this while the system is running, and then reboot. No need for recovery/lice cd (if everything goes fine; you'll need it if the system no longer boots).
This is very involved, I know, so ensure you have an instruction web page up there to follow from. Run a google search on how to use Ubuntu to rectify an lvm. If you find the right one, it'll have all the instructions you need- except for the inittab: found that out the hard way. If you don't fix that, you get a selinux error and it won't boot properly.
I think you're confusing inittab with fstab (or initrd). The inittab file has no reference to the root device.
Good luck
Yeah, that's always needed.
I'd suggest that new Fedora releases create a random name for the VG and that their initrd/nash support getting the vg from the root= kernel command line.
Regards, Luciano Rocha
On Thu, 2008-03-20 at 20:12 +1000, Da Rock wrote:
On Thu, 2008-03-20 at 08:48 +0000, Chris G wrote:
I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing.
I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it?
Running vgscan returns:-
Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
-- Chris Green
Actually its a real pain the ***. Bee there, done that. For future reference- when installing change the name of the fs to the machine name. Saves these sorts of issues, I found this out the hard way and came across this gem on the net.
Forgive me for going into a taboo area, but the way I fixed it (vgrename won't work in this case I reckon- please try though) was to throw an Ubuntu live disk in the cdrom and boot, download lvm2 from the Ubuntu repo (Debian won't work- although if Debian make a live disk then use their repo). Run update software and run the vgrename from there. If you need root password then (it seems a little redundant but anyway... it works for me...) go to administration and users and change the root password there.
Seeing you can't have both disks with the same name at the same time, you'll need to change the name of your current disk. If you reboot it will fail once you've renamed, so make sure you change your grub, init file, and mount your main lvm partition and change your inittab file to match your new name.
This is very involved, I know, so ensure you have an instruction web page up there to follow from. Run a google search on how to use Ubuntu to rectify an lvm. If you find the right one, it'll have all the instructions you need- except for the inittab: found that out the hard way. If you don't fix that, you get a selinux error and it won't boot properly.
Good luck
Excuse me - fstab, not inittab.
On Thu, 2008-03-20 at 10:22 +0000, Luciano Rocha wrote:
On Thu, Mar 20, 2008 at 08:12:05PM +1000, Da Rock wrote:
On Thu, 2008-03-20 at 08:48 +0000, Chris G wrote:
I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing.
I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it?
Running vgscan returns:-
Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
-- Chris Green
Actually its a real pain the ***. Bee there, done that. For future reference- when installing change the name of the fs to the machine name. Saves these sorts of issues, I found this out the hard way and came across this gem on the net.
Forgive me for going into a taboo area, but the way I fixed it (vgrename won't work in this case I reckon- please try though) was to throw an Ubuntu live disk in the cdrom and boot, download lvm2 from the Ubuntu repo (Debian won't work- although if Debian make a live disk then use their repo). Run update software and run the vgrename from there. If you need root password then (it seems a little redundant but anyway... it works for me...) go to administration and users and change the root password there.
You can use the install/recovery disc for Fedora. On the command line, you'll have to prefix the lvm commands with lvm, like this:
lvm pvscan lvm vgscan lvm vgchange ...
Good to know- a shortcut. Is this under repair on the install cd?
Seeing you can't have both disks with the same name at the same time, you'll need to change the name of your current disk. If you reboot it will fail once you've renamed, so make sure you change your grub, init file, and mount your main lvm partition and change your inittab file to match your new name.
You mean:
- edit grub.conf, change root= to the new name
- edit etc/fstab, change swap, root, etc. to use new name
- re-create initrd, as it has the vg name hardcoded: mkinitrd -f -v /boot/initrd-`uname -r`.img `uname -r`
You can do this while the system is running, and then reboot. No need for recovery/lice cd (if everything goes fine; you'll need it if the system no longer boots).
Surely not if you've just changed the name using the repair disk? But very succinctly put- I've only done this once and it took several hours following from instructions on a page. I had trouble remembering the exact steps myself.
This is very involved, I know, so ensure you have an instruction web page up there to follow from. Run a google search on how to use Ubuntu to rectify an lvm. If you find the right one, it'll have all the instructions you need- except for the inittab: found that out the hard way. If you don't fix that, you get a selinux error and it won't boot properly.
I think you're confusing inittab with fstab (or initrd). The inittab file has no reference to the root device.
Yes, I do apologise for the confusion. I rectified that in a later email.
Good luck
Yeah, that's always needed.
I'd suggest that new Fedora releases create a random name for the VG and that their initrd/nash support getting the vg from the root= kernel command line.
Regards, Luciano Rocha
You don't think setting it to the machine name is any good? Given current install procedures, what do you suggest to prevent this? Obviously something manually.
On Thu, Mar 20, 2008 at 03:23:08PM +0530, Anoop Chandran wrote:
On Thu, Mar 20, 2008 at 2:18 PM, Chris G <[1]cl@isbd.net> wrote:
I have just had Fedora 7 re-installed on my work desktop as the old disk drive was slowly failing. I need to access the old disk if I can, it's still in the system and visible but the person who installed it didn't change volume groups so I have two disk drives with the same volume group. How do I change the name of the old disk's volume group so I can mount it and see it? Running vgscan returns:- Reading all physical volumes. This may take a while... WARNING: Duplicate VG name VolGroup00: Existing P6sqp0-rIos-JYmi-8L32-ymtN-LzB4-g5BdLL (created here) takes precedence over TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI Found volume group "VolGroup00" using metadata type lvm2 Found volume group "VolGroup00" using metadata type lvm2
Could you try vgrename? "man vgrename" for more info. From man page - vgrename /dev/vg02 /dev/my_volume_group renames existing volume group "vg02" to "my_volume_group".
Ah, but they're *both* called /dev/vg02 so that's no help.
However it turns out that vgrename understands UUIDs so the following works:-
vgrename TdWFKp-H4tw-UrVq-Jmre-26hv-zmyE-IZXQLI MyVolGroup
It's not immediately clear from the man page that this works, but it does - phew!
On Thu, Mar 20, 2008 at 08:58:04PM +1000, Da Rock wrote:
On Thu, 2008-03-20 at 10:22 +0000, Luciano Rocha wrote:
You can use the install/recovery disc for Fedora. On the command line, you'll have to prefix the lvm commands with lvm, like this:
lvm pvscan lvm vgscan lvm vgchange ...
Good to know- a shortcut. Is this under repair on the install cd?
Yes, or you can boot to the installation screen, then switch to the 2nd console (ctrl+alt+f2), where you'll find a command prompt.
- edit grub.conf, change root= to the new name
- edit etc/fstab, change swap, root, etc. to use new name
- re-create initrd, as it has the vg name hardcoded: mkinitrd -f -v /boot/initrd-`uname -r`.img `uname -r`
You can do this while the system is running, and then reboot. No need for recovery/lice cd (if everything goes fine; you'll need it if the system no longer boots).
Surely not if you've just changed the name using the repair disk? But very succinctly put- I've only done this once and it took several hours following from instructions on a page. I had trouble remembering the exact steps myself.
Yes, if the change was made in the repair disk, the kernel version will probably be different, and the paths are relative to the system's root.
But the rename can be done while the system is running, so only the followin pass is missing: 0. vgrename ...
I'd suggest that new Fedora releases create a random name for the VG and that their initrd/nash support getting the vg from the root= kernel command line.
Regards, Luciano Rocha
You don't think setting it to the machine name is any good? Given current install procedures, what do you suggest to prevent this? Obviously something manually.
Currently the filesystem is defined before the network (and, thus, the hostname). Also, you might have two different installations with the same hostname (like a new install to a new set of hard disks).
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
Regards, Luciano Rocha
On Thu, 2008-03-20 at 11:38 +0000, Luciano Rocha wrote:
On Thu, Mar 20, 2008 at 08:58:04PM +1000, Da Rock wrote:
On Thu, 2008-03-20 at 10:22 +0000, Luciano Rocha wrote:
You can use the install/recovery disc for Fedora. On the command line, you'll have to prefix the lvm commands with lvm, like this:
lvm pvscan lvm vgscan lvm vgchange ...
Good to know- a shortcut. Is this under repair on the install cd?
Yes, or you can boot to the installation screen, then switch to the 2nd console (ctrl+alt+f2), where you'll find a command prompt.
- edit grub.conf, change root= to the new name
- edit etc/fstab, change swap, root, etc. to use new name
- re-create initrd, as it has the vg name hardcoded: mkinitrd -f -v /boot/initrd-`uname -r`.img `uname -r`
You can do this while the system is running, and then reboot. No need for recovery/lice cd (if everything goes fine; you'll need it if the system no longer boots).
Surely not if you've just changed the name using the repair disk? But very succinctly put- I've only done this once and it took several hours following from instructions on a page. I had trouble remembering the exact steps myself.
Yes, if the change was made in the repair disk, the kernel version will probably be different, and the paths are relative to the system's root.
But the rename can be done while the system is running, so only the followin pass is missing: 0. vgrename ...
I'd suggest that new Fedora releases create a random name for the VG and that their initrd/nash support getting the vg from the root= kernel command line.
Regards, Luciano Rocha
You don't think setting it to the machine name is any good? Given current install procedures, what do you suggest to prevent this? Obviously something manually.
Currently the filesystem is defined before the network (and, thus, the hostname). Also, you might have two different installations with the same hostname (like a new install to a new set of hard disks).
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
Regards, Luciano Rocha
Good to know. Thanks
Luciano Rocha wrote:
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
That doesn't sound particularly unique to me. If you set up a dual/multi boot machine you'll probably want it to have the same hostname regardless of the boot choice, and you are likely to install the whole thing in the same day.
On Thu, Mar 20, 2008 at 08:46:41AM -0500, Les Mikesell wrote:
Luciano Rocha wrote:
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
That doesn't sound particularly unique to me. If you set up a dual/multi boot machine you'll probably want it to have the same hostname regardless of the boot choice, and you are likely to install the whole thing in the same day.
I wasn't talking of changing the hostname to include the date, but of changing the VG to include the hostname *and* the date.
On Thu, Mar 20, 2008 at 01:51:53PM +0000, Luciano Rocha wrote:
On Thu, Mar 20, 2008 at 08:46:41AM -0500, Les Mikesell wrote:
Luciano Rocha wrote:
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
That doesn't sound particularly unique to me. If you set up a dual/multi boot machine you'll probably want it to have the same hostname regardless of the boot choice, and you are likely to install the whole thing in the same day.
I wasn't talking of changing the hostname to include the date, but of changing the VG to include the hostname *and* the date.
Sorry, I didn't parse your message correctly.
Usually, you'd want to use the same VG for both installs. Otherwise, the VG name will have to include a sequential number, and then be dependent of installing with any other VG available.
Then we'd have: hostnameYYMMDDseqseq
The bigger it gets, the uglier it gets, but I don't see a solution besides forcing the definition of the name by the user. That way, at least the fault would reside completely with the user. ;)
VolGroup00/LogVol00 just isn't pretty, useful or conflict-free.
Luciano Rocha wrote:
On Thu, Mar 20, 2008 at 08:46:41AM -0500, Les Mikesell wrote:
Luciano Rocha wrote:
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
That doesn't sound particularly unique to me. If you set up a dual/multi boot machine you'll probably want it to have the same hostname regardless of the boot choice, and you are likely to install the whole thing in the same day.
I wasn't talking of changing the hostname to include the date, but of changing the VG to include the hostname *and* the date.
I thought the object here was to ensure that the VG's created by the separate installs of a multi-boot host did not get the same automatically-assigned name. You need the same thing for filesystem labels, especially if you move disks around.
On Thu, Mar 20, 2008 at 10:19:14AM -0500, Les Mikesell wrote:
Luciano Rocha wrote:
On Thu, Mar 20, 2008 at 08:46:41AM -0500, Les Mikesell wrote:
Luciano Rocha wrote:
But I do use the hostname as the VG, so I think that's best, probably with current date appended (like: hostname080320).
That doesn't sound particularly unique to me. If you set up a dual/multi boot machine you'll probably want it to have the same hostname regardless of the boot choice, and you are likely to install the whole thing in the same day.
I wasn't talking of changing the hostname to include the date, but of changing the VG to include the hostname *and* the date.
I thought the object here was to ensure that the VG's created by the separate installs of a multi-boot host did not get the same automatically-assigned name. You need the same thing for filesystem labels, especially if you move disks around.
You're right, I misunderstood your e-mail. Please see my reply to my reply to your reply...
Regards, Luciano Rocha
On Thu, 2008-03-20 at 20:58 +1000, Da Rock wrote:
You don't think setting it to the machine name is any good?
Well, if you change drives in the same machine, that rule still leaves you with two like-named volume groups. You want different names per drive, so that they don't clash when both are connected to the same box.
Personally, I take the approach of physically naming the drives, as well as the software label. I write a name on them with texta, and add that as a prefix or suffix to volume labels. e.g. "fred-boot" That way I can tell what's what, in or out of the box. That's especially handy if you have otherwise identical drive models.