ESXi Commands
Check whether the /tmp directory is full
vdf | grep tmp
System Module
esxcli system module list
esxcli system module set --enabled=false --module=<module-name>
esxcli system module set --enabled=true --module=<module-name>
手動修改 vmx
經由 OVF 匯入 VM 後,設定裡有音效卡無法移除。必須手動修改 vmx 檔,將以下內容移除:
sound.autoDetect = "TRUE"
sound.virtualDev = "hdaudio"
sound.fileName = "-1"
sound.present = "TRUE"
sound.pciSlotNumber = "35"
手動修改 vmx 檔後,還須執行以下指令更新 VM
# Find the Vmid for the affected VM
vim-cmd vmsvc/getallvms
# Reload configuration for the VM
vim-cmd vmsvc/reload <Vmid-of-VM>
Network
[root@tpeitpexb95:~] esxcli network ip interface list
vmk0
Name: vmk0
MAC Address: 80:30:e0:3b:a0:c4
Enabled: true
Portset: vSwitch0
Portgroup: Management Network
Netstack Instance: defaultTcpipStack
VDS Name: N/A
VDS UUID: N/A
VDS Port: N/A
VDS Connection: -1
Opaque Network ID: N/A
Opaque Network Type: N/A
External ID: N/A
MTU: 1500
TSO MSS: 65535
RXDispQueue Size: 1
Port ID: 33554442
vmk1
Name: vmk1
MAC Address: 00:50:56:6b:5c:ed
Enabled: true
Portset: vSwitch1
Portgroup: FT1
Netstack Instance: defaultTcpipStack
VDS Name: N/A
VDS UUID: N/A
VDS Port: N/A
VDS Connection: -1
Opaque Network ID: N/A
Opaque Network Type: N/A
External ID: N/A
MTU: 1500
TSO MSS: 65535
RXDispQueue Size: 1
Port ID: 50331654
vmk2
Name: vmk2
MAC Address: 00:50:56:62:26:d7
Enabled: true
Portset: vSwitch1
Portgroup: FT2
Netstack Instance: defaultTcpipStack
VDS Name: N/A
VDS UUID: N/A
VDS Port: N/A
VDS Connection: -1
Opaque Network ID: N/A
Opaque Network Type: N/A
External ID: N/A
MTU: 1500
TSO MSS: 65535
RXDispQueue Size: 1
Port ID: 50331655
[root@tpeitpexb95:~] esxcli network ip interface ipv4 get
Name IPv4 Address IPv4 Netmask IPv4 Broadcast Address Type Gateway DHCP DNS
---- ------------- ------------- --------------- ------------ ----------- --------
vmk0 10.14.1.95 255.255.248.0 10.14.7.255 STATIC 10.14.0.254 false
vmk1 192.168.101.7 255.255.0.255.0 192.168.255.101.255 STATIC 0.0.0.0 false
vmk2 192.168.103.7 255.255.255.0 192.168.103.255 STATIC 0.0.0.0 false
[root@tpeitpexb95:~] esxcli network ip route ipv4 list
Network Netmask Gateway Interface Source
------------- ------------- ----------- --------- ------
default 0.0.0.0 10.14.0.254 vmk0 MANUAL
10.14.0.0 255.255.248.0 0.0.0.0 vmk0 MANUAL
192.168.101.0 255.255.255.0 0.0.0.0 vmk1 MANUAL
192.168.103.0 255.255.255.0 0.0.0.0 vmk2 MANUAL