LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   Problems networking Linux and Windows. Pinging does not work. (https://www.linuxquestions.org/questions/linux-networking-3/problems-networking-linux-and-windows-pinging-does-not-work-142254/)

ElijahLofgren 02-04-2004 01:13 PM

Problems networking Linux and Windows. Pinging does not work.
 
I'm try to get Red Hat Linux 9 machine networked with a Windows 98 machine so that I can share files and share my dail-up connection with the Windows box.
I'm unable to ping the Linux box from the Windows box, and pinging the Windows one from the Linux one does not work either.
I get a " Destination Host Unreachable" error.
How can I fix this?
I know that everything is connected right because when I boot the Linux machine into Windows, pinging the other Windows machine works. (I'm dual-booting).
The ips go like this:
Linux: 192.168.1.1
Subnet: 255.255.255.0
Windows: 192.168.1.2
Subnet: 255.255.255.0

Here are the results of ifconfig:

[root@localhost root]# ifconfig
eth0 Link encap:Ethernet HWaddr 00:0C:6E:B3:A0:C0
inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:0 errors:548 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:0 (0.0 b) TX bytes:0 (0.0 b)
Interrupt:5 Base address:0x1400

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:137510 errors:0 dropped:0 overruns:0 frame:0
TX packets:137510 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:9641847 (9.1 Mb) TX bytes:9641847 (9.1 Mb)

Does "TX packets:0 errors:548 dropped:0 overruns:0 carrier:0" mean something?
Here are the results of route:
(dashed added to preserve spacing
[root@localhost root]# route
Kernel IP routing table
Destination-----Gateway----Genmask---------Flags--Metric-Ref---Use---- Iface
1.1.21.2------------*----------255.255.255.255 ---UH-----0------0------0------ ppp0
192.168.1.0-------*----------255.255.255.0--------U------0------0------0------ eth0
169.254.0.0-------*----------255.255.0.0-----------U------0------0------0------ eth0
127.0.0.0----------*----------255.0.0.0--------------U-------0------0------0------ lo
default-------------1.1.21.2--0.0.0.0---------------UG------0------0------0------ ppp0




I've been working on this for the past couple of days. I have tried many things that I have seen on other posts in this forum.

Thanks for helping me,

Elijah

fur 02-04-2004 01:46 PM

Are you going though a hub or switch to connect the two computers, or are just connecting the computers together with a single ethernet cable?

If you are using a single cable it has to be a cross-over cable.

ElijahLofgren 02-04-2004 03:09 PM

Sorry, I forgot to mention. I'm going through an ethernet hub to connect the computers together. I know that everthing is cabled right becuase when I boot the Linux machine into Windows the LAN works.

I wonder why pinging does not work from the Linux machine. Any ideas?

Thanks for your help so far,
Elijah

vectordrake 02-04-2004 03:14 PM

I know this sounds silly, but this seems like a firewall in the way. Are you running a software firewall on either machine?

ElijahLofgren 02-04-2004 03:16 PM

I have the security level set to: No Firewall on the linux machine. There is not firewall on the Windows machine.

vectordrake 02-04-2004 03:18 PM

Try pinging the Windows machine with itself. ping 127.0.0.1 It should yeild results. BTW, are you pinging IPs or hostnames?

ElijahLofgren 02-04-2004 03:24 PM

Quote:

Try pinging the Windows machine with itself. ping 127.0.0.1 It should yeild results
That works fine. It says recieved data etc..
The Linux machine can ping itself also.
Quote:

BTW, are you pinging IPs or hostnames?
I'm pinging IPs.
The linux machine's ip is: 192.168.1.1
The Windows machine's ip is: 192.168.1.2

Thanks again for you help,
Elijah

vectordrake 02-04-2004 03:27 PM

Should have asked before. Can either or both machines reach the internet? What machine is connected to the phone line? How are you sharing your connection? ICS? NAT? Proxy program? I'll try to stop the questions and aim an answer on ya after this, I promise. :D (I did say 'try'
)

homey 02-04-2004 03:32 PM

I'm kinda guessing here. :(
When you are booted up to Windows, is that machine set to do Internet Connection Sharing?
If so, the second box gets it's ip address from the first one. right?
Now if you boot to Linux with box one, the other windows box has no instructions on how to get an address from the Linux machine.

To prove that, at Windows box two, type winipcfg while the first box is booted up to Linux.
You may get something like 169...... That means the Windows machine is set to obtain address automatically, but doesn't have any place set up to obtain it from.

Easy solution, Install Firestarter on the Linux box.

ElijahLofgren 02-04-2004 06:17 PM

Quote:

Can either or both machines reach the internet?
Only the Linux machine can connect to the internet right now.
Quote:

What machine is connected to the phone line?
The Linux machine is connected to the phone line via a serial external modem.
Quote:

How are you sharing your connection? ICS? NAT? Proxy program?
Currently I'm not sharing the connection at all. I first need to get the Linux and Windows machine to be able to talk to each other. I thought that Squid was the proxy program I should use to let the Windows machine use the Linux machine as a proxy to access the internet. Is that correct? But first I need the machines to at least be able to ping each other. Correct?
Quote:

When you are booted up to Windows, is that machine set to do Internet Connection Sharing?
No, I'm going to try to get the Linux machine to share its connection with the Windows machine. e.g. the windows machine will use the linux machine as a proxy to connect to the internet.
Quote:

If so, the second box gets it's ip address from the first one. right?
Now if you boot to Linux with box one, the other windows box has no instructions on how to get an address from the Linux machine.
Both machines have static ips for the ethernet card.
The Linux machine connects to the internet through an external dail-up modem.

I was looking through: /var/log/messages
and I found the following.
Quote:

Feb 4 17:55:18 localhost kernel: NETDEV WATCHDOG: eth0: transmit timed out
Feb 4 17:55:18 localhost kernel: eth0: Transmit timed out, status 0002, PHY status 786d, resetting...
Feb 4 17:55:22 localhost kernel: NETDEV WATCHDOG: eth0: transmit timed out
Feb 4 17:55:22 localhost kernel: eth0: Transmit timed out, status 0002, PHY status 786d, resetting...
What do those errors mean? Is that my problem?

Thanks again guys!
Awaiting your helpful replies,
Elijah

berserker_b2k 02-04-2004 06:45 PM

you should check that there's no filtering rules active (besides you chosed NO FIREWALL).

To do so, type: IPTABLES -L
You should see 3 entries: INPUT, OUTPUT and FORWARD
All of them should say ACCEPT

vectordrake 02-04-2004 06:54 PM

Does your NIC in your Linux box happen to be a 3Com 3c905?

ElijahLofgren 02-04-2004 08:35 PM

Quote:

you should check that there's no filtering rules active (besides you chosed NO FIREWALL).
To do so, type: IPTABLES -L
You should see 3 entries: INPUT, OUTPUT and FORWARD
All of them should say ACCEPT
Looks like that is fine.
Here is the output:
Quote:

[root@localhost root]# iptables -L
Chain INPUT (policy ACCEPT)
target prot opt source destination

Chain FORWARD (policy ACCEPT)
target prot opt source destination

Chain OUTPUT (policy ACCEPT)
target prot opt source destination
Quote:

Does your NIC in your Linux box happen to be a 3Com 3c905?
No its integrated with my motherboard. It's a Onboard LAN Asus A7V8X-X (VT6102 [Rhine-II])
Does this work with Linux? It seems like Linux has detected it ok.

Thanks again,
Elijah

vectordrake 02-04-2004 08:46 PM

I think your problem may reside with a wonky driver for your card. It may be negotiating the wrong way. It is suggested to set it to auto (had to do that with my rtl8139 for any amount of speed with my cable modem). There's a bit about that on a few kernel newsgroups. The 3com has the same problem and its more common. Check this out: http://www.scyld.com/pipermail/netdr...ay/000022.html

and this:
http://www.scyld.com/network/ethercard.html

There might be light at the end of the tunnel.

On the network sharing, you might wanna try NAT instead of a proxy. Much less configuration, I believe. There is a good howto (but RH should do it automatically): http://www.netfilter.org/documentati...NAT-HOWTO.html

Good luck.

berserker_b2k 02-04-2004 08:49 PM

I have the same mobo & I have no problems...

berserker_b2k 02-04-2004 08:52 PM

well... you should try this BTW

iptables -A OUTPUT -p ICMP -j ACCEPT
iptables -A INPUT -p ICMP -j ACCEPT

ElijahLofgren 02-04-2004 08:52 PM

Hmmm....
I was looking through: /var/log/messages
And I found:
Quote:

Feb 4 20:43:06 localhost ifup: route: netmask 000000ff doesn't make sense with host route
....
....
Feb 4 20:43:32 localhost kernel: NETDEV WATCHDOG: eth0: transmit timed out
Feb 4 20:43:32 localhost kernel: eth0: Transmit timed out, status 0003, PHY status 786d, resetting...
Feb 4 20:43:35 localhost modprobe: modprobe: Can't locate module char-major-10-134
Feb 4 20:43:36 localhost kernel: NETDEV WATCHDOG: eth0: transmit timed out
Feb 4 20:43:36 localhost kernel: eth0: Transmit timed out, status 0002, PHY status 786d, resetting...
I wonder if those errors are my problem? Any ideas?

ElijahLofgren 02-04-2004 08:57 PM

Quote:

well... you should try this BTW

iptables -A OUTPUT -p ICMP -j ACCEPT
iptables -A INPUT -p ICMP -j ACCEPT
I just tried that and it's still not working.
Here is what I did.
Quote:

[root@localhost root]# iptables -A OUTPUT -p ICMP -j ACCEPT
[root@localhost root]# iptables -A INPUT -p ICMP -j ACCEPT
[root@localhost root]# ping 192.168.1.2
PING 192.168.1.2 (192.168.1.2) 56(84) bytes of data.
From 192.168.1.1 icmp_seq=1 Destination Host Unreachable
From 192.168.1.1 icmp_seq=2 Destination Host Unreachable
From 192.168.1.1 icmp_seq=3 Destination Host Unreachable

--- 192.168.1.2 ping statistics ---
5 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3999ms
, pipe 3
When I try to ping the Linux machine from the Windows machine, I still get "Request time out".

vectordrake 02-04-2004 09:01 PM

Have you got another cable to try? Don't overlook the obvious....

vectordrake 02-04-2004 09:02 PM

Heh heh. You're Gonna get a network!:D

berserker_b2k 02-04-2004 09:02 PM

mmm... you should check your route table...

what you posted:

Kernel IP routing table
Destination-----Gateway----Genmask---------Flags--Metric-Ref---Use---- Iface
1.1.21.2------------*----------255.255.255.255 ---UH-----0------0------0------ ppp0
192.168.1.0-------*----------255.255.255.0--------U------0------0------0------ eth0
169.254.0.0-------*----------255.255.0.0-----------U------0------0------0------ eth0
127.0.0.0----------*----------255.0.0.0--------------U-------0------0------0------ lo
default-------------1.1.21.2--0.0.0.0---------------UG------0------0------0------ ppp0

check under default... shouldn't it say "255.255.255.255" under Genmask?

ElijahLofgren 02-04-2004 09:15 PM

Quote:

I think your problem may reside with a wonky driver for your card.
I could try putting in an ethernet PCI card from another computer. It's a Siemens SpeedStream model SS1020. Is that a good idea?
Quote:

Have you got another cable to try? Don't overlook the obvious..
Cable should work because if I boot the Linux machine into Windows (I'm dual booting Red Hat Linux 9/Windows 98) the LAN works.
Quote:

Heh heh. You're Gonna get a network!
Thanks for the encouragement! :)
Quote:

mmm... you should check your route table...
...
...
check under default... shouldn't it say "255.255.255.255" under Genmask?
I don't quite understand what you mean? How do I check my route table? (Sorry I'm newbie to Linux ;) )


