Ubuntu 22.04 盒子无法 ping 并连接到某些服务

Ubuntu 22.04 盒子无法 ping 并连接到某些服务
iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination         
ufw-before-logging-input  all  --  anywhere             anywhere            
ufw-before-input  all  --  anywhere             anywhere            
ufw-after-input  all  --  anywhere             anywhere            
ufw-after-logging-input  all  --  anywhere             anywhere            
ufw-reject-input  all  --  anywhere             anywhere            
ufw-track-input  all  --  anywhere             anywhere            

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination         
ufw-before-logging-forward  all  --  anywhere             anywhere            
ufw-before-forward  all  --  anywhere             anywhere            
ufw-after-forward  all  --  anywhere             anywhere            
ufw-after-logging-forward  all  --  anywhere             anywhere            
ufw-reject-forward  all  --  anywhere             anywhere            
ufw-track-forward  all  --  anywhere             anywhere            

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination         
ufw-before-logging-output  all  --  anywhere             anywhere            
ufw-before-output  all  --  anywhere             anywhere            
ufw-after-output  all  --  anywhere             anywhere            
ufw-after-logging-output  all  --  anywhere             anywhere            
ufw-reject-output  all  --  anywhere             anywhere            
ufw-track-output  all  --  anywhere             anywhere            

Chain ufw-after-forward (1 references)
target     prot opt source               destination         

Chain ufw-after-input (1 references)
target     prot opt source               destination         

Chain ufw-after-logging-forward (1 references)
target     prot opt source               destination         

Chain ufw-after-logging-input (1 references)
target     prot opt source               destination         

Chain ufw-after-logging-output (1 references)
target     prot opt source               destination         

Chain ufw-after-output (1 references)
target     prot opt source               destination         

Chain ufw-before-forward (1 references)
target     prot opt source               destination         

Chain ufw-before-input (1 references)
target     prot opt source               destination         

Chain ufw-before-logging-forward (1 references)
target     prot opt source               destination         

Chain ufw-before-logging-input (1 references)
target     prot opt source               destination         

Chain ufw-before-logging-output (1 references)
target     prot opt source               destination         

Chain ufw-before-output (1 references)
target     prot opt source               destination         

Chain ufw-reject-forward (1 references)
target     prot opt source               destination         

Chain ufw-reject-input (1 references)
target     prot opt source               destination         

Chain ufw-reject-output (1 references)
target     prot opt source               destination         

Chain ufw-track-forward (1 references)
target     prot opt source               destination         

Chain ufw-track-input (1 references)
target     prot opt source               destination         

Chain ufw-track-output (1 references)
target     prot opt source               destination 

如果我偶尔重新应用 netplan,我可以建立连接一分钟,然后又无法连接。我不确定我配置了什么导致此问题,我在同一个未标记 VLAN 上的其他盒子没有受到影响。

附加接口信息:

user@168:~$ ip route
default via 216.126.237.1 dev enp7s0 proto static metric 200 
default via 168.100.162.64 dev enp7s0 proto static metric 300 
168.100.162.64/31 dev enp7s0 proto kernel scope link src 168.100.162.65 
216.126.237.0/24 dev enp7s0 proto kernel scope link src 216.126.237.26 
user@168:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: enp5s0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN group default qlen 1000
    link/ether a8:a1:59:63:4b:63 brd ff:ff:ff:ff:ff:ff
3: enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc mq state UP group default qlen 1000
    link/ether 00:1b:21:bc:4f:6e brd ff:ff:ff:ff:ff:ff
    inet 168.100.162.65/31 scope global enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.26/24 brd 216.126.237.255 scope global enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.27/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.28/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.29/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.30/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.31/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.32/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.33/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.34/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.35/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.36/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.37/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.38/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.39/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.40/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.41/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.42/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.43/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.44/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.45/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.46/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.47/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet 216.126.237.48/24 brd 216.126.237.255 scope global secondary enp7s0
       valid_lft forever preferred_lft forever
    inet6 fe80::21b:21ff:febc:4f6e/64 scope link 
       valid_lft forever preferred_lft forever
4: 4552338250@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc htb state UP group default qlen 500
    link/ether 00:b7:c3:3c:c9:cb brd ff:ff:ff:ff:ff:ff
    inet6 fe80::2b7:c3ff:fe3c:c9cb/64 scope link 
       valid_lft forever preferred_lft forever
6: 3419880028@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc htb state UP group default qlen 500
    link/ether 00:e8:02:3c:7b:c6 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::2e8:2ff:fe3c:7bc6/64 scope link 
       valid_lft forever preferred_lft forever
7: 2120085243@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc htb state UP group default qlen 500
    link/ether 00:93:95:5e:a1:6f brd ff:ff:ff:ff:ff:ff
    inet6 fe80::293:95ff:fe5e:a16f/64 scope link 
       valid_lft forever preferred_lft forever
8: 4914537162@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc htb state UP group default qlen 500
    link/ether 00:59:1c:2a:36:b8 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::259:1cff:fe2a:36b8/64 scope link 
       valid_lft forever preferred_lft forever
10: 6609085104@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 500
    link/ether 00:8d:f1:e2:b9:49 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::28d:f1ff:fee2:b949/64 scope link 
       valid_lft forever preferred_lft forever
12: 7535403182@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc htb state UP group default qlen 500
    link/ether 00:0a:2a:1b:6a:5e brd ff:ff:ff:ff:ff:ff
    inet6 fe80::20a:2aff:fe1b:6a5e/64 scope link 
       valid_lft forever preferred_lft forever
14: 4092806070@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc htb state UP group default qlen 500
    link/ether 00:32:6a:da:bf:e5 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::232:6aff:feda:bfe5/64 scope link 
       valid_lft forever preferred_lft forever
16: 5585546347@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 500
    link/ether 00:28:d6:8c:3a:70 brd ff:ff:ff:ff:ff:ff
    inet6 fe80::228:d6ff:fe8c:3a70/64 scope link 
       valid_lft forever preferred_lft forever
18: 1916431113@enp7s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 500
    link/ether 00:6a:34:0e:70:0b brd ff:ff:ff:ff:ff:ff
    inet6 fe80::26a:34ff:fe0e:700b/64 scope link 
       valid_lft forever preferred_lft forever

我还想指出的是,机器上的虚拟机可以正常连接到互联网,只是主机出现了问题。

相关内容