P
P
panaceya2016-09-28 13:42:41
LVM
panaceya, 2016-09-28 13:42:41

How to restore LVE in XenServer?

Good day to all.
There is a server that once hung up and stopped loading XenServer. Booted from LiveCD (linuxrecovery) and copied all LVE volumes to another server using dd.
Then I reinstalled XenServer.
Already on the new XenServer, I created a VDI (disk, aka LVE volume) with the same volume as before, and using dd copied the data from another server (dd if=.. of=... skip=1 seek=1 bs=32256/ dd if=.. of=... )
When starting the server, I get an error:

The server failed to handle your request, due to an internal error.  The given message may give details useful for debugging the problem.
message: xenopsd internal error: Storage_interface.Illegal_transition(_)

The check gives an error in the metadata.
vhd-util check -n /dev/VG_XenStorage-f5abaadb-a96f-4db3-5cdc-0b0a42a333a9/VHD-68e50174-cc67-4022-a6e4-c47d8175e4de 
error resolving ./VG_XenStorage--e2851840--dd1b--ffd8--2a11--e3e7ff4a5e48-VHD--74dbad33--cdbf--4efe--9ac9--223c3d6a0d9f: -2
/dev/VG_XenStorage-f5abaadb-a96f-4db3-5cdc-0b0a42a333a9/VHD-68e50174-cc67-4022-a6e4-c47d8175e4de appears invalid; dumping metadata
VHD Footer Summary:
-------------------
Cookie              : conectix
Features            : (0x00000002) <RESV>
File format version : Major: 1, Minor: 0
Data offset         : 512
Timestamp           : Tue Feb 16 14:16:28 2016
Creator Application : 'tap'
Creator version     : Major: 1, Minor: 3
Creator OS          : Unknown!
Original disk size  : 10240 MB (10737418240 Bytes)
Current disk size   : 10240 MB (10737418240 Bytes)
Geometry            : Cyl: 20805, Hds: 16, Sctrs: 63
                    : = 10239 MB (10737377280 Bytes)
Disk type           : Differencing hard disk
Checksum            : 0xffffef5c|0xffffef5c (Good!)
UUID                : 547e1ce8-dca5-4e2f-b978-2cb290fd03ba
Saved state         : No
Hidden              : 0

VHD Header Summary:
-------------------
Cookie              : cxsparse
Data offset (unusd) : 18446744073709
Table offset        : 1536
Header version      : 0x00010000
Max BAT size        : 1048576
Block size          : 2097152 (2 MB)
Parent name         : VG_XenStorage--e2851840--dd1b--ffd8--2a11--e3e7ff4a5e48-VHD--74dbad33--cdbf--4efe--9ac9--223c3d6a0d9f
Parent UUID         : fa99ac79-d6ab-4b25-b25a-2d89f11f8389
Parent timestamp    : Tue Feb 16 14:16:27 2016
Checksum            : 0xffffc63a|0xffffc63a (Good!)

VHD Parent Locators:
--------------------
locator:            : 0
       code         : PLAT_CODE_MACX
       data_space   : 512
       data_length  : 110
       data_offset  : 4327424
       decoded name : ./VG_XenStorage--e2851840--dd1b--ffd8--2a11--e3e7ff4a5e48-VHD--74dbad33--cdbf--4efe--9ac9--223c3d6a0d9f

locator:            : 1
       code         : PLAT_CODE_W2KU
       data_space   : 512
       data_length  : 206
       data_offset  : 4327936
       decoded name : ./VG_XenStorage--e2851840--dd1b--ffd8--2a11--e3e7ff4a5e48-VHD--74dbad33--cdbf--4efe--9ac9--223c3d6a0d9f

locator:            : 2
       code         : PLAT_CODE_W2RU
       data_space   : 512
       data_length  : 206
       data_offset  : 4328448
       decoded name : ./VG_XenStorage--e2851840--dd1b--ffd8--2a11--e3e7ff4a5e48-VHD--74dbad33--cdbf--4efe--9ac9--223c3d6a0d9f

VHD Batmap Summary:
-------------------
Batmap offset       : 4196352
Batmap size (secs)  : 256
Batmap version      : 0x00010002
Checksum            : 0xffff2543|0xffff2543 (Good!)

I have successfully managed to restore VDIs that were previously either offline (VM) or second. But with the first - there is such a problem.
How to restore true LVE volume?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
L
lovecraft, 2016-10-13
@lovecraft

dd if=.. of=... skip=1 seek=1 bs=32256

But why is this? skip=1 seek=1 Why are you skipping the first 32256 bytes on the source and destination?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question