Hi!
I use my hAP ac2 as wireguard client. I have 2 endpoints: Ubuntu server and Keneetik router. Both worked well. But the connection to the Keenetic ceased to be established after a power outage and a reboot my hAP. The connection to the Ubuntu server works well. I can connect to the Keneetic with destktop or mobile wireguard app with same config. But when connecting Mikrotik, only outgoing handshakes go. Rx traffic is 0 B, Tx is n*148 B. My hAP got a different ip from DHCP after a reboot. Can be trouble cause with DHCP?
Maybe more information is needed? Configs, etc?
Read Para 6 . - https://forum.mikrotik.com/viewtopic.php?t=182340
TY for manual. P6 is for endpoint’s dynamic IP. But my both endpoints have public IP. Connection to ubuntu endpoint works well. Connection to keenetic don’t work. I dont recieve handshake. But connetcion to keenetic works well before power outage. My MT router is behind provider’s router. Something went wrong after reboot provider’s router and MT

So can you confirm you have access to the providers router in front of the MT, in other words, you can port forward the listening port of the wireguard to the LANIP of the Mikrotik router on the ISPs LAN?? If not, then the MT is solely a client device.
I have not access to providers router. MT is a client device
So right now you have no remote access to the MT because WG is broken.
Tis why I also use SSTP from wireguard as a backup…
NO, PARA 6 is for the CLIENT!!!
The scripts are for the MT Client Router…
Suggest use this script and run it every 10 minutes…
Code: Select all
:foreach i in=[/interface/wireguard/peers/find where disabled=no endpoint-address~"[a-z]\$"] do={
:local LastHandshake [/interface/wireguard/peers/get $i last-handshake]
:if (([:tostr $LastHandshake] = "") or ($LastHandshake > [:totime "5m"])) do={
/interface/wireguard/peers/set $i endpoint-address=[/interface/wireguard/peers/get $i endpoint-address]
}
}