VMware Cloud Community
fshscikm
Contributor
Contributor

Virtual Machines displayed "unknown" or "not connected" in Virtual Center

Hello,

we hav a strange problem: We moved some of our VMs to a new storage and everything looked fine. The old storage was displayed empty in VC. After we removed the old storage some machines became unavailable (color changed from blach to grey) and we are not able to start the VMs.

It seems that the ESX does not recognize (or know) the moved VMs.

I had a look into the VC-Database and it seems that the VMs still belong to the removed storage.

If I look into the .vmx file of one of the affected VMs on the new storage there is a path that refers to the old storage ( sched.swap.derivedName = /vmfs/volumes/<lots of numbers>/<Name>/<Name>.vswp)but I assume this is only swap-memory.I changed it but that did not help.

Is there a way to reconfigure the VMs manually to match the new storage configuration?

Where does the ESX-Server store the configuration information for all VMs (beside the VC-Database)?

Does anybody have an idea where I can look?

Any hints welcome!

Thanks,

Frank

0 Kudos
11 Replies
NTurnbull
Expert
Expert

Hi, is the .vswap file in the same directory as the virtual machine on the new storage? It could be that the vswap file was held in a different location/LUN on your old storage.

The path "/vmfs/volumes/<lots of numbers>/<Name>/<Name>.vswp" the 'lots of numbers' represents the ESX unique datastore name.

Thanks,

Neil

Thanks, Neil
0 Kudos
fshscikm
Contributor
Contributor

Hi Neil,

thanks for you answer. Yes, all is located in the same directory.

Thanks,

Frank

0 Kudos
bulletprooffool
Champion
Champion

Shut down the VM

Open the .vmx file and verify that the paths to disks etc do not point to the old volumes (You can simply specify the filename as it exists in the same folder as the vmx file)

i.e. delete /vmfs/volumes/<lots of numbers>/<Name>/

Start the VM

One day I will virtualise myself . . .
0 Kudos
fshscikm
Contributor
Contributor

Hi,

this is a sample configuration. The only path I could find in there is the swap-path.

=================

powerType.powerOff = "default"

powerType.powerOn = "default"

powerType.suspend = "default"

powerType.reset = "default"

displayName = "ThinClient for Citrix"

extendedConfigFile = "ThinClient for Citrix.vmxf"

scsi0.present = "true"

scsi0.sharedBus = "none"

scsi0.virtualDev = "buslogic"

memsize = "512"

scsi0:0.present = "true"

scsi0:0.fileName = "ThinClient for Citrix.vmdk"

scsi0:0.deviceType = "scsi-hardDisk"

ide0:0.present = "true"

ide0:0.clientDevice = "true"

ide0:0.deviceType = "cdrom-raw"

ide0:0.startConnected = "false"

floppy0.startConnected = "false"

floppy0.clientDevice = "true"

ethernet0.present = "true"

ethernet0.networkName = "EXTERN"

ethernet0.addressType = "vpx"

ethernet0.generatedAddress = "00:50:56:90:7b:77"

guestOSAltName = "Other Linux (32-bit)"

guestOS = "linux"

uuid.bios = "50 10 ba 3a 55 ed 76 1e-22 44 b9 46 d4 ef 89 1b"

toolScripts.afterPowerOn = "true"

toolScripts.afterResume = "true"

toolScripts.beforeSuspend = "true"

toolScripts.beforePowerOff = "true"

scsi0:0.redo = ""

uuid.location = "56 4d 3b 16 76 0d e7 7e-66 85 b3 16 e0 31 3f dc"

sched.swap.derivedName = "/vmfs/volumes/4a853308-06154f76-5af0-0015176734bc/ThinClient for Citrix/ThinClient for Citrix-4ef3fbc8.vswp"

tools.remindInstall = "TRUE"

hostCPUID.0 = "0000000a756e65476c65746e49656e69"

guestCPUID.0 = "0000000a756e65476c65746e49656e69"

userCPUID.0 = "0000000a756e65476c65746e49656e69"

hostCPUID.1 = "0001067600040800000ce3bdbfebfbff"

guestCPUID.1 = "0001067800010800000822010febfbff"

userCPUID.1 = "0001067600040800000822010febfbff"

hostCPUID.80000001 = "00000000000000000000000120100000"

guestCPUID.80000001 = "00000000000000000000000120100000"

userCPUID.80000001 = "00000000000000000000000120100000"

evcCompatibilityMode = "FALSE"

sched.scsi0:0.shares = "normal"

floppy0.fileName = "/dev/fd0"

=================

extendedConfigFile = "ThinClient for Citrix.vmxf":

<?xml version="1.0"?>

<Foundry>

<VM>

<VMId type="string">52 d3 8f cc b6 fc b3 8a-aa df 8e 77 ed b0 14 f4</VMId>

<ClientMetaData>

<clientMetaDataAttributes/>

<HistoryEventList/></ClientMetaData>

<vmxPathName type="string">ThinClient for Citrix.vmx</vmxPathName></VM></Foundry>

0 Kudos
NTurnbull
Expert
Expert

I see spaces in your vm name, go to the console and go into "/vmfs/volumes/4a853308-06154f76-5af0-0015176734bc" and do an ls and a dir, do you see any backslashes in the path name?

Thanks,

Neil

Thanks, Neil
0 Kudos
fshscikm
Contributor
Contributor

Hi,

yes, there are backslashes

directory: ThinClient\ for\ Citrix

# dir

ThinClient\ for\ Citrix-flat.vmdk ThinClient\ for\ Citrix.vmdk ThinClient\ for\ Citrix.vmx vmware-1.log vmx.bck

ThinClient\ for\ Citrix.nvram ThinClient\ for\ Citrix.vmsd ThinClient\ for\ Citrix.vmxf vmware.log

0 Kudos
NTurnbull
Expert
Expert

Hi, thought so, thats the path you've got to use - is why it's not a good idea to use spaces in vm names. Paths and vm names are used in the xxxxx.vmdk, .vmx, .vmxf and .vmsd files.

It may be easier for you to note down the vm configuration, create a new directory under the datastore maybe using _ instead of spaces, copy * .vmdk files into that, use vmkfstools -E to rename the copied virtual disk to the same as the new directory which will rewrite the vmdk descriptor file, then go into VC and create a new vm using an existing virtual disk (newly renamed vdmk) which will rebuild all the supporting files in the new directory and edit the 'new' vm settings to mirror what the 'old' one had and hey presto - fixed Smiley Happy

Thanks,

Neil

Thanks, Neil
fshscikm
Contributor
Contributor

This sounds like a good idea. I will give it a try.

Thank you very much!

Best Regards,

Frank

0 Kudos
NTurnbull
Expert
Expert

No problem, at least it makes VC rebuild your paths so you don't have to. drop me a line if you run into a problem

Thanks,

Neil

Thanks, Neil
0 Kudos
fshscikm
Contributor
Contributor

Hi Neil,

I tried with two machines and it worked. Thank you very much!

Best regards,

Frank

0 Kudos
NTurnbull
Expert
Expert

Glad to help Smiley Happy

Thanks,

Neil

Thanks, Neil
0 Kudos