Please help with network setup (Hetzner)

tukan

New Member
Oct 13, 2020
6
0
1
54
Hello, please advise, I have these ip addresses from Hetzner. Proxmox network (etc / network / interfaces) configured as follows. Further modify these lines without a character #
net.ipv4.ip_forward=1
net.ipv6.conf.all.forwarding=1

Sorry for my English :)

However, the server is not functional on the network (internal or external). Thanks for the advice on what I'm doing wrong.

------------------------------------------------------------------------------------------------------------------

IP addresses from Hetzner are attached

## Hetzner Online GmbH installimage

source /etc/network/interfaces.d/*

auto lo
iface lo inet loopback
iface lo inet6 loopback

auto enp4s0
iface enp4s0 inet static
address 94.130.217.230
netmask 255.255.255.192
pointopoint 94.130.217.193
gateway 94.130.217.193
up route add -net 94.130.217.192 netmask 255.255.255.192 gw 94.130.217.193 dev enp4s0

iface enp4s0 inet6 static
address 2a01:4f8:13b:1a5d::2
netmask 64
gateway fe80::1

auto vmbr0
iface vmbr0 inet static
address 94.130.217.230
netmask 255.255.255.255
bridge_ports none
bridge_stp off
bridge_fd 0
up ip route add 94.130.250.141/32 dev vmbr0
up ip route add 94.130.250.142/32 dev vmbr0

auto vmbr1
iface vmbr1 inet static
address 10.20.30.1
netmask 255.255.255.0
bridge_ports none
bridge_stp off
bridge_fd 0
post-up iptables -t nat -A POSTROUTING -s '10.20.30.0/24' -o vmbr0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '10.20.30.0/24' -o vmbr0 -j MASQUERADE


------------------------------------------------------------------------------------------------------------------------------------------------------


In proxmox, I created a VM with Ubuntu 16.04 and set up the network like this
(etc/network/interfaces)

auto lo
iface lo inet loopback

auto ens18
iface ens18 inet static
address 94.130.250.141
netmask 255.255.255.255
dns-nameservers 213.133.100.100 213.133.98.98 213.133.99.99
post-up ip route add 94.130.217.230 dev ens18
post-up ip route add default via 94.130.217.230 dev ens18
pre-down ip route del default via 94.130.217.230 dev ens18
pre-down ip route del 94.130.217.230 dev ens18


auto ens19
iface ens19 inet static
address 10.20.30.3
netmask 255.255.255.0
gateway 10.20.30.1

However, the server is not functional on the network (internal or external). Thanks for the advice on what I'm doing wrong.

hetzner.png

pve.png
 
Hi,
if you use /32 addresses, you need to add "pointopoint " in your ubuntu guest config
https://docs.hetzner.com/robot/dedicated-server/network/net-config-debian/

Code:
auto ens18
iface ens18 inet static
address 94.130.250.141
netmask 255.255.255.255
gateway 94.130.217.230
pointopoint  94.130.217.230

(not sure if it's exactly the same than your post-up route-add).

also check in hertzner panel that you don't have reserved macaddress for theses ips.


about your ens19, I don't see the second nic on vmbr1 in your proxmox config ?
 
Thank you so much for the advice. Finally, I reinstalled the server and started combining with pfSense. I'm learning :)
 

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 yours easily in our online shop.

Buy now!