[linux-lvm] Re: newbie problem with LVM

Argus Array argusarray2 at gmail.com
Mon Jun 26 02:32:46 UTC 2006


I've been digging around a bit and I found that /etc/lvm/archive has some
information that might be useful for restoring my LVM data.

I've attached the latest VGforMythTV_00008.vg data (before the versions for
the new ones that I created).

I read on this blog:
http://codeworks.gnomedia.com/archives/2005/general/lvm_recovery/

that this information could be used to recreate my physical volumes using a
command like this:
[mythtv at localhost archive]# /usr/sbin/pvcreate -u
J3hQY6-8yfK-pMPS-dGhN-WFig-ENnC-LSR2nn /dev/hdb1
  Can't initialize physical volume "/dev/hdb1" of volume group "VGforMythTV"
without -ff

I am hesitant to use the "-ff" (force) command without knowing what the
impact will be.  Any advice?

Thanks,

-Argus

VGforMythTV_00008.vg
---------------------------------------

# Generated by LVM2: Mon Apr 11 22:59:52 2005

contents = "Text Format Volume Group"
version = 1

description = "Created *before* executing '/usr/sbin/lvextend --size +160G
/dev/VGforMythTV/video'"

creation_host = "localhost.localdomain" # Linux localhost.localdomain
2.6.10-1.737_FC3 #1 Mon Jan 10 13:50:10 EST 20
05 i686
creation_time = 1113274792      # Mon Apr 11 22:59:52 2005

VGforMythTV {
        id = "YKYYOd-PcmN-lGub-gllT-6d0j-IyGp-BweNJY"
        seqno = 3
        status = ["RESIZEABLE", "READ", "WRITE"]
        extent_size = 131072            # 64 Megabytes
        max_lv = 0
        max_pv = 0

        physical_volumes {

                pv0 {
                        id = "J3hQY6-8yfK-pMPS-dGhN-WFig-ENnC-LSR2nn"
                        device = "/dev/hdb"     # Hint only

                        status = ["ALLOCATABLE"]
                        pe_start = 384
                        pe_count = 3038 # 189.875 Gigabytes
                }

                pv1 {
                        id = "5DR2ds-AXzi-Om4M-Mg1R-KpRQ-swOr-JHQTUa"
                        device = "/dev/hdc"     # Hint only

                        status = ["ALLOCATABLE"]
                        pe_start = 384
                        pe_count = 2442 # 152.625 Gigabytes
                }
        }
 logical_volumes {

                video {
                        id = "gscBJa-pCAA-Yv25-kOHu-9U6z-K7iQ-1dpm42"
                        status = ["READ", "WRITE", "VISIBLE"]
                        segment_count = 1

                        segment1 {
                                start_extent = 0
                                extent_count = 3024     # 189 Gigabytes

                                type = "striped"
                                stripe_count = 1        # linear

                                stripes = [
                                        "pv0", 0
                                ]
                        }
                }
        }
}


On 6/23/06, Argus Array <argusarray2 at gmail.com> wrote:
>
> Terribly sorry for the double post to the mailing list, accidentally hit
> the google shortcut.
>
> I have been using LVM for several months to record video files for my PVR
> across a 200GB and 160GB disk (hdb and hdc).
>
> Recently I decided to upgrade my FC3 install to FC5.  After the install,
> my LVM mount does not come up.  It appeared that all of the LVM information
> in /dev/ was gone; however, only the non-LVM drive (/dev/hda) should have
> been touched by the FC5 upgrade.
>
> This is my fstab entry:
> /dev/VGforMythTV/video  /var/media              xfs     defaults        1
> 1
>
> This is what fdisk shows:
> /dev/hdb1               1       24792   199141708+  8e  Linux LVM
>
> /dev/hdc1               1       19929   160079661   8e  Linux LVM
>
> In my attempt to fix this, I think I may have totally fouled things up; I
> tried to create a new volume group with the same name and more PVs for the
> new drives, then combine them together into an PV with the old LV name.
> However, this still does not allow it to mount.
>
> Any ideas?  Have I deleted all my data?
>
> Thanks for any help,
>
> Argus
>
> I've pasted my history commands below.
>
>   548  more /etc/fstab
>   549  vgcreate VGforMythTV -s 64m /dev/hda1
>   550  /usr/sbin/vgcreate VGforMythTV -s 64m /dev/hda1
>   551*
>   552  /usr/sbin/pvcreate /dev/hdb1
>   553  /usr/sbin/pvcreate /dev/hdc1
>   554  /usr/sbin/vgcreate VGforMythTV /dev/hdb1 /dev/hdc1
>   555  mount /dev/VGforMythTV /var/media
>   556  mount /dev/VGforMythTV/video /var/media
>   557  mount /dev/VGforMythTV/media /var/media
>   558  lvcreate --name video VGforMythTV
>   559  /usr/sbin/lvcreate --name video VGforMythTV
>   560  /usr/sbin/lvcreate --name video -l VGforMythTV
>   561  /usr/sbin/lvcreate --name video -l ` VGforMythTV
>   562  /usr/sbin/lvcreate --name video -l 1 VGforMythTV
>   563  mount /dev/VGforMythTV/media /var/media
>   564  mount /dev/VGforMythTV/video /var/media
>   565  mount -t xfs /dev/VGforMythTV/video /var/media
>   566  mount /dev/VGforMythTV/video /var/media
>   567  /usr/sbin/lvcreate --name video -l 2 VGforMythTV
>   568  ls
>   569  /usr/sbin/pvdisplay
>   570  /usr/sbin/lvmdiskscan
>   571  mount /dev/VGforMythTV /var/media/
>   572  mount /dev/VGforMythTV/video /var/media/
>   573  mount /dev/VGforMythTV/media /var/media/
>   574  mount /dev/VGforMythTV/video /var/media/
>   575  /sbin/fdisk /dev/hdb
>   576  /sbin/fdisk /dev/hdc
>   577  /usr/sbin/vgextend
>   578  more /etc/fstab
>   579  /usr/sbin/vgextend VGforMythTV /dev/hdb1
>   580  /usr/sbin/vgextend VGforMythTV /dev/hdb
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/linux-lvm/attachments/20060625/db4d0afb/attachment.htm>


More information about the linux-lvm mailing list