Skip to contentSkip to conversation

one PV crashed

linux-lvm Turbo Fredriksson 2 participants 13 messages Feb 1, 2002 – Feb 15, 2002

lore
Share & tools
lore
#0 lore raw

I have (had) 6 PV's in my VG. The last one crashed (the whole disk seems to have broken totaly).

It don't seem possible to restore the information (not without spending $$$ to a data recovery company), so how do I get the data stored on the OTHER disks?

[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)
pvscan -- inactive PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk" of VG "vg1" [5.87 GB / 0 free] pvscan -- inactive PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66" of VG "vg1" [1004.00 MB / 0 free] pvscan -- inactive PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH" of VG "vg1" [2.37 GB / 0 free] pvscan -- inactive PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK" of VG "vg1" [8.50 GB / 0 free] pvscan -- inactive PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2" of VG "vg1" [17.09 GB / 0 free] pvscan -- total: 5 [34.84 GB] / in use: 5 [34.84 GB] / in no VG: 0 [0]
[papadoc.root]# /etc/init.d/lvm start
Setting up LVM Volume Groups...
vgchange -- ERROR: physical volume "/dev/sdg1" of volume group "vg1" is offline
vgchange -- run vgscan
[papadoc.root]# vgscan
vgscan -- reading all physical volumes (this may take a while...)
vgscan -- "/etc/lvmtab" and "/etc/lvmtab.d" successfully created
vgscan -- WARNING: This program does not do a VGDA backup of your volume group
[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)

pvscan -- inactive PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2"  is associated to an unknown VG (run vgscan)

pvscan -- total: 5 [34.84 GB] / in use: 5 [34.84 GB] / in no VG: 0 [0]

This was the info the sg1 disk had:

PV#     PV Name    VG Name PV UUID                                 PV Size
6       /dev/sdg1  vg1     7x1CdK-50u6-NAmJ-6bHY-Ho09-U3hC-K7c18w  15.55 GB 0 free

World Trade Center FSF spy Nazi terrorist supercomputer cryptographic toluene [Hello to all my fans in domestic surveillance] assassination counter-intelligence Ft. Bragg subway Rule Psix security [See http://www.aclu.org/echelonwatch/index.html for more about this]

#1 lore raw
Quoted 6 lines · Turbo Fredriksson

I have (had) 6 PV's in my VG. The last one crashed (the whole disk seems to have broken totaly).

It don't seem possible to restore the information (not without spending $$$ to a data recovery company), so how do I get the data stored on the OTHER disks?

You don't spend a single dollar :-)

There's 2 solutions:

A:
--

Buy a replacemeent drive (say /dev/sdg1 ;-) and run

fdisk # to partition it the same way the broken one was pvcreate /dev/sdg1
vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/sdg1 vgscan

B:
--

If you don't have a replacement drive at hand you can even be faster by faking one (you must have loop configured in the kernel and use LVM 1.0.2):

dd if=/dev/zero of=/tmp/my_sdg1.vgda bs=1k count=512 losetup /dev/loop0 /tmp/my_sdg1.vgda
pvcreate /dev/loop0
vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /devloop0 vgscan

After either of the above aproaches you need to lvreduce/lvremove those LVs which had extents allocated on the failed drive.

You can figure out which those are by

pvdisplay -v /dev/sdg1

- or -

pvdisplay -v /dev/loop0

respectively.

If you had a replacement drive (case A), you can continue to use it because it will jsut be an empty PV which belonngs to your VG after the lvreduce/lvremove runs recommended above.

If you used the loop0 fake (case B) run

vgreduce vg1 /dev/loop0
losetup -d /dev/loop0
rm /tmp/my_sdg1.vgda

Hope that helps :-)

Regards,
Heinz -- The LVM Guy --

Quoted 37 lines

[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)
pvscan -- inactive PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk" of VG "vg1" [5.87 GB / 0 free] pvscan -- inactive PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66" of VG "vg1" [1004.00 MB / 0 free] pvscan -- inactive PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH" of VG "vg1" [2.37 GB / 0 free] pvscan -- inactive PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK" of VG "vg1" [8.50 GB / 0 free] pvscan -- inactive PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2" of VG "vg1" [17.09 GB / 0 free] pvscan -- total: 5 [34.84 GB] / in use: 5 [34.84 GB] / in no VG: 0 [0]
[papadoc.root]# /etc/init.d/lvm start
Setting up LVM Volume Groups...
vgchange -- ERROR: physical volume "/dev/sdg1" of volume group "vg1" is offline
vgchange -- run vgscan
[papadoc.root]# vgscan
vgscan -- reading all physical volumes (this may take a while...)
vgscan -- "/etc/lvmtab" and "/etc/lvmtab.d" successfully created
vgscan -- WARNING: This program does not do a VGDA backup of your volume group
[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)

