VMware Communities
Aaron_Levey1
Enthusiast
Enthusiast

Persistent <-> Non-Persistent ... on the fly?

I often use Player to run headless VMs ... during creation/testing, and for occational maintenance, it would be nice to quickly change the disk from Non-Persistent (its normal state) to Persistent to make changes.

Anyone have a script to allow this while running?

thx

0 Kudos
1 Reply
WoodyZ
Immortal
Immortal

I believe the default mode of a virtual hard disk created under VMware Player would be considered dependent-persistent, even though there is not a .vmx parameter shown by default using that designation, and cannot be changed from the VMware Player GUI (although it can be from the VMware Workstation GUI).

With VMware Player, one can manually edit the target .vmx configuration file using the following syntax:

[ide|scsi](n):(n).mode = "independent-[(non)persistent]"

Examples:

ide0:0.mode = "independent-persistent"
ide0:0.mode = "independent-nonpersistent"
scsi0:0.mode = "independent-persistent"
scsi0:0.mode = "independent-nonpersistent"

Changing this parameter "on the fly" suggests changing the current active state while running and I would think not possible although that doesn't stop the target .vmx configuration file from being edited while running however changes would not take effect until the Virtual Machine is shutdown.

Can this change be scripted, whether or not the Virtual Machine is running, yes and how and what language to use will in part depend on the Host OS.

Note:  As a general rule I do not advise manually modifying a Virtual Machine's files while it's running or the VMware Product is open.

0 Kudos