I can't install Docker because containerd.io has no installation candidate

后端 未结 4 1140
星月不相逢
星月不相逢 2021-02-11 15:15

I tried to install Docker on Kubuntu 19.10.

I used these steps to install: https://docs.docker.com/install/linux/docker-ce/ubuntu/

During step 2, after added r

相关标签:
4条回答
  • 2021-02-11 15:25

    If the from @vavalm did not work either, check that you have installed ubuntu amd64. There is a chance that you have installed the Ubuntu version i384 instead

    0 讨论(0)
  • 2021-02-11 15:37

    Edit the file : /etc/apt/sources.list

    Look for repo entry :

    deb-src [arch=amd64] https://download.docker.com/linux/ubuntu eoan stable
    

    Changing it to:

    deb-src [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable 
    

    resolved the issue for me

    0 讨论(0)
  • 2021-02-11 15:39

    It's not the cleanest way to do it I guess, but I had the same problem as you and I changed:

    $ sudo add-apt-repository \
       "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
       $(lsb_release -cs) \
       stable"
    

    to

    $ sudo add-apt-repository \
       "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
       bionic \
       stable"
    

    because

    $(lsb_release -cs)
    

    returns "eoan" (the name of the latest ubuntu version, currently 19.10) and it seems to cause problems. Replacing this with "bionic" (ubuntu 18.10) worked perfectly for me, and I still have no problems 4 months later.

    Don't forget to open "/etc/apt/sources.list" and comment-out/delete the line:

    deb-src [arch=amd64] https://download.docker.com/linux/ubuntu eoan stable
    

    to avoid conflicts. (You added this with the first command you entered in this process.)

    0 讨论(0)
  • 2021-02-11 15:45

    The official docker documentation recommend to use

      $ sudo add-apt-repository \
           "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
           $(lsb_release -cs) \
           stable"
    

    for Ubuntu 19.10 which seems that doesn't contain 'containerd.io' package yet.

    Remove the previously added repository using add-apt-repository --remove :

    $ sudo add-apt-repository --remove \
           "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
           $(lsb_release -cs) \
           stable"
    

    and add the one used for bionic (18.10) Ubuntu release:

    $ sudo add-apt-repository \
       "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
       bionic \
       stable"
    

    After this, update and install docker:

    $ sudo apt-get update
    $ sudo apt-get install docker-ce docker-ce-cli containerd.io
    
    0 讨论(0)
提交回复
热议问题