我将手放在遗留系统(Xen集群)上,我正在尝试了解它的架构.似乎有监听IP(例如,1.2.3.4)的服务没有出现在ifconfig输出中:
# ifconfig eth0 Link encap:Ethernet HWaddr 00:16:3e:98:46:4b inet addr:3.3.3.3 Bcast:3.3.3.255 Mask:255.255.255.0 inet6 addr: fe80::216:3eff:fe98:464b/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:2701271309 errors:0 dropped:0 overruns:0 frame:0 TX packets:2580523122 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:2013971483375 (1.8 TiB) TX bytes:1994970579127 (1.8 TiB) eth0:0 Link encap:Ethernet HWaddr 00:16:3e:98:46:4b inet addr:10.0.5.4 Bcast:10.0.5.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:12776938 errors:0 dropped:0 overruns:0 frame:0 TX packets:12776938 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:2103144670 (1.9 GiB) TX bytes:2103144670 (1.9 GiB)
如果我有IP监听IP 1.2.3.4,它可以在外面访问:
nc -s 1.2.3.4 -p 8081 -l
(即我可以telnet或nc到1.2.3.4:8081并发送数据).
这使我得出结论,没有NAT.但是,ifconfig为什么不列出IP?
我见过ifconfig没有显示分配给接口的所有地址的情况,但是可以看到ip addr(其中ip来自iproute2包).
原文链接:https://www.f2er.com/ubuntu/348051.html