給ECS虛擬機(jī)配置VIP,無法通訊,原因?
站在用戶的角度思考問題,與客戶深入溝通,找到杜集網(wǎng)站設(shè)計(jì)與杜集網(wǎng)站推廣的解決方案,憑借多年的經(jīng)驗(yàn),讓設(shè)計(jì)與互聯(lián)網(wǎng)技術(shù)結(jié)合,創(chuàng)造個(gè)性化、用戶體驗(yàn)好的作品,建站類型包括:網(wǎng)站建設(shè)、成都網(wǎng)站設(shè)計(jì)、企業(yè)官網(wǎng)、英文網(wǎng)站、手機(jī)端網(wǎng)站、網(wǎng)站推廣、國際域名空間、網(wǎng)絡(luò)空間、企業(yè)郵箱。業(yè)務(wù)覆蓋杜集地區(qū)。
[root@pg11 ~]# ip addr show eth0 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000 link/ether 00:16:3e:0a:5c:f1 brd ff:ff:ff:ff:ff:ff inet 172.17.20.29/20 brd 172.17.31.255 scope global dynamic eth0 valid_lft 313883835sec preferred_lft 313883835sec
postgres@pg11-> ip addr show eth0 2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP qlen 1000 link/ether 00:16:3e:12:2f:48 brd ff:ff:ff:ff:ff:ff inet 172.17.20.30/20 brd 172.17.31.255 scope global dynamic eth0 valid_lft 313883847sec preferred_lft 313883847sec
相互可以訪問
a ping b ping 172.17.20.29 PING 172.17.20.29 (172.17.20.29) 56(84) bytes of data. 64 bytes from 172.17.20.29: icmp_seq=1 ttl=64 time=0.156 ms 64 bytes from 172.17.20.29: icmp_seq=2 ttl=64 time=0.102 ms b ping a ping 172.17.20.30 PING 172.17.20.30 (172.17.20.30) 56(84) bytes of data. 64 bytes from 172.17.20.30: icmp_seq=1 ttl=64 time=0.166 ms 64 bytes from 172.17.20.30: icmp_seq=2 ttl=64 time=0.112 ms
配置VIP,無法跨機(jī)訪問
host a
[root@pg11 ~]# ip addr add 172.17.20.39/20 brd + dev eth0 label eth0:1 [root@pg11 ~]# ifconfig eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 172.17.20.29 netmask 255.255.240.0 broadcast 172.17.31.255 ether 00:16:3e:0a:5c:f1 txqueuelen 1000 (Ethernet) RX packets 22221492822 bytes 33552649055304 (30.5 TiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 631860042 bytes 42907936724 (39.9 GiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 eth0:1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 172.17.20.39 netmask 255.255.240.0 broadcast 172.17.31.255 ether 00:16:3e:0a:5c:f1 txqueuelen 1000 (Ethernet) lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 loop txqueuelen 1 (Local Loopback) RX packets 959417 bytes 111291935 (106.1 MiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 959417 bytes 111291935 (106.1 MiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 [root@pg11 ~]# ping 172.17.20.39 PING 172.17.20.39 (172.17.20.39) 56(84) bytes of data. 64 bytes from 172.17.20.39: icmp_seq=1 ttl=64 time=0.012 ms 64 bytes from 172.17.20.39: icmp_seq=2 ttl=64 time=0.008 ms
host b
[root@pg11 ~]# ping 172.17.20.39 PING 172.17.20.39 (172.17.20.39) 56(84) bytes of data.
無防火墻
[root@pg11 ~]# iptables -L -v -n Chain INPUT (policy ACCEPT 8 packets, 528 bytes) pkts bytes target prot opt in out source destination Chain FORWARD (policy ACCEPT 0 packets, 0 bytes) pkts bytes target prot opt in out source destination Chain OUTPUT (policy ACCEPT 6 packets, 1000 bytes) pkts bytes target prot opt in out source destination
宿主機(jī)通過openflow進(jìn)行流控,未注冊的vm+ip可以被拒絕。具體可參考SDN文檔。
刪除VIP
[root@pg11 ~]# ip addr del 172.17.20.39/20 brd + dev eth0 label eth0:1 [root@pg11 ~]# ifconfig eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 172.17.20.29 netmask 255.255.240.0 broadcast 172.17.31.255 ether 00:16:3e:0a:5c:f1 txqueuelen 1000 (Ethernet) RX packets 22221492889 bytes 33552649060975 (30.5 TiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 631860095 bytes 42907943783 (39.9 GiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 loop txqueuelen 1 (Local Loopback) RX packets 959424 bytes 111292619 (106.1 MiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 959424 bytes 111292619 (106.1 MiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
《linux IP 命令使用舉例》
A Virtual Switch Platform for Host SDN in the Public Cloud
https://www.microsoft.com/en-us/research/wp-content/uploads/2017/09/login_fall17_02_firestone.pdf
https://www.opennetworking.org/
https://www.cisco.com/c/en/us/about/press/internet-protocol-journal/back-issues/table-contents-59/161-sdn.html
https://en.wikipedia.org/wiki/OpenFlow
原文地址:https://github.com/digoal/blog/blob/master/201810/20181005_01.md
新聞名稱:關(guān)于ECS無法使用VIP的問題-SDN,openflow
標(biāo)題來源:http://aaarwkj.com/article42/pdiehc.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供電子商務(wù)、網(wǎng)站策劃、、云服務(wù)器、用戶體驗(yàn)、網(wǎng)站改版
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來源: 創(chuàng)新互聯(lián)