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

OpenVPN: Routing-Problem



Hallo,

ich habe mich in der OpenVPN-Konfiguration verheddert und deshalb einmal
alle route- oder push route-Anweisungen entfernt.

Es sollen die beiden Netz 192.168.100.0 und 192.168.200.0 so verbunden
werden, dass jeweils jeder Host jeden anderen ereichen kann.
192.168.x.100 sind jeweils OpenVPN-Server- bzw. Client und
Default-Gateway für alle anderen Hosts. 192.168.x.250 ist jeweils der
externe Router für die Internetverbindung. Die Default-Route muss auch
so bleiben, weil sonst die OpenVPN-Verbindung (über das Internet) abreißt.


------------------------------------------------------------------------


So sieht es auf 192.168.100.100 aus:

eth0      Link encap:Ethernet  HWaddr 00:E0:7D:7C:9E:EB
          inet addr:192.168.100.100  Bcast:192.168.100.255
Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:20638088 errors:3 dropped:6 overruns:3 frame:0
          TX packets:34597222 errors:0 dropped:0 overruns:10 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:21402403 (20.4 MiB)  TX bytes:4015366944 (3.7 GiB)
          Interrupt:17 Base address:0xcc00

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:39434 errors:0 dropped:0 overruns:0 frame:0
          TX packets:39434 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:8351510 (7.9 MiB)  TX bytes:8351510 (7.9 MiB)

tun0      Link encap:UNSPEC  HWaddr
00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
          inet addr:192.168.111.1  P-t-P:192.168.111.2  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

tun1      Link encap:UNSPEC  HWaddr
00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
          inet addr:192.168.222.6  P-t-P:192.168.222.5  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use
Iface
192.168.111.2   0.0.0.0         255.255.255.255 UH    0      0        0 tun0
192.168.222.5   0.0.0.0         255.255.255.255 UH    0      0        0 tun1
192.168.222.1   192.168.222.5   255.255.255.255 UGH   0      0        0 tun1
192.168.100.0   0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.111.0   192.168.111.2   255.255.255.0   UG    0      0        0 tun0
0.0.0.0         192.168.100.250 0.0.0.0         UG    0      0        0 eth0


------------------------------------------------------------------------


So dagegen auf 192.168.200.100:

eth0      Link encap:Ethernet  HWaddr 00:07:E9:F4:14:DA
          inet addr:192.168.200.100  Bcast:192.168.200.255
Mask:255.255.255.0
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:11336832 errors:0 dropped:0 overruns:0 frame:0
          TX packets:16034759 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:1269204949 (1.1 GiB)  TX bytes:1547298410 (1.4 GiB)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:9369 errors:0 dropped:0 overruns:0 frame:0
          TX packets:9369 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:1855053 (1.7 MiB)  TX bytes:1855053 (1.7 MiB)

tun0      Link encap:UNSPEC  HWaddr
00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
          inet addr:192.168.222.1  P-t-P:192.168.222.2  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

tun1      Link encap:UNSPEC  HWaddr
00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
          inet addr:192.168.111.6  P-t-P:192.168.111.5  Mask:255.255.255.255
          UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:100
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use
Iface
192.168.111.1   192.168.111.5   255.255.255.255 UGH   0      0        0 tun1
192.168.222.2   0.0.0.0         255.255.255.255 UH    0      0        0 tun0
192.168.111.5   0.0.0.0         255.255.255.255 UH    0      0        0 tun1
192.168.200.0   0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.222.0   192.168.222.2   255.255.255.0   UG    0      0        0 tun0
0.0.0.0         192.168.200.250 0.0.0.0         UG    0      0        0 eth0


------------------------------------------------------------------------


Was ist bisher hinbekommen habe, ist das sich die beiden Server anpingen
können bzw. man vom Server Hosts aus dem anderen Netz anpingen kann,
aber von den Hosts kann man nicht ins andere Netz pingen. Daher habe ich
alle Routen wieder entfernt und suche nach der richtigen Lösung.


Dank für Tipps,

Michael



Reply to: