Прошу помогите прошу вас ! Стоит роутер на Openwrt с двумя каналами поднят ipip туннель в случае недоступности первого интерфейса переключает на резервный. Проблема в том что с резервного никак не хочет обратно на основной. В статусе туннелей : концы туннелей 192.168.170.101 и 192.168.170.97 отвечают на ping. Проблема в машрутизаторе или все же в сервере
show ip ospf neighbor
Neighbor ID Pri State Dead Time Address Interface RXmtL RqstL DBsmL
192.168.168.2 1 Init/DROther 00:00:35 192.168.170.101 tun0wrk:192.168.170.102 0 0 0
192.168.168.2 1 Full/DROther 00:00:35 192.168.170.97 tun1wrk:192.168.170.98 0 0 0
ifconfig
br0
Link encap:Ethernet HWaddr C0:C1:C0:20:7B:90
inet addr:192.168.143.225 Bcast:192.168.143.255 Mask:255.255.255.224
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:4626 errors:0 dropped:0 overruns:0 frame:0
TX packets:5436 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:752884 (735.2 KiB) TX bytes:932212 (910.3 KiB)
eth0
Link encap:Ethernet HWaddr C0:C1:C0:20:7B:90
UP BROADCAST RUNNING PROMISC MULTICAST MTU:1500 Metric:1
RX packets:16430 errors:0 dropped:0 overruns:0 frame:0
TX packets:14910 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:2594180 (2.4 MiB) TX bytes:2840676 (2.7 MiB)
Interrupt:4
eth1
Link encap:Ethernet HWaddr C0:C1:C0:20:7B:92
UP BROADCAST RUNNING ALLMULTI MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:378 errors:7 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:36519 (35.6 KiB)
Interrupt:2 Base address:0x5000
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:157 errors:0 dropped:0 overruns:0 frame:0
TX packets:157 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:8717 (8.5 KiB) TX bytes:8717 (8.5 KiB)
tun0wrk
Link encap:UNSPEC HWaddr D4-5E-6F-2A-00-00-00-00-00-00-00-00-00-00-00-00
inet addr:192.168.170.102 P-t-P:192.168.170.101 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MTU:1480 Metric:1
RX packets:724 errors:0 dropped:0 overruns:0 frame:0
TX packets:274 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:52060 (50.8 KiB) TX bytes:25568 (24.9 KiB)
tun1wrk
Link encap:UNSPEC HWaddr 5D-BD-DD-3D-00-00-00-00-00-00-00-00-00-00-00-00
inet addr:192.168.170.98 P-t-P:192.168.170.97 Mask:255.255.255.255
UP POINTOPOINT RUNNING NOARP MTU:1480 Metric:1
RX packets:9059 errors:0 dropped:0 overruns:0 frame:0
TX packets:9360 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:1135746 (1.0 MiB) TX bytes:1637449 (1.5 MiB)
vlan0
Link encap:Ethernet HWaddr C0:C1:C0:20:7B:90
UP BROADCAST RUNNING ALLMULTI MULTICAST MTU:1500 Metric:1
RX packets:4626 errors:0 dropped:0 overruns:0 frame:0
TX packets:5436 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:771388 (753.3 KiB) TX bytes:953956 (931.5 KiB)
vlan1
Link encap:Ethernet HWaddr C0:C1:C0:20:7B:90
inet addr:211.74.101.42 Bcast:211.74.101.47 Mask:255.255.255.248
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:893 errors:0 dropped:0 overruns:0 frame:0
TX packets:43 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:78574 (76.7 KiB) TX bytes:5746 (5.6 KiB)
vlan2
Link encap:Ethernet HWaddr C0:C1:C0:20:7B:90
inet addr:97.188.222.61 Bcast:97.188.222.63 Mask:255.255.255.248
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:10910 errors:0 dropped:0 overruns:0 frame:0
TX packets:9426 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:1448528 (1.3 MiB) TX bytes:1808965 (1.7 MiB)
S40network
#!/bin/sh
case "$1" in
start|restart)
rm -f /tmp/resolv.conf
ln -s /tmp/resolv.conf.auto /tmp/resolv.conf
ifup_interfaces=$(nvram get ifup_interfaces)
ifup_interfaces=${ifup_interfaces:-"lan wan wifi"}
for iface in $ifup_interfaces; do
ifup $iface
if [ "$iface" = "wifi" ]; then
$iface up
fi
done
/sbin/route add -net 212.150.110.8 netmask 255.255.255.248 gw 211.74.101.41
/sbin/route add -net 212.150.110.64 netmask 255.255.255.240 gw 97.188.222.62
/sbin/insmod ipip
/usr/sbin/ip tun add tun0wrk mode ipip remote 212.150.110.10 local 211.74.101.42 ttl 255
/usr/sbin/ip tun add tun1wrk mode ipip remote 212.150.110.71 local 97.188.222.61 ttl 255
/sbin/ifconfig tun0wrk 192.168.170.102 pointopoint 192.168.170.101
/sbin/ifconfig tun1wrk 192.168.170.98 pointopoint 192.168.170.97
;;
esac
ospfd.conf
hostname Pereezd-gw
password quagga
enable password backspace
interface tun0wrk
ip ospf cost 10
ip ospf network point-to-point
ip ospf authentication-key 13579
interface tun1wrk
ip ospf cost 100
ip ospf network point-to-point
ip ospf authentication-key 13579
router ospf
router-id 192.168.143.225
network 192.168.0.0/16 area 0
redistribute connected route-map Local_Network
log stdout
zebra.conf
hostname Pereezd-gw
password quagga
enable password backspace
interface tun0wrk
ip forwarding
interface tun1wrk
ip forwarding
log stdout
Дополнение
tcpdump -i vlan1
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on vlan1, link-type EN10MB (Ethernet), capture size 96 bytes
00:52:39.488174 IP 212.150.110.10 > 211.74.101.42: IP 192.168.168.215 > 192.168.170.102: ICMP echo request, id 768, seq 35850, length 40 (ipip-proto-4)
00:52:39.840655 IP 211.74.101.41 > 224.0.0.1: igmp query v2
00:52:39.841006 IP 211.74.101.41 > 224.0.0.12: igmp v2 report 224.0.0.12
00:52:40.167214 IP 212.150.110.10 > 211.74.101.42: IP 192.168.170.101 > 224.0.0.5: OSPFv2, Hello, length: 44 (ipip-proto-4)
00:52:44.989062 IP 212.150.110.10 > 211.74.101.42: IP 192.168.168.215 > 192.168.170.102: ICMP echo request, id 768, seq 36106, length 40 (ipip-proto-4)
00:52:50.169346 IP 212.150.110.10 > 211.74.101.42: IP 192.168.170.101 > 224.0.0.5: OSPFv2, Hello, length: 44 (ipip-proto-4)
00:52:50.488694 IP 212.150.110.10 > 211.74.101.42: IP 192.168.168.215 > 192.168.170.102: ICMP echo request, id 768, seq 36362, length 40 (ipip-proto-4)
tcpdump -i tun0wrk
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on tun0wrk, link-type RAW (Raw IP), capture size 96 bytes
00:56:50.216047 IP 192.168.170.101 > 224.0.0.5: OSPFv2, Hello, length: 44
00:56:52.501102 IP 192.168.168.215 > 192.168.170.102: ICMP echo request, id 768, seq 47626, length 40
00:56:53.700698 IP 192.168.170.102 > 224.0.0.5: OSPFv2, Hello, length: 48
00:56:58.001688 IP 192.168.168.215 > 192.168.170.102: ICMP echo request, id 768, seq 47882, length 40
00:57:00.216294 IP 192.168.170.101 > 224.0.0.5: OSPFv2, Hello, length: 44