输入docker ps 报错信息处理Get http:///var/run/docker.sock/v1.19/containers/json: dial unix /var/run/docker.sock: permission denied.

完整错误信息

Get http:///var/run/docker.sock/v1.19/containers/json: dial unix /var/run/docker.sock: permission denied. Are you trying to connect to a TLS-enabled daemon without TLS?

原因:

  1.未使用root用户进行操作

  2.未让docker以daemon方式运行/bin/bash

解决方案:

  1.没有使用root

    在控制台上切换为root用户后进行操作

su

  2.让docker以daemon方式运行/bin/bash

docker -d

  运行启动后就可以使用了,启动成功后如下图

  

时间: 2024-10-19 02:59:05

输入docker ps 报错信息处理Get http:///var/run/docker.sock/v1.19/containers/json: dial unix /var/run/docker.sock: permission denied.的相关文章

Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.38/images/json: dial unix /var/run/docker.sock: conne

使用docker报如下错误信息: Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.38/images/json: dial unix /var/run/docker.sock: connect: permission denied 过程:早先是以root

FATA[0000] Get http:///var/run/docker.sock/v1.18/images/json: dial unix /var/run/docker.sock: no such file or directory. Are you trying to connect to a TLS-enabled daemon without TLS?

>> docker imagesFATA[0000] Get http:///var/run/docker.sock/v1.18/images/json: dial unix /var/run/docker.sock: no such file or directory. Are you trying to connect to a TLS-enabled daemon without TLS? solution: Execute 'service docker restart'. If vm

docker运行报错docker0: iptables: No chain/target/match by that name.

转自:https://blog.csdn.net/wohaqiyi/article/details/84450562 docker运行报错docker0: iptables: No chain/target/match by that name.  最近在一个新的服务器上装服务,没有安装iptables ,后来安装了iptables 之后,忽然发现我的docker 不能运行了.  注意,可能别人的不行,我这个原因是,开始在新服务器上没有安装iptables ,先安装的docker ,后来才停用默

service docker start 报错 :Failed to start docker.se

service docker start 报错 :Failed to start docker.service: Unit not found. 解决办法: vi /usr/lib/systemd/system/docker.socket 添加内容如下: [Unit] Description=Docker Socket for the API PartOf=docker.service [Socket] ListenStream=/var/run/docker.sock SocketMode=0

输入pip命令报错:from pip import main ImportError: cannot import name 'main'

报错信息: [email protected]:~$ pip Traceback (most recent call last): File "/usr/bin/pip", line 9, in <module> from pip import main ImportError: cannot import name 'main' 很多博文的解决方案是,可能他们执行这命令有效果,我这ubuntu是不管怎么升级都只能是pip的8版本,也没找到如何pip的10版本设为默认版本,

连接数据库报错:ERROR 2002 (HY000): Can&#39;t connect to local MySQL server through socket &#39;/var/lib/mysql/mysql.sock&#39; (2)

报错: ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) 1.楼主是新安装的mysql,注意新安装完成不会默认启动服务 2.百度上各种处理办法均不对,查看数据库状态发现未启动!!! 3.重启把服务拉起即可成功连接:systemctl start mariadb.service 4.安装新服务后一定要先检查服务的状态信息,再去判断报错!!! 连

创建Docker容器时报dial unix /var/run/docker.sock: no such file or directory

在创建容器时报下列错误 [[email protected] sample]# docker build -t ovcer/nginx .Sending build context to Docker daemon 2015/01/07 06:43:51 Post http:///var/run/docker.sock/v1.15/build?rm=1&t=ovcer%2Fnginx: dial unix /var/run/docker.sock: no such file or directo

docker run和docker exec报错context deadline exceeded

现象描述docker run -d centos:v1 /bin/bash创建容器或者docker exec -it container_name bash进入容器,都会报错"usrbindocker-current Error response from daemon:shim error.context deadline exceeded.",docker ps.docker stats.docker info等命令均可用基础环境物理机操作系统:CentOS Linux relea

Jenkins中执行docker命令报错

Cannot connect to the Docker daemon. Is the docker daemon running on this host? @(Jenkins) ? 在配置Jenkins从Gitlab自动构建Dockerfile上传至Harbor时遇到了上述问题,jenkins中执行docker命令会有上述报错,查阅相关资料后发现解决办法如下: 一.修改Docker服务配置 systemctl stop docker sudo gpasswd -a jenkins docke