OpenVPN: route already in table. ERROR: FreeBSD route add command failed

tripst0r

Konsolen-Cowboy
Hi,

ich habe ein Problem mit OpenVPN unter FreeBSD. Die Client Konfiguration weiter unten nutze ich auch unter Windows und Debian Linux, dort funktioniert es problemlos, sich in ein entferntes VPN einzuklinken. Unter FreeBSD taucht folgende Fehlermeldung auf:

Code:
route: writing to routing socket: File exists
add net 192.168.1.0: gateway 192.168.5.1: route already in table
ERROR: FreeBSD route add command failed: shell command exited with error status: 1

Weitere Infos:

Code:
# ifconfig myk0
myk0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
        options=2b<RXCSUM,TXCSUM,VLAN_MTU,JUMBO_MTU>
        inet 192.168.1.2 netmask 0xffffff00 broadcast 192.168.1.255
        ether 00:AA:BB:CC:EE:FF
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active

# netstat -r
Routing tables

Internet:
Destination        Gateway            Flags    Refs      Use  Netif Expire
default            paketschubser      UGS         0     4916   myk0
localhost          localhost          UH          0       49    lo0
192.168.1          link#1             UC          0        0   myk0
paketschubser      00:01:02:03:04:05  UHLW        2     9528   myk0    909
192.168.1.255      ff:ff:ff:ff:ff:ff  UHLWb       1       31   myk0

Das Problem ist wohl, daß mein lokales Klasse C Netz 192.168.1.x schon in der Routingtabelle drin steht und daher nicht überschrieben, bzw. neu eingetragen werden kann. Gibt es eine Möglichkeit, ohne ein anderes lokales (Sub)Netz zu wählen und damit mein komplettes Netzlayout zu ändern, die Verbindung zum VPN aufzubauen?

Log komplett:

Code:
# openvpn --remote 217.72.195.142 1194 --proto udp --dev tap --client --pull --ca ~/openvpn/ca.crt --cert ~/openvpn/hans.crt --key ~/openvpn/hans.key --tls-auth ~/openvpn/ta.key 1 --cipher AES-256-CBC --ns-cert-type server --comp-lzo --persist-key --persist-tun --resolv-retry infinite --nobind --verb 3 --ping 10 --ping-restart 60 --ping-timer-rem

Mon Sep 10 17:37:18 2007 OpenVPN 2.0.6 i386-portbld-freebsd6.2 [SSL] [LZO] built on May 28 2007
Mon Sep 10 17:37:18 2007 IMPORTANT: OpenVPN's default port number is now 1194, based on an official port number assignment by IANA.  OpenVPN 2.0-beta16 and earlier used 5000 as the default port.
Enter Private Key Password:
Mon Sep 10 17:37:20 2007 Control Channel Authentication: using '/root/openvpn/ta.key' as a OpenVPN static key file
Mon Sep 10 17:37:20 2007 Outgoing Control Channel Authentication: Using 160 bit message hash 'SHA1' for HMAC authentication
Mon Sep 10 17:37:20 2007 Incoming Control Channel Authentication: Using 160 bit message hash 'SHA1' for HMAC authentication
Mon Sep 10 17:37:20 2007 LZO compression initialized
Mon Sep 10 17:37:20 2007 Control Channel MTU parms [ L:1590 D:166 EF:66 EB:0 ET:0 EL:0 ]
Mon Sep 10 17:37:20 2007 Data Channel MTU parms [ L:1590 D:1450 EF:58 EB:135 ET:32 EL:0 AF:3/1 ]
Mon Sep 10 17:37:20 2007 Local Options hash (VER=V4): '48527533'
Mon Sep 10 17:37:20 2007 Expected Remote Options hash (VER=V4): '44bd8b5e'
Mon Sep 10 17:37:20 2007 UDPv4 link local: [undef]
Mon Sep 10 17:37:20 2007 UDPv4 link remote: 217.72.195.142:1194
Mon Sep 10 17:37:20 2007 TLS: Initial packet from 217.72.195.142:1194, sid=bf2535f7 8bcb49f2
Mon Sep 10 17:37:20 2007 VERIFY OK: depth=1, /C=DE/ST=BAWÜ/L=Eppingen/O=Buero/CN=squid/emailAddress=hans@web.de
Mon Sep 10 17:37:20 2007 VERIFY OK: nsCertType=SERVER
Mon Sep 10 17:37:20 2007 VERIFY OK: depth=0, /C=DE/ST=BAWÜ/O=Buero/CN=server/emailAddress=hans@web.de
Mon Sep 10 17:37:23 2007 Data Channel Encrypt: Cipher 'AES-256-CBC' initialized with 256 bit key
Mon Sep 10 17:37:23 2007 Data Channel Encrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Mon Sep 10 17:37:23 2007 Data Channel Decrypt: Cipher 'AES-256-CBC' initialized with 256 bit key
Mon Sep 10 17:37:23 2007 Data Channel Decrypt: Using 160 bit message hash 'SHA1' for HMAC authentication
Mon Sep 10 17:37:23 2007 Control Channel: TLSv1, cipher TLSv1/SSLv3 DHE-RSA-AES256-SHA, 2048 bit RSA
Mon Sep 10 17:37:23 2007 [server] Peer Connection Initiated with 217.72.195.142:1194
Mon Sep 10 17:37:24 2007 SENT CONTROL [server]: 'PUSH_REQUEST' (status=1)
Mon Sep 10 17:37:24 2007 PUSH: Received control message: 'PUSH_REPLY,route 192.168.1.0 255.255.255.0 192.168.5.1,dhcp-option DNS 192.168.1.9,dhcp-option WINS 192.168.1.9,ping 10,ping-restart 120,ifconfig 192.168.5.10 255.255.255.0'
Mon Sep 10 17:37:24 2007 OPTIONS IMPORT: timers and/or timeouts modified
Mon Sep 10 17:37:24 2007 OPTIONS IMPORT: --ifconfig/up options modified
Mon Sep 10 17:37:24 2007 OPTIONS IMPORT: route options modified
Mon Sep 10 17:37:24 2007 OPTIONS IMPORT: --ip-win32 and/or --dhcp-option options modified
Mon Sep 10 17:37:24 2007 gw 192.168.1.1
Mon Sep 10 17:37:24 2007 TUN/TAP device /dev/tap0 opened
Mon Sep 10 17:37:24 2007 /sbin/ifconfig tap0 192.168.5.10 netmask 255.255.255.0 mtu 1500 up
Mon Sep 10 17:37:24 2007 /sbin/route add -net 192.168.1.0 192.168.5.1 255.255.255.0
route: writing to routing socket: File exists
add net 192.168.1.0: gateway 192.168.5.1: route already in table
Mon Sep 10 17:37:24 2007 ERROR: FreeBSD route add command failed: shell command exited with error status: 1
Mon Sep 10 17:37:24 2007 Initialization Sequence Completed

Bis neulich,
tripst0r
 
Nope gibt es nicht. Dein VPN-Netzwerk muss immer in einem anderen Subnetz sein wie Dein lokales LAN.

Gruß,

Ice
 
Hi,
ich erinnere mich vage daran, darüber mal etwas in der OpenVPN Doku gelesen zu haben, jedoch frag ich mich, warum es dann bei Windows und Debian klappt......die beiden Kisten hängen im gleichen Subnet. :confused:

Bis neulich,
tripst0r
 
Back
Top