Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Cant ping linux server from win 2k 1

Status
Not open for further replies.

LittlePud

Technical User
Sep 3, 2002
5
GB
I have 2 servers, one is running win 2k and the other is running mandrake 9. I cannot get them to ping each other,
win 2k IP = 192.168.0.1
ML9 IP = 192.168.0.2 (although eth0 shows 192.168.1.1)
same subnets
connection via hub
hardware known to be good.

can anyone help please
 
This part confuses me:

ML9 IP = 192.168.0.2 (although eth0 shows 192.168.1.1)

Which IP address is bound to the card? If the IP on eth0 is the second address, does the subnet mask on both machines include both addresses? ______________________________________________________________________
TANSTAAFL!
 


"The subnet mask on both machines is 255.255.255.0. The address that is bound to the card is 192.168.1.1.

How can we make 192.168.0.2 bind to the card or include both addresses in the subnet mask?"
Thanks
 
Eth0 is the nic. If it says that its IP is 192.168.1.1, then thats its IP address. Plain and simple.
On the linux machine run ifconfig and you'll see what eth0's IP is.

In order to change eth0's IP address run: setup from the command prompt. This works in RedHat Linux, so I'm hoping it runs on Mandrake as well. If it doens't work then you need to find how to change the IP of the Linux server.
Or if you're more familiar with it, just change the IP on the win2k machine to the 192.168.1.x subnet.

The machines should be able to talk then.
 
It sounds like you want to run IP aliasing on eth0, which allows you to bind multiple IP's to the same NIC? This is very similar to the method that Cisco uses to add subinterfaces to an interface. You want to specify a new alias, something like "eth0:1". Here's the steps...

[root]@penguin root]# ifconfig
eth0 Link encap:Ethernet HWaddr 00:50:56:40:59:3C
inet addr:192.168.1.103 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:7 errors:0 dropped:0 overruns:0 frame:0
TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:1231 (1.2 Kb) TX bytes:660 (660.0 b)
Interrupt:10 Base address:0x10a0

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:10 errors:0 dropped:0 overruns:0 frame:0
TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:700 (700.0 b) TX bytes:700 (700.0 b)


[root]@penguin root]# ifconfig eth0:1 192.168.0.100 netmask 255.255.255.0

[root]@penguin root]# ifconfig
eth0 Link encap:Ethernet HWaddr 00:50:56:40:59:3C
inet addr:192.168.1.103 Bcast:192.168.1.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:7 errors:0 dropped:0 overruns:0 frame:0
TX packets:6 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:100
RX bytes:1231 (1.2 Kb) TX bytes:660 (660.0 b)
Interrupt:10 Base address:0x10a0

eth0:1 Link encap:Ethernet HWaddr 00:50:56:40:59:3C
inet addr:192.168.0.100 Bcast:192.168.0.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
Interrupt:10 Base address:0x10a0

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:10 errors:0 dropped:0 overruns:0 frame:0
TX packets:10 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:700 (700.0 b) TX bytes:700 (700.0 b)


Now, you have 2 IP's bound to eth0.

To make these changes survive a reboot, create the /etc/sysconfig/network-scripts/ifcfg-eth0:1 file and just copy the contents of ifcfg-eth0. Of course, change the network settings in the new file to match what you want.

[root]@penguin root]# cat /etc/sysconfig/network-scripts/ifcfg-eth0
DEVICE=eth0:1
IPADDR=192.168.1.103
NETMASK=255.255.255.0
NETWORK=192.168.1.0

[root]@penguin root]# cat /etc/sysconfig/network-scripts/ifcfg-eth0:1
DEVICE=eth0:1
IPADDR=192.168.0.100
NETMASK=255.255.255.0
NETWORK=192.168.0.0




ChrisP



 
I have managed to get the eth0 to be 192.168.0.1 and can now ping the win2k machine. However the win2k machine still cannot see the linux box.
Thanks for all you help on this.
 
When you say "see", do you mean the win2k machine cannot
ping the linux machine? Or do you mean that you are expecting
to see the linux machine in NN or something?

You could try adding an arp entry, try arp/? for details..
arp -s inet_addr linux mac-address ..
and then try again if all else fails.
 
Fixed the problem, stupid me had set the security to very high so it would not allow ping (sorry)
Thanks for all the help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top