template for best practices guide - wordpress.com · nutanix@cvm$ acli net.list network name...
TRANSCRIPT
![Page 1: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/1.jpg)
![Page 2: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/2.jpg)
![Page 3: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/3.jpg)
![Page 4: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/4.jpg)
![Page 5: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/5.jpg)
![Page 6: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/6.jpg)
![Page 7: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/7.jpg)
![Page 8: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/8.jpg)
![Page 9: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/9.jpg)
o
o
o
o
![Page 10: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/10.jpg)
![Page 11: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/11.jpg)
![Page 12: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/12.jpg)
nutanix@CVM$ manage_ovs --bridge_name br0 show_uplinks
Uplink ports: bond0 Uplink ifaces: eth3 eth2
nutanix@CVM$ manage_ovs show_interfaces
name mode link speed eth0 1000 True 1000 eth1 1000 True 1000 eth2 10000 True 10000 eth3 10000 True 10000
nutanix@CVM$ ssh [email protected] "ovs-appctl bond/show bond0"
---- bond0 ---- bond_mode: active-backup bond-hash-basis: 0 updelay: 0 ms downdelay: 0 ms lacp_status: off
slave eth2: enabled may_enable: true
slave eth3: enabled active slave may_enable: true
nutanix@CVM$ ssh [email protected] "ovs-vsctl show"
![Page 13: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/13.jpg)
4d060060-0f23-4e47-bbea-a28c344525cc Bridge "br0" Port "vnet0" Interface "vnet0" Port "br0-dhcp" Interface "br0-dhcp" type: vxlan options: {key="2", remote_ip="10.4.56.84"} Port "br0" Interface "br0" type: internal Port "br0-arp" Interface "br0-arp" type: vxlan options: {key="2", remote_ip="192.168.5.2"} Port "bond0" Interface "eth2" Interface "eth3" ovs_version: "2.3.2"
![Page 14: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/14.jpg)
nutanix@CVM$ acli
<acropolis> net.list
Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266 VLAN 27 vlan.0 a1850d8a-a4e0-4dc9-b247-1849ec97b1ba VLAN 0
<acropolis> net.list_vms vlan.0
VM UUID VM name MAC address 7956152a-ce08-468f-89a7-e377040d5310 VM1 52:54:00:db:2d:11 47c3a7a2-a7be-43e4-8ebf-c52c3b26c738 VM2 52:54:00:be:ad:bc 501188a6-faa7-4be0-9735-0e38a419a115 VM3 52:54:00:0c:15:35
nutanix@CVM$ allssh "manage_ovs show_interfaces"
nutanix@CVM$ allssh "manage_ovs --bridge_name bridge show_uplinks"
nutanix@CVM$ allssh "manage_ovs --bridge_name bridge --interfaces <interfaces> update_uplinks"
![Page 15: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/15.jpg)
manage_ovs
nutanix@CVM$ manage_ovs --help
USAGE: manage_ovs [flags] <action>
nutanix@CVM$ ssh [email protected] "ovs-vsctl add-br br1"
![Page 16: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/16.jpg)
nutanix@CVM$ manage_ovs --bridge_name br0 --bond_name bond0 --interfaces 10g update_uplinks
nutanix@CVM$ manage_ovs --bridge_name br1 --bond_name bond1 --interfaces 1g update_uplinks
nutanix@CVM$ ssh [email protected] "ovs-vsctl add-br br1"
![Page 17: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/17.jpg)
nutanix@CVM$ ssh [email protected] "ovs-vsctl add-br br2"
nutanix@CVM$ manage_ovs --bridge_name br0 --bond_name bond0 --interfaces eth4,eth5 update_uplinks
nutanix@CVM$ manage_ovs --bridge_name br1 --bond_name bond1 --interfaces eth2,eth3 update_uplinks
nutanix@CVM$ manage_ovs --bridge_name br2 --bond_name bond2 --interfaces eth0,eth1 update_uplinks
![Page 18: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/18.jpg)
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port br0 tag=10"
nutanix@CVM$ ssh [email protected] "ovs-vsctl list port br0"
nutanix@CVM$ change_cvm_vlan 10
nutanix@CVM$ ssh [email protected] "ovs-appctl bond/show"
![Page 19: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/19.jpg)
---- bond0 ----
bond_mode: active-backup
bond-hash-basis: 0
updelay: 0 ms
downdelay: 0 ms
lacp_status: off
slave eth2: enabled
active slave
may_enable: true
slave eth3: enabled
may_enable: true
![Page 20: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/20.jpg)
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 bond_mode=active-backup"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 bond_mode=balance-slb"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 other_config:bond-rebalance-interval=60000"
![Page 21: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/21.jpg)
nutanix@CVM$ ssh [email protected] "ovs-appctl bond/show bond0"
---- bond0 ----
bond_mode: balance-slb
bond-hash-basis: 0
updelay: 0 ms
downdelay: 0 ms
next rebalance: 59108 ms
lacp_status: off
slave eth2: enabled
may_enable: true
hash 120: 138065 kB load
hash 182: 20 kB load
slave eth3: enabled
active slave
may_enable: true
hash 27: 0 kB load
hash 31: 20 kB load
hash 104: 1802 kB load
hash 206: 20 kB load
![Page 22: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/22.jpg)
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 lacp=active"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 bond_mode=balance-tcp"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 other_config:lacp-fallback-ab=true"
![Page 23: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/23.jpg)
nutanix@CVM$ ssh [email protected] "ip link set dev eth0 mtu 9000"
nutanix@CVM$ ssh [email protected] "ip link set dev eth1 mtu 9000"
o
o
o
o
![Page 24: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/24.jpg)
![Page 25: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/25.jpg)
![Page 26: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/26.jpg)
o
o
o
o
![Page 27: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/27.jpg)
o
o
nutanix@CVM$ acli ha.update num_host_failures_to_tolerate=X
o
o
o
o nutanix@CVM$ acli ha.update reservation_type=kAcropolisHAReserveHosts
o
o nutanix@CVM$ acli ha.update reservation_type=kAcropolisHAReserveSegments
![Page 28: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/28.jpg)
nutanix@CVM$ acli vm.update <VM Name> ha_priority=-1
nutanix@CVM$ acli vm.create <VM Name> ha_priority=-1
o
o
o
o
o
o
o
![Page 29: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/29.jpg)
o a
o
bandwidth_mbps=X
nutanix@CVM$ acli vm.migrate slow-lane-VM1 bandwidth_mbps=100 host=10.10.10.11 live=yes
o
o
![Page 30: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/30.jpg)
o
o
o
o
o
nutanix@cvm$ allssh "virsh capabilities | egrep 'cell id|cpus num|memory unit'"
![Page 31: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/31.jpg)
Executing virsh capabilities | egrep 'cell id|cpus num|memory unit' on the cluster
================== 10.4.56.82 =================
<cell id='0'>
<memory unit='KiB'>134181480</memory>
<cpus num='20'>
<cell id='1'>
<memory unit='KiB'>134217728</memory>
<cpus num='20'>
root@AHVHost# virsh list --all | grep CVM
root@AHVHost# virsh shutdown cvm_name
a. root@AHVHost# virsh setmaxmem cvm_name --config --size 32GiB
b. root@AHVHost# virsh setmem cvm_name --config --size 32GiB start
a. root@AHVHost# virsh dumpxml cvm_name | grep -I memory
a. root@AHVHost# virsh start cvm_name
![Page 32: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/32.jpg)
RAM Required = VM configured RAM + (150 MB) + (10 MB * Number of VM CPUs)
nutanix@CVM$ ssh [email protected] "cat /sys/kernel/mm/transparent_hugepage/enabled"
[always] madvise never
![Page 33: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/33.jpg)
![Page 34: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/34.jpg)
![Page 35: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/35.jpg)
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
![Page 37: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/37.jpg)
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
o
![Page 38: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/38.jpg)
nutanix@CVM$ manage_ovs --bridge_name br0 show_uplinks
nutanix@CVM$ ssh [email protected] "ovs-appctl bond/show bond0"
nutanix@CVM$ ssh [email protected] "ovs-vsctl show"
nutanix@CVM$ acli
<acropolis> net.list
<acropolis> net.list_vms vlan.0
nutanix@CVM$ allssh "manage_ovs show_interfaces"
nutanix@CVM$ allssh "manage_ovs --bridge_name bridge show_uplinks"
nutanix@CVM$ allssh "manage_ovs --bridge_name bridge --interfaces <interfaces> update_uplinks"
nutanix@CVM$ ssh [email protected] "ovs-vsctl add-br br1"
nutanix@CVM$ manage_ovs --bridge_name br0 --bond_name bond0 --interfaces 10g update_uplinks
nutanix@CVM$ manage_ovs --bridge_name br1 --bond_name bond1 --interfaces 1g update_uplinks
nutanix@CVM$ ssh [email protected] "ovs-vsctl add-br br1"
nutanix@CVM$ ssh [email protected] "ovs-vsctl add-br br2"
nutanix@CVM$ manage_ovs --bridge_name br0 --bond_name bond0 --interfaces eth4,eth5 update_uplinks
nutanix@CVM$ manage_ovs --bridge_name br1 --bond_name bond1 --interfaces eth2,eth3 update_uplinks
nutanix@CVM$ manage_ovs --bridge_name br2 --bond_name bond2 --interfaces eth0,eth1 update_uplinks
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port br0 tag=10"
nutanix@CVM$ ssh [email protected] "ovs-vsctl list port br0"
nutanix@CVM$ change_cvm_vlan 10
nutanix@CVM$ ssh [email protected] "ovs-appctl bond/show"
![Page 39: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/39.jpg)
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 bond_mode=active-backup"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 bond_mode=balance-slb"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 other_config:bond-rebalance-interval=60000"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 lacp=active"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 bond_mode=balance-tcp"
nutanix@CVM$ ssh [email protected] "ovs-vsctl set port bond0 other_config:lacp-fallback-ab=true"
nutanix@CVM$ ssh [email protected] "ip link set dev eth0 mtu 9000"
nutanix@CVM$ ssh [email protected] "ip link set dev eth1 mtu 9000"
nutanix@CVM$ acli ha.update num_host_failures_to_tolerate=X
nutanix@CVM$ acli ha.update reservation_type=kAcropolisHAReserveHosts
nutanix@CVM$ acli ha.update reservation_type=kAcropolisHAReserveSegments
nutanix@CVM$ acli vm.update <VM Name> ha_priority=-1
nutanix@CVM$ acli vm.create <VM Name> ha_priority=-1
nutanix@CVM$ acli vm.migrate slow-lane-VM1 bandwidth_mbps=100 host=10.10.10.11 live=yes
nutanix@cvm$ allssh "virsh capabilities | egrep 'cell id|cpus num|memory unit'"
root@AHVHost# virsh list --all | grep CVM
root@AHVHost# virsh shutdown cvm_name
root@AHVHost# virsh setmaxmem cvm_name --config --size 32GiB
root@AHVHost# virsh setmem cvm_name --config --size 32GiB start
root@AHVHost# virsh dumpxml cvm_name | grep -I memory
root@AHVHost# virsh start cvm_name
![Page 40: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/40.jpg)
nutanix@CVM$ ssh [email protected] "cat /sys/kernel/mm/transparent_hugepage/enabled"
[always] madvise never
![Page 41: Template for Best Practices Guide - WordPress.com · nutanix@CVM$ acli net.list Network name Network UUID Type Identifier Production ea8468ec-c1ca-4220-bc51-714483c6a266](https://reader034.vdocuments.site/reader034/viewer/2022052102/603cb1dc74df362280708626/html5/thumbnails/41.jpg)