Results 1 to 5 of 5

Thread: [VPS Server] Error Updating Packages in Ubuntu 24.04 LTS

  1. #1
    Join Date
    May 2009
    Location
    Chittagong
    Beans
    70
    Distro
    Ubuntu

    Exclamation [VPS Server] Error Updating Packages in Ubuntu 24.04 LTS

    Hello,

    I have a VPS which came with Ubuntu 22.04 LTS, I have upgraded it into Ubuntu 24.04 LTS. I have followed this guide here- https://www.cyberciti.biz/faq/how-to...ntu-24-04-lts/

    After upgrade, I have found it's ok and the VPS upgraded into latest 24.04 LTS. But I can't run command-

    Code:
    sudo apt-get update
    This is returning an error like below-

    Code:
    W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble/InRelease  Temporary failure resolving 'archive.ubuntu.com'W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble-updates/InRelease  Temporary failure resolving 'archive.ubuntu.com'
    W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/noble-backports/InRelease  Temporary failure resolving 'archive.ubuntu.com'
    W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/noble-security/InRelease  Temporary failure resolving 'security.ubuntu.com'
    W: Some index files failed to download. They have been ignored, or old ones used instead.
    I have tried to temporarily add nameserver (8.8.8.8) in resolv.conf file and try to update again. But it's giving same error.

    Here is the content of my current /etc/resolv.conf file -

    Code:
    nameserver 127.0.0.53
    options edns0 trust-ad
    search .
    I have tried to ping www.google.com and it returns ping: www.google.com: Temporary failure in name resolution

    How to fix the issue please? Can anybody please help me here?

    Thanks in advance.

  2. #2
    currentshaft Guest

    Re: [VPS Server] Error Updating Packages in Ubuntu 24.04 LTS

    /etc/resolv.conf is now a symlink which gets generated by netplan, I think? Any edits to it will be overwritten, as you've demonstrated in your output.

    What I do is delete the symlink and replace it with an immutable file:

    sudo rm -f /etc/resolv.conf
    sudo vim /etc/resolv.conf
    add "nameserver 127.0.0.1" (since I use dnsmasq locally)
    sudo chattr +i /etc/resolv.conf

    Otherwise, I think you want to edit /etc/netplan files to set your DNS resolver and use "resolvectl status" to confirm it. I looked at them and puked, glad my resolv.conf method is still working.

  3. #3
    Join Date
    May 2009
    Location
    Chittagong
    Beans
    70
    Distro
    Ubuntu

    Re: [VPS Server] Error Updating Packages in Ubuntu 24.04 LTS

    Quote Originally Posted by currentshaft View Post
    Otherwise, I think you want to edit /etc/netplan files to set your DNS resolver and use "resolvectl status" to confirm it. I looked at them and puked, glad my resolv.conf method is still working.
    I can't find any files inside /etc/netplan folder, it's empty

  4. #4
    currentshaft Guest

    Re: [VPS Server] Error Updating Packages in Ubuntu 24.04 LTS

    Hmm, perhaps try /etc/network/interfaces? Surely there's a valid networking configuration if you're able to access the host remotely

  5. #5
    Join Date
    Oct 2008
    Location
    Brisbane, Australia
    Beans
    138

    Re: [VPS Server] Error Updating Packages in Ubuntu 24.04 LTS

    idk if this will help you but I have exactly the same resolv.conf linked in my 24.04 Ubuntu and things like 'ping www.google.com' work fine. I think the resolv.config might be a red herring.

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •