skip to Main Content

I’ve been trying to downgrade docker from 19.03.2 to 18.09.9 on CentOS 7. I installed it via yum.

This is what I’ve tried so far.

Only a single version available returned.

$ yum list docker-ce.x86_64 --showduplicates | sort -r 
 * updates: centos4.zswap.net
 Loading mirror speeds from cached hostfile
 Loaded plugins: fastestmirror
 Installed Packages
 * extras: mirrors.usinternet.com
 * epel: d2lzkl7pfhq30w.cloudfront.net
 docker-ce.x86_64   3:19.03.2-3.el7 .  @docker-ce-stable
 * base: centos4.zswap.net

No luck on this, duh!

$ yum downgrade docker-ce.x86_64 3:18.09.9-3.el7

Tried to downgrade it with downloaded rpm packages. No luck either.

$ yum downgrade file docker-ce-cli-18.09.9-3.el7.x86_64.rpm 
$ yum downgrade file docker-ce-18.09.9-3.el7.x86_64.rpm 

Finally, the docker engine command ran successfully, but now there are two different versions, APIs are the same though.

$ docker engine update --version 18.09.9 

Two different docker versions.

$ docker version
Client: Docker Engine - Community
 Version:           19.03.2
 API version:       1.39 (downgraded from 1.40)
 Go version:        go1.12.8
 Git commit:        6a30dfc
 Built:             Thu Aug 29 05:28:55 2019
 OS/Arch:           linux/amd64
 Experimental:      false

Server: Docker Engine - Community
 Engine:
 Version:          18.09.9
 API version:      1.39 (minimum version 1.12)
 Go version:       go1.11.13
 Git commit:       039a7df
 Built:            Wed Sep  4 16:22:32 2019
 OS/Arch:          linux/amd64
 Experimental:     false

How do I downgrade the client now?

2

Answers


  1. Let’s say if I want to downgrade my own Client: Docker Engine - Community from 19.03.2 to 18.09.9.

    And below is the list of available versions.

    yum list docker-ce-cli --showduplicates | sort -r
    
    docker-ce-cli.x86_64              1:19.03.7-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.6-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.5-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.4-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.3-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.2-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.1-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:19.03.0-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.9-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.8-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.7-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.6-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.5-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.4-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.3-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.2-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.1-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.0-3.el7              docker-ce-stable 
    docker-ce-cli.x86_64              1:18.09.0-3.el7              @docker-ce-stable
    

    I can achieve this by executing the following command.

    for i in {1..3}; do yum downgrade docker-ce-cli -y; done

    Login or Signup to reply.
  2. To downgrade your docker-ce version you need to tap this cmd :

    sudo apt-get install -y --allow-downgrades docker-ce=17.03.2~ce-0~ubuntu-xenial
    
    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search