【仅KVM机器有IPV6】
IPV6仅能自行于主机上使用命令查看
ip -6 addr show scope global | grep -oP '(?<=inet6 )[0-9a-f:]+' | grep -vE '^(fc|fd)[0-9a-f:]' | head -n1
因IPV6为DHCPv6配发,若长时间未使用则会被收回。
KVM主机可以使用以下命令稳定IPV6不因为闲置而被收回
echo 'iface eth0 inet6 auto' >> /etc/network/interfaces
systemctl restart networking