docker删除镜像

  1. 切换至根目录
  2. 查看正在运行的镜像
  3. 停止镜像进程
  4. 卸载镜像
  5. 查看镜像images
  6. 删除images
[ljq@192 ~]$ su - root
密码:
上一次登录:六 3月 13 15:12:31 CST 2021:1 上
[root@192 ~]# docker ps -a
CONTAINER ID        IMAGE                                                  COMMAND                  CREATED             STATUS                       PORTS               NAMES
3bdb2512e4a1        registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g   "/bin/sh -c '/home..."   10 days ago         Exited (137) 4 minutes ago                       oracle11g
[root@192 ~]# docker stop ^C
[root@192 ~]# docker stop 3bdb2512e4a1 
3bdb2512e4a1
[root@192 ~]# docker rm 3bdb2512e4a1
3bdb2512e4a1
[root@192 ~]# docker images
REPOSITORY                                             TAG                 IMAGE ID            CREATED             SIZE
registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g   latest              3fa112fd3642        5 years ago         6.85 GB
[root@192 ~]# docker rmi 3fa112fd3642
Untagged: registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g:latest
Untagged: registry.cn-hangzhou.aliyuncs.com/helowin/oracle_11g@sha256:4c12b98372dfcbaafcd9564a37c8d91456090a5c6fb07a4ec18270c9d9ef9726
Deleted: sha256:3fa112fd3642abcf7e9f46c5429bbba7faca3d196cf54dad53ad705c8063c609
Deleted: sha256:4a8e8e3224bd2491e46d073ce408bb9beab52c8cfdf9f8bdc91fb6d05ffab161
Deleted: sha256:28b9e4535f66dd999db5e0999148ae3b93223529414cea21d834591740d1c146
Deleted: sha256:3143b1ab2e49f3b3aa318352a8521a96d5c28584ed9a1de0cf1c5ac90dff4738
Deleted: sha256:0694992f4b170975572425674bbcd17e31b5db3a6aa8886a292c000bb4d6de24
Deleted: sha256:2a06f786beceab87b832df6417009ac19a8830a62d02e95e1f038d84210acda4
Deleted: sha256:1260d529476c882ba7c147d3804095a9533ac0658c820c21c7f9e5973da3725f
Deleted: sha256:bab207619a1bbcdc3340d6927d347296128a34508dd96159a2ef9c5da8cc1b4c

你可能感兴趣的:(VMware虚拟机,docker)