我是ubuntu服务器的新手。我试图在服务器上打开端口9090进行openfire,但是无法这样做。我在我们的服务器上安装了ufw。
到目前为止我做了什么。
nmap localhost -p 9090
Starting Nmap 6.40 ( http://nmap.org ) at 2015-04-21 12:36 IST
Nmap scan report for localhost (127.0.0.1)
Host is up (0.000044s latency).
Other addresses for localhost (not scanned): 127.0.0.1
PORT STATE SERVICE
9090/tcp closed zeus-admin
Nmap done: 1 IP address (1 host up) scanned in 0.03 seconds
输出 sudo ufw status
Status: active
To Action From
-- ------ ----
9091/tcp ALLOW Anywhere
5222/tcp ALLOW Anywhere
7777/tcp ALLOW Anywhere
7443/tcp ALLOW Anywhere
7070/tcp ALLOW Anywhere
3478/tcp ALLOW Anywhere
3479/tcp ALLOW Anywhere
22 ALLOW Anywhere
80 ALLOW Anywhere
3306 ALLOW Anywhere
22/tcp ALLOW Anywhere
9090/tcp ALLOW Anywhere
9090 ALLOW Anywhere
9091/tcp (v6) ALLOW Anywhere (v6)
5222/tcp (v6) ALLOW Anywhere (v6)
7777/tcp (v6) ALLOW Anywhere (v6)
7443/tcp (v6) ALLOW Anywhere (v6)
7070/tcp (v6) ALLOW Anywhere (v6)
3478/tcp (v6) ALLOW Anywhere (v6)
3479/tcp (v6) ALLOW Anywhere (v6)
22 (v6) ALLOW Anywhere (v6)
3306 (v6) ALLOW Anywhere (v6)
22/tcp (v6) ALLOW Anywhere (v6)
9090/tcp (v6) ALLOW Anywhere (v6)
9090 (v6) ALLOW Anywhere (v6)
使用ufw删除9090端口并再次添加。但它的显示端口仍然关闭。
nmap outpu
nmap localhost
Starting Nmap 6.40 ( http://nmap.org ) at 2015-04-21 12:42 IST
Nmap scan report for localhost (127.0.0.1)
Host is up (0.00037s latency).
Other addresses for localhost (not scanned): 127.0.0.1
Not shown: 997 closed ports
PORT STATE SERVICE
22/tcp open ssh
80/tcp open http
3306/tcp open mysql
Nmap done: 1 IP address (1 host up) scanned in 0.05 seconds
任何人都可以帮助我解决问题
答案 0 :(得分:1)
您不仅需要允许使用ufw
访问端口,还需要一个程序来监听该端口,以便将其视为开放。
您可以使用lsof -i :9090
或netstat -tln | grep 9090
等命令检查端口9090上是否有某些内容正在侦听。
答案 1 :(得分:0)
这是因为您没有应用程序侦听端口。 nmap结果有六种端口状态。 closed
州为A closed port is accessible (it receives and responds to Nmap probe packets), but there is no application listening on it.
您可以参考nmap链接,了解有关这六个州的更多信息。