Thanks guys! I think with all your help, I may be able to get this working......

Elijah

vectordrake 02-04-2004 09:22 PM

Actually, check that table! Good point. I don't know why I didn't see it before. If you have one NIC and one modem, there should be 3 entries: one for the PPP device, one for loopback, and ONE for eth0. What is that 169.x.x.x address? Put in the other card and see if it works (as the Rhine and Rhine II have the hardwired negotiation issue, a does that 3com chipset - if you checked out the sites I posted, you saw there was a utility to change the firmware with). Change the card and see if that second IP disappears. Remember, your route wasn't resolving either. It should be much easier than this with RH and your fairly popular chipset. Looks like an extra entry showed up for some reason.

ElijahLofgren 02-04-2004 09:23 PM

Why would having a subnet mask of 255.255.255.0 and not 255.255.255.255 make a difference? (I don't really understand this whole subnet mask thing :( ).

Quote:

Put in the other card and see if it works
Ok, I'll try doing that now.

vectordrake 02-04-2004 09:25 PM

Quote:

Originally posted by ElijahLofgren
Why would having a subnet mask of 255.255.255.0 and not 255.255.255.255 make a difference? (I don't really understand this whole subnet mask thing :( ).
I've always used 255.255.255.0 (for 192.x.x.x and 10.x.x.x as well). Dunno. I think its the two IPs that the interface seems to be getting.

ElijahLofgren 02-04-2004 10:11 PM

It works!
 
Quote:

Put in the other card and see if it works
That was the answer! Thank you! It works now! :)
Thank you to everybody that helped!
But I would like to especially thank vectordrake for all his patient help!

Everything works now! :p

Now a very happy geek,

Elijah

vectordrake 02-04-2004 10:30 PM

:eek: Thanks for sticking with it. You'll be telling someone yourself someday soon. ;) Now you'll be speed-testing file transfer between yer boxes!:rolleyes: Glad to see you are doing it in the right direction as well. Win98 wasn't a very good gateway for me. I had to limit my Linux box's MTU and mss to get the correct packet size on the eth adaptors to get responses from 1/2 the websites out there (buggy ICS). You've got the worst over you. The rest is software and configs (which may do it all for you, depending on your choices).

rockee 02-11-2004 10:35 PM

OK. Now maybe someone can help me.

I want to download Mandrake 9.2 from an ftp site to an NFS partition to my laptop. Laptop has RH 7.0 installed.

I have a pcmcia adapter 3com 3c589-TP. Adapter works in Win95 OK and using my router can talk to another Win machine.

Under Redhat 7.0, the adapter is recognized and is communicating with the router. I can see the light on the router on. Yet, I cannot ping anything or talk to anything. I ecive the usual "unknown host" or "not connected" or "destimation host unreachable".

Where should I start?

vectordrake 02-11-2004 10:39 PM

Do you have a DNS server listed so you can get to another IP? Try pinging a known IP first. If it connects, then you try pinging the name of that IP and see. If it craps out, you don't have DNS. Put in the nameserver your ISP provides and you'll be fine after that. If that's not it, we'll see...

rockee 02-11-2004 11:10 PM

Quote:

Originally posted by vectordrake
Do you have a DNS server listed so you can get to another IP? Try pinging a known IP first. If it connects, then you try pinging the name of that IP and see. If it craps out, you don't have DNS. Put in the nameserver your ISP provides and you'll be fine after that. If that's not it, we'll see...
Tried a known ip:
"network is unreachable"

Tried it by name:
"unknown host".


All times are GMT -5. The time now is 02:30 AM.