#VMware #ESXi #VirtualDisks
Full steps can be found at [ Ссылка ]
--------------------------------------------------------------------
Virtual Disk Types in VMware
--------------------------------------------------------------------
- Thick Provision Lazy Zeroed (default) – Space required for the virtual disk is allocated during the creation of the disk file. Any data remaining on the physical device is not erased during creation, but is zeroed out on demand at a later time on first write from the virtual machine. The virtual machine does not read stale data from disk.
- Thick Provision Eager Zeroed – Space required for the virtual disk is allocated at creation time. In contrast to thick provision format, the data remaining on the physical device is zeroed out during creation. It might take much longer to create disks in this format than to create other types of disks.
- Thin Provision – Space required for the virtual disk is not allocated during creation, but is supplied and zeroed out, on demand at a later time.
Source: [ Ссылка ]
--------------------------------------------------------------------
Converting/Cloning to Thin Disk Type
--------------------------------------------------------------------
01. Log into the ESXi web UI
02. Enable the SSH service if it is not already enabled by selecting Actions ≫ Services ≫ Enable Secure Shell (SSH) Actions ≫ Services ≫ Enable Secure Shell (SSH)
03. Shutdown the target VM if it is currently running
04. Select the target VM from the left navigation
05. Expand the Hard disk configuration
06. Copy the folder and file name (TurnkeyLinux/TurnkeyLinux.vmdk in this example) and paste into a text document
07. Click the virtual disk .vmdk file name link
08. Copy the location path value displayed (/vmfs/volumes/61a66fb9-5be9b2dc-6d0f-b8ca3a9babec in this example) and paste into a text document
09. Connect to the ESXi host via SSH
10. Run the following commands
# change directory to the datastore, update path as needed
# (/vmfs/... path from above)
cd /vmfs/volumes/61a66fb9-5be9b2dc-6d0f-b8ca3a9babec
# use vmkfstools to clone the virtual disk to thin provisioned
# use the folder and file name copied from above
# syntax
# vmkfstools -i "≪%SOURCE FILE.vmdk%≫" -d thin "≪%TARGET THIN FILE.vmdk%≫"
vmkfstools -i "./TurnkeyLinux/TurnkeyLinux.vmdk" -d thin "./TurnkeyLinux/TurnkeyLinux-thin.vmdk"
# after the clone process completes, rename the source (thick) file
mv "./TurnkeyLinux/TurnkeyLinux.vmdk" "./TurnkeyLinux/TurnkeyLinux.vmdk.thick"
# rename the target (thin) file to the original .vmdk file name
mv "./TurnkeyLinux/TurnkeyLinux.vmdk-thin.vmdk" "./TurnkeyLinux/TurnkeyLinux.vmdk"
--------------------------------------------------------------------
Updating the VM Configuration
--------------------------------------------------------------------
01. Back in the ESXi web UI, right click on the VM ≫ Unregister ≫ Click Yes to confirm
02. Select Virtual Machines from the left navigation pane ≫ Click Create/Register VM
03. Select Register an existing virtual machine ≫ Click Next
04. Click the Select one or more virtual machines, a datastore, or a directory button ≫ Browse to the virtual machine directory ≫ Select the .vmx ≫ Click Select
05. Click Next and then Finish
06. Select the virtual machine ≫ Click Edit
07. Expand the Hard disk configuration
08. Verify the Type value now shows Thin provisioned
09. Start the VM to verify it boots and runs without issues
--------------------------------------------------------------------
Cleaning Up
--------------------------------------------------------------------
01. After fully testing that the VM is functional, select Storage from the left navigation pane
02. Click Datastore browser in the main content area
03. Browse to the virtual machine directory
04. Select the original thick .vmdk file (renamed .vmdk.thick earlier)
05. Click Delete ≫ Click Delete again to confirm the action
### Connect with me and others ###
★ Discord: [ Ссылка ]
★ Reddit: [ Ссылка ]
★ Twitter: [ Ссылка ]
Ещё видео!