Can't ping eth1 via eth0Network routing issues on LinuxPing reply not getting to LAN machines but getting in Linux router GatewayIP address reuse on macvlan devicesRemote end of IPSec transport is 'permenantly glued' to loopback after some messing around with GREarp table entry outside configured networkRoute traffic through private IP for only certain hosts - CentOS 6.6How to configure dual homed server in order for both network segments to communicate?How to add an static route on google compute engineHow to correctly set up routing on machine with 4 interfaces so that three of interfaces are on the same subnet?Linux: Bridging two ethernet connections together to allow second host onto first network
Function to extract float from different price patterns
From system of coupled ODEs to separable ODE
Traffic law UK, pedestrians
How do I write "Show, Don't Tell" as an Asperger?
How is TD(0) method helpful? What good does it do?
Will TSA allow me to carry a Continuous Positive Airway Pressure (CPAP)/sleep apnea device?
Is the decompression of compressed and encrypted data without decryption also theoretically impossible?
Their answer is discrete, mine is continuous. They baited me into the wrong answer. I have a P Exam question
You've spoiled/damaged the card
Can't login after removing Flatpak
Do manufacturers try make their components as close to ideal ones as possible?
What makes linear regression with polynomial features curvy?
Is it a problem that pull requests are approved without any comments
How could a government be implemented in a virtual reality?
Can a magnetic field of an object be stronger than its gravity?
What risks are there when you clear your cookies instead of logging off?
Does the "6 seconds per round" rule apply to speaking/roleplaying during combat situations?
Finding x,y coordinates where y is largest
Why did a party with more votes get fewer seats in the 2019 European Parliament election in Denmark?
Etymology of 'calcit(r)are'?
How do I calculate APR from monthly instalments?
PC video game involving floating islands doing aerial combat
What do we gain with higher order logics?
Why is the relationship between frequency and pitch exponential?
Can't ping eth1 via eth0
Network routing issues on LinuxPing reply not getting to LAN machines but getting in Linux router GatewayIP address reuse on macvlan devicesRemote end of IPSec transport is 'permenantly glued' to loopback after some messing around with GREarp table entry outside configured networkRoute traffic through private IP for only certain hosts - CentOS 6.6How to configure dual homed server in order for both network segments to communicate?How to add an static route on google compute engineHow to correctly set up routing on machine with 4 interfaces so that three of interfaces are on the same subnet?Linux: Bridging two ethernet connections together to allow second host onto first network
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
I have two virtual machines with CentOS 7 installed.
Each VM has two NICs and two IP addresses.
ip configuration of VM1:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:0b:03:33 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.5/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::4f07:27f6:5839:d257/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:4b:2f:58 brd ff:ff:ff:ff:ff:ff
inet 10.11.111.254/21 brd 10.11.111.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::d64c:aeee:1111:16d5/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM1:
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
ip configuration of VM2:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:7a:3c:e7 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.6/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::35e3:6bb7:918e:6bca/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:25:38:9a brd ff:ff:ff:ff:ff:ff
inet 10.10.1.210/24 brd 10.10.1.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::5ec3:f912:51a5:761c/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM2:
10.10.1.0/24 dev eth1 proto kernel scope link src 10.10.1.210 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.6 metric 100
I can ping from VM1(172.255.255.5,10.11.111.254) to 172.255.255.6 and can ping from VM2(172.255.255.6, 10.10.1.210) to 172.255.255.5.
The problem is, I want to ping from VM1(172.255.255.5,10.11.111.254) to 10.10.1.210, so I add a route in VM1
ip route add 10.10.1.210 via 172.255.255.6
so the route of VM1 is:
10.10.1.210 via 172.255.255.6 dev eth0
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
But I still can't ping from VM1 to 10.10.1.210.
So, where am I wrong?
By the way, I have disabled SELinux and firewalld on all my machines.
ip route get 10.10.1.210:
10.10.1.210 via 172.255.255.6 dev eth0 src 172.255.255.5
cachetcpdump -e -nn -i eth0 'icmp' on VM1:
20:47:00.147549 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 48, length 64
20:47:01.147541 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 49, length 64
20:47:02.147543 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 50, length 64
20:47:03.147551 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 51, length 64VM1, iptables-save -c :
*security
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*raw
:PREROUTING ACCEPT [5456:12843525]
:OUTPUT ACCEPT [28969:2491905]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*mangle
:PREROUTING ACCEPT [5456:12843525]
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28969:2491905]
:POSTROUTING ACCEPT [28970:2491949]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*filter
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*nat
:PREROUTING ACCEPT [41:6031]
:INPUT ACCEPT [26:3643]
:OUTPUT ACCEPT [196:139164]
:POSTROUTING ACCEPT [197:139236]
COMMIT
# Completed on Mon May 20 20:48:08 2019```VM2, iptables-save -c :
*nat
:PREROUTING ACCEPT [151:139500]
:INPUT ACCEPT [136:137067]
:OUTPUT ACCEPT [126:76110]
:POSTROUTING ACCEPT [126:76110]
COMMIT
# Completed on Mon May 20 20:51:19 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:51:19 2019
*filter
:INPUT ACCEPT [22121:14364143]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [21468:1823390]
COMMIT
# Completed on Mon May 20 20:51:19 2019```tcpdump -e -nn -i eth0 'icmp' on VM2
20:53:50.348475 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 459, length 64
20:53:50.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 459, length 64
20:53:51.348443 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 460, length 64
20:53:51.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 460, length 64
20:53:52.348432 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 461, length 64
20:53:52.348456 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 461, length 64
linux networking centos linux-networking
add a comment |
I have two virtual machines with CentOS 7 installed.
Each VM has two NICs and two IP addresses.
ip configuration of VM1:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:0b:03:33 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.5/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::4f07:27f6:5839:d257/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:4b:2f:58 brd ff:ff:ff:ff:ff:ff
inet 10.11.111.254/21 brd 10.11.111.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::d64c:aeee:1111:16d5/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM1:
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
ip configuration of VM2:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:7a:3c:e7 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.6/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::35e3:6bb7:918e:6bca/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:25:38:9a brd ff:ff:ff:ff:ff:ff
inet 10.10.1.210/24 brd 10.10.1.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::5ec3:f912:51a5:761c/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM2:
10.10.1.0/24 dev eth1 proto kernel scope link src 10.10.1.210 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.6 metric 100
I can ping from VM1(172.255.255.5,10.11.111.254) to 172.255.255.6 and can ping from VM2(172.255.255.6, 10.10.1.210) to 172.255.255.5.
The problem is, I want to ping from VM1(172.255.255.5,10.11.111.254) to 10.10.1.210, so I add a route in VM1
ip route add 10.10.1.210 via 172.255.255.6
so the route of VM1 is:
10.10.1.210 via 172.255.255.6 dev eth0
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
But I still can't ping from VM1 to 10.10.1.210.
So, where am I wrong?
By the way, I have disabled SELinux and firewalld on all my machines.
ip route get 10.10.1.210:
10.10.1.210 via 172.255.255.6 dev eth0 src 172.255.255.5
cachetcpdump -e -nn -i eth0 'icmp' on VM1:
20:47:00.147549 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 48, length 64
20:47:01.147541 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 49, length 64
20:47:02.147543 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 50, length 64
20:47:03.147551 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 51, length 64VM1, iptables-save -c :
*security
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*raw
:PREROUTING ACCEPT [5456:12843525]
:OUTPUT ACCEPT [28969:2491905]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*mangle
:PREROUTING ACCEPT [5456:12843525]
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28969:2491905]
:POSTROUTING ACCEPT [28970:2491949]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*filter
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*nat
:PREROUTING ACCEPT [41:6031]
:INPUT ACCEPT [26:3643]
:OUTPUT ACCEPT [196:139164]
:POSTROUTING ACCEPT [197:139236]
COMMIT
# Completed on Mon May 20 20:48:08 2019```VM2, iptables-save -c :
*nat
:PREROUTING ACCEPT [151:139500]
:INPUT ACCEPT [136:137067]
:OUTPUT ACCEPT [126:76110]
:POSTROUTING ACCEPT [126:76110]
COMMIT
# Completed on Mon May 20 20:51:19 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:51:19 2019
*filter
:INPUT ACCEPT [22121:14364143]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [21468:1823390]
COMMIT
# Completed on Mon May 20 20:51:19 2019```tcpdump -e -nn -i eth0 'icmp' on VM2
20:53:50.348475 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 459, length 64
20:53:50.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 459, length 64
20:53:51.348443 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 460, length 64
20:53:51.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 460, length 64
20:53:52.348432 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 461, length 64
20:53:52.348456 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 461, length 64
linux networking centos linux-networking
what is the result ofip r s
? have you set default route ?
– Archemar
May 20 at 5:00
Enable IP forwarding on VM2 if not enabled: ip-forwarding, try turning iptables off while testing, or check their rules.
– Sergey Nudnov
May 20 at 5:02
no default route on both machines. ip forwarding(net.ipv4.ip_forward) is enabled on both machines.
– Gary Allen
May 20 at 5:11
eth1's IP are not in same range, you won't be able to connect directly.
– Archemar
May 20 at 9:25
add a comment |
I have two virtual machines with CentOS 7 installed.
Each VM has two NICs and two IP addresses.
ip configuration of VM1:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:0b:03:33 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.5/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::4f07:27f6:5839:d257/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:4b:2f:58 brd ff:ff:ff:ff:ff:ff
inet 10.11.111.254/21 brd 10.11.111.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::d64c:aeee:1111:16d5/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM1:
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
ip configuration of VM2:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:7a:3c:e7 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.6/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::35e3:6bb7:918e:6bca/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:25:38:9a brd ff:ff:ff:ff:ff:ff
inet 10.10.1.210/24 brd 10.10.1.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::5ec3:f912:51a5:761c/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM2:
10.10.1.0/24 dev eth1 proto kernel scope link src 10.10.1.210 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.6 metric 100
I can ping from VM1(172.255.255.5,10.11.111.254) to 172.255.255.6 and can ping from VM2(172.255.255.6, 10.10.1.210) to 172.255.255.5.
The problem is, I want to ping from VM1(172.255.255.5,10.11.111.254) to 10.10.1.210, so I add a route in VM1
ip route add 10.10.1.210 via 172.255.255.6
so the route of VM1 is:
10.10.1.210 via 172.255.255.6 dev eth0
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
But I still can't ping from VM1 to 10.10.1.210.
So, where am I wrong?
By the way, I have disabled SELinux and firewalld on all my machines.
ip route get 10.10.1.210:
10.10.1.210 via 172.255.255.6 dev eth0 src 172.255.255.5
cachetcpdump -e -nn -i eth0 'icmp' on VM1:
20:47:00.147549 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 48, length 64
20:47:01.147541 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 49, length 64
20:47:02.147543 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 50, length 64
20:47:03.147551 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 51, length 64VM1, iptables-save -c :
*security
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*raw
:PREROUTING ACCEPT [5456:12843525]
:OUTPUT ACCEPT [28969:2491905]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*mangle
:PREROUTING ACCEPT [5456:12843525]
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28969:2491905]
:POSTROUTING ACCEPT [28970:2491949]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*filter
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*nat
:PREROUTING ACCEPT [41:6031]
:INPUT ACCEPT [26:3643]
:OUTPUT ACCEPT [196:139164]
:POSTROUTING ACCEPT [197:139236]
COMMIT
# Completed on Mon May 20 20:48:08 2019```VM2, iptables-save -c :
*nat
:PREROUTING ACCEPT [151:139500]
:INPUT ACCEPT [136:137067]
:OUTPUT ACCEPT [126:76110]
:POSTROUTING ACCEPT [126:76110]
COMMIT
# Completed on Mon May 20 20:51:19 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:51:19 2019
*filter
:INPUT ACCEPT [22121:14364143]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [21468:1823390]
COMMIT
# Completed on Mon May 20 20:51:19 2019```tcpdump -e -nn -i eth0 'icmp' on VM2
20:53:50.348475 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 459, length 64
20:53:50.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 459, length 64
20:53:51.348443 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 460, length 64
20:53:51.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 460, length 64
20:53:52.348432 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 461, length 64
20:53:52.348456 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 461, length 64
linux networking centos linux-networking
I have two virtual machines with CentOS 7 installed.
Each VM has two NICs and two IP addresses.
ip configuration of VM1:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:0b:03:33 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.5/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::4f07:27f6:5839:d257/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:4b:2f:58 brd ff:ff:ff:ff:ff:ff
inet 10.11.111.254/21 brd 10.11.111.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::d64c:aeee:1111:16d5/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM1:
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
ip configuration of VM2:
eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:7a:3c:e7 brd ff:ff:ff:ff:ff:ff
inet 172.255.255.6/30 brd 172.255.255.7 scope global noprefixroute eth0
valid_lft forever preferred_lft forever
inet6 fe80::35e3:6bb7:918e:6bca/64 scope link noprefixroute
valid_lft forever preferred_lft forever
eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1450 qdisc pfifo_fast state UP group default qlen 1000
link/ether fa:16:3e:25:38:9a brd ff:ff:ff:ff:ff:ff
inet 10.10.1.210/24 brd 10.10.1.255 scope global noprefixroute eth1
valid_lft forever preferred_lft forever
inet6 fe80::5ec3:f912:51a5:761c/64 scope link noprefixroute
valid_lft forever preferred_lft forever
route of VM2:
10.10.1.0/24 dev eth1 proto kernel scope link src 10.10.1.210 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.6 metric 100
I can ping from VM1(172.255.255.5,10.11.111.254) to 172.255.255.6 and can ping from VM2(172.255.255.6, 10.10.1.210) to 172.255.255.5.
The problem is, I want to ping from VM1(172.255.255.5,10.11.111.254) to 10.10.1.210, so I add a route in VM1
ip route add 10.10.1.210 via 172.255.255.6
so the route of VM1 is:
10.10.1.210 via 172.255.255.6 dev eth0
10.11.104.0/21 dev eth1 proto kernel scope link src 10.111.111.254 metric 101
172.255.255.4/30 dev eth0 proto kernel scope link src 172.255.255.5 metric 100
But I still can't ping from VM1 to 10.10.1.210.
So, where am I wrong?
By the way, I have disabled SELinux and firewalld on all my machines.
ip route get 10.10.1.210:
10.10.1.210 via 172.255.255.6 dev eth0 src 172.255.255.5
cachetcpdump -e -nn -i eth0 'icmp' on VM1:
20:47:00.147549 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 48, length 64
20:47:01.147541 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 49, length 64
20:47:02.147543 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 50, length 64
20:47:03.147551 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 51, length 64VM1, iptables-save -c :
*security
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*raw
:PREROUTING ACCEPT [5456:12843525]
:OUTPUT ACCEPT [28969:2491905]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*mangle
:PREROUTING ACCEPT [5456:12843525]
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28969:2491905]
:POSTROUTING ACCEPT [28970:2491949]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*filter
:INPUT ACCEPT [5440:12841065]
:FORWARD ACCEPT [2:144]
:OUTPUT ACCEPT [28968:2491805]
COMMIT
# Completed on Mon May 20 20:48:08 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:48:08 2019
*nat
:PREROUTING ACCEPT [41:6031]
:INPUT ACCEPT [26:3643]
:OUTPUT ACCEPT [196:139164]
:POSTROUTING ACCEPT [197:139236]
COMMIT
# Completed on Mon May 20 20:48:08 2019```VM2, iptables-save -c :
*nat
:PREROUTING ACCEPT [151:139500]
:INPUT ACCEPT [136:137067]
:OUTPUT ACCEPT [126:76110]
:POSTROUTING ACCEPT [126:76110]
COMMIT
# Completed on Mon May 20 20:51:19 2019
# Generated by iptables-save v1.4.21 on Mon May 20 20:51:19 2019
*filter
:INPUT ACCEPT [22121:14364143]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [21468:1823390]
COMMIT
# Completed on Mon May 20 20:51:19 2019```tcpdump -e -nn -i eth0 'icmp' on VM2
20:53:50.348475 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 459, length 64
20:53:50.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 459, length 64
20:53:51.348443 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 460, length 64
20:53:51.348501 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 460, length 64
20:53:52.348432 fa:16:3e:0b:03:33 > fa:16:3e:7a:3c:e7, ethertype IPv4 (0x0800), length 98: 172.255.255.5 > 10.10.1.210: ICMP echo request, id 4116, seq 461, length 64
20:53:52.348456 fa:16:3e:7a:3c:e7 > fa:16:3e:0b:03:33, ethertype IPv4 (0x0800), length 98: 10.10.1.210 > 172.255.255.5: ICMP echo reply, id 4116, seq 461, length 64
linux networking centos linux-networking
linux networking centos linux-networking
edited May 20 at 13:18
Gary Allen
asked May 20 at 2:58
Gary AllenGary Allen
112
112
what is the result ofip r s
? have you set default route ?
– Archemar
May 20 at 5:00
Enable IP forwarding on VM2 if not enabled: ip-forwarding, try turning iptables off while testing, or check their rules.
– Sergey Nudnov
May 20 at 5:02
no default route on both machines. ip forwarding(net.ipv4.ip_forward) is enabled on both machines.
– Gary Allen
May 20 at 5:11
eth1's IP are not in same range, you won't be able to connect directly.
– Archemar
May 20 at 9:25
add a comment |
what is the result ofip r s
? have you set default route ?
– Archemar
May 20 at 5:00
Enable IP forwarding on VM2 if not enabled: ip-forwarding, try turning iptables off while testing, or check their rules.
– Sergey Nudnov
May 20 at 5:02
no default route on both machines. ip forwarding(net.ipv4.ip_forward) is enabled on both machines.
– Gary Allen
May 20 at 5:11
eth1's IP are not in same range, you won't be able to connect directly.
– Archemar
May 20 at 9:25
what is the result of
ip r s
? have you set default route ?– Archemar
May 20 at 5:00
what is the result of
ip r s
? have you set default route ?– Archemar
May 20 at 5:00
Enable IP forwarding on VM2 if not enabled: ip-forwarding, try turning iptables off while testing, or check their rules.
– Sergey Nudnov
May 20 at 5:02
Enable IP forwarding on VM2 if not enabled: ip-forwarding, try turning iptables off while testing, or check their rules.
– Sergey Nudnov
May 20 at 5:02
no default route on both machines. ip forwarding(net.ipv4.ip_forward) is enabled on both machines.
– Gary Allen
May 20 at 5:11
no default route on both machines. ip forwarding(net.ipv4.ip_forward) is enabled on both machines.
– Gary Allen
May 20 at 5:11
eth1's IP are not in same range, you won't be able to connect directly.
– Archemar
May 20 at 9:25
eth1's IP are not in same range, you won't be able to connect directly.
– Archemar
May 20 at 9:25
add a comment |
1 Answer
1
active
oldest
votes
Steps to troubleshoot.
- Check the actual routes. On VM1 run
ip route get 10.10.1.210
. It should return valid route. - Your setup doesn't require enabled forwarding in the current state.
- Run the
tcpdump -ni eth0 'icmp'
on VM1. You should see outgoingicmp echo requests
. If you don't see them, then they are either filtered or routed through other interface. - Anyway check the firewall with command
iptables-save -c
. - Run the
tcpdump -ni eth0 'icmp'
on VM2. Do you see incomingicmp echo request
and outgoingicmp echo reply
?
If the steps above haven't helped, paste the outputs of commands from them into the question, and I'll extend the answer.
I have pasted the output of each step into the question. VM1 only hasicmp echo requests
, VM2 haveicmp echo request
andicmp echo reply
.
– Gary Allen
May 20 at 13:23
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither doesping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.
– Gary Allen
May 20 at 14:04
Have you seen errors at runping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?
– Anton Danilov
May 20 at 14:07
no error, just silence
– Gary Allen
May 20 at 14:09
|
show 3 more comments
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "2"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f968021%2fcant-ping-eth1-via-eth0%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Steps to troubleshoot.
- Check the actual routes. On VM1 run
ip route get 10.10.1.210
. It should return valid route. - Your setup doesn't require enabled forwarding in the current state.
- Run the
tcpdump -ni eth0 'icmp'
on VM1. You should see outgoingicmp echo requests
. If you don't see them, then they are either filtered or routed through other interface. - Anyway check the firewall with command
iptables-save -c
. - Run the
tcpdump -ni eth0 'icmp'
on VM2. Do you see incomingicmp echo request
and outgoingicmp echo reply
?
If the steps above haven't helped, paste the outputs of commands from them into the question, and I'll extend the answer.
I have pasted the output of each step into the question. VM1 only hasicmp echo requests
, VM2 haveicmp echo request
andicmp echo reply
.
– Gary Allen
May 20 at 13:23
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither doesping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.
– Gary Allen
May 20 at 14:04
Have you seen errors at runping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?
– Anton Danilov
May 20 at 14:07
no error, just silence
– Gary Allen
May 20 at 14:09
|
show 3 more comments
Steps to troubleshoot.
- Check the actual routes. On VM1 run
ip route get 10.10.1.210
. It should return valid route. - Your setup doesn't require enabled forwarding in the current state.
- Run the
tcpdump -ni eth0 'icmp'
on VM1. You should see outgoingicmp echo requests
. If you don't see them, then they are either filtered or routed through other interface. - Anyway check the firewall with command
iptables-save -c
. - Run the
tcpdump -ni eth0 'icmp'
on VM2. Do you see incomingicmp echo request
and outgoingicmp echo reply
?
If the steps above haven't helped, paste the outputs of commands from them into the question, and I'll extend the answer.
I have pasted the output of each step into the question. VM1 only hasicmp echo requests
, VM2 haveicmp echo request
andicmp echo reply
.
– Gary Allen
May 20 at 13:23
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither doesping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.
– Gary Allen
May 20 at 14:04
Have you seen errors at runping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?
– Anton Danilov
May 20 at 14:07
no error, just silence
– Gary Allen
May 20 at 14:09
|
show 3 more comments
Steps to troubleshoot.
- Check the actual routes. On VM1 run
ip route get 10.10.1.210
. It should return valid route. - Your setup doesn't require enabled forwarding in the current state.
- Run the
tcpdump -ni eth0 'icmp'
on VM1. You should see outgoingicmp echo requests
. If you don't see them, then they are either filtered or routed through other interface. - Anyway check the firewall with command
iptables-save -c
. - Run the
tcpdump -ni eth0 'icmp'
on VM2. Do you see incomingicmp echo request
and outgoingicmp echo reply
?
If the steps above haven't helped, paste the outputs of commands from them into the question, and I'll extend the answer.
Steps to troubleshoot.
- Check the actual routes. On VM1 run
ip route get 10.10.1.210
. It should return valid route. - Your setup doesn't require enabled forwarding in the current state.
- Run the
tcpdump -ni eth0 'icmp'
on VM1. You should see outgoingicmp echo requests
. If you don't see them, then they are either filtered or routed through other interface. - Anyway check the firewall with command
iptables-save -c
. - Run the
tcpdump -ni eth0 'icmp'
on VM2. Do you see incomingicmp echo request
and outgoingicmp echo reply
?
If the steps above haven't helped, paste the outputs of commands from them into the question, and I'll extend the answer.
edited May 20 at 6:46
answered May 20 at 6:30
Anton DanilovAnton Danilov
1,400711
1,400711
I have pasted the output of each step into the question. VM1 only hasicmp echo requests
, VM2 haveicmp echo request
andicmp echo reply
.
– Gary Allen
May 20 at 13:23
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither doesping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.
– Gary Allen
May 20 at 14:04
Have you seen errors at runping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?
– Anton Danilov
May 20 at 14:07
no error, just silence
– Gary Allen
May 20 at 14:09
|
show 3 more comments
I have pasted the output of each step into the question. VM1 only hasicmp echo requests
, VM2 haveicmp echo request
andicmp echo reply
.
– Gary Allen
May 20 at 13:23
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither doesping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.
– Gary Allen
May 20 at 14:04
Have you seen errors at runping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?
– Anton Danilov
May 20 at 14:07
no error, just silence
– Gary Allen
May 20 at 14:09
I have pasted the output of each step into the question. VM1 only has
icmp echo requests
, VM2 have icmp echo request
and icmp echo reply
.– Gary Allen
May 20 at 13:23
I have pasted the output of each step into the question. VM1 only has
icmp echo requests
, VM2 have icmp echo request
and icmp echo reply
.– Gary Allen
May 20 at 13:23
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
It's interesting case. Replies are losing somewhere in hypervisor bridge. Run 'ping -I 10.10.1.210 172.255.255.5'. Is it pinging successfully? Check the tcpdump captures.
– Anton Danilov
May 20 at 13:41
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither does
ping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.– Gary Allen
May 20 at 14:04
'ping -I 10.10.1.210 172.255.255.5' doesn't work, neither does
ping -I 10.11.111.254 172.255.255.6
. the capture output is too long, so I put it in a another answer, please check, thank you.– Gary Allen
May 20 at 14:04
Have you seen errors at run
ping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?– Anton Danilov
May 20 at 14:07
Have you seen errors at run
ping -I 10.10.1.210 172.255.255.5
on VM2 or there was just silence?– Anton Danilov
May 20 at 14:07
no error, just silence
– Gary Allen
May 20 at 14:09
no error, just silence
– Gary Allen
May 20 at 14:09
|
show 3 more comments
Thanks for contributing an answer to Server Fault!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fserverfault.com%2fquestions%2f968021%2fcant-ping-eth1-via-eth0%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
what is the result of
ip r s
? have you set default route ?– Archemar
May 20 at 5:00
Enable IP forwarding on VM2 if not enabled: ip-forwarding, try turning iptables off while testing, or check their rules.
– Sergey Nudnov
May 20 at 5:02
no default route on both machines. ip forwarding(net.ipv4.ip_forward) is enabled on both machines.
– Gary Allen
May 20 at 5:11
eth1's IP are not in same range, you won't be able to connect directly.
– Archemar
May 20 at 9:25