docker常用命令
查看docker镜像:
#docker images
镜像新建(重命名):
docker tag old
REPOSITORY:oldTAG(或
IMAGE ID) new
REPOSITORY:newTAG
删除镜像:
docker rmi
old
REPOSITORY(:oldTAG)
查看运行的docker容器:
#docker ps (-a)
进入docker容器:
#docker inspect --format "{{ .State.Pid }}" b3c9f1b43b8e<CONTAINER ID>
4609
#nsenter --target 4609<Pid> --mount --uts --net --pid
错误处理:
Failed global initialization: BadValue Invalid or no user locale set. Please ensure LANG and/or LC_* environment variables are set correctly.
#export LC_ALL=C