If you guys think this doesnt belong here then I can remove it as I know it may not be related to Mikrotik itself
I have a wireguard VPN set up to my mikrotik. We use it for people working from home and also we have a separate site with about 4 people, they all use a wireguard client to connect to the NAS in our main office.
It currently does not work on two laptops. One is a person who works from home and the other is on a remote laptop we have at a customer location. (All the people on the remote site it works for, possibly because they have a strong fibre internet connection?)
I am able to ping the NAS from both laptops, but when I type \192.168.88.194 into the address bar, the windows credentials box pops up ‘Enter username and password’. This is normally what you would expect. However when I type in user and password (which I know for a fact are 100% correct) it takes ages to load, and eventually pops up an error
"\192.168.88.194 is not accessible. you might not have permission to use this network resource. contact the administrator of this server to find out if you have access permissions.
the remote call procedure failed.’
I have tried reinstalling wireguard and using a different wireguard peer but it doesnt work. The same wireguard peer works on different laptops anyway. Also, the person who works from home tried to use a 4g hotspot to connect and it didnt work. Yet from a different location, it DOES work with 4g hotspot, from the same phone, laptop, and all same config settings.
If anyone has seen this error before let me know but I cant find any results online for it.
EDIT: also seeing that if i try to connect to one of our IP phones via google chrome (on a laptop remotely accessing the network), it manages to ask for user and pass but once you enter the correct details it just loads indefinitely.
Without seeing the config of the router and the config of the wireguard on the laptop, its unknown. ALso windows has firewalls and AV programs that can interfere.
Perhaps there are some MTU issues…
Best is to make packet-capture and spot for issues…this smells indeed MTU or alike.
If you get authentication-box already etc then I doubt “settings” of Wireguard are at play here.
Firewall-rules also seems OK at this point then, but that can be checked in the logs (if you enable logging on each “drop” rule at least)
Anav and Jvan, thank you for your replies. I will look into MTU
Earlier today I also couldnt connect from my own home PC, but now suddenly I am able to a few hours later. Not sure why.. here is my config anyway.
Still can’t connect on a certain remote laptop we have on a customer site. When I type the IP of the NAS into a web browser, it loads some of the text on the page but not the images. When I do it on my (now working) home PC, it loads everything. I attached images of both. On the one where the images/color isnt loaded you can see the loading bar in the top left (it is still loading after 10 minutes)
Seems like it can load all the text but not images? Could that be some clue?
Okay so changing MTU to 1300 in Wireguard → Wireguard → (double click interface) → MTU appears to have fixed the problem. I dont really know what MTU does but that definitely seems to have been the problem given this remote laptop which hasn’t worked for months is now suddenly working. Thanks for the help guys!
Internet MTU (Maximum Transmission Unit) is 1500 bytes. Packets <= MTU avoid Layer 3 fragmentation or Layer 2 packet drop. See MTU in RouterOS for more.
All encapsulating protocols such as tunneling, VPN, Wiregauard, etc. add a header which increases packet size.
The consequence is down stream interface MTU must be lowered to avoid exceeding upstream MTU size.
Encapsulation header sizes are defined so choosing an exact MTU size becomes possible.
I use 6to4 tunnel with 20 byte header and then set MTU to 1480.
I suggest Google Search: Wireguard header size
Reddit r/WireGuard: MTU issue/questions
default MTU on wireguard is 1420…
I actually increased it to 1500 for one scenario and it worked out.
If your MT is at the client end Try this… /ip firewall mangle
add action=change-mss chain=forward comment=“Clamp MSS to PMTU for Outgoing packets” new-mss=clamp-to-pmtu out-interface=wireguard1 passthrough=yes protocol=tcp tcp-flags=syn
What do you mean by MT at the client end? I have a MT router in work premises, then remote laptop with wireguard on it at a completely separate location
While the connection is better now that I changed MTU in wireguard winbox to 1300, it still seems to be slightly slow at moving files onto the server and moving through the folders on the NAS. So maybe something is still wrong possibly. But at least its letting me log onto the server unlike before.
When copying files onto the NAS it goes up to like 1 MB/s, then suddenly down to 0 bytes/s, then it says ‘a network error occured’
If your MT is a client device for the handshake, in this case it appears not to be the case.
Just ensure the MTU is the same at both ends of the tunnel and try different numbers seeing as no one else has any other ideas…
1420 and up (1440. 1460. 1480. 1500, 1520)
1420 and down (1400, 1380, 1360, 1340)