网关配置错误导致spring boot项目启动慢

问题描述

网卡信息中GATEWAY配置错误,导致该机器可以连接内网,但是连接不上外网。ping DNS时会出现多次请求失败。

[root@xxx ~]# vi /etc/sysconfig/network-scripts/ifcfg-eth0
NAME=eth0
DEVICE=eth0
TYPE=Ethernet
BOOTPROTO=static
ONBOOT=yes
IPADDR=192.168.139.203
NETMASK=255.255.240.0
GATEWAY=192.168.128.100 
[root@xxx ~]# ping 114.114.114.114
PING 114.114.114.114 (114.114.114.114) 56(84) bytes of data.
From 192.168.139.203 icmp_seq=1 Destination Host Unreachable
From 192.168.139.203 icmp_seq=2 Destination Host Unreachable
From 192.168.139.203 icmp_seq=3 Destination Host Unreachable
From 192.168.139.203 icmp_seq=4 Destination Host Unreachable
From 192.168.139.203 icmp_seq=5 Destination Host Unreachable
From 192.168.139.203 icmp_seq=6 Destination Host Unreachable
From 192.168.139.203 icmp_seq=7 Destination Host Unreachable
From 192.168.139.203 icmp_seq=8 Destination Host Unreachable
^C
--- 114.114.114.114 ping statistics ---
8 packets transmitted, 0 received, +8 errors, 100% packet loss, time 7000ms
pipe 4

使用apache-tomcat-7.0.69发布war格式打包的springboot项目,执行bin/startup.sh。

.   ____          _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v1.5.3.RELEASE)

Aug 24, 2017 12:23:21 PM org.apache.catalina.startup.HostConfig deployWAR
INFO: Deployment of web application archive /apache-tomcat-7.0.69/webapps/xxx.war has finished in 76,815 ms
Aug 24, 2017 12:23:21 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-9080"]
Aug 24, 2017 12:23:21 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-9009"]
Aug 24, 2017 12:23:21 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 76930 ms

网络配置正常的场景下,

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值