pvscan -- inactive PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2"  is associated to an unknown VG (run vgscan)

pvscan -- total: 5 [34.84 GB] / in use: 5 [34.84 GB] / in no VG: 0 [0]

This was the info the sg1 disk had:

PV#     PV Name    VG Name PV UUID                                 PV Size
6       /dev/sdg1  vg1     7x1CdK-50u6-NAmJ-6bHY-Ho09-U3hC-K7c18w  15.55 GB 0 free

World Trade Center FSF spy Nazi terrorist supercomputer cryptographic toluene [Hello to all my fans in domestic surveillance] assassination counter-intelligence Ft. Bragg subway Rule Psix security [See http://www.aclu.org/echelonwatch/index.html for more about this]

Quoted 5 lines

_______________________________________________
linux-lvm mailing list
[email protected]
http://lists.sistina.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://www.sistina.com/lvm/Pages/howto.html

*** Software bugs are stupid.
Nevertheless it needs not so stupid people to solve them ***

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Heinz Mauelshagen Sistina Software Inc.
Senior Consultant/Developer Am Sonnenhang 11
56242 Marienrachdorf Germany
[email protected] +49 2626 141200

                                                       FAX 924446

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

#2 lore raw
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Heinz" == Heinz J Mauelshagen <[email protected]> writes:

Heinz> On Fri, Feb 01, 2002 at 11:01:22AM +0100, Turbo Fredriksson Heinz> wrote:
>> I have (had) 6 PV's in my VG. The last one crashed (the whole >> disk seems to have broken totaly).
>>
>> It don't seem possible to restore the information (not without >> spending $$$ to a data recovery company), so how do I get the >> data stored on the OTHER disks?

Heinz> You don't spend a single dollar :-)

I was referring to restore the lost data on the failed disk ..

Heinz> There's 2 solutions:

Heinz> A: --
Heinz> Buy a replacemeent drive (say /dev/sdg1 ;-) and run

Heinz> fdisk # to partition it the same way the broken one was Heinz> pvcreate /dev/sdg1 vgcfgrestore -f /etc/lvmconf/vg1.conf -n Heinz> vg1 /dev/sdg1 vgscan

I'll get a replacement from IBM (the disk is still on warranty), so I'd go for this...

Since I have data on the vg, will this still let me keep this, or will it be destroyed when doing the pvcreate/vgcfgrestore?

Heinz> B: --
Heinz> If you don't have a replacement drive at hand you can even Heinz> be faster by faking one (you must have loop configured in Heinz> the kernel and use LVM 1.0.2):

Heinz> dd if=/dev/zero of=/tmp/my_sdg1.vgda bs=1k count=512 Heinz> losetup /dev/loop0 /tmp/my_sdg1.vgda pvcreate /dev/loop0 Heinz> vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /devloop0 Heinz> vgscan

I'll do this as a temporary solution, while waiting for the replacement. Knowing IBM, it can take a while :)

Same question here, will the content on the VG be destroyed?

Heinz> Hope that helps :-)

It does (at least in the sense that I'll won't loose MORE data :) Thanx.

spy NORAD Peking domestic disruption Kennedy subway Ortega president quiche class struggle [Hello to all my fans in domestic surveillance] AK-47 CIA Ft. Bragg attack
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#3 lore raw
Quoted 7 lines · Turbo Fredriksson
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Heinz" == Heinz J Mauelshagen <[email protected]> writes:

Heinz> On Fri, Feb 01, 2002 at 11:01:22AM +0100, Turbo Fredriksson Heinz> wrote:
>> I have (had) 6 PV's in my VG. The last one crashed (the whole >> disk seems to have broken totaly).
>>

Quoted 7 lines

>> It don't seem possible to restore the information (not without >> spending $$$ to a data recovery company), so how do I get the >> data stored on the OTHER disks?

Heinz> You don't spend a single dollar :-)

I was referring to restore the lost data on the failed disk ..

Well, that's a different story :)

Quoted 6 lines

Heinz> There's 2 solutions:

