[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

openbsd routing logic confused by ip prefixes - correction



Hello,

> I have an ethernet segment with different network prefixes, 
> concretely: 195.55.55.0/25 and 195.55.55.128/26. 
> (195.55.55.192/26 was not assigned to me) 

sorry Łukasz , I wrote wrong prefixes, they are:
195.55.55.0/26 <- gateway block
195.55.55.64/26 <- BSD box
195.55.55.128/26 <- for future use
*195.55.55.192/26 is not mine.
http://www.ripe.net/perl/whois?form_type=simple&full_query_string=&searchtext=195.55.55.0&do_search=Search

and the problem explained below persist :(

So the BSD box has a interface in the second block (195.55.55.66) 
and the gateway is in the first block (195.55.55.1). All that I 
need to do is add a static route to 195.55.55.1, but OpenBSD
refuse to work with it. AFAIK it is a legal configuration and
using a test GNU/Linux box with this routing table works fine.

any suggestion?

fuego2# uname -a
OpenBSD open-cvs 3.4 GENERIC#0 i386
fuego2#
fuego2# netstat -rn -f inet
Routing tables

Internet:
Destination        Gateway            Flags     Refs     Use    Mtu  Interface
127/8              127.0.0.1          UGRS        0        0  33224   lo0
127.0.0.1          127.0.0.1          UH          1        0  33224   lo0
195.55.55.64/26    link#1             UC          0        0      -   xl0
224/4              127.0.0.1          URS         0        0  33224   lo0
fuego2# ifconfig xl0
xl0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        address: 00:01:02:b3:f2:86
        media: Ethernet autoselect (10baseT)
        status: active
        inet 195.55.55.66 netmask 0xffffffc0 broadcast 195.55.55.127
        inet6 fe80::201:2ff:feb3:f286%xl0 prefixlen 64 scopeid 0x1
fuego2#
fuego2#
fuego2#
fuego2# route add -host 195.55.55.1 195.55.55.66 -interface
Feb 3 22:27:22 fuego2 /bsd: arp_rtrequest: bad gateway value
add host 195.55.55.1: gateway 195.55.55.66
fuego2#
fuego2# netstat -rn -f inet
Routing tables

Internet:
Destination        Gateway            Flags     Refs     Use    Mtu  Interface
127/8              127.0.0.1          UGRS        0        0  33224   lo0
127.0.0.1          127.0.0.1          UH          1        0  33224   lo0
195.55.55.1        195.55.55.66       UHS         0        0      -   xl0
195.55.55.64/26    link#1             UC          0        0      -   xl0
224/4              127.0.0.1          URS         0        0  33224   lo0
fuego2#
fuego2#
fuego2# ping 195.55.55.1
PING 195.55.55.1 (195.55.55.1): 56 data bytes
Feb 3 22:28:38 fuego2 /bsd: arpresolve: can't allocate llinfo
^C--- 195.55.55.1 ping statistics ---
5 packets transmitted, 0 packets received, 100.0% packet loss

-- 
-----BEGIN GEEK CODE BLOCK-----
Version: 3.1
GCS/IT d- s+:+() a- C+++ UBL+++$ P+ L+++ E--- W++ N+ o++ K- w---
O+ M+ V- PS+ PE+ Y++ PGP+>+++ t+ 5 X+$ R- tv-- b+++ DI D++>+++
G++ e- h+(++) !r !z
------END GEEK CODE BLOCK------