Missing Logical Volume... mount points gone... I might have trashed it... hoping it can be recovered

  • I tried to add another drive to an external eSATA box connected to my OMV server.


    The disks in the system are
    /dev/sda
    /dev/sdb
    /dev/sdc
    /dev/sdd
    /dev/sde
    /dev/sdf


    /dev/sdd is the boot drive. a, b, c, and e are all physically inside the case, sata devices connected to motherboard. /def/sdf is in an external eSATA enclosure. "f" is a 4 terabyte drive, so prior to adding this drive, the total was ~10 terabytes: 3 x 2 TB + 1 x 4 TB.


    I had configured the Logical Volume to include "f" that was in the enclosure.


    I acquired a second 4 TB drive and tried to get it set by inserting it into the enclosure, after powering down the enclosure but without powering down the entire OMV server.


    I had added it to the logical volume, but not used the "extend" function to actually add it. the drive was in the volume, but the size of the volume still only showed as if it wasn't added. This may be irrelevant, as just meant that despite adding the new 4 terabyte drive, the logical volume was still only 10 terabyte.


    Long story short, the folder


    /media/{guid}/


    is now empty... none of the mount points that were there:


    video
    documents
    software
    music
    backups


    are there any more... but I am confident I didn't format / erase the drives or anything.


    Is there any way via command line to confirm that there is actually still data there?


    then, if the data is all still there, is there any way to recover the mount points etc.?


    I have been googling for half an hour and my grasp of linux terminology isn't great, so maybe I'm not searching for the right things... "fdisk -l" gives me this: (I admit with some command line tools, it gives me strange values like "partition table: unknown"... but again it was all working until... i messed something up... and now I have to try to recover... things... somehow.



    Thanks terribly much in advance.

  • I think I did not quite understand. Are those drives grouped into a single logical volume? You did not use mdadm, did you use lvm?

    Yes, they should all be a single logical volume: they are but "the files are gone"... they may actually still be there, if I configure them properly ... I'm prepared to take the drives out of the server and run various linux disk utilities to recover the files if necessary, but I'm hoping that what I did is reversable, if I know what to do.


    In creating the Logical Volume, I used the built-in features of OMV 4.0 under the "Storage" / "Logical Volume Management" menus.

  • Well, I'm still having trouble.


    pvscan gives this:


    Code
    PV /dev/sda VG Fantasia lvm2 [1.82 TiB / 1.82 TiB free]
    PV /dev/sdc VG Fantasia lvm2 [1.82 TiB / 1.82 TiB free]
    PV /dev/sdd VG Fantasia lvm2 [1.82 TiB / 1.82 TiB free]
    PV /dev/sde VG Fantasia lvm2 [3.64 TiB / 3.64 TiB free]
    PV /dev/sdf VG Fantasia lvm2 [3.64 TiB / 3.64 TiB free]


    what is "troubling" is that the folder where the 'mount points' were for my shares i.e.


    /media/{UUID}/backups
    /media/{UUID}/video
    /media/{UUID}/music
    /media/{UUID}/software
    /media/{UUID}/documents


    are all gone. Does that mean that the "directory structure" is gone?


    I really don't know what is stored "in" a logical volume vs. what is stored externally.


    I used testdisk on the drives and the partition type is reported as "none" which I read somewhere is not a problem for EXT4.


    In OMV, I see the physical volumes (like those listed under PVSCAN) and I see the Volume Group, but the Logical Volume tab is empty, and I'm afraid if I click "Add" and choose "Fantasia", I'll be wiping out whatever data / directory information is there, rather than just "connecting to it" or mounting it or what not.


    When I try to use "vgconfig -ay" it says


    Code
    vgscan
    Reading volume groups from cache.
    Found volume group "Fantasia" using metadata type lvm2
    vgchange -ay
    0 logical volume(s) in volume group "Fantasia" now active


    so I'm kind of stuck in a place where the physical volumes exist and I don't believe the data has been destroyed, the Volume Group is established but I may have broken that along the way but I'm not sure, and the logical volume is just... not there maybe.


    I did "testdisk" on the drives and it shows LVM2 found, says it's "OK" but I don't know what to do from there non-destructively. Analyze took almost a full day on a 4 terabyte drive so... well, there I am: I have these drives I believe still contain all my data in the LVM (there was no RAID, no encryption etc.) and I just want to plug them back in so to speak.


    If there is anyone who might be willing to do something in pseudo real-time at some point, possibly evening EST, I could be here posting whatever you want to know in real time, or even to a skype screen share. I know I'm not communicating very effectively because I certainly can't find any clear answers via Google, because you have to know what you're looking for to find it (well, most of the time)

  • But it looks like pvscan found everything.
    Can't you just mount it on the command line?

    It says "0 logical volume(s)... when I use vgconfig -ay so that's the problem I need to solve. Is it solved by mounting it? I tried using mount -a and that didn't work I'm not sure if there's a problem with my fstab... but thanks for confirming that all the info i.e. file pointers / directory data (whatever the kids are calling "the list of files and where they are on the disk" is stored in the LV.


    If there is any other guidance you could give , it would be appreciated :-)

  • Did you read, what I wrote about the backups?

    I missed that originally: I will have to purchase a replacement drive I have a spare 4 terabyte drive I could use, but not an 8 terabyte drive... can I do this one physical drive at a time? I am assuming I have to work with all the physical drives at the same time, or is it possible to create a new volume group with just the one physical drive, then add the other drives back in one by one until I've got everything back?


    but first, a question about OMV specifically:


    1) in OMV 4, under "Logical Volume Management":
    - on the "Physical Volumes" tab, I see all my /dev/sda, /dev/sdc etc. through /dev/sdf all listed as being in the Volume Group "Fantasia".


    - on the "Volume Groups" tab, I see "Fantasia" with the /dev/sda etc. listed under the "Physical Volumes" column, and the "Available" and "Free" columns both show 12.74 terabytes (the same amount being "Available" and "Free" does make me think the data is lost: doesn't "Free" mean "room for files", so does that mean there's no data? Setting that aside for a moment) but the Logical Volumes column just shows "--".


    - on the "Logical Volumes" tab, there is a table with no data, and an enabled "Add" button.


    When clicked, I see a "Create Logical Volume" dialog. Now, the notion of "Creating" something gives me pause: I don't want to wallop whatever may still be there.


    This dialog has a "Name" text box and a and "Volume Group" dropdown.


    The Name text box is empty, and the only entry in the "Volume Group" is my full Volume Group 12.74 terabytes "Fantasia" Volume Group


    If I enter a Name like "FixIt" and choose the "Fantasia" volume group from the dropdown, would that do the trick? Would the subfolders /backup, /music, /software, /video, and /documents/ suddently be visible somehow? Or would using "Create" in this way WIPE out the data on the drives?


    I'm skittish about pushing a button labeled "Create" if that has the potential to effectively "initialize" things.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!