If you are running into an issue where my Proxmox LXC containers can't resolve or ping FQDNs even though networking seems to be working fine, there are a few things you need to try.
First things to check - Make sure of the following
✅ The container has network access (can
✅ DNS settings inside the container (/etc/resolv.conf
) point to a proper DNS server (e.g., 8.8.8.8
)
✅ The Proxmox host itself can resolve FQDNs correctly
✅ The container is using a bridge network (vmbr0
)
Troubleshooting Steps and Fixes:
1. Check DNS Settings in the Container
Run:
If you want to manualy add/configure DNS to something like Googleโs DNS as an example, you can use the following:
If /etc/resolv.conf
keeps getting reset, you can check if it is managed by systemd-resolved. You might need to override settings using the follwoing command
2. Make sure the container has correct network configuration settings
Check the containerโs network settings in /etc/network/interfaces
:ย
If you have DHCP running on your network, but DNS is not getting set correctly, try setting a static IP with a known good DNS server and see if this resolves the issue:
Restart networking with:
3. Check Proxmox Hostโs LXC Configuration
Ensure the container isnโt restricted from using DNS resolution by checking its config file:
Look for any unusual settings like unprivileged: 1
or lxc.apparmor.profile
that may block networking. You may need to add:
Or try switching from unprivileged: 1
to unprivileged: 0
temporarily to see if it resolves the issue.
4. Check if the DNS Queries are Being Blocked
Test resolving manually with:
If these checks fail, check if Proxmox is filtering DNS queries. Some firewalls (like pfSense) may block external DNS queries if not configured to do so
5. Restart Network Services
Try restarting systemd-resolved inside the container:
Or restart the container:
Other things to try
If you've checked the above and it's still not working, the issue could be due to:
- Proxmox LXC AppArmor profiles blocking DNS
- Firewall rules preventing outbound DNS queries
- The network bridge (
vmbr0
) not properly passing DNS requests
Let me know if any of these steps worked for you or if you're still facing the issue! 🚀