Skip to content

Instantly share code, notes, and snippets.

@kyokuheki
Last active August 9, 2018 03:46
Show Gist options
  • Save kyokuheki/0ced49f13ca1dd83a37512f9504604ec to your computer and use it in GitHub Desktop.
Save kyokuheki/0ced49f13ca1dd83a37512f9504604ec to your computer and use it in GitHub Desktop.
esxi config command
esxcli network vswitch standard portgroup add -p "vlan 1096" -v vSwitch0
esxcli network vswitch standard portgroup set -p "vlan 1096" -v 1096

esxcli network ip interface remove -i vmk1
esxcli network ip interface add -i vmk1 -p "vlan 1096"

esxcli network ip interface ipv6 set -i vmk1 -I 10.0.163.2 -N 255.255.255.128 -t static
esxcli network ip route ipv4 add --gateway 10.0.163.1 -N defaultTcpipStack --network default

esxcli network ip set --ipv6-enabled=true
esxcli network ip interface ipv6 address add --ipv6=xxxx:fa8:f163::2/64 -i vmk1
esxcli network ip route ipv6 add -g xxxx:fa8:f163::1 -N defaultTcpipStack -n default

esxcli system hostname set --host=hv-azm --domain=xxxx.net
ssh
cd /etc/vmware/ssl
mv rui.crt rui.crt.`date +%Y%m%d`
mv rui.key rui.key.`date +%Y%m%d`
cat >rui.crt
cat >rui.key
/etc/init.d/hostd restart
/etc/init.d/vpxa restart

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment