Subject: Re: Can't configure default gateway
To: Rui Paulo <rpaulo@gmail.com>
From: Alexandre Almeida <ale.almeida@mail.telepac.pt>
List: tech-net
Date: 11/09/2006 12:30:27
Rui Paulo escreveu:
>
> On Nov 9, 2006, at 10:31 AM, Alexandre Almeida wrote:
>
>> That I think is the problem, here are configuration parameter's:
>>
>> $ ifconfig -a
>> tlp0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
>> address: 00:00:f8:04:29:59
>> media: Ethernet autoselect (10baseT)
>> status: active
>> inet 172.20.27.61 netmask 0xffffffc0 broadcast 172.20.27.63
>> tlp1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
>> address: 00:00:f8:09:85:be
>> media: Ethernet autoselect (10baseT)
>> status: active
>> inet 82.155.138.115 netmask 0xff000000 broadcast 82.255.255.255
>> lo0: flags=8009<UP,LOOPBACK,MULTICAST> mtu 33136
>> inet 127.0.0.1 netmask 0xff000000
>>
>> $ netstat -ranf inet
>> Routing tables
>>
>> Internet:
>> Destination Gateway Flags Refs Use Mtu Interface
>> 82/8 link#2 UC 0 0 - tlp1
>> 82.155.138.115 127.0.0.1 UGHS 0 0 33136 lo0
>> 127/8 127.0.0.1 UGRS 0 0 33136 lo0
>> 127.0.0.1 127.0.0.1 UH 2 46 33136 lo0
>>
>> On windows or linux the default is configuesd by DHCP, here the
>> routing table:
>>
>> Rotas activas:
>> Destino de rede Máscara de rede Gateway Interface
>> Métrica
>> 0.0.0.0 0.0.0.0 194.65.169.215
>> 82.155.154.8 1
>> 82.0.0.0 255.0.0.0 82.155.154.8
>> 82.155.154.8 20
>> 82.155.154.8 255.255.255.255 127.0.0.1
>> 127.0.0.1 20
>> 82.255.255.255 255.255.255.255 82.155.154.8
>> 82.155.154.8 20
>> 127.0.0.0 255.0.0.0 127.0.0.1
>> 127.0.0.1 1
>> 224.0.0.0 240.0.0.0 82.155.154.8
>> 82.155.154.8 20
>> 255.255.255.255 255.255.255.255 82.155.154.8
>> 5 1
>> 255.255.255.255 255.255.255.255 82.155.154.8
>> 4 1
>> 255.255.255.255 255.255.255.255 82.155.154.8
>> 82.155.154.8 1
>> 255.255.255.255 255.255.255.255 82.155.154.8
>> 2 1
>> 255.255.255.255 255.255.255.255 82.155.154.8
>> 6 1
>> Gateway predef.: 194.65.169.215
>> ===========================================================================
>>
>>
>> I have tried to had manually to configure with:
>>
>> route had default 194.65.169.215
>> error no route to host
>> route add -host 194.65.169.215 -gateway 82.155.138.115 -interface
>> -llinfo -cloned
>> arpresolve: can't allocate llinfo on tlp1 for 194.65.169.215
>> arpresolve: can't allocate llinfo on tlp1 for 194.65.169.215
>>
>> # netstat -ran
>> Routing tables
>>
>> Internet:
>> Destination Gateway Flags Refs Use Mtu Interface
>> 82/8 link#2 UC 0 0 - tlp1
>> 82.155.138.115 127.0.0.1 UGHS 0 0 33136 lo0
>> 127/8 127.0.0.1 UGRS 0 0 33136 lo0
>> 127.0.0.1 127.0.0.1 UH 2 46 33136 lo0
>> 194.65.169.215 82.155.138.115 UHLSc 0 4 - tlp1
>
> To add such route you need something like:
>
> route add -ifa <your_tlp1_address> default 194.65.169.215
> --
> Rui Paulo
>
>
When I do:
route add -ifa 82.155.244.210 default 194.65.169.215
or
route add -ifp 00:90:d0:e4:da:81 default 194.65.169.215
the error:
arplookup: unable to enter address for 192.168.1.254@00:90:d0:e4:da:81
on tlp1 (host is not on local network)
so I have done this:
assign an alias to tlp1 (192.168.1.101)
assign as default 192.168.1.254
and now works, I have the public ip on NETBSD.
tlp1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
address: 00:00:f8:09:85:be
media: Ethernet autoselect (10baseT)
status: active
inet 82.155.244.210 netmask 0xff000000 broadcast 82.255.255.255
inet alias 192.168.1.101 netmask 0xffffff00 broadcast 192.168.1.255
lo0: flags=8009<UP,LOOPBACK,MULTICAST> mtu 33136
inet 127.0.0.1 netmask 0xff000000
Destination Gateway Flags Refs Use Mtu
Interface
default 192.168.1.254 UGS 0 0 - tlp1
82/8 link#2 UC 6 0 - tlp1
82.154.237.54 00:90:d0:e4:da:81 UHLc 1 64 - tlp1
82.155.24.181 00:90:d0:e4:da:81 UHLc 0 3 - tlp1
82.155.74.97 00:90:d0:e4:da:81 UHLc 0 4 - tlp1
82.155.151.74 00:90:d0:e4:da:81 UHLc 0 3 - tlp1
82.155.242.129 00:90:d0:e4:da:81 UHLc 0 2 - tlp1
82.155.242.218 00:90:d0:e4:da:81 UHLc 0 1 - tlp1
82.155.244.210 127.0.0.1 UGHS 0 0 33136 lo0
127/8 127.0.0.1 UGRS 0 0 33136 lo0
127.0.0.1 127.0.0.1 UH 2 10 33136 lo0
192.168.1/24 link#2 UC 1 0 - tlp1
192.168.1.254 00:90:d0:e4:da:81 UHLc 1 11 - tlp1
But I think that this behavior is not normal. this error
arplookup: unable to enter address for 192.168.1.254@00:90:d0:e4:da:81
on tlp1 (host is not on local network)
must have a motive to occurs.
Alexandre Almeida