Portál AbcLinuxu, 6. května 2025 07:41
route add -net 10.0.0.0/24 gw 10.8.0.99
[root@schrapnel ~]# netstat -rn Kernel IP routing table Destination Gateway Genmask Flags MSS Window irtt Iface 0.0.0.0 146.X.Y.1 0.0.0.0 UG 0 0 0 eth0 10.0.0.0 10.8.0.99 255.255.255.0 UG 0 0 0 tun0 10.8.0.0 0.0.0.0 255.255.255.0 U 0 0 0 tun0 10.14.0.0 0.0.0.0 255.255.0.0 U 0 0 0 eth0 146.185.155.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0masquerade mám pre tun0 na serveri nastavenú, teda aspoň podľa:
firewall-cmd --zone=trusted --list-all trusted (active) interfaces: tun0 sources: services: ports: masquerade: yes forward-ports: icmp-blocks: rich rules:
tun0: flags=4305 UP,POINTOPOINT,RUNNING,NOARP,MULTICAST mtu 1500 inet 10.8.0.1 netmask 255.255.255.0 destination 10.8.0.1 unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00 txqueuelen 100 (UNSPEC) RX packets 0 bytes 0 (0.0 B) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 6 bytes 504 (504.0 B) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0No do svojej domácej siete sa jednoducho nedostanem ...
# ping 10.0.0.1 PING 10.0.0.1 (10.0.0.1) 56(84) bytes of data. ^C --- 10.0.0.1 ping statistics --- 3 packets transmitted, 0 received, 100% packet loss, time 1999msKaždá rada dobrá, vopred ďakujem.
iroute 10.0.0.0 255.255.255.0informoval openvpn server aby traffic do danej siete posielal cez neho. Takže v synology zakomentovať, v raspberry pridať a všetko funguje ako po masle.
cat synology ifconfig-push 10.8.0.25 255.255.255.0 #iroute 10.0.0.0 255.255.255.0 cat raspberry ifconfig-push 10.8.0.99 255.255.255.0 iroute 10.0.0.0 255.255.255.0 [schrapnel@schrapnel ccd]$*[pekac - problem exists between keyboard and chair]
Tiskni
Sdílej:
ISSN 1214-1267, (c) 1999-2007 Stickfish s.r.o.