PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Noms de domaine > comp.protocols.tcp-ip > why can't ping gateway?
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.protocols.tcp-ip TCP and IP network protocols.

why can't ping gateway?

Réponse
 
LinkBack Outils de la discussion
Vieux 08/09/2007, 11h17   #1
iLRainyday
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut why can't ping gateway?

there is simple configuration,but I really could not figure out why
can't works.

linux box : eth0 (192.168.1.2)used to home connection
eth1 (192.168.3.150)used to campus conncetion,which has
192.168.3.1 as gateway IP.

windows box: eth0 (192.168.1.3),used to home connection,gateway IP is
192.168.1.2

Now,on my windows box,I could ping linux eth1 (192.168.3.150) but
can't get ping 192.168.3.1 through.

[root@localhost ~]# netstat -rn
Kernel IP routing table
Destination Gateway Genmask Flags MSS Window
irtt Iface
192.168.3.0 0.0.0.0 255.255.255.0 U 0 0
0 eth1
192.168.1.0 0.0.0.0 255.255.255.0 U 0 0
0 eth0
169.254.0.0 0.0.0.0 255.255.0.0 U 0 0
0 eth1
0.0.0.0 192.168.3.1 0.0.0.0 UG 0 0
0 eth1


sorry for my english and thanks in advance!

  Réponse avec citation
Vieux 08/09/2007, 21h16   #2
Barry Margolin
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: why can't ping gateway?

In article <1189246624.522520.252840@y42g2000hsy.googlegroups .com>,
iLRainyday <iLRainyday@gmail.com> wrote:

> there is simple configuration,but I really could not figure out why
> can't works.
>
> linux box : eth0 (192.168.1.2)used to home connection
> eth1 (192.168.3.150)used to campus conncetion,which has
> 192.168.3.1 as gateway IP.
>
> windows box: eth0 (192.168.1.3),used to home connection,gateway IP is
> 192.168.1.2
>
> Now,on my windows box,I could ping linux eth1 (192.168.3.150) but
> can't get ping 192.168.3.1 through.


Sounds like the 192.168.3.1 box doesn't have a route for 192.168.1.0/24
pointing to 192.168.3.150, so it can't reply to the pings you're sending.

>
> [root@localhost ~]# netstat -rn
> Kernel IP routing table
> Destination Gateway Genmask Flags MSS Window
> irtt Iface
> 192.168.3.0 0.0.0.0 255.255.255.0 U 0 0
> 0 eth1
> 192.168.1.0 0.0.0.0 255.255.255.0 U 0 0
> 0 eth0
> 169.254.0.0 0.0.0.0 255.255.0.0 U 0 0
> 0 eth1
> 0.0.0.0 192.168.3.1 0.0.0.0 UG 0 0
> 0 eth1
>
>
> sorry for my english and thanks in advance!


--
Barry Margolin, barmar@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
*** PLEASE don't copy me on replies, I'll read them in the group ***
  Réponse avec citation
Vieux 08/09/2007, 23h40   #3
Martijn Lievaart
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: why can't ping gateway?

On Sat, 08 Sep 2007 16:16:49 -0400, Barry Margolin wrote:

> In article <1189246624.522520.252840@y42g2000hsy.googlegroups .com>,
> iLRainyday <iLRainyday@gmail.com> wrote:
>
>> there is simple configuration,but I really could not figure out why
>> can't works.
>>
>> linux box : eth0 (192.168.1.2)used to home connection
>> eth1 (192.168.3.150)used to campus conncetion,which has
>> 192.168.3.1 as gateway IP.
>>
>> windows box: eth0 (192.168.1.3),used to home connection,gateway IP is
>> 192.168.1.2
>>
>> Now,on my windows box,I could ping linux eth1 (192.168.3.150) but can't
>> get ping 192.168.3.1 through.

>
> Sounds like the 192.168.3.1 box doesn't have a route for 192.168.1.0/24
> pointing to 192.168.3.150, so it can't reply to the pings you're
> sending.
>


Or routing is not turned on.

M4
  Réponse avec citation
Vieux 09/09/2007, 01h56   #4
Moe Trin
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: why can't ping gateway?

On Sat, 08 Sep 2007, in the Usenet newsgroup comp.protocols.tcp-ip, in article
<1189246624.522520.252840@y42g2000hsy.googlegroups .com>, iLRainyday wrote:

>there is simple configuration,but I really could not figure out why
>can't works.


Hmmm, no details of distribution, but the headers suggest CentOS which
is a Red Hat clone. It s to include your distribution data, as
things are done differently by the 800+ Linux distributions.

Have you installed the HOWTOs? There should be over 450 documents in
/usr/share/HOWTO/.

>linux box : eth0 (192.168.1.2)used to home connection
> eth1 (192.168.3.150)used to campus conncetion,which has
>192.168.3.1 as gateway IP.
>
>windows box: eth0 (192.168.1.3),used to home connection,gateway IP is
>192.168.1.2


OK - fairly normal setup

>Now,on my windows box,I could ping linux eth1 (192.168.3.150) but
>can't get ping 192.168.3.1 through.


1. cat /proc/sys/net/ipv4/ip_forward Is that a "1"?
2. Does 192.168.3.1 know how to reach 192.168.1.x by sending the
replies to 192.168.3.150 to be forwarded?

>[root@localhost ~]# netstat -rn
>Kernel IP routing table
>Destination Gateway Genmask Flags MSS Window irtt Iface
>192.168.3.0 0.0.0.0 255.255.255.0 U 0 0 0 eth1
>192.168.1.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0
>169.254.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth1
>0.0.0.0 192.168.3.1 0.0.0.0 UG 0 0 0 eth1


Looks fine - and I guess that the windoze box is able to ping the
eth1 address (however it is not the eth1 interface that is answering, but
the _kernel_ which knows all of it's addresses, and is answering through
the "appropriate" interface - in this case eth0) so it is configured
correctly. You need to look at the 192.168.3.1 router routing table to
see that it knows how to reach 192.168.1.x. The 169.254.0.0 is only
needed if you have a broken DHCP server on the 192.168.3.x network. If
you look inside /etc/sysconfig/network-scripts/ifup you'll probably
find something like:

# Add Zeroconf route.
if [ -z "${NOZEROCONF}" -a "${ISALIAS}" = "no" ]; then
ip route replace 169.254.0.0/16 dev ${REALDEVICE}
fi

So if you set NOZEROCONF=yes in the /etc/sysconfig/network configuration
file, this "feature" will be disabled. That probably is also where you
can set

FORWARD_IPV4=

to 'yes' or 'true', which the network boot scripts will then set the
kernel variable '/proc/sys/net/ipv4/ip_forward' correctly.

>sorry for my english and thanks in advance!


Your English is fine.

Old guy

  Réponse avec citation
Vieux 09/09/2007, 08h35   #5
iLRainyday
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: why can't ping gateway?

thanks for everyone

the reason is "192.168.3.1 has no routing for icmp to return",as above
said~

in addition,Barry Margolin, thanks for encouraging my english

  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 02h24.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,13173 seconds with 13 queries