Operating System - Linux
1827064 Members
4323 Online
109713 Solutions
New Discussion

Cannot ping win box from linux or linux from windows.

 
Greg Smelser
Occasional Contributor

Cannot ping win box from linux or linux from windows.

I had this setup once before, then upgraded and wrecked everything. I can ping both nics and internet on the Linux box but not the Windows lan. I can ping each
(4) windows box in the lan but not the linux box.
I have a DSL conn I would like to share with the lan using the Linux box as firewall. Here are some conf specs let me know what else is needed.

ifconfig:
eth0
Link encap:Ethernet HWaddr 00:C0:F0:3C:21:6F
inet addr:33.222.222.222 Bcast:33.222.222.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1

eth1
Link encap:Ethernet HWaddr 00:80:C6:F7:1D:0F
inet addr:192.168.0.20 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1

lo
Link Encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:3924 Metric:1

------------------------------------------------------
ifcfg-eth0: DEVICE="eth0"
BOOTPROTO="none"
BROADCAST="33.222.222.255
IPADDR="33.222.222.222"
NETMASK="255.255.255.0"
NETWORK="33.222.222.0
ONBOOT="yes"
----------------------------------------------------------
ifcfg-eth1: DEVICE="eth1"
BOOTPROTO="none"
IPADDR="192.168.0.20"
NETMASK="255.255.255.0"
ONBOOT="yes"
---------------------------------------------------------
network: NETWORKING=yes
FORWARD_IPV4="yes"
HOSTNAME="server.someone.com"
DOMAINNAME="someone.com"
GATEWAY="33.222.222.254"
GATEWAYDEV="eth0"
----------------------------------------------------------
hostname: server

hosts: 127.0.0.1 localhost.localdomain localhost server
33.222.222.222 someone.com someone
192.168.0.20 lan.someone.com
-------------------------------------------
hosts.allow:
#
# hosts.allow This file etc.etc.etc.
#
#
ALL:LOCAL
ALL:192.168.0.0/255.255.255.0

-----------------------------------------------------------
hosts.deny:
#
# hosts.deny This etc.etc.etc.
#
#
#
# The portmap line is etc.etc.etc.
#

ALL:ALL
---------------------------------------------------------------
ipmasq:
LOCALNET=192.168.0.20/255.255.255.0
---------------------------------------------------------------------
Kernel 2.2.12-20
Red Hat ver.6.1
5 REPLIES 5
Tim Malnati
Honored Contributor

Re: Cannot ping win box from linux or linux from windows.

Everything looks like it should work. Can you ping your default gateway device (33.222.222.254)? If you can't, the ip and/or mask to it is probably wrong.
Albert E. Whale, CISSP
Honored Contributor

Re: Cannot ping win box from linux or linux from windows.

Greg,

What does a netstat -rn report? What run level are in you in?
Sr. Systems Consultant @ ABS Computer Technology, Inc. http://www.abs-comptech.com/aewhale.html & http://www.ancegroup.com
Tom Emerson
Advisor

Re: Cannot ping win box from linux or linux from windows.

I get the feeling what you've checked is a red herring that is leading you astray...

To clarify:

-- the LINUX box has two NICS:
-- NIC 1 is set to 32.222.222.222 [really?]
presumably, this goes "to the internet"
-- NIC 2 is set to 192.168.0.22
presumably, this is your internal (windows) LAN
-- there are 4 "windows" boxes; IP addresses not given, however they CAN ping each other, correct? [if not, I think you'll see the problem pretty quickly now...]

So, what is the address of the windows boxes? They SHOULD be 192.168.0.xx where xx is anything from 1 to 254 exclusive of 22 [your linux box]

IF your windows boxes are set to "retrieve an IP address automatically", then the "problem" is that you don't have a local DHCP server running [which SHOULD be run from the linux box...]

IF they are set to something entirely different, well, I think we found the proper herring... :)

if indeed they are set to 192.168.0.xx, then the thing to check is the cable between the hub and the linux box -- are the lights lit? try swapping cables and/or reseating the cables -- you might have inadvertantly put in a "crossover" cable (which would be needed between a DSL modem and a hub, or in cases where you are using twisted-pair cables between two and only two computers and have no "hub"] [also, in rare cases, some hubs have a "crossover/normal" switch which will change the way a particular port is "wired"]

So, if you're at this point, you've verified:
1) the windows boxes are configured on the 192.168.0 network
2) the cables are "good"
3) [possibly] the NIC card in the linux box is OK (when you checked for synch lights, remember?)
if you STILL cannot get a "ping" to work between the windows & linux machines, well, it's time to bring in an expert to physically inspect things -- that's about the limit of my over-the-internet-webpage-troubleshooting I can do :)

Tom
Volker Borowski
Honored Contributor

Re: Cannot ping win box from linux or linux from windows.

Just a silly idea: May be your Upgrade switched ETH0 and ETH1 on the driver side ?
So you Box is right opposite connected now ?
Volker
Greg Smelser
Occasional Contributor

Re: Cannot ping win box from linux or linux from windows.

It's fixed! Chose to Up-grade one more time to RH 7.0,
what was there to lose, went thru the up-grade with no
problems and now everything works just fine, go figure.
I did not do anything different to my configuration before the upgrade, but when it was through upgrading I had no problems. I think the Linux box overheard me talking about Win 2000 haha, thanks anyway for the help.