Community discussions

MikroTik App
 
fleg
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 76
Joined: Mon Nov 06, 2017 12:31 pm

Lost camera connection via VPN after reboot/lost pptp connection

Fri May 28, 2021 11:18 am

I have one camera connected via VPN (pptp). If camera`s site lost connection and reconnect again I have to add static route again in the table because old record has unknown gw.
Can I fix it permanently?
1 ADC 192.168.1.0/24 192.168.1.1 bridge 0
2 ADC 192.168.2.0/24 192.168.2.100 ether1 0
3 ADC 192.168.89.21/32 192.168.89.22 <pptp-celadince> 0
4 A S 192.168.100.0/24 <pptp-celadince> 1
The 4th record has uknown gw instead pptp-celadince always if connection was broken.
Main site with camera`s server(Mikrotik GW)---------internet-------another network wth MT GW-----(LAN with cam).
 
tdw
Forum Guru
Forum Guru
Posts: 1841
Joined: Sat May 05, 2018 11:55 am

Re: Lost camera connection via VPN after reboot/lost pptp connection  [SOLVED]

Fri May 28, 2021 1:26 pm

Interfaces of the form <someinterfacename> are dynamic and references to them will not persist as the interface index changes each time a dynamic interface is created.

You can use server bindings which create a static interface associated with a (user)name already defined in PPP Secrets, the PPP Profile used by the PPP Secret should have only-one=yes.

Alternatively you can add route definitions to entries in PPP Secrets, these static routes are automatically added to the dynamic interface as it is created when the VPN connects.

Also whilst PPTP is an easy VPN protocol to set up, the MSCHAPv2 password and MPPE encryption have not been considered secure for years - consider using something better.
 
fleg
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 76
Joined: Mon Nov 06, 2017 12:31 pm

Re: Lost camera connection via VPN after reboot/lost pptp connection

Mon May 31, 2021 11:33 pm

Alternatively you can add route definitions to entries in PPP Secrets, these static routes are automatically added to the dynamic interface as it is created when the VPN connects.
This is the right way what I needed.

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot], karlisi and 98 guests