{"id":512,"date":"2013-07-10T10:39:02","date_gmt":"2013-07-10T08:39:02","guid":{"rendered":"http:\/\/kb.toderu.ro\/?p=512"},"modified":"2013-07-10T10:39:02","modified_gmt":"2013-07-10T08:39:02","slug":"vpn-client-synology-permanent-static-routes","status":"publish","type":"post","link":"https:\/\/kb.toderu.ro\/?p=512","title":{"rendered":"vpn client synology permanent static routes"},"content":{"rendered":"<p>\t\t\t\t<a href=\"https:\/\/kb.toderu.ro\/wp-content\/uploads\/2013\/07\/wp.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-513\" alt=\"syno vpn client control panel\" src=\"https:\/\/kb.toderu.ro\/wp-content\/uploads\/2013\/07\/wp.png\" width=\"863\" height=\"457\" srcset=\"https:\/\/kb.toderu.ro\/wp-content\/uploads\/2013\/07\/wp.png 863w, https:\/\/kb.toderu.ro\/wp-content\/uploads\/2013\/07\/wp-300x159.png 300w, https:\/\/kb.toderu.ro\/wp-content\/uploads\/2013\/07\/wp-768x407.png 768w\" sizes=\"auto, (max-width: 863px) 100vw, 863px\" \/><\/a><\/p>\n<p>oke, after u setup the vpn and you get it working:<br \/>\nenable telnet\/ssh on synology box<br \/>\nlogin into synology<br \/>\ntype <code>ifconfig<\/code><br \/>\nyou should see an pppx interface:<\/p>\n<p><code>ppp0 Link encap:Point-to-Point Protocol<br \/>\ninet addr:192.168.1.44 P-t-P:192.168.1.99 Mask:255.255.255.255<br \/>\nUP POINTOPOINT RUNNING NOARP MULTICAST MTU:1396 Metric:1<br \/>\nRX packets:1819 errors:0 dropped:0 overruns:0 frame:0<br \/>\nTX packets:1372 errors:0 dropped:0 overruns:0 carrier:0<br \/>\ncollisions:0 txqueuelen:3<br \/>\nRX bytes:1694061 (1.6 MiB) TX bytes:236202 (230.6 KiB)<br \/>\n<\/code><br \/>\nyou need the P-t-P ip: in this case is 192.168.1.99<\/p>\n<p><code>vi \/etc\/ppp\/ip-up<\/code><\/p>\n<p>add at the end of file:<\/p>\n<p><code>#added for vpn routes<br \/>\ncase \"${IPREMOTE}\" in<br \/>\n192.168.1.99)<br \/>\nip ro add 1.2.3.4\/24 dev ${IFNAME}<br \/>\nip ro add 2.3.4.0\/24 dev ${IFNAME}<br \/>\n;;<br \/>\nesac<\/code><\/p>\n<p>restart vpn from control panel:<br \/>\nyou should see already the new routes:<\/p>\n<p><code>nas&gt; ip route show<br \/>\n192.168.1.99 dev ppp0 src 192.168.1.44<br \/>\n|ip of vpn server| via |default gw| dev eth0 src |ip of syno|<br \/>\n|local subnet|\/24 dev eth0<br \/>\n1.2.3.4\/24 dev ppp0<br \/>\n2.3.4.0\/24 dev ppp0<br \/>\ndefault via |gateway| dev eth0<br \/>\n<\/code>\t\t<\/p>\n","protected":false},"excerpt":{"rendered":"<p>oke, after u setup the vpn and you get it working: enable telnet\/ssh on synology box login into synology type ifconfig you should see an pppx interface: ppp0 Link encap:Point-to-Point Protocol inet addr:192.168.1.44 P-t-P:192.168.1.99 Mask:255.255.255.255 UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1396 Metric:1 RX packets:1819 errors:0 dropped:0 overruns:0 frame:0 TX packets:1372 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19,20,5,8],"tags":[],"class_list":["post-512","post","type-post","status-publish","format-standard","hentry","category-bash","category-bash-scripting","category-linux","category-networking"],"_links":{"self":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/512","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=512"}],"version-history":[{"count":0,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=\/wp\/v2\/posts\/512\/revisions"}],"wp:attachment":[{"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=512"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=512"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/kb.toderu.ro\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=512"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}