Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a machine C with two NICs, namely eth0 and eth1, with CentOS 4.9 installed on it. Also I have a machine A connecting to C through eth0 and a machine B connecting to C through eth1. Now I want machine A to be in a subnet (e.g. and machine B to be in another subnet (e.g. and they could communicate with each other.

                  eth0         eth1
Machine A <---------> Machine C <---------> Machine B
           ...3.0/24             ...4.0/24

According to the answer of my previous question about this problem, I configured my eth0 and eth1:





And configure Machine A (Windows XP) with,, and Machine B (windows 7) with, I have enabled ip forwarding on machine C. Now, I haven't added any routes or iptables rules. I could ping from machine B, but not vice vesa. Am i missing some routing rules? If yes, how to add these rules?

Any suggestions or tutorials or howtos will be appreciated.

share|improve this question
Good question, well done. – womble Aug 3 '11 at 9:20
up vote 1 down vote accepted

A quick test:

Control Panel -> Windows Firewall (under System and Security, if you do that sort of thing). In the left pane, click 'Turn Windows Firewall On/Off', then turn off the Firewall in the right pane.

If you can ping it then, great... you can turn it back on, and allow ping by using the directions at

If that doesn't work, another quick test would be to shutdown iptables, just for troubleshooting purposes, of course. Even if you don't remember messing with it, it's worth testing...

sudo /etc/init.d/iptables stop
share|improve this answer
Thanks very much. The problem is exactly what you've said. Great thanks to you. – machinarium Aug 3 '11 at 10:56

The fact that one machine can successfully ping the other machine suggests that the router machine (C) is configured at least reasonably correctly -- IP forwarding works, and there's no default "reject" policy in the iptables configuration.

I'd be inclined to suspect a firewall setting on Machine B that makes it not respond to pings by default. I'm not Microsoft guru, though, so I don't know if that might be a default Windows 7 thing, or how to go about checking and fixing it, but presumably there's some config manager in there somewhere you can click around in.

If that doesn't seem to be bearing fruit, just make a sanity check on your iptables config by running iptables -L -n and making sure there are no rules in the FORWARD chain (some system config thing might have added them) and that the policy for that chain is, in fact, ACCEPT (this isn't good security practice, but we're not as far as "making it secure" yet, just "making it work"). If you're not confident interpreting the output, paste the output into your question and someone will give you the thumbs up.

share|improve this answer
Thanks, womble. You're so kind and patient to help me out. – machinarium Aug 3 '11 at 10:58
Upvotes (and accepted answers) are appreciated in return. – womble Aug 3 '11 at 11:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.