Heinz> A: --
Heinz> Buy a replacemeent drive (say /dev/sdg1 ;-) and run

Quoted 6 lines

Heinz> fdisk # to partition it the same way the broken one was Heinz> pvcreate /dev/sdg1 vgcfgrestore -f /etc/lvmconf/vg1.conf -n Heinz> vg1 /dev/sdg1 vgscan

I'll get a replacement from IBM (the disk is still on warranty), so I'd go for this...

Ok.

Quoted 9 lines

Since I have data on the vg, will this still let me keep this, or will it be destroyed when doing the pvcreate/vgcfgrestore?

Heinz> B: --
Heinz> If you don't have a replacement drive at hand you can even Heinz> be faster by faking one (you must have loop configured in Heinz> the kernel and use LVM 1.0.2):

Quoted 7 lines

Heinz> dd if=/dev/zero of=/tmp/my_sdg1.vgda bs=1k count=512 Heinz> losetup /dev/loop0 /tmp/my_sdg1.vgda pvcreate /dev/loop0 Heinz> vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /devloop0 Heinz> vgscan

I'll do this as a temporary solution, while waiting for the replacement. Knowing IBM, it can take a while :)

No comment.

Quoted 7 lines

Same question here, will the content on the VG be destroyed?

Heinz> Hope that helps :-)

It does (at least in the sense that I'll won't loose MORE data :) Thanx.

Right.

Did you try it already with loop?

Quoted 11 lines

spy NORAD Peking domestic disruption Kennedy subway Ortega president quiche class struggle [Hello to all my fans in domestic surveillance] AK-47 CIA Ft. Bragg attack
[See http://www.aclu.org/echelonwatch/index.html for more about this]

_______________________________________________
linux-lvm mailing list
[email protected]
http://lists.sistina.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://www.sistina.com/lvm/Pages/howto.html

Signature · 15 lines
Regards,
Heinz    -- The LVM Guy --

*** Software bugs are stupid.
    Nevertheless it needs not so stupid people to solve them ***

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Heinz Mauelshagen                                 Sistina Software Inc.
Senior Consultant/Developer                       Am Sonnenhang 11
                                                  56242 Marienrachdorf
                                                  Germany
[email protected]                           +49 2626 141200
                                                       FAX 924446
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
#4 lore raw
Quoted 4 lines
Quoted 4 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Heinz" == Heinz J Mauelshagen <[email protected]> writes:

I'll do this as a temporary solution, while waiting for the
replacement. Knowing IBM, it can take a while :)

Heinz> No comment.

Ahh, a diplomat... That's rare in these day's n' age :)

Quoted 2 lines
Quoted 2 lines

It does (at least in the sense that I'll won't loose MORE data
:) Thanx.

Heinz> Right.

Heinz> Did you try it already with loop?

Not yet, I haven't dared :) I don't want to risk loosing what's left...

Ft. Bragg Iran Saddam Hussein cracking plutonium Peking pits kibo Ortega SDI Semtex Panama DES Marxist Waco, Texas
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#5 lore raw
In reply to Heinz J . Mauelshagen

Quoting "Heinz J . Mauelshagen" <[email protected]>:

Quoted 5 lines

dd if=/dev/zero of=/tmp/my_sdg1.vgda bs=1k count=512 losetup /dev/loop0 /tmp/my_sdg1.vgda
pvcreate /dev/loop0
vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /devloop0 vgscan

----- s n i p -----
[papadoc.root]# dd if=/dev/zero of=/var/my_sdg1.vgda bs=1k count=512 512+0 records in
512+0 records out
[papadoc.root]# losetup /dev/loop0 /var/my_sdg1.vgda [papadoc.root]# pvcreate /dev/loop0
pvcreate -- physical volume "/dev/loop0" successfully created

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/loop0 vgcfgrestore -- physical volume "/dev/loop0" doesn't belong to volume group "vg1"

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/loop0 vgcfgrestore -- ERROR "pv_read(): pv_create_name_from_kdev_t" reading physical volume "/dev/loop0"

[papadoc.root]# vgscan
vgscan -- reading all physical volumes (this may take a while...) vgscan -- "/etc/lvmtab" and "/etc/lvmtab.d" successfully created vgscan -- WARNING: This program does not do a VGDA backup of your volume group

----- s n i p -----

Quoted 1 line

pvdisplay -v /dev/loop0

