Networking Forums

Networking Forums > Computer Networking > Linux Networking > Why does my routing table only have 1 entry?

Reply
Thread Tools Display Modes

Why does my routing table only have 1 entry?

 
 
laredotornado@zipmail.com
Guest
Posts: n/a

 
      07-27-2006, 06:22 PM
Hi,

We were recently assigned to a new network, and I'm trying to update
the settings on my Solaris machine. Assume the IP of the default
gateway is 123.234.123.234. When I run netstat -rn, I get the
following

Routing Table
Destination Gateway Flags Ref Use Interface
--------------------------------------------------------------------------------------------
127.0.0.1 127.0.0.1 UH 0 0 lo0

which seems odd. Shouldn't my default gateway appear in this table?
Then when I try to ping the gateway (which works from other computers),
I get this message

> ping 123.234.123.234

ICMP Net Unreachable from gateway localhost (127.0.0.1) for icmp from
localhost (127.0.0.1) to 123.234.123.234

Any advice you can offer on updating my routing table is greatly
appreciated. Thanks, - Dave

 
Reply With Quote
 
 
 
 
Allen Kistler
Guest
Posts: n/a

 
      07-27-2006, 06:47 PM
(E-Mail Removed) wrote:
> Hi,
>
> We were recently assigned to a new network, and I'm trying to update
> the settings on my Solaris machine. Assume the IP of the default
> gateway is 123.234.123.234. When I run netstat -rn, I get the
> following
>
> Routing Table
> Destination Gateway Flags Ref Use Interface
> --------------------------------------------------------------------------------------------
> 127.0.0.1 127.0.0.1 UH 0 0 lo0
>
> which seems odd. Shouldn't my default gateway appear in this table?
> Then when I try to ping the gateway (which works from other computers),
> I get this message
>
>
>>ping 123.234.123.234

>
> ICMP Net Unreachable from gateway localhost (127.0.0.1) for icmp from
> localhost (127.0.0.1) to 123.234.123.234
>
> Any advice you can offer on updating my routing table is greatly
> appreciated. Thanks, - Dave


