远程设备无法连接到新的 Arch 安装

远程设备无法连接到新的 Arch 安装

我的网络设置似乎出了问题,有人能从这个信息中看出我做错了什么吗?

似乎可以通过 ssh 连接到机器

然而,任何其他服务似乎都有问题..如果有人能指出我正确的方向,我将非常感激!谢谢

mike@mike-arch:~|⇒  nc -l -p 1234

mike@mike-arch:~|⇒  nc -zvw10 192.168.8.103 1234
Warning: Host 192.168.8.103 isn't authoritative! (direct lookup mismatch)
  192.168.8.103 -> mike-arch  BUT  mike-arch -> 127.0.0.1
192.168.8.103 1234 (search-agent): Connection refused

/etc/主机

mike@mike-arch:~|⇒  cat /etc/hosts
127.0.0.1       mike-arch
127.0.0.1       localhost
::1             mike-arch

iptables

mike@mike-arch:~|⇒  sudo iptables -L                                                                                                                                                                                                                                                      
[sudo] password for mike:                                                                                                                    
Chain INPUT (policy ACCEPT)                                                                                                                  
target     prot opt source               destination  

LIBVIRT_INP  all  --  anywhere             anywhere            

Chain FORWARD (policy DROP)
target     prot opt source               destination         
LIBVIRT_FWX  all  --  anywhere             anywhere            
LIBVIRT_FWI  all  --  anywhere             anywhere            
LIBVIRT_FWO  all  --  anywhere             anywhere            
DOCKER-USER  all  --  anywhere             anywhere            
DOCKER-ISOLATION-STAGE-1  all  --  anywhere             anywhere            
ACCEPT     all  --  anywhere             anywhere             ctstate RELATED,ESTABLISHED
DOCKER     all  --  anywhere             anywhere            
ACCEPT     all  --  anywhere             anywhere            
ACCEPT     all  --  anywhere             anywhere            

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination         
LIBVIRT_OUT  all  --  anywhere             anywhere            

Chain DOCKER (1 references)
target     prot opt source               destination         

Chain DOCKER-ISOLATION-STAGE-1 (1 references)
target     prot opt source               destination         
DOCKER-ISOLATION-STAGE-2  all  --  anywhere             anywhere            
RETURN     all  --  anywhere             anywhere            

Chain DOCKER-ISOLATION-STAGE-2 (1 references)
target     prot opt source               destination         
DROP       all  --  anywhere             anywhere            
RETURN     all  --  anywhere             anywhere            

Chain DOCKER-USER (1 references)
target     prot opt source               destination         
RETURN     all  --  anywhere             anywhere            

Chain LIBVIRT_FWI (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             192.168.122.0/24     ctstate RELATED,ESTABLISHED
REJECT     all  --  anywhere             anywhere             reject-with icmp-port-unreachable

Chain LIBVIRT_FWO (1 references)
target     prot opt source               destination         
ACCEPT     all  --  192.168.122.0/24     anywhere            
REJECT     all  --  anywhere             anywhere             reject-with icmp-port-unreachable

Chain LIBVIRT_FWX (1 references)
target     prot opt source               destination         
ACCEPT     all  --  anywhere             anywhere            

Chain LIBVIRT_INP (1 references)
target     prot opt source               destination         
ACCEPT     udp  --  anywhere             anywhere             udp dpt:domain
ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:domain
ACCEPT     udp  --  anywhere             anywhere             udp dpt:bootps
ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:bootps

Chain LIBVIRT_OUT (1 references)
target     prot opt source               destination         
ACCEPT     udp  --  anywhere             anywhere             udp dpt:domain
ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:domain
ACCEPT     udp  --  anywhere             anywhere             udp dpt:bootpc
ACCEPT     tcp  --  anywhere             anywhere             tcp dpt:bootpc

答案1

在您的主机文件中,您已使用环回地址而不是实际 IP 地址设置主机名。

您的 /etc/hosts 文件应如下所示:

127.0.0.1   localhost
::1         localhost
127.0.1.1   mike-arch

相关内容