![]() | 1 sujin190 2019-03-26 15:12:11 +08:00 只绑定了 127.0.0.1 ? |
2 CallMeReznov 2019-03-26 15:19:16 +08:00 虚拟机网络设置问题 请选择"桥接" |
4 ClancyH OP @CallMeReznov 我没有用虚拟机啊 |
5 CallMeReznov 2019-03-26 15:29:09 +08:00 |
6 2exploring 2019-03-26 15:33:35 +08:00 绑定地址用 0.0.0.0 解君愁 |
![]() | 7 shanlan 2019-03-26 15:41:29 +08:00 为什么开发要用 Ubuntu 呀,Windows 不顺手吗? |
8 ClancyH OP @2exploring 试过了,不行 |
9 ClancyH OP @CallMeReznov 这个是开发电脑不是正式服务器没有外网地址,我关闭了防火墙绑定了局域网地址还是不行 |
![]() | 10 masker 2019-03-26 15:46:49 +08:00 via Android 防火墙规则添加后 reload 了吗,telnet 试下 |
12 ClancyH OP 监听地址默认是 0:0:0:0:9008 改成局域网 ip:9008,两个都不行 |
![]() | 13 lusi1990 2019-03-26 16:55:05 +08:00 telnet ip port 可以测试端口是否通畅 |
![]() | 14 zro 2019-03-26 17:22:15 +08:00 主用过一段时间,一堆迷之 Bug。。又转回 Win10 了 ![]() |
17 aaaaasam 2019-03-27 10:48:25 +08:00 1、先确定一个事情就是,你的虚拟机网段是否和你的本机网段一致; |
19 aaaaasam 2019-03-27 10:51:37 +08:00 2、然后,确定一下你的虚拟机是否可以上网,如果可以说明网络连通性是没有问题的; 3、确定你的网卡模式,是 NAT 模式还是桥接模式,如果是 NAT,更改为桥接就好,如果不想更改桥接,需要在你的公司路由上加路由,到你虚拟机的网络下一跳到你的 IP 上; 4、还可以通过 traceroute 跟踪一下内网其他主机是为什么不能到你的服务器的(判断的话,应该是路由问题,桥接网卡好像并不会受到你本机防火墙的影响) |
22 ClancyH OP 另外在另外一台机器 nmap 扫描是能够扫描到端口而且端口是 open 的 |
24 aaaaasam 2019-03-27 10:54:09 +08:00 可以大概的贴一下内网的网段,然后你服务器绑定的网段么 另外打印一下 iptables -L -n -v |
25 ClancyH OP @aaaaasam 内网网段是 192.168.1.0 服务绑定( netstat -ano|grep 9008 ) tcp6 0 0 192.168.1.159:9008 :::* LISTEN off (0.00/0/0) iptables -L -n -v Chain INPUT (policy ACCEPT 107K packets, 145M bytes) pkts bytes target prot opt in out source destination 1050K 1400M ufw-before-logging-input all -- * * 0.0.0.0/0 0.0.0.0/0 1050K 1400M ufw-before-input all -- * * 0.0.0.0/0 0.0.0.0/0 140K 147M ufw-after-input all -- * * 0.0.0.0/0 0.0.0.0/0 139K 147M ufw-after-logging-input all -- * * 0.0.0.0/0 0.0.0.0/0 139K 147M ufw-reject-input all -- * * 0.0.0.0/0 0.0.0.0/0 139K 147M ufw-track-input all -- * * 0.0.0.0/0 0.0.0.0/0 0 0 ACCEPT tcp -- * * 192.168.1.0/24 0.0.0.0/0 state NEW tcp dpt:9008 Chain FORWARD (policy ACCEPT 0 packets, 0 bytes) pkts bytes target prot opt in out source destination 0 0 ufw-before-logging-forward all -- * * 0.0.0.0/0 0.0.0.0/0 0 0 ufw-before-forward all -- * * 0.0.0.0/0 0.0.0.0/0 0 0 ufw-after-forward all -- * * 0.0.0.0/0 0.0.0.0/0 0 0 ufw-after-logging-forward all -- * * 0.0.0.0/0 0.0.0.0/0 0 0 ufw-reject-forward all -- * * 0.0.0.0/0 0.0.0.0/0 0 0 ufw-track-forward all -- * * 0.0.0.0/0 0.0.0.0/0 Chain OUTPUT (policy ACCEPT 103K packets, 74M bytes) pkts bytes target prot opt in out source destination 988K 681M ufw-before-logging-output all -- * * 0.0.0.0/0 0.0.0.0/0 988K 681M ufw-before-output all -- * * 0.0.0.0/0 0.0.0.0/0 111K 75M ufw-after-output all -- * * 0.0.0.0/0 0.0.0.0/0 111K 75M ufw-after-logging-output all -- * * 0.0.0.0/0 0.0.0.0/0 111K 75M ufw-reject-output all -- * * 0.0.0.0/0 0.0.0.0/0 111K 75M ufw-track-output all -- * * 0.0.0.0/0 0.0.0.0/0 Chain ufw-after-forward (1 references) pkts bytes target prot opt in out source destination Chain ufw-after-input (1 references) pkts bytes target prot opt in out source destination Chain ufw-after-logging-forward (1 references) pkts bytes target prot opt in out source destination Chain ufw-after-logging-input (1 references) pkts bytes target prot opt in out source destination |
26 aaaaasam 2019-03-27 11:09:27 +08:00 看不出来什么问题,给两条建议: 1、关掉防火墙,看看是否还有问题,如果有,就是你网络的问题,如果没有就是防火墙的问题; 2、如果是网络问题,可以通过 traceroute 去跟踪数据包试试; |
![]() | 27 tomychen 2019-03-27 12:31:11 +08:00 fw 规则有问题,只有 input 链,没有 output 没做 所以在没有办法确定是不是 fw 的问题的前提就是先 backup 一下 fw rule,先禁用再说。 能 ping 通,说明链路已经通了,至于连接不行,那就是协议层的事。 |
28 ClancyH OP 解决了,前端的机器开了代理服务,三次握手失败 |