云服务器内容精选

  • 卸载容器 在虚拟机上执行以下命令,获取asm-proxy容器ID。 docker ps | grep asm-proxy 回显第一列为asm-proxy容器的ID。 46afed024f46 asm-proxy:1.8.4 "/usr/bin/bash /usr/..." 2 days ago Up 2 days asm-proxy 执行以下命令,停止asm-proxy容器。 docker rm -f xxx 其中,xxx为1获取的asm-proxy容器ID。
  • 删除已添加的iptables规则 以root用户登录虚拟机。 执行以下命令删除添加的istio iptables规则。 iptables -t nat -D PREROUTING -p tcp -j ISTIO_INBOUND iptables -t nat -D OUTPUT -p tcp -j ISTIO_OUTPUT iptables -t nat -F ISTIO_OUTPUT iptables -t nat -X ISTIO_OUTPUT iptables -t nat -F ISTIO_INBOUND iptables -t nat -X ISTIO_INBOUND iptables -t nat -F ISTIO_REDIRECT iptables -t nat -X ISTIO_REDIRECT iptables -t nat -F ISTIO_IN_REDIRECT iptables -t nat -X ISTIO_IN_REDIRECT iptables-save 执行以下命令查看虚拟机当前的iptables规则。 iptables -t nat -L -v 回显如下,可以看到istio相关规则已经清除。 Chain PREROUTING (policy ACCEPT 2 packets, 104 bytes) pkts bytes target prot opt in out source destination 47 2498 DOCKER all -- any any anywhere anywhere ADDRTYPE match dst-type LOCALChain INPUT (policy ACCEPT 2 packets, 104 bytes) pkts bytes target prot opt in out source destination Chain OUTPUT (policy ACCEPT 5 packets, 350 bytes) pkts bytes target prot opt in out source destination 0 0 DOCKER all -- any any anywhere !localhost/8 ADDRTYPE match dst-type LOCALChain POSTROUTING (policy ACCEPT 5 packets, 350 bytes) pkts bytes target prot opt in out source destination 0 0 MASQUERADE all -- any !docker0 172.17.0.0/16 anywhere Chain DOCKER (2 references) pkts bytes target prot opt in out source destination 0 0 RETURN all -- docker0 any anywhere anywhere