VMware Cloud Community
anonimous
Enthusiast
Enthusiast
Jump to solution

cannot delete *.vswp file

Hi

We have ESX 3.5 Update2 and I cannot delete *.vswp file from the Datastore.

BTW In this directory ist only this *.vswp file and the VM was removed from the inventory using Infrastructure Client.

I've tried already:

service mgmt-vmware restart

but it doesn't help.

Even this:

vmware-cmd -s unregister /vmfs/volumes/vmware:storage1/TEST/TEST-461053fd.vswp

VMControl error -11: No such virtual machine

0 Kudos
1 Solution

Accepted Solutions
Chamon
Commander
Commander
Jump to solution

do a

ps auxfww |grep -i "Test"

This should get you the process ID for it.

View solution in original post

0 Kudos
8 Replies
AWo
Immortal
Immortal
Jump to solution

I assume you have tried to delete it with "rm". Which failure message do you get?

Try to see if a process has this file still open: "lsof | grep "

=Send "Posting" to 911 for only $999999,99!=

vExpert 2009/10/11 [:o]===[o:] [: ]o=o[ :] = Save forests! rent firewood! =
0 Kudos
AndreTheGiant
Immortal
Immortal
Jump to solution

Maybe the VM is still running.

See:

http://www.applicationdelivery.co.uk/home/leew/vmware-esx-killing-a-virtual-machine-that-wont-die/

Andre

Andrew | http://about.me/amauro | http://vinfrastructure.it/ | @Andrea_Mauro
anonimous
Enthusiast
Enthusiast
Jump to solution

lsof | grep TEST-461053fd.vswp

rm TEST-461053fd.vswp

rm: remove regular file `TEST-461053fd.vswp'? y

rm: cannot remove `TEST-461053fd.vswp': Device or resource busy

BTW The VM was deleted using infrastructure client and vmx file doesn't exist.

0 Kudos
Chamon
Commander
Commander
Jump to solution

If you have already removed the VM run

pidof vmname

And when you get the pid # do a kill pid# or akill -9 pid#

To end the process

then do the

rm

anonimous
Enthusiast
Enthusiast
Jump to solution

On my ESX 3.5 Update

pidof TEST

doesn't show anything, even if I try pidof on any others running VM's.

0 Kudos
Chamon
Commander
Commander
Jump to solution

do a

ps auxfww |grep -i "Test"

This should get you the process ID for it.

0 Kudos
anonimous
Enthusiast
Enthusiast
Jump to solution

Thx a lot.

ps auxfww |grep -i "Test"

solved my problem.

0 Kudos
Chamon
Commander
Commander
Jump to solution

Good to hear! With ESX 3.5 We had VMs that would hang more then one would like so we used this too much. I haven't had the issue with vSphere 4 yet.

0 Kudos