我不能在端口80远程访问我的服务器。首先,我没有设置它。 别人做了。 我不是系统pipe理员。 但是这两个部分(我和系统pipe理员)之间的沟通需要时间和截止date,所以我决定把事情交给我自己。 毕竟我有root权限。
在我看来有一个防火墙问题,但我该如何解决?
这是我从我身边得到的:
chris@mint-desktop ~ $ nmap -Pn remote_server -p 80 Starting Nmap 6.00 ( http://nmap.org ) at 2014-07-01 16:28 EEST Nmap scan report for remote_server (remote_addr) Host is up. rDNS record for remote_addr: rDNS_record_for_remote_addr_seems_valid PORT STATE SERVICE 80/tcp filtered http Nmap done: 1 IP address (1 host up) scanned in 2.13 seconds
这是我得到的服务器端:
~# ps ax|grep "apache" 5620 ? Ss 0:13 /usr/sbin/apache2 -k start 6203 pts/2 S+ 0:00 grep apache 21115 ? S 0:00 /usr/sbin/apache2 -k start 21168 ? S 0:00 /usr/sbin/apache2 -k start
和…
~# netstat -ntlp | grep :80 tcp6 0 0 :::80 :::* LISTEN 5620/apache2
也…
~# iptables -L -n Chain INPUT (policy ACCEPT) target prot opt source destination Chain FORWARD (policy ACCEPT) target prot opt source destination Chain OUTPUT (policy ACCEPT) target prot opt source destination
最后
cat /var/log/apache2/access.log ::1 - - [29/Jun/2014:07:35:02 +0100] "OPTIONS * HTTP/1.0" 200 126 "-" "Apache/2.2.22 (Debian) (internal dummy connection)" ::1 - - [29/Jun/2014:07:35:02 +0100] "OPTIONS * HTTP/1.0" 200 126 "-" "Apache/2.2.22 (Debian) (internal dummy connection)" 192.168.30.40 - - [30/Jun/2014:15:02:00 +0100] "GET / HTTP/1.1" 304 209 "-" "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko"
但是,当我在我的网页浏览器上点击远程名称时,我没有得到任何回应。 日志说,内部昨天有一个命中,但没有外部访问。 所以,我猜系统pipe理员testing了它,并意识到它已经到了。 但我无法访问它。
它看起来像你的服务器上有一个私人的IP。 因此,您需要在指向Web服务器端口80的网关上使用DNAT /端口转发规则。