0

I have an older server, namely, Fujitsu Siemens Primergy TX 150 S6 on witch i have installed XenServer 6.5.0-90233c.

On it i have multiple virtual machines of different sizes of witch i need to recover some data.

I've installed XenServer on a usb device plugged directly in the Motherboard, i used two 1T HDD in Raid 1 using mdadm for the SR (Storage Repository).

To assemble the array at boot i use those commands in my rc.local file:

modprobe md_mod
mdadm --assemble --verbose /dev/md1 /dev/sdb /dev/sdc

Now today i got in to a problem, i was doing some maintaining because it had an up time a few mounts at least and it wouldn't shut down so i force shut it down by pressing the power button.

On starting up again the server i noticed that it goes in to a loop restarting after transferring the kernel to the ram.

I took another usb stick with Xen on it and plugged it in. The system booted fine, now after assembling the array by mistake i wrote the command xe sr-create ... and so recreating an emty SR.

Now using the steps from here of course using the /etc/lvm/backup/file from the original usb and after assembling the array with the command mdadm --assemble --scan - because by now i took a hdd out for safe keeping and this was the only way i found that wold assemble the array - i end up with the following results:

fdisk -l

Disk /dev/sda: 15.7 GB, 15728640000 bytes
256 heads, 63 sectors/track, 1904 cylinders
Units = cylinders of 16128 * 512 = 8257536 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        1905    15359999+  ee  EFI GPT

Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1               1      121601   976760001   83  Linux

Disk /dev/md127: 1000.0 GB, 1000067825664 bytes
2 heads, 4 sectors/track, 244157184 cylinders
Units = cylinders of 8 * 512 = 4096 bytes

Disk /dev/md127 doesn't contain a valid partition table