----- s n i p -----
[papadoc.root]# pvdisplay -v /dev/loop0
pvdisplay -- getting physical volume size
pvdisplay -- ERROR "pv_read(): pv_create_name_from_kdev_t" no VALID physical volume "/dev/loop0"

----- s n i p -----

Panama Soviet Iran North Korea Kennedy smuggle Cocaine Ft. Meade 747 toluene 767 Qaddafi kibo cryptographic Clinton
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#6 lore raw

Quoting Turbo Fredriksson <[email protected]>:

Quoted 9 lines

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/loop0 vgcfgrestore -- physical volume "/dev/loop0" doesn't belong to volume group "vg1"

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/loop0 vgcfgrestore -- ERROR "pv_read(): pv_create_name_from_kdev_t" reading physical volume "/dev/loop0"

[papadoc.root]# pvdisplay -v /dev/loop0
pvdisplay -- getting physical volume size
pvdisplay -- ERROR "pv_read(): pv_create_name_from_kdev_t" no VALID physical volume "/dev/loop0"

Does anyone have a solution to this? What am I doing wrong?

SEAL Team 6 Iran killed KGB Kennedy Treasury cracking Semtex quiche strategic radar Honduras Legion of Doom nitrate PLO
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#7 lore raw
Quoted 8 lines · Turbo Fredriksson

Quoting Turbo Fredriksson <[email protected]>:

Quoted 6 lines

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/loop0 vgcfgrestore -- physical volume "/dev/loop0" doesn't belong to volume group "vg1"

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/loop0 vgcfgrestore -- ERROR "pv_read(): pv_create_name_from_kdev_t" reading physical volume "/dev/loop0"

Quoted 6 lines
Quoted 3 lines

[papadoc.root]# pvdisplay -v /dev/loop0
pvdisplay -- getting physical volume size
pvdisplay -- ERROR "pv_read(): pv_create_name_from_kdev_t" no VALID physical volume "/dev/loop0"

Does anyone have a solution to this? What am I doing wrong?

Turbo,

