linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
* [linux-lvm] Accidental removal of logical volume - any way to salvage?
@ 2006-02-05 17:53 Martin Lindquist
  2006-02-05 17:58 ` Alasdair G Kergon
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Lindquist @ 2006-02-05 17:53 UTC (permalink / raw)
  To: linux-lvm

[-- Attachment #1: Type: text/plain, Size: 1171 bytes --]

Ok, here's the situation:

I have a volume group consisting of two whole disk partitions, on top of
which I used to have a full size logical volume containing data of system
non-critical but nevertheless important nature. After deciding to replace a
lot of the hardware in the machine (and to reinstall the system) I realized
that I would first need to export the volume group or I could be in for a
lot of trouble (lesson learned from previous experience). To make a long and
stupid story (for which I have no defense) a lot shorter; I did 'lvremove
main' ("main" being the name of the lv in question), ran 'vgexport rajd'
("rajd" being the vg), backed up a lot of files (including /etc and most of
/var), replaced the hardware, reinstalled the system, ran 'vgimport rajd'
and only then realized what 'lvremove' really did.

Now, instead of getting questions like "what did you think 'lvremove main'
would do?" or "are you the result of several generations of inbreeding?",
could anyone first of all tell me if there is any way at all to salvage the
data from the logical volume "main"? If there is I would love to find out
how.


Regards,
Martin

[-- Attachment #2: Type: text/html, Size: 1231 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [linux-lvm] Accidental removal of logical volume - any way to salvage?
  2006-02-05 17:53 [linux-lvm] Accidental removal of logical volume - any way to salvage? Martin Lindquist
@ 2006-02-05 17:58 ` Alasdair G Kergon
  2006-02-05 18:05   ` Martin Lindquist
  0 siblings, 1 reply; 5+ messages in thread
From: Alasdair G Kergon @ 2006-02-05 17:58 UTC (permalink / raw)
  To: LVM general discussion and development

On Sun, Feb 05, 2006 at 06:53:45PM +0100, Martin Lindquist wrote:
> could anyone first of all tell me if there is any way at all to salvage the
> data from the logical volume "main"? 

man vgcfgrestore if you retained metadata backups from /etc from before
you deleted the LV.

Failing that, if you're using LVM2 you might still be able to salvage
the metadata from the from the front of the disk.

Alasdair
-- 
agk@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [linux-lvm] Accidental removal of logical volume - any way to salvage?
  2006-02-05 17:58 ` Alasdair G Kergon
@ 2006-02-05 18:05   ` Martin Lindquist
  2006-02-05 20:54     ` Alasdair G Kergon
  0 siblings, 1 reply; 5+ messages in thread
From: Martin Lindquist @ 2006-02-05 18:05 UTC (permalink / raw)
  To: LVM general discussion and development

[-- Attachment #1: Type: text/plain, Size: 1225 bytes --]

First of all, thank you for a fast response.

The backup of /etc was done after running 'lvremove' and 'vgexport' so if I
understand you correctly that won't do any good.

Yes, I am using LVM2. How do I salvage the metadata "from the front of the
disk?"

Regards,
Martin

2006/2/5, Alasdair G Kergon <agk@redhat.com>:
>
> On Sun, Feb 05, 2006 at 06:53:45PM +0100, Martin Lindquist wrote:
> > could anyone first of all tell me if there is any way at all to salvage
> the
> > data from the logical volume "main"?
>
> man vgcfgrestore if you retained metadata backups from /etc from before
> you deleted the LV.
>
> Failing that, if you're using LVM2 you might still be able to salvage
> the metadata from the from the front of the disk.
>
> Alasdair
> --
> agk@redhat.com
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@redhat.com
> https://www.redhat.com/mailman/listinfo/linux-lvm
> read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
>



--
Martin Lindquist
IRC: nms @ irc.freenode.net, irc.vapor.com and irc.gimp.org
E-mail: black.ant@gmail.com
ICQ: 10386446
Skype: bilgalning
GSM: +46-(0)73-505 29 97
WoW: Vhasiu @ Ravencrest (EU)

[-- Attachment #2: Type: text/html, Size: 1872 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [linux-lvm] Accidental removal of logical volume - any way to salvage?
  2006-02-05 18:05   ` Martin Lindquist
@ 2006-02-05 20:54     ` Alasdair G Kergon
  2006-02-06  9:09       ` Martin Lindquist
  0 siblings, 1 reply; 5+ messages in thread
From: Alasdair G Kergon @ 2006-02-05 20:54 UTC (permalink / raw)
  To: LVM general discussion and development

On Sun, Feb 05, 2006 at 07:05:10PM +0100, Martin Lindquist wrote:
> The backup of /etc was done after running 'lvremove' and 'vgexport' so if I
> understand you correctly that won't do any good.
 
Take a look at your backup and check the comments in the files 
in /etc/lvm/archive/<vgname>*

Alasdair
-- 
agk@redhat.com

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [linux-lvm] Accidental removal of logical volume - any way to salvage?
  2006-02-05 20:54     ` Alasdair G Kergon
@ 2006-02-06  9:09       ` Martin Lindquist
  0 siblings, 0 replies; 5+ messages in thread
From: Martin Lindquist @ 2006-02-06  9:09 UTC (permalink / raw)
  To: LVM general discussion and development

[-- Attachment #1: Type: text/plain, Size: 802 bytes --]

Many, many, many thanks. After sleeping for a few hours and eating a proper
breakfast I managed to restore all of the lost data thanks to your hints.

Eternally thankful,
Martin

2006/2/5, Alasdair G Kergon <agk@redhat.com>:
>
> On Sun, Feb 05, 2006 at 07:05:10PM +0100, Martin Lindquist wrote:
> > The backup of /etc was done after running 'lvremove' and 'vgexport' so
> if I
> > understand you correctly that won't do any good.
>
> Take a look at your backup and check the comments in the files
> in /etc/lvm/archive/<vgname>*
>
> Alasdair
> --
> agk@redhat.com
>
> _______________________________________________
> linux-lvm mailing list
> linux-lvm@redhat.com
> https://www.redhat.com/mailman/listinfo/linux-lvm
> read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/
>

[-- Attachment #2: Type: text/html, Size: 1244 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-02-06  9:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-02-05 17:53 [linux-lvm] Accidental removal of logical volume - any way to salvage? Martin Lindquist
2006-02-05 17:58 ` Alasdair G Kergon
2006-02-05 18:05   ` Martin Lindquist
2006-02-05 20:54     ` Alasdair G Kergon
2006-02-06  9:09       ` Martin Lindquist

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).