lvscan

  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/MGT' [4.00 MB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-8d2d5e42-1327-4e9f-9d22-3ede3f0c6c05' [2.28 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-4fdddb5e-1161-4b6e-9545-430ed6ed915f' [8.02 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-b4614124-f4ea-466e-a598-111507ccf971' [80.16 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-9aad79b1-e54d-4d27-b9ea-84f8982ffa1d' [8.02 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-41d723fc-b805-4abb-89ce-a17aedfcf9f1' [100.20 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-830ce97a-8633-495c-898d-eb130351f66c' [100.20 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-19123cb8-cc2d-4fde-bca1-ee53c9c81c11' [8.02 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-5596a2ce-0ea7-4742-b172-78a677bed423' [100.20 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-59cedc2b-6f96-4d4e-a7d1-ccd152eeb9f0' [8.02 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-cb7650cc-9702-44f7-967e-18da0c5b87b7' [50.11 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-d7a1a2a2-e466-4fb7-bacc-edcd7660665a' [256.00 MB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-a4ce27ac-ffc1-496e-a415-878cd91d83e0' [10.03 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-00f4c83e-03de-4f47-876e-3f25790fce91' [10.03 GB] inherit
  inactive          '/dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-d5dc7799-4849-4ae4-aa2e-3aa9a4a6f13d' [200.40 GB] inherit
  ACTIVE            '/dev/XSLocalEXT-72ae6106-a518-3a75-71e2-73d33fc2e931/72ae6106-a518-3a75-71e2-73d33fc2e931' [6.64 GB] inherit

I can activate them by using lvchange -a y <path to lv>

lvdisplay

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/MGT
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                SMGgs5-hR1n-bniH-Rz3t-VIK4-GbTY-fkLsut
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                4.00 MB
  Current LE             1
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-8d2d5e42-1327-4e9f-9d22-3ede3f0c6c05
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                BuLGEF-ASSz-51Ud-6y7h-as4t-bjIF-hOLC1R
  LV Write Access        read only
  LV Status              NOT available
  LV Size                2.28 GB
  Current LE             583
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-4fdddb5e-1161-4b6e-9545-430ed6ed915f
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                To0vZA-1uQ9-IY2W-Bd52-pyAQ-lq9J-PLRGQj
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                8.02 GB
  Current LE             2054
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-b4614124-f4ea-466e-a598-111507ccf971
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                fv0r3c-ElRb-bBwP-EFer-WKnT-pzPx-uNtvfA
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                80.16 GB
  Current LE             20522
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-9aad79b1-e54d-4d27-b9ea-84f8982ffa1d
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                cVu0T4-xHWP-9QIr-WY3p-7Cri-6Z8d-cRjh37
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                8.02 GB
  Current LE             2054
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-41d723fc-b805-4abb-89ce-a17aedfcf9f1
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                qYQ4kl-oAZA-NMP8-QcNT-AtRG-FOkg-mSUJmn
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                100.20 GB
  Current LE             25652
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-830ce97a-8633-495c-898d-eb130351f66c
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                8l9w3j-gp7z-nPZs-ed45-a32Y-rmSR-gYWI4A
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                100.20 GB
  Current LE             25652
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-19123cb8-cc2d-4fde-bca1-ee53c9c81c11
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                E54dY6-n8Jl-KccN-elum-dcwf-ABeJ-Wfs8BK
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                8.02 GB
  Current LE             2054
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-5596a2ce-0ea7-4742-b172-78a677bed423
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                Ug2dke-h04E-8WTd-b37v-oSDd-sRst-9LqdcC
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                100.20 GB
  Current LE             25652
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-59cedc2b-6f96-4d4e-a7d1-ccd152eeb9f0
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                X0P4Eq-I9oo-xl0U-sc2G-2S8f-1UB9-ZLijgq
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                8.02 GB
  Current LE             2054
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-cb7650cc-9702-44f7-967e-18da0c5b87b7
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                5kgOE0-zcsQ-JQKi-6sAi-ytE7-SJfv-l71hIX
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                50.11 GB
  Current LE             12827
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-d7a1a2a2-e466-4fb7-bacc-edcd7660665a
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                UI17NG-V5RK-FPgr-suaq-TCOk-pMC7-NQdQiS
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                256.00 MB
  Current LE             64
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-a4ce27ac-ffc1-496e-a415-878cd91d83e0
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                aI8jMD-gucv-VH2L-sbGv-11Px-Rjwd-rQcpfc
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                10.03 GB
  Current LE             2567
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-00f4c83e-03de-4f47-876e-3f25790fce91
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                05Lvub-73EW-1re5-Zjay-5WRd-8I1q-2B5Yq6
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                10.03 GB
  Current LE             2567
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324/VHD-d5dc7799-4849-4ae4-aa2e-3aa9a4a6f13d
  VG Name                VG_XenStorage-eca2a6f4-ad2f-3205-3ddd-39232f91f324
  LV UUID                cbyeON-iK4x-sRKB-vxop-7klU-DfLK-4I9NlW
  LV Write Access        read/write
  LV Status              NOT available
  LV Size                200.40 GB
  Current LE             51302
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto

  --- Logical volume ---
  LV Name                /dev/XSLocalEXT-72ae6106-a518-3a75-71e2-73d33fc2e931/72ae6106-a518-3a75-71e2-73d33fc2e931
  VG Name                XSLocalEXT-72ae6106-a518-3a75-71e2-73d33fc2e931
  LV UUID                V0xnx6-Ggz6-uqbX-NSvC-IKtF-Vttc-0ZOc0E
  LV Write Access        read/write
  LV Status              available
  # open                 1
  LV Size                6.64 GB
  Current LE             1699
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0

Now if what i did until now is correct i don't know how to attach the SR in my case or manually mount the lv's. Mount doesn't works because it says it has no filesystem - actually it says that i need to specific the filesystem - but i understand it's because they are actually xen vm's, and with attaching the SR i can't find any method that wold work, everything that i found is outdated.

EDIT: Now i'm on a different stage:

  • i have deleted old, unnecessary/broken SR's like mentioned here
  • i have added the SR containing my vm's to xen using the instructions from here

The result is that i can see the storage for vm's in xencenter - Imgur - but when attached to a functioning vm i find myself having two issues one regarding the device Path Imgur and second is about the output of fdisk -l from inside the vm:

Disk /dev/xvda: 16.1 GB, 16106127360 bytes
255 heads, 63 sectors/track, 1958 cylinders, total 31457280 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000d3bb2

    Device Boot      Start         End      Blocks   Id  System
/dev/xvda1            2048      499711      248832   83  Linux
/dev/xvda2          501758    31455231    15476737    5  Extended
/dev/xvda5          501760    31455231    15476736   8e  Linux LVM

Disk /dev/mapper/giumbai--vg-root: 12.5 GB, 12452888576 bytes
255 heads, 63 sectors/track, 1513 cylinders, total 24322048 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/giumbai--vg-root doesn't contain a valid partition table

Disk /dev/mapper/giumbai--vg-swap_1: 3342 MB, 3342860288 bytes
255 heads, 63 sectors/track, 406 cylinders, total 6529024 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00000000

Disk /dev/mapper/giumbai--vg-swap_1 doesn't contain a valid partition table

My new question is, can i really recover my data or should i just forget about it?

Also if i try manual mounting the storage in xen following this example i get Required parameter not found: device, because there is no device specified:

vbd-list

uuid ( RO)             : 835c791f-79b5-e6c2-738b-dbba04689325
          vm-uuid ( RO): ef376a47-e477-ba06-41fd-b892ffe50b4f
    vm-name-label ( RO): Ubuntu Trusty Tahr 14.04 (1)
         vdi-uuid ( RO): d5dc7799-4849-4ae4-aa2e-3aa9a4a6f13d
            empty ( RO): false
           device ( RO): 


uuid ( RO)             : b0b14f6c-0aa4-8ac3-83c2-6e848f4ec5c3
          vm-uuid ( RO): ef376a47-e477-ba06-41fd-b892ffe50b4f
    vm-name-label ( RO): Ubuntu Trusty Tahr 14.04 (1)
         vdi-uuid ( RO): 830ce97a-8633-495c-898d-eb130351f66c
            empty ( RO): false
           device ( RO): 


uuid ( RO)             : f2bcdd13-219d-075d-4a23-1552a70f6b6a
          vm-uuid ( RO): ef376a47-e477-ba06-41fd-b892ffe50b4f
    vm-name-label ( RO): Ubuntu Trusty Tahr 14.04 (1)
         vdi-uuid ( RO): 96e23a4c-5786-444b-bb0c-34c604097c85
            empty ( RO): false
           device ( RO): xvda


uuid ( RO)             : e08ee76a-d374-2f0d-4a21-b4d1352391f2
          vm-uuid ( RO): ef376a47-e477-ba06-41fd-b892ffe50b4f
    vm-name-label ( RO): Ubuntu Trusty Tahr 14.04 (1)
         vdi-uuid ( RO): 8c56153b-d64a-4e96-82c9-f492792a190e
            empty ( RO): false
           device ( RO): xvdd

Why and how can i repair this?

3
  • Let me guess...you have no backups?
    – EEAA
    Mar 3, 2016 at 23:27
  • nope, no backup, that was my backup, i have some git repos that where on the sever on my lp, but most of my data was there.
    – Sergiu
    Mar 4, 2016 at 22:12
  • 1
    Well, you've learned a hard lesson the RAID isn't a backup. In fact, anything that is stored in the same physical area as the original data isn't a backup.
    – EEAA
    Mar 4, 2016 at 22:13

0

You must log in to answer this question.

Browse other questions tagged .