2 network interface in server and access only from one interface

ds(ds)

Active Member
Sep 11, 2011
60
0
26
There are 2 network interfaces (eth0-lan eth1-internet)
I want to give access SSH only through eth0.
have any questions
1. best done through iptables or there are other better solutions?

2. if cut, ssh (port 22) on eth1, lost access to the vm (via ssh) are connected through vmbr1? (need to change port ssh from 22 to 23 for example?)
 

coffe

Guest
i have solved hat with a shorewall install on server.. and stop traffic to local , will work if clients have external ips.
 

udo

Famous Member
Apr 22, 2009
5,923
180
83
Ahrensburg; Germany
There are 2 network interfaces (eth0-lan eth1-internet)
I want to give access SSH only through eth0.
have any questions
1. best done through iptables or there are other better solutions?

2. if cut, ssh (port 22) on eth1, lost access to the vm (via ssh) are connected through vmbr1? (need to change port ssh from 22 to 23 for example?)
Hi,
why not easy: told sshd to listen only on eth0!
in /etc/ssh/sshd_config
Code:
ListenAddress=127.0.0.1
ListenAddress=ip.of.et.h0
Udo
 

ds(ds)

Active Member
Sep 11, 2011
60
0
26
2 udo
its really best solution :)

and another question: how to disable the web interface from the outside? (hosts.deny ???)
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get your own in 60 seconds.

Buy now!