VMware vSphere

 View Only
  • 1.  recover vmware after disc change

    Posted Oct 23, 2013 08:01 AM

    Hi,

    I need some help with an updated ESXi 5.5 installation.

    The history:

    1 ESXi Host (2 local 2TB SATA drives) with several (important !) vms running without any issue (1st disc with the installed ESXi and the 2nd extends the first one = VMFS extended storage)

    2 ESXi started complaining, storage have I/O drops which causes VMware to unmount one of the discs

    3 datacenter service did a complete server replacment. Both old discs are connected via USB-SATA interfaces to the new server

    4 I used dd within the recovery system to clone each usb disc to one of the new installed discs

    5 Booting failed (KVM ony get through "loading kernel" and after this I get a black blank screen)

    6 I added overrideDuplicateImageDetection to the boot options in boot.cfg (Shift+O shows this option)

    7 tried vmfs-fuse to mount the vmfs discs without success

    I don't have any idea how to get the data from my discs. I have a recovery system and a vKVM as connection option. The access to the startup logs is available, so if you need some more information, please let m know.

    Thanks for your help.



  • 2.  RE: recover vmware after disc change

    Posted Oct 23, 2013 08:07 AM

    Whoooho.

    I got it. I always tried to mount the second disc with vmfs-fuse which never worked.

    Now I tried to mount the first vmfs filesystem on disc one and it worked!! Now I'm able to copy the vmdk files and reinstall the ESX host.

    :smileyhappy:

    Trying to copy the vmdk of the most important disc, crashed with an error. It seems the vmdk file is still in use.

    I see the following folder structur:

    ls -alh plesk
    total 510G
    drwxr-xr-x  2 root root 3.1K Oct 17 07:09 .
    drwxr-xr-t 25 root root 4.3K Oct 16 14:51 ..
    -rw-------  1 root root 1.5G Oct 17 20:20 plesk-000001-delta.vmdk
    -rw-------  1 root root  315 Oct 17 07:09 plesk-000001.vmdk
    -rw-------  1 root root 8.0G Oct 11 21:54 plesk-12e12c87.vswp
    -rw-------  1 root root 500G Oct 16 09:01 plesk-flat.vmdk
    -rw-------  1 root root 8.5K Oct 17 07:09 plesk.nvram
    -rw-------  1 root root  28K Oct 16 09:01 plesk-Snapshot1.vmsn
    -rw-------  1 root root  495 Oct 16 08:49 plesk.vmdk
    -rw-r--r--  1 root root  372 Oct 16 12:37 plesk.vmsd
    -rwxr-xr-x  1 root root 2.9K Oct 17 07:08 plesk.vmx
    -rwxr-xr-x  1 root root 2.9K Oct 17 07:08 plesk.vmx~
    -rw-r--r--  1 root root  260 Sep  2 14:39 plesk.vmxf
    -rw-------  1 root root    0 Oct 11 21:54 plesk.vmx.lck
    -rw-r--r--  1 root root  27K Aug 22 10:41 vmware-4.log
    -rw-r--r--  1 root root 106K Oct 11 10:50 vmware-5.log
    -rw-r--r--  1 root root 113K Oct 11 11:23 vmware-6.log
    -rw-r--r--  1 root root 134K Oct 11 21:50 vmware-7.log
    -rw-r--r--  1 root root 113K Oct 11 22:15 vmware-8.log
    -rw-r--r--  1 root root 124K Oct 16 12:44 vmware-9.log
    -rw-r--r--  1 root root 114K Oct 17 08:55 vmware.log
    -rw-------  1 root root 129M Oct 11 21:54 vmx-plesk-316746887-1.vswp

    Any idea?

    Thanks



  • 3.  RE: recover vmware after disc change

    Posted Oct 23, 2013 09:07 AM

    > Trying to copy the vmdk of the most important disc, crashed with an error. It seems the vmdk file is still in use.

    I assume the VMFS is mounted via vmfs-fuse ? - try to copy with gdd-rescue instead of using cp.

    When does it crash ? -
    Can you view the file with hexdump ?

    If you still cant copy the vmdk - let me have a look - I found procedures to recover vmdks when vmfs-fuse fails



  • 4.  RE: recover vmware after disc change

    Posted Oct 23, 2013 09:16 AM

    Yes I've mounted the filesystem using vmfs-fuse.

    # hexdump plesk-flat.vmdk (the large 500GB file)
    hexdump: plesk-flat.vmdk: Input/output error

    # hexdump plesk.vmdk (the small file ~1GB)

    0000000 2023 6944 6b73 4420 7365 7263 7069 6f74

    0000010 4672 6c69 0a65 6576 7372 6f69 3d6e 0a31

    0000020 6e65 6f63 6964 676e 223d 5455 2d46 2238

    0000030 430a 4449 623d 3032 3032 3533 0a34 6170

    0000040 6572 746e 4943 3d44 6666 6666 6666 6666

    0000050 690a 4e73 7461 7669 5365 616e 7370 6f68

    0000060 3d74 6e22 226f 630a 6572 7461 5465 7079

    0000070 3d65 7622 666d 2273 0a0a 2023 7845 6574

    0000080 746e 6420 7365 7263 7069 6974 6e6f 520a

    0000090 2057 3031 3834 3735 3036 3030 5620 464d

    00000a0 2053 7022 656c 6b73 662d 616c 2e74 6d76

    00000b0 6b64 0a22 230a 5420 6568 4420 7369 206b

    00000c0 6144 6174 4220 7361 2065 230a 4444 0a42

    00000d0 640a 6264 612e 6164 7470 7265 7954 6570

    00000e0 3d20 2220 736c 6c69 676f 6369 0a22 6464

    00000f0 2e62 6567 6d6f 7465 7972 632e 6c79 6e69

    0000100 6564 7372 3d20 2220 3536 3732 2230 640a

    0000110 6264 672e 6f65 656d 7274 2e79 6568 6461

    0000120 2073 203d 3222 3535 0a22 6464 2e62 6567

    0000130 6d6f 7465 7972 732e 6365 6f74 7372 3d20

    0000140 2220 3336 0a22 6464 2e62 6f6c 676e 6f43

    0000150 746e 6e65 4974 2044 203d 3722 6164 6633

    0000160 3235 3932 3333 6139 3538 6163 6661 3661

    0000170 3336 6266 3032 3032 3533 2234 640a 6264

    0000180 742e 6f6f 736c 6556 7372 6f69 206e 203d

    0000190 3922 3232 2231 640a 6264 752e 6975 2064

    00001a0 203d 3622 2030 3030 4320 2032 3339 3020

    00001b0 2064 3233 3920 2066 3861 322d 2030 3839

    00001c0 3620 2031 6334 6120 2063 6139 3220 2031

    00001d0 3564 0a22 6464 2e62 6976 7472 6175 486c

    00001e0 5657 7265 6973 6e6f 3d20 2220 2239 000a

    00001ef

    I tried to get the file using winscp. Because the rescue system is a small discless system and all discs are now vmfs or fat16 (bootpartition):

    # parted -l

    Model: ATA TOSHIBA DT01ACA2 (scsi)

    Disk /dev/sda: 2000GB

    Sector size (logical/physical): 512B/4096B

    Partition Table: gpt

    Disk Flags:

    Number  Start   End     Size    File system  Name  Flags

    1      32.8kB  4194kB  4162kB  fat16              boot

    5      4211kB  266MB   262MB   fat16

    6      266MB   528MB   262MB   fat16

    7      528MB   644MB   115MB

    8      644MB   944MB   300MB   fat16

    2      944MB   5238MB  4294MB  fat16

    3      5238MB  2000GB  1995GB

    Model: ATA TOSHIBA DT01ACA2 (scsi)

    Disk /dev/sdb: 2000GB

    Sector size (logical/physical): 512B/4096B

    Partition Table: gpt

    Disk Flags:

    Number  Start   End     Size    File system  Name  Flags

    1      1049kB  2000GB  2000GB

    The ESX host crashed while the maschine was running.


    =====


    ESX host is up and VMs are running. :smileyhappy: Thanks for your help.


    Imporant was always to choose the first disc. It contains all data for the second disc. So I've added the datastore again keeping the current signature and the Vms came back.