求助 lvs-nat 能ping通但无法访问VIP

xiaozhuang314 发布于 2013/05/24 17:30
阅读 2K+
收藏 0
LVS
lvs01: 
        eth0:10.78.60.6
         eth1:10.78.104.2      #外网vip 
web01:
        eth0:10.78.60.1
        gw  : 10.78.60.6

iptables和selinux已关闭
# cat /proc/sys/net/ipv4/ip_forward
1

[root@lvs01 ~]# lsmod | grep ip_vs
ip_vs_sh                1949  1 
ip_vs                 115643  3 ip_vs_sh
libcrc32c               1246  1 ip_vs
ipv6                  321454  88 ip_vs,ip6t_REJECT,nf_conntrack_ipv6,nf_defrag_ipv6

root@lvs01 ~]# uname -a
Linux lvs01 2.6.32-358.6.2.el6.x86_64 #1 SMP Thu May 16 20:59:36 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux

[root@lvs01 ~]# modinfo ip_vs
filename:       /lib/modules/2.6.32-358.6.2.el6.x86_64/kernel/net/netfilter/ipvs/ip_vs.ko
license:        GPL
srcversion:     8D67D0A4DA48741A8B71BEB
depends:        ipv6,libcrc32c
vermagic:       2.6.32-358.6.2.el6.x86_64 SMP mod_unload modversions 

#ipvsadm -ln
  -> RemoteAddressort           Forward Weight ActiveConn InActConn
TCP  10.78.104.2:80 rr
  -> 10.78.60.1:80                Route   1      0          0  

# ipvsadm -lnc
IPVS connection entries
pro expire state       source             virtual            destination
TCP 00:09   SYN_RECV    10.78.104.3:37018  10.78.104.2:80     10.78.60.1:80

# wget http://10.78.104.2/index.html
--2013-05-13 14:09:42--  http://10.78.104.2/index.html
Connecting to 10.78.104.2:80... failed: Connection refused.

加载中
0
玖零
玖零
网关的设置有问题,把内网的网关指定到lvs上即可。
返回顶部
顶部