Did you know you posted to a Linux group, not a Solaris group? (Of
course, some cross-over of expertise is to be expected, but I'm setting
follow-ups to comp.unix.solaris.

Based on the routing table, I'd say your Ethernet interfaces are either
not up or not configured.
 
Reply With Quote
 
Unruh
Guest
Posts: n/a

 
      07-27-2006, 07:06 PM
(E-Mail Removed) writes:

>Hi,


>We were recently assigned to a new network, and I'm trying to update
>the settings on my Solaris machine. Assume the IP of the default
>gateway is 123.234.123.234. When I run netstat -rn, I get the
>following


>Routing Table
>Destination Gateway Flags Ref Use Interface
>--------------------------------------------------------------------------------------------
>127.0.0.1 127.0.0.1 UH 0 0 lo0


>which seems odd. Shouldn't my default gateway appear in this table?


It is not odd. It just says that no routes whatsoever have been set up.
Probably the ethernet card is not set up either.


>Then when I try to ping the gateway (which works from other computers),
>I get this message


>> ping 123.234.123.234

>ICMP Net Unreachable from gateway localhost (127.0.0.1) for icmp from
>localhost (127.0.0.1) to 123.234.123.234


Of course not. It has no way of getting the packet there.

YOu need a local route, which includes the gateway, which your system can
reach via the local attacked ethernet (Ie are on the same net) and a
default route through the gateway.

route add -net 111.222.333.0 netmask 255.255.255.0 eth0
route add default gw 111.222.333.254 eth0


>Any advice you can offer on updating my routing table is greatly
>appreciated. Thanks, - Dave


 
Reply With Quote
 
Dave Uhring
Guest
Posts: n/a

 
      07-27-2006, 08:10 PM
On Thu, 27 Jul 2006 19:06:06 +0000, Unruh wrote:

> YOu need a local route, which includes the gateway, which your system can
> reach via the local attacked ethernet (Ie are on the same net) and a
> default route through the gateway.
>
> route add -net 111.222.333.0 netmask 255.255.255.0 eth0
> route add default gw 111.222.333.254 eth0


It's a bit different in Solaris, which is the OS the OP is using.

 
Reply With Quote
 
laredotornado@zipmail.com
Guest
Posts: n/a

 
      07-27-2006, 08:12 PM
This is very useful. When I try the first command you suggest

> route add -net 111.222.333.0 netmask 255.255.255.224 eth0


in whichi "255.255.255.224" is the actual subnet mask given by our IT
department, i get the error "netmask: bad value". What happened?
Thanks, -

Unruh wrote:
> (E-Mail Removed) writes:
>
> >Hi,

>
> >We were recently assigned to a new network, and I'm trying to update
> >the settings on my Solaris machine. Assume the IP of the default
> >gateway is 123.234.123.234. When I run netstat -rn, I get the
> >following

>
> >Routing Table
> >Destination Gateway Flags Ref Use Interface
> >--------------------------------------------------------------------------------------------
> >127.0.0.1 127.0.0.1 UH 0 0 lo0

>
> >which seems odd. Shouldn't my default gateway appear in this table?

>
> It is not odd. It just says that no routes whatsoever have been set up.
> Probably the ethernet card is not set up either.
>
>
> >Then when I try to ping the gateway (which works from other computers),
> >I get this message

>
> >> ping 123.234.123.234

> >ICMP Net Unreachable from gateway localhost (127.0.0.1) for icmp from
> >localhost (127.0.0.1) to 123.234.123.234

>
> Of course not. It has no way of getting the packet there.
>
> YOu need a local route, which includes the gateway, which your system can
> reach via the local attacked ethernet (Ie are on the same net) and a
> default route through the gateway.
>
> route add -net 111.222.333.0 netmask 255.255.255.0 eth0
> route add default gw 111.222.333.254 eth0
>
>
> >Any advice you can offer on updating my routing table is greatly
> >appreciated. Thanks, - Dave


 
Reply With Quote
 
Jim Cochrane
Guest
Posts: n/a

 
      07-27-2006, 08:30 PM
On 2006-07-27, (E-Mail Removed) <(E-Mail Removed)> wrote:
> This is very useful. When I try the first command you suggest
>
>> route add -net 111.222.333.0 netmask 255.255.255.224 eth0

>
> in whichi "255.255.255.224" is the actual subnet mask given by our IT
> department, i get the error "netmask: bad value". What happened?
> Thanks, -


Probably, solaris 'route' does not understand Linux syntax.
 
Reply With Quote
 
Chris Davies
Guest
Posts: n/a

 
      07-28-2006, 08:41 AM
(E-Mail Removed) wrote:
> This is very useful. When I try the first command you suggest
>> route add -net 111.222.333.0 netmask 255.255.255.224 eth0


> in whichi "255.255.255.224" is the actual subnet mask given by our IT
> department, i get the error "netmask: bad value".


> What happened?


What happened is that you asked for Solaris advice in a Linux group, and
didn't apply the (correct) information from one OS to another. Suggest
you read the man page for route, which - at least on Solaris 9 - gives
actual examples for setting the netmask.

Chris
 
Reply With Quote
 
Michael Heiming
Guest
Posts: n/a

 
      07-29-2006, 09:06 AM
In comp.os.linux.networking Unruh <unruh-(E-Mail Removed)>:
> (E-Mail Removed) writes:


>>We were recently assigned to a new network, and I'm trying to update
>>the settings on my Solaris machine. Assume the IP of the default


Great, but what has this to do with linux? As others already
pointed out use a solaris ng for some solaris question!

Or at least check the manuals on your system and if still can't
figure it out:

http://sunsolve.sun.com/
[..]

>>> ping 123.234.123.234

>>ICMP Net Unreachable from gateway localhost (127.0.0.1) for icmp from
>>localhost (127.0.0.1) to 123.234.123.234


> Of course not. It has no way of getting the packet there.


> YOu need a local route, which includes the gateway, which your system can
> reach via the local attacked ethernet (Ie are on the same net) and a
> default route through the gateway.


> route add -net 111.222.333.0 netmask 255.255.255.0 eth0


You don't need to add a route to the network the IP belongs to on
linux, the system will do this on its own.

On solaris you might need in addition to set a host route to the
own interface, currently unsure (off-hand) if this is the case
for HP-UX, solaris or both. Guess I had to look it up. ;-)

--
Michael Heiming (X-PGP-Sig > GPG-Key ID: EDD27B94)
mail: echo (E-Mail Removed) | perl -pe 'y/a-z/n-za-m/'
#bofh excuse 174: Backbone adjustment
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Routing Table for JonnyCAD JonnyCAD Windows Networking 0 12-05-2006 11:45 AM
Routing table Matt Scoff Windows Networking 6 06-08-2006 02:19 AM
how to set default entry in routing table? kernel.lover Linux Networking 1 03-15-2005 10:40 PM
How to use second routing table? Martin Pauly Linux Networking 0 03-08-2005 04:54 PM
routing to multiple subnets in one entry /dev/rob0 Linux Networking 0 07-12-2003 11:04 PM



1 2 3 4 5 6 7 8 9 10 11