LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Enterprise (https://www.linuxquestions.org/questions/linux-enterprise-47/)
-   -   Pinging Linux Box from Windows (https://www.linuxquestions.org/questions/linux-enterprise-47/pinging-linux-box-from-windows-611325/)

meetmefar 01-05-2008 09:52 AM

Pinging Linux Box from Windows
 
Hi Gurus,

I have recently installed enterprise Linux provided by Oracle (Redhat). I am trying to ping the box from my Windows box and I am getting request timeout error. Both the boxes are connected to the network using a router and firewall is disabled on the linux box. Both machines can connect to internet.

Any help is really appreciated.

Thank You,
meetmefar

bbfuller 01-05-2008 11:44 AM

Hello meetmefar

You don't say if you can ping the Linux (Redhat) box by ip address. If you can then it's a name resolution issue.

If it's a name resolution issue then I hesitate to offer my experience as with Redhat provided by Oracle you are probably looking for more than a homebrew solution.

However, on Fedora machines where I want that to be possible on a mixed Windows/Linux network all I have to do is install and run samba and edit my /etc/nsswitch.conf file so that the line that reads:

Code:

hosts:      files dns
now reads:

Code:

hosts:      files wins dns
It's important that the entry wins comes before any entry to do with dns or my machines try to resolve the local name on the internet. There may be other entries on that line in the file so I always keep 'wins' after the 'files' entry

This solution only applies as it stands to Fedora/CentOS and possibly Red Hat.

On other distributions it can be necessary to install other packages.

Some require 'wins_nss' and others 'winbind' before it will work.

meetmefar 01-05-2008 11:49 AM

Hi bbfuller,

Thanks for the response. I am pinging by ipaddress and it returns the request timed out error.

Thanks,
meetmefar

bbfuller 01-05-2008 12:00 PM

Hello meetmefar

Can both machines ping the router and ping 212.58.251.202

That last is www.bbc.co.uk

Also you could use:

ifconfig

on the Linux box and check that it is getting an ip address in the same range as the windows machine. I assume that you are allocating ip addresses by dhcp?

meetmefar 01-05-2008 12:07 PM

Hi bbfuller,

I can successfully ping 212.58.251.202. The ifconfig command shows the ip address of LINUX box as 192.168.15.100 and my Windows IP address is 192.168.1.66.

Yes, your'e right I am getting IP address automatically from DHCP.

Thanks,
meetmefar

bbfuller 01-05-2008 12:54 PM

Hello meetmefar

Is that the correct ip address you have given for the Linux box?

Normally, if you were receiving ip addresses by dhcp they would both be in the same range.

Either both would be 192.168.1.something or both 192.168.15.something.

meetmefar 01-05-2008 01:38 PM

Hi bbfuller,

Thank You! Yes, that was a mistake from my part. The LINUX BOX IP is 192.168.1.65 and that of Windows is 192.168.1.66

Thanks,
meetmefar

bbfuller 01-05-2008 02:42 PM

Hello meetmefar

Although both machines can ping an ip address on the internet, you haven't said if they can each ping the router. I think we need to establish that next because depending on your answer, it's either the router blocking local pinging or one of the machines. I think we still need to determine which.

As that's Enterprise Red Hat/Oracle Linux, does it have SELinux on it and enabled? Worth temporarily disabling that if so and trying.

farslayer 01-06-2008 04:41 PM

I'd say check for a local firewall on the Linux box..

iptables -L

maooah 01-08-2008 11:37 PM

hi all

i encounter the same scenario where i couldnot able to ping from windows to linux or vice versa, however i am in the same network ie linux 192.168.1.5 and windows also 192.168.1.35

your response will be appreciated

Regards

farslayer 01-08-2008 11:47 PM

Quote:

Originally Posted by maooah (Post 3016243)
hi all

i encounter the same scenario where i couldnot able to ping from windows to linux or vice versa, however i am in the same network ie linux 192.168.1.5 and windows also 192.168.1.35

your response will be appreciated

Regards

Again it sounds like you have firewalls enabled on both PC's

maooah 01-13-2008 06:21 AM

dear farslayer

i didnot configure firewall settings for either linux or windows

waiting for your response

farslayer 01-13-2008 09:37 PM

Both Windows and Linux may enable the firewall by default during install (RHEL does) did you verify they were off ? or are you assuming they are off because you didn't recall specifically configuring them ?

Code:

debianetch:~# 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



All times are GMT -5. The time now is 01:15 AM.