you seem to be using an older LVM version with broken loop support :-( Found a bug in vgcfgrestore(8) which will likely cause problems with this too. More to follow...

Quoted 11 lines

SEAL Team 6 Iran killed KGB Kennedy Treasury cracking Semtex quiche strategic radar Honduras Legion of Doom nitrate PLO
[See http://www.aclu.org/echelonwatch/index.html for more about this]

_______________________________________________
linux-lvm mailing list
[email protected]
http://lists.sistina.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://www.sistina.com/lvm/Pages/howto.html

Signature · 15 lines
Regards,
Heinz    -- The LVM Guy --

*** Software bugs are stupid.
    Nevertheless it needs not so stupid people to solve them ***

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Heinz Mauelshagen                                 Sistina Software Inc.
Senior Consultant/Developer                       Am Sonnenhang 11
                                                  56242 Marienrachdorf
                                                  Germany
[email protected]                           +49 2626 141200
                                                       FAX 924446
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
#8 lore raw

Quoting "Heinz J . Mauelshagen" <[email protected]>:

Quoted 14 lines · Turbo Fredriksson
Quoted 13 lines

Quoting Turbo Fredriksson <[email protected]>:

Quoted 9 lines

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/loop0 vgcfgrestore -- physical volume "/dev/loop0" doesn't belong to volume group "vg1"

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/loop0 vgcfgrestore -- ERROR "pv_read(): pv_create_name_from_kdev_t" reading physical volume "/dev/loop0"

[papadoc.root]# pvdisplay -v /dev/loop0
pvdisplay -- getting physical volume size
pvdisplay -- ERROR "pv_read(): pv_create_name_from_kdev_t" no VALID physical volume "/dev/loop0"

Quoted 7 lines
Quoted 1 line

Does anyone have a solution to this? What am I doing wrong?

Turbo,

you seem to be using an older LVM version with broken loop support :-( Found a bug in vgcfgrestore(8) which will likely cause problems with this too. More to follow...

Dang! My LVM version is: 1.0.1-rc4

I'll try the other solution, with a separate harddisk. I borrowed a 18Gb disk to at least hold SOME of the data I and my users are collecting (mail etc) :)

smuggle Honduras Iran class struggle Treasury PLO Serbian colonel spy nuclear president FSF assassination Soviet kibo
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#9 lore raw
In reply to Heinz J . Mauelshagen

Quoting "Heinz J . Mauelshagen" <[email protected]>:

Quoted 6 lines

Buy a replacemeent drive (say /dev/sdg1 ;-) and run

fdisk # to partition it the same way the broken one was pvcreate /dev/sdg1
vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/sdg1 vgscan

Oki, since I had a LVM with broken loop support, I'll try with a spare disk...

----- s n i p -----
[papadoc.root]# pvcreate /dev/sdh1
pvcreate -- physical volume "/dev/sdh1" successfully created

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 /dev/sdh1 vgcfgrestore -- physical volume "/dev/sdh1" doesn't belong to volume group "vg1"

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/sdh1 vgcfgrestore -- size of physical volume /dev/sdh1 differs from backup ----- s n i p -----

I'm not sure exactly how big my previous (now crashed) sdg disk was, or how big the sdg1 partition was...

How do I:

1. Find out _exactly_ how big the sdg1 partition was (the only number I have is '15.5Gb')?
or
2. Use the existing sdh1 even though the size don't match?

Quoted 6 lines

After either of the above aproaches you need to lvreduce/lvremove those LVs which had extents allocated on the failed drive.

You can figure out which those are by

pvdisplay -v /dev/sdg1

----- s n i p ----
[papadoc.root]# pvdisplay -v /dev/sdh1
pvdisplay -- getting physical volume size pvdisplay -- "/dev/sdh1" is a new physical volume of 2.22 GB ----- s n i p ----

Not nearly the same size as the original sdg1, but....

cracking Saddam Hussein Albanian class struggle smuggle BATF Legion of Doom Cuba ammonium DES 747 767 pits Serbian plutonium
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#10 lore raw
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Turbo" == Turbo Fredriksson <[email protected]> writes:

Turbo> Oki, since I had a LVM with broken loop support, I'll try Turbo> with a spare disk...

Turbo> [papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n Turbo> vg1 -o /dev/sdg1 /dev/sdh1 vgcfgrestore -- size of physical Turbo> volume /dev/sdh1 differs from backup ----- s n i p -----

Turbo> I'm not sure exactly how big my previous (now crashed) sdg Turbo> disk was, or how big the sdg1 partition was...

Oki, I managed to pvcreate my new sdh1, and then a vgcfgrestore.

vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/sdh1

This went ok, but 'pvscan -u' is behaving (?) strangly...

----- s n i p -----
[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)

pvscan -- inactive PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK"  is associated to an unknown VG (run vgscan)
pvscan -- inactive PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2"  is associated to an unknown VG (run vgscan)

pvscan -- inactive PV "/dev/sdh1 " with UUID "ZNODti-EFFz-rGID-HYyh-kg7Z-yDCe-LLbXBv" is in no VG [15.55 GB] pvscan -- total: 6 [50.39 GB] / in use: 5 [34.84 GB] / in no VG: 1 [15.55 GB]
----- s n i p -----

Running vgscan (as directed) gives me:

----- s n i p -----
[papadoc.root]# vgscan
vgscan -- reading all physical volumes (this may take a while...) vgscan -- "/etc/lvmtab" and "/etc/lvmtab.d" successfully created vgscan -- WARNING: This program does not do a VGDA backup of your volume group ----- s n i p -----

Ideas how to get my VG up and running again?

cryptographic Ft. Bragg NORAD plutonium 747 Legion of Doom Serbian Saddam Hussein munitions Noriega supercomputer colonel fissionable smuggle kibo
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#11 lore raw
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Turbo" == Turbo Fredriksson <[email protected]> writes:

Turbo> This went ok, but 'pvscan -u' is behaving (?) strangly...

Shutting down (vgchange -a n), doing the vgcfgrestore, and then starting it again (vgchange -a y) gave me this:

----- s n i p -----
[papadoc.root]# /etc/init.d/lvm stop
Shutting down LVM Volume Groups...
vgchange -- no volume groups found

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/sdh1 vgcfgrestore -- VGDA for "vg1" successfully restored to physical volume "/dev/sdh1" vgcfgrestore -- you may not have an actual backup of restored volume group "vg1"

[papadoc.root]# /etc/init.d/lvm start
Setting up LVM Volume Groups...
vgchange -- volume group "vg1" successfully activated

[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)

pvscan -- ACTIVE   PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk" of VG "vg1" [5.87 GB / 0 free]
pvscan -- ACTIVE   PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66" of VG "vg1" [1004.00 MB / 0 free]
pvscan -- ACTIVE   PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH" of VG "vg1" [2.37 GB / 0 free]
pvscan -- ACTIVE   PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK" of VG "vg1" [8.50 GB / 0 free]
pvscan -- ACTIVE   PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2" of VG "vg1" [17.09 GB / 0 free]

pvscan -- inactive PV "/dev/sdh1 " with UUID "ZNODti-EFFz-rGID-HYyh-kg7Z-yDCe-LLbXBv" is in no VG [15.55 GB] pvscan -- total: 6 [50.39 GB] / in use: 5 [34.84 GB] / in no VG: 1 [15.55 GB]
----- s n i p -----

I'm getting so close, I can SMELL the coffey! :)

Why is sdh1 inactive?

Qaddafi NSA Treasury NORAD FBI smuggle Saddam Hussein Kennedy Soviet jihad bomb genetic Khaddafi pits quiche
[See http://www.aclu.org/echelonwatch/index.html for more about this]

#12 lore raw

Turbo,

did you run "vgscan" *before* the "vgchange -ay"? Not running it could explain the inactive PV on /dev/sdh1.

Quoted 45 lines · Turbo Fredriksson
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Turbo" == Turbo Fredriksson <[email protected]> writes:

Turbo> This went ok, but 'pvscan -u' is behaving (?) strangly...

Shutting down (vgchange -a n), doing the vgcfgrestore, and then starting it again (vgchange -a y) gave me this:

----- s n i p -----
[papadoc.root]# /etc/init.d/lvm stop
Shutting down LVM Volume Groups...
vgchange -- no volume groups found

[papadoc.root]# vgcfgrestore -f /etc/lvmconf/vg1.conf -n vg1 -o /dev/sdg1 /dev/sdh1 vgcfgrestore -- VGDA for "vg1" successfully restored to physical volume "/dev/sdh1" vgcfgrestore -- you may not have an actual backup of restored volume group "vg1"

[papadoc.root]# /etc/init.d/lvm start
Setting up LVM Volume Groups...
vgchange -- volume group "vg1" successfully activated

[papadoc.root]# pvscan -u
pvscan -- reading all physical volumes (this may take a while...)

pvscan -- ACTIVE   PV "/dev/sdb1 " with UUID "ofZCeT-O16H-Df0h-4KoB-xQhm-lc24-67dZvk" of VG "vg1" [5.87 GB / 0 free]
pvscan -- ACTIVE   PV "/dev/sdc1 " with UUID "xN0MF7-xKU0-Uk3L-g8Pw-0YfH-fS3V-zgFA66" of VG "vg1" [1004.00 MB / 0 free]
pvscan -- ACTIVE   PV "/dev/sdd10" with UUID "5V0XNB-gA87-OU66-1iza-cvsz-xQ2q-6DEbyH" of VG "vg1" [2.37 GB / 0 free]
pvscan -- ACTIVE   PV "/dev/sde1 " with UUID "Bdm7PX-50Dq-hC6R-yXmv-DDq1-n6Nx-4ohaKK" of VG "vg1" [8.50 GB / 0 free]
pvscan -- ACTIVE   PV "/dev/sdf1 " with UUID "QnqfyA-fOTB-J1Pp-4be5-t6QU-bGjS-i2BKf2" of VG "vg1" [17.09 GB / 0 free]

pvscan -- inactive PV "/dev/sdh1 " with UUID "ZNODti-EFFz-rGID-HYyh-kg7Z-yDCe-LLbXBv" is in no VG [15.55 GB] pvscan -- total: 6 [50.39 GB] / in use: 5 [34.84 GB] / in no VG: 1 [15.55 GB]
----- s n i p -----

I'm getting so close, I can SMELL the coffey! :)

Why is sdh1 inactive?

Qaddafi NSA Treasury NORAD FBI smuggle Saddam Hussein Kennedy Soviet jihad bomb genetic Khaddafi pits quiche
[See http://www.aclu.org/echelonwatch/index.html for more about this]

_______________________________________________
linux-lvm mailing list
[email protected]
http://lists.sistina.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://www.sistina.com/lvm/Pages/howto.html

Signature · 15 lines
Regards,
Heinz    -- The LVM Guy --

*** Software bugs are stupid.
    Nevertheless it needs not so stupid people to solve them ***

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

Heinz Mauelshagen                                 Sistina Software Inc.
Senior Consultant/Developer                       Am Sonnenhang 11
                                                  56242 Marienrachdorf
                                                  Germany
[email protected]                           +49 2626 141200
                                                       FAX 924446
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-