7

I am facing an issue with apt : sudo apt-get update won't successfully complete on my Ubuntu 18.04 Desktop.

First I'd like to specify that the subject Xenial repository does not have a release file did not solve my problems, nor did Ubuntu repository does not have a release file or any other.

My distro is a fresh installed Ubuntu 18.04.1 Bionic.

The problem is, on a sudo apt-get update I get the following error messages :

E: The repository 'http://security.ubuntu.com/ubuntu bionic-security Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

I get these messages on EACH REPOSITORY of my sources.list, the defaults ones for Ubuntu 18.04.

Here is the content my /etc/apt/sources.list file (I git it from Ubuntu Official Documentation). I removed the commented lines to improve readability.

 # deb cdrom:[Ubuntu 18.04 LTS _Bionic Beaver_ - Release amd64 (20180426)]/ bionic main restricted
deb http://us.archive.ubuntu.com/ubuntu/ bionic main restricted
deb http://us.archive.ubuntu.com/ubuntu/ bionic-updates main restricted
deb http://us.archive.ubuntu.com/ubuntu/ bionic universe
deb http://us.archive.ubuntu.com/ubuntu/ bionic-updates universe
deb http://us.archive.ubuntu.com/ubuntu/ bionic multiverse
deb http://us.archive.ubuntu.com/ubuntu/ bionic-updates multiverse
deb http://security.ubuntu.com/ubuntu bionic-security main restricted
deb http://security.ubuntu.com/ubuntu bionic-security universe
deb http://security.ubuntu.com/ubuntu bionic-security multiverse

I have understood by reading posts about that error msg, that it often comes from a bad configuration of repositories in that file (e.g, asking for the bionic version of a package which has not already been published on bionic repos).

The thing is: these are the default repositories. And when I go check the dist folder in the url given, I can see the distros specified in configuration : bionic, bionic-updates and bionic-security.

So, to sum it up:

  • I have only the official default repositories for Ubuntu Bionic 18.04 configured
  • each and every one of them get the same error (does not have Release file)
  • any hint I've found is about one specific repository, or about a full system upgrade, which is not my case

If someone have an idea, a hint or even better, a solution to make sudo apt-get update work, I'd be really grateful !

Thanks

Zolano
  • 71
  • In your sources.list there's always a space after http://. If you have that in your actual file please remove it and try updating again. – Florian Diesch Aug 07 '18 at 15:55
  • @Florian OP had a note at the bottom saying the spaces were added on purpose. I just fixed the formatting. – wjandrea Aug 07 '18 at 16:27
  • Are you using a proxy or VPN? Are you on a home network or university/corporate network? Are you in the USA? – wjandrea Aug 07 '18 at 16:36
  • 1
    As a side note, Ubuntu repositories are not PPAs - the latter are a separate type of unofficial repository – Zanna Aug 07 '18 at 19:27
  • Hi, thanks for your answers. @Florian: as wrandja has noticed, the space was on purpose. – Zolano Aug 08 '18 at 06:57
  • 1
    @wjandrea : I am behind a corporate proxy. I added the proxy configuration to /etc/apt/apt.conf, as follows : Acquire::http::Proxy "http://myUser:myPassword@companyProxy:proxyPortNumber".

    This configuration seems OK to me, since I can "sudo apt-get install" a package (e.g, sudo apt-get install peco did install peco correctly). It sudo apt-get update command that raises the error.

    I am located in europe. I tried fr.archive.ubuntu mirror, as well as uk.archive.ubuntu mirror, with the same results.

    And I am not behind any VPN.

    – Zolano Aug 08 '18 at 06:57
  • @Zanna: my bad, and thank you for correcting my mistake. – Zolano Aug 08 '18 at 06:57
  • Thanks you all for your answers, I hope the additionnal info will help finding out what the problem is. – Zolano Aug 08 '18 at 06:57
  • If you're using a corporate proxy, the obvious answer would be that your proxy is blocking some files but not others. And if you don't have control over the proxy, there's nothing to be done. – muru Aug 08 '18 at 07:48
  • @muru : Hi, I think this is not the case, since I can access the repositories URL via my web browser, which is configured with the same corporate proxy settings as apt is.

    The files are not blocked that way (including the release file http://us.archive.ubuntu.com/ubuntu/dists/bionic/Release).

    If the proxy was blocking some files for apt, I guess it would block them for my web browser too, am I right ?

    – Zolano Aug 08 '18 at 07:55
  • @Zolano not necessarily. Try the URL with curl or wget. Depending on what the proxy software is, it might behave differently with different user agents. It might also be messing with the HTTP headers in a way that confuses apt. – muru Aug 08 '18 at 07:57
  • @muru : curl http://us.archive.ubuntu.com/ubuntu/dists/bionic/Release works well. I cannot paste the output since it's too long for a comment, but the curl works, and displays me the same content I can see via my web browser – Zolano Aug 08 '18 at 08:02
  • Then it's probably modified headers. At any rate, check with whoever administers this proxy. – muru Aug 08 '18 at 08:04
  • @muru I'll try and check with the proxy admin. However other employees do not meet this problem. The main difference here is that I am on Ubuntu 18.04 (just begun), and most of them are on Ubuntu 16.04. They can perform sudo apt-get update without troubles. Thanks for your help anyway. – Zolano Aug 08 '18 at 08:09
  • @manojSawai Hi, thanks for the insight. I have a semicolon in my apt.conf file too, I missed it when I copied/pasted the content of the file.

    @ muru I'll keep you aware of the outcome of checking with de proxy admin, if I ever can get help from.

    Thank you all for helping

    – Zolano Aug 08 '18 at 08:14
  • I created an issue in our internal proxy admin ticketing system, to get insight from my company's proxy admin about that issue. I will keep this post up-to-date if it is solved of course – Zolano Aug 09 '18 at 08:49
  • Could you please [edit] your question to include the full, verbatim output of sudo apt-get update? Longer listings (the editor will tell you what’s too long) should be uploaded to a pastie service and linked to in the question. Thanks. – David Foerster Aug 09 '18 at 12:34
  • 1
    @Zolano have you sorted this. Was the problem the ; in the /etc/apt/apt.conf file? – Carmine Sep 17 '18 at 14:31

0 Answers0