I have a VPS(with OpenVZ virtualisation) set up with OpenVPN. Clients can connect to the server and the server can ping and access clients.
But clients does not have access to the internet through openvpn, therefore I want to add the following iptables line:
iptables -t nat -A POSTROUTING -j SNAT --to-source <venet's IP>
This allows the openvpn clients to access the internet, but when I add this line the server can no longer ping clients or e.g. ssh into clients, is there a way to fix this?