Hi,
some more commands…
Capture Network Packets on the a physical interface
pktcap-uw --uplink vmnic0
List all physical nic’s
esxcli network nic list
List kernel interfaces
esxcfg-vmknic -l
Create a n Kernel interface with a specfic MAC and IP Address and add it to a portgroup
esxcfg-vmknic -a -i 192.168.254.3 -n 255.255.255.0 -M 01:12:34:56:78:90 -p PortGroupName esxcfg-vmknic -p PortGroupName -6 false
Or with DHCP enabled
esxcfg-vmknic -a -i DHCP -M 01:12:34:56:78:90 -p PortGroupName
Delete an Kernel interface
esxcfg-vmknic -d -p PortGroupName
Show routing table
esxcli network ip route ipv4 list
Show arp cache
esxcli network ip neighbor list
List all vSwitches
esxcli network vswitch standard list
Change the physical uplink of an vSwitch
esxcli network vswitch standard uplink remove -u vmnic0 -v vSwitch1 esxcli network vswitch standard uplink add -u vmnic1 -v vSwitch1
Change the uplink priority of the physical adapters
esxcli network vswitch standard portgroup policy failover set -p MyPortgroup --active-uplinks vmnic0 --standby-uplinks vSwitch1
List all portgroups
esxcli network vswitch standard portgroup list
Add a new portgroup at the vSwitch to which the Kernel Interface should connected
esxcli network vswitch standard portgroup add -p "PG vMotion" -v vSwitch0
Set the VLAN id
esxcli network vswitch standard portgroup set --vlan-id 0 -p "PG vMotion"
Add a Kernel interface to the new Portgroup
esxcfg-vmknic –a -i 192.168.254.5 -n 255.255.255.0 "PG vMotion"
or, for example, recreating the vmk0 Kernel Interface
esxcli network ip interface remove --interface-name=vmk0 esxcli network ip interface add --interface-name=vmk0 -p "Management Network" -M 01:12:34:56:78:90 esxcli network ip interface ipv4 set --interface-name=vmk0 --ipv4=192.168.254.5 --netmask=255.255.255.0 --type=static
Set Interface as Management Network
esxcli network ip interface tag add -i vmk0 -t Management
Set Default Gateway
esxcfg-route -a default 192.168.254.1
Michael