# network table is reversed

## terry

hello,

my gentoo show routing table reversed.

I am not sure, when this is happen.

```

terry@macbookpro ~ $ netstat -rn

Kernel IP routing table

Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface

0.0.0.0         125.XXX.XXX.94  0.0.0.0         UG        0 0          0 eth0

125.XXX.XXX.64  0.0.0.0         255.255.255.224 U         0 0          0 eth0

127.0.0.0       127.0.0.1       255.0.0.0       UG        0 0          0 lo

terry@macbookpro ~ $ /sbin/route

Kernel IP routing table

Destination     Gateway         Genmask         Flags Metric Ref    Use Iface

default         125.XXX.XXX.94  0.0.0.0         UG    2      0        0 eth0

125.XXX.XXX.64  *               255.255.255.224 U     2      0        0 eth0

loopback        macbookpro.linu 255.0.0.0       UG    0      0        0 lo

terry@macbookpro ~ $
```

I think default gateway, should remain bottom line. am i right?

how can I fix it?

Thanks

----------

## SLBMEH

For as long as i can remember my default gateway has always been the first entry.  What problem is it causing you?

----------

## terry

 *SLBMEH wrote:*   

> For as long as i can remember my default gateway has always been the first entry.  What problem is it causing you?

 

hum.. that is strange.. for me.

I remember my default gateway has always been last.

and.

ubuntu, and redhat is same that default gateway in last line.

I check them twice.

and there is some post showing routing table

https://forums.gentoo.org/viewtopic-t-689590.html,(only show routing table..)

that also show, default gateway remain in bottom line..

Thanks for replay,

----------

## MassimoM

I don't think that it can cause any problem.

Routes in the routing table are selected using http://en.wikipedia.org/wiki/Longest_prefix_match and not by its position in routing table.

On my Gentoo default gw is the last line.

It's odd, but not worrying IMHO.

what does new-generation tool "ip route show" print? (package iproute2)

----------

