You are not logged in.

#1 2019-12-31 10:25:57

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,597
Website

SSH to container stops when OpenVPN is connected... how to allow

I have a LXC that runs OpenVPN.  The container's network adapter is a NAT bridge run by lxc-net.
Host machine = 192.168.1.103
LXC = 10.0.3.100

On the host, I added this to /etc/ufw/before.rules

*nat
:PREROUTING ACCEPT [0:0]
-A PREROUTING -i eth0 -p tcp --dport 22220 -j DNAT --to-destination 10.0.3.100:22
COMMIT

That allow me to connect to the LXC by this command:

ssh -p 22220 192.168.1.103

I can ssh into this container just fine when openvpn is not running, but when it connects, the ssh connect is frozen (cannot ctrl+c or do anything).  Trying to ssh via another session just timeouts.  I am wondering what I can do within the container (also using ufw) to prevent this.  The container uses ufw which I setup per this wiki.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

Board footer

Powered by FluxBB