I have the following configuration in a lab environment:
Code: Select all
# aug/03/2024 23:56:44 by RouterOS 6.48.6
# model = 951Ui-2HnD
/ip pool
add name=vpn_pool ranges=172.168.0.5-172.168.0.10
/ppp profile
add local-address=172.168.0.1 name=ovpn_profile remote-address=vpn_pool
/interface ovpn-server server
set auth=sha1 certificate=Server cipher=aes256 enabled=yes require-client-certificate=yes
/ip address
add address=192.168.5.50/24 interface=ether2 network=192.168.5.0
add address=10.10.11.1/24 interface=ether4 network=10.10.11.0
/ip dns
set allow-remote-requests=yes servers=8.8.8.8
/ip firewall nat
add action=masquerade chain=srcnat
/ppp secret
add name=huso password=huso profile=ovpn_profile service=ovpn
Ether4 Port: Connected to another Windows laptop with IP address 10.10.11.2 and subnet mask 255.255.255.0.
The VPN connection is successfully established on the Windows laptop connected to the Ether2 port. However, it is not possible to ping the addresses 10.10.11.1 or 10.10.11.2.
When I add the line route 10.10.11.0 255.255.255.0 to the OpenVPN client config file, the ping works.
What I want to achieve is to perform this routing configuration on the MikroTik device instead of adding routes on the client machine.
I have tried various options, including adding routes and NAT rules, but nothing seems to work.