升到pve9後
pvesh get /cluster/resources 的欄位有變
修正如下
pvesh get /cluster/resources|awk '{print $46" "$2" "$36" "$8}'|grep -E "lxc|qemu"|sed 's/....$//' > /tmp/all_guest_cpu
原來是
pvesh get /cluster/resources|awk '{print $41" "$2" "$33" "$8}'|grep -E "lxc|qemu"|sed 's/....$//' > /tmp/all_guest_cpu
主要是要拿 host name,guest id,guest name,guest cpu
沒有留言:
張貼留言