Typo causes apt-get to fail on ubuntu

February 8, 2016 4k views
Linux Basics Linux Commands

First thing I do on my new droplet as root: apt-get install git

I get errors that look like:

Err http://mirrors.digitalocean.com/ubuntu/ trusty-updates/main git-man all 1:1.9.1-1ubuntu0.1

I’m PRETTY SURE there’s a typo there: ’ trusty-updates’ is meant to be ‘trusty-updates’ (extra leading space!).

Please fix this, DO!

  • That is certainly a problem. Which OS image did you use to create this droplet?

  • Nevermind my previous. The image is identifiable from the info you provided. I have passed this along to our images team so we can get it corrected ASAP.

  • Hi, you can fix your own droplet by doing:
    sudo su
    vi /etc/apt/sources.list

    Then you find the correct line, press i for insert mode where cursor is.
    When you have deleted the space, you press ESC, then you press:

    Then when you see the colon there, you write to write and quit:

    Then afterwards I think this is enough:
    apt-get update
    apt-get upgrade

  • Sorry I should have been more clear. It was the default Ubuntu, which at the time of writing was version 14.04 x64.

  • olavamjelde thanks for the suggestion but funnily enough it was easier to just spin up another instance with a later version of ubuntu!

  • Show 1 more comments
2 Answers

I just spun up a new Ubuntu 14.04.3 droplet but was unable to duplicate this issue. Was this a new droplet created from the Ubuntu 14.04 image?

Have another answer? Share your knowledge.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!