Answer the question
In order to leave comments, you need to log in
How to use another ip for VM in Proxmox?
There is Proxmox 6 on OVH.
Issued ip1 as primary and ip2 as "failover ip".
In /etc/network/interfaces:
auto lo
iface lo inet loopback
iface eno1 inet manual
auto vmbr0
iface vmbr0 inet static
address [ip1]/24
gateway [ip1.gateway]
bridge-ports eno1
bridge-stp off
bridge-fd 0
nameservers 1.1.1.1 8.8.8.8
auto vmbr1
iface vmbr1 inet static
address 10.0.0.1/24
bridge-ports none
bridge-stp off
bridge-fd 0
post-up echo 1 > /proc/sys/net/ipv4/ip_forward
post-up iptables -t nat -A POSTROUTING -s '10.0.0.0/24' -o vmbr0 -j MASQUERADE
pre-down iptables -t nat -D POSTROUTING -s '10.0.0.0/24' -o vmbr0 -j MASQUERADE
auto vmbr2
iface vmbr2 inet static
address [ip2]/24
bridge-ports none
bridge-stp off
bridge-fd 0
post-up iptables -t nat -A POSTROUTING -s '10.0.0.0/24' -o vmbr2 -j MASQUERADE
pre-down iptables -t nat -D POSTROUTING -s '10.0.0.0/24' -o vmbr2 -j MASQUERADE
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question