我是新手,不知道如何将我的机器公开。我使用 WIFI USB 卡适配器上网,并使用安卓手机作为热点。
这是 route -n 的输出
frozenmafia@frozenmafia-H81M-S:~$ route -n
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.43.1 0.0.0.0 UG 600 0 0 wlxd03745b828ea
169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 wlxd03745b828ea
192.168.43.0 0.0.0.0 255.255.255.0 U 600 0 0 wlxd03745b828ea
这是 ifconfig 的输出
frozenmafia@frozenmafia-H81M-S:~$ ifconfig
enp3s0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
ether 40:8d:5c:a5:eb:f9 txqueuelen 1000 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
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
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (Local Loopback)
RX packets 5249 bytes 490718 (490.7 KB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 5249 bytes 490718 (490.7 KB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
wlxd03745b828ea: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 192.168.43.152 netmask 255.255.255.0 broadcast 192.168.43.255
inet6 fe80::2a06:7ce0:e44b:36d0 prefixlen 64 scopeid 0x20<link>
ether d0:37:45:b8:28:ea txqueuelen 1000 (Ethernet)
RX packets 4865 bytes 57887713 (57.8 MB)
RX errors 0 dropped 287 overruns 0 frame 0
TX packets 5067 bytes 6296300 (6.2 MB)
TX errors 0 dropped 35 overruns 0 carrier 0 collisions 0
这是 status ufw status 的输出
frozenmafia@frozenmafia-H81M-S:~$ sudo ufw status
[sudo] password for frozenmafia:
Status: active
To Action From
-- ------ ----
Apache Full ALLOW Anywhere
8080 ALLOW Anywhere
80/tcp ALLOW Anywhere
Apache Full (v6) ALLOW Anywhere (v6)
8080 (v6) ALLOW Anywhere (v6)
80/tcp (v6) ALLOW Anywhere (v6)
这是 sudo netstat -tlpn 的输出
frozenmafia@frozenmafia-H81M-S:~$ sudo netstat -tlpn
[sudo] password for frozenmafia:
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 0.0.0.0:139 0.0.0.0:* LISTEN 2365/smbd
tcp 0 0 127.0.0.53:53 0.0.0.0:* LISTEN 683/systemd-resolve
tcp 0 0 127.0.0.1:631 0.0.0.0:* LISTEN 733/cupsd
tcp 0 0 0.0.0.0:445 0.0.0.0:* LISTEN 2365/smbd
tcp6 0 0 :::139 :::* LISTEN 2365/smbd
tcp6 0 0 :::80 :::* LISTEN 973/apache2
tcp6 0 0 ::1:631 :::* LISTEN 733/cupsd
tcp6 0 0 :::445 :::* LISTEN 2365/smbd
我正在证明我的公共 IP 数据。
我可以在手机浏览器和 UBUNTU 桌面上访问我的网页,但无法在任何其他设备上访问。
现在,我不知道该怎么做。我的设置可以吗?这会起作用吗?如果有人能用简单的语言向我解释并提供永久的解决方案,我将不胜感激。
谢谢