Cannot use apt-get in ubuntuserver VM

Senor_Dog_Water

New Member
Aug 14, 2025
7
0
1
So when I try to use apt-get update it keeps on failing to fetch from http://archive.ubuntu.

I can ping 8.8.8.8, I can ping google.com so it is not a DNS issue.
I disabled the firewall on my VM and Proxmox host, and I have no rules in iptables
I am not using NAT, I am using bridge as far as internet goes from my VM to my Proxmox host.


Anyone have any suggestions?
 
Last edited:
So when I try to use apt-get update it keeps on failing to fetch from http://archive.ubuntu.
There is no such thing as archive.ubuntu

Code:
~$ host archive.ubuntu
Host archive.ubuntu not found: 3(NXDOMAIN)

You need to post comprehensible details to get a useful answer!

Start with posting the output of "ip addr show", "ip link show", "ip route show", EDIT: "cat /etc/network/interfaces" - that one does not exist on Ubuntu, right?

...and add "apt update" in [code]...[/code]-tags please.
 
Last edited:
Sorry, attached to this should be all the requested commands.
 

Attachments

  • ip addr show.png
    ip addr show.png
    19.7 KB · Views: 10
  • ip link show.png
    ip link show.png
    8.2 KB · Views: 7
  • ip route show.png
    ip route show.png
    12.1 KB · Views: 10
  • apt-get update.png
    apt-get update.png
    33 KB · Views: 10
hey there,
can you reach everything else okay?
Are there other network related problems?
Firewall active and blocking?
Any other devices between ubuntu VM and gateway router?
Sorry for asking holes, but more info needed :)
 
hey there,
can you reach everything else okay?
Are there other network related problems?
Firewall active and blocking?
Any other devices between ubuntu VM and gateway router?
Sorry for asking holes, but more info needed :)
No you're good!

So I can ping everything else okay. My Proxmox Firewall and VM firewall are both disabled and there are no iptable rules. When I do run
curl -I http://archive.ubuntu.com/ubuntu I am getting curl: (56) Recv failure: Connection reset by peer.
 
hey there,
hm...strange indeed.
Sometimes these servers are somewhat not reachable...but I can ping those IPs in your screenshot just fine and that curl... gave some answer as well. So this time it is indeed on your side of the table to look for problems, it seems.
You did not change standard mtu (which can be a problem), so....strange.

Has it worked before?
Have you (for the Fun of it) tried with /24 network size?
Switch or anything else between ubuntu VM and gateway router?
And the usual: "Have you rebooted all those devices (router, switch, host)?" ;)
 
oh:
and another common suspect: any privacy or antivir software running anywhere on your lan related to that host? Those mess up stuff regularly in my experience. :)
 
No this is pretty much a fresh install of ubuntuserver, so this is my first time trying to do anything with it. I have not tried changing my network size. Right, I'm looking into possibly adding a Masquerade rule for the proxmox host. Maybe if the traffic is routed to the host and I let the host route it to the VM it might help.
 
how ist your lan setup?
VLANs? Anything fancy? Or straight gateway router ------------ proxmox host----------vm ubuntu?
I did not setup anything fancy...here I have vlans, host has its management interface IP to be reachable, vms (using vlan aware bridge) their vlan ID when creating them...never had any problems with it.
So you can ping (from ubuntu vm) anything...except http://archive.ubuntu and so on?
Can you reach other websites with curl okay (from said ubuntu machine)?
What about apt update from proxmox host? Any problems?
 
how ist your lan setup?
VLANs? Anything fancy? Or straight gateway router ------------ proxmox host----------vm ubuntu?
I did not setup anything fancy...here I have vlans, host has its management interface IP to be reachable, vms (using vlan aware bridge) their vlan ID when creating them...never had any problems with it.
So you can ping (from ubuntu vm) anything...except http://archive.ubuntu and so on?
Can you reach other websites with curl okay (from said ubuntu machine)?
What about apt update from proxmox host? Any problems?
I am not using any vlans. I can't curl anything; I get the same curl: (56) Recv failure: Connection reset by peer . Also I can ping the mirror sites. but it keeps on saying Failed to Fetch from https://archive.ubuntu...