Greetings,
I am trying to make my containers have access to internet through proxmox host public ip. Below are my proxmox host networking configurations.
```
auto lo
iface lo inet loopback
iface eno1 inet manual
auto eno4
iface eno4 inet manual
iface eno2 inet manual
iface eno3 inet manual
auto vmbr0
iface vmbr0 inet static
address 207.45.76.20
netmask 255.255.255.192
gateway 207.45.76.1
bridge-ports eno1
bridge-stp off
bridge-fd 0
auto vmbr1
#private sub network
iface vmbr1 inet static
address 10.10.10.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.10.10.0/24' -o vmbr0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '10.10.10.0/24' -o vmbr0 -j MASQUERADE
post-up iptables -t raw -I PREROUTING -i fwbr+ -j CT --zone 1
post-down iptables -t raw -D PREROUTING -i fwbr+ -j CT --zone 1
```
And my container network configurations
But my container does not seem to have internet access. It cannot even ping my host private ip.
root@networking:~# ping 10.10.10.1
PING 10.10.10.1 (10.10.10.1) 56(84) bytes of data.
From 10.10.10.10 icmp_seq=1 Destination Host Unreachable
From 10.10.10.10 icmp_seq=2 Destination Host Unreachable
From 10.10.10.10 icmp_seq=3 Destination Host Unreachable
^C
--- 10.10.10.1 ping statistics ---
6 packets transmitted, 0 received, +3 errors, 100% packet loss, time 5101ms
pipe 4
Can only ping to itself
root@networking:~#
root@networking:~#
root@networking:~# ping 10.10.10.10
PING 10.10.10.10 (10.10.10.10) 56(84) bytes of data.
64 bytes from 10.10.10.10: icmp_seq=1 ttl=64 time=0.015 ms
64 bytes from 10.10.10.10: icmp_seq=2 ttl=64 time=0.023 ms
^C
--- 10.10.10.10 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1029ms
rtt min/avg/max/mdev = 0.015/0.019/0.023/0.004 ms
DNS settings on the container looks like below.
root@networking:~# cat /etc/resolv.conf
# --- BEGIN PVE ---
search phxdcnet.com
nameserver 8.8.8.8
# --- END PVE ---
root@networking:~# ^C
root@networking:~# apt update
0% [Working]^C
root@networking:~# ^C
root@networking:~#
I have checked multiple posts on this forum, but none of them seem to work for me.
Can someone help me figure out what i am doing wrong above.
Thanks.
I am trying to make my containers have access to internet through proxmox host public ip. Below are my proxmox host networking configurations.
```
auto lo
iface lo inet loopback
iface eno1 inet manual
auto eno4
iface eno4 inet manual
iface eno2 inet manual
iface eno3 inet manual
auto vmbr0
iface vmbr0 inet static
address 207.45.76.20
netmask 255.255.255.192
gateway 207.45.76.1
bridge-ports eno1
bridge-stp off
bridge-fd 0
auto vmbr1
#private sub network
iface vmbr1 inet static
address 10.10.10.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.10.10.0/24' -o vmbr0 -j MASQUERADE
post-down iptables -t nat -D POSTROUTING -s '10.10.10.0/24' -o vmbr0 -j MASQUERADE
post-up iptables -t raw -I PREROUTING -i fwbr+ -j CT --zone 1
post-down iptables -t raw -D PREROUTING -i fwbr+ -j CT --zone 1
```
And my container network configurations
But my container does not seem to have internet access. It cannot even ping my host private ip.
root@networking:~# ping 10.10.10.1
PING 10.10.10.1 (10.10.10.1) 56(84) bytes of data.
From 10.10.10.10 icmp_seq=1 Destination Host Unreachable
From 10.10.10.10 icmp_seq=2 Destination Host Unreachable
From 10.10.10.10 icmp_seq=3 Destination Host Unreachable
^C
--- 10.10.10.1 ping statistics ---
6 packets transmitted, 0 received, +3 errors, 100% packet loss, time 5101ms
pipe 4
Can only ping to itself
root@networking:~#
root@networking:~#
root@networking:~# ping 10.10.10.10
PING 10.10.10.10 (10.10.10.10) 56(84) bytes of data.
64 bytes from 10.10.10.10: icmp_seq=1 ttl=64 time=0.015 ms
64 bytes from 10.10.10.10: icmp_seq=2 ttl=64 time=0.023 ms
^C
--- 10.10.10.10 ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1029ms
rtt min/avg/max/mdev = 0.015/0.019/0.023/0.004 ms
DNS settings on the container looks like below.
root@networking:~# cat /etc/resolv.conf
# --- BEGIN PVE ---
search phxdcnet.com
nameserver 8.8.8.8
# --- END PVE ---
root@networking:~# ^C
root@networking:~# apt update
0% [Working]^C
root@networking:~# ^C
root@networking:~#
I have checked multiple posts on this forum, but none of them seem to work for me.
Can someone help me figure out what i am doing wrong above.
Thanks.