Fixes to make cleanup of VM resources more robust

Change-Id: I3b688a34ae151849da9c8e4c272215e63d31b58e