Skip to content

VMware Workstation | Cheatsheet

VMware Workstation Pro is a hosted hypervisor that runs on x64 versions of Windows and Linux operating systems it enables users to set up virtual machines on a single physical machine and use them simultaneously along with the host machine.


Convert vmdk drive to qcow2

tar -xvf original.ova
qemu-img convert \
   -O qcow2 win10.vmdk harddrive_foo.qcow2

Launch qemu and test your new drive

qemu-system-x86_64 \
   -enable-kvm \
   -cpu host -smp 4  \
   -device usb-ehci,id=ehci \
   -device qemu-xhci,id=xhci \
   -device usb-tablet,bus=xhci.0 \
   -net nic -net user \
   -m 4192 \
   -cdrom harddrive_foo.qcow2

Convert qcow2 drive to vmdk

qemu-img convert \
   -f qcow2 \
   -O vmdk harddrive_foo.qcow2 harddrive_foo.vmdk

vmware-modconfig

Install all required modules for kernel

vmware-modconfig --console --install-all
vmware-modconfig --console --install-status
vmware-modconfig --console --get-gcc

Generate properties file

vmware-modconfig --console --generate-prop-file

Uninstall vmware-workstation

y|./vmware-workstation.bundle \
   --uninstall-product vmware-workstation
Configure modules for vmware-workstation released =<2020
#!/bin/bash
# Author: wuseman
# Desc: Configure modules for vmware-workstation (workaround)

tmpPath='/tmp/patch-vmware'
vmwareVersion='workstation-12.5.9'


   rm -rf -v ${tmpPath}
   mkdir -v -p ${tmpPath}
   cd ${tmpPath}

   git clone https://github.com/mkubecek/vmware-host-modules.git
   cd ${tmpPath}/vmware-host-modules
   git checkout ${vmwareVersio}
   git fetch
   make -j$(nproc)
   make install

   cp /usr/lib/vmware/lib/libz.so.1/libz.so.1 /usr/lib/vmware/lib/libz.so.1/libz.so.1.old
   ln -s /lib/x86_64-linux-gnu/libz.so.1 /usr/lib/vmware/lib/libz.so.1/libz.so.1
vmware-networks --status

Start vmware network

vmware-networks --start

Stop all network interfaces in use

vmware-networks --stop

Migrate network settings

vmware-networks --migrate-network-settings <settings_file>

vmware-vmx

Launch vmware machie from cli
/usr/lib/vmware/bin/vmware-vmx \
   -s vmx.stdio.keep=TRUE \
   -# product=1;name=VMware Workstation;version=16.1.2;buildnumber=17966106;licensename=VMware Workstation;licenseversion=16.0; \
   -@ duplex=3;msgs=ui /home/wuseman/vmware/windows/windows.10/windows_v10-x64/windows_v10-x64.vmx

Ping from vmware host with interval

vmware-ping localhost -i N

Ping from vmware host and add interval for timeout

vmware-ping localhost -t N

vmware-natd

/usr/bin/vmnet-natd -s 6 \
   -m /etc/vmware/vmnet8/nat.mac \
   -c /etc/vmware/vmnet8/nat/nat.conf

Run dhcpd for your vmware enviroment

/usr/bin/vmnet-dhcpd -s 6 \
   -cf /etc/vmware/vmnetX/dhcpd/dhcpd.conf \
   -lf /etc/vmware/vmnetX/dhcpd/dhcpd.leases \
   -pf /var/run/vmnet-dhcpd-vmnet1.pid vmnetX

Show vmware power status for vmware in tray

vmware-tray poweredOn

vmware files

Location Description
/etc/vmware/vmnet8/nat/nat.conf Network configuration for nat

vmware-fuse

vmware-fuseUI -s -r 8 -w 11 -p 23019
Reference(s)

Comments