[Solution] What to do if you get a Docker error'ERROR: Cannot connect to the Docker daemon at unix: ///var/run/docker.sock. Is the docker daemon running?'

Solve this

[vagrant@localhost ~]$ sudo docker version Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

Method

$ sudo groupadd docker
$ sudo usermod -aG docker $USER

Log in again

$ newgrp docker 
$ sudo docker version

Resolve if there is no daemon error

reference https://docs.docker.com/engine/install/linux-postinstall/ https://stackoverflow.com/questions/21871479/docker-cant-connect-to-docker-daemon

Recommended Posts

[Solution] What to do if you get a Docker error'ERROR: Cannot connect to the Docker daemon at unix: ///var/run/docker.sock. Is the docker daemon running?'
How to deal with `Cannot connect to the Docker daemon at unix: /// var/run/docker.sock. Is the docker daemon running?`
What to do if you get an "A server is already running." Error when you try to start the rails server
What to do if you get a gcc error in Docker
Ubuntu on WSL2: Cannot connect to the Docker daemon at unix
What to do if you get a java.io.IOException in GlassFish
What to do if you get a "Cannot Pull Container Error" when starting ECS ​​Fargate
What to do if you get a DISPLAY error in gym.render ()
What to do if you cannot roll back the migration (UnknownMigrationVersionError)
What to do if you get a groovy warning in Thymeleaf Layout
What to do if you get a MiniMagick vulnerability alert on GitHub
What to do if Operation not permitted is displayed when you execute a command in the terminal
[Rails / Docker] What to do if access is denied by the browser (localhost: 3000) after adding a gem
What to do if you get the error message unrecognized selector send to instance "***"
What to do if you get To install the missing version, run `gem install bundler: 2.1.4`
What to do if you get a javax.net.ssl.SSLHandshakeException: Remote host closed connection during handshake in the IBM JDK
What to do if you accidentally create a model
What to do if you get a wrong number of arguments error in binding.pry
What to do if you can't get the text of an element in Selenium
What to do if you get a NoClassDefFoundError when trying to run eclipse on Java9
What to do if you get the error Couldn't find Item without an ID
What to do if you get a port error when docker-compose up on Mac
What to do if you cannot execute with the command "Java package name / class name"
How to solve when you cannot connect to DB with a new container because the port is assigned to the existing docker container
What to do if the adb command cannot be executed
What to do if you can't use the rails command
What to do if you change the Listen Address from the settings screen with Mattermost docker
[Rails] What to do if you can't get an error message with the errors method
What to do if you get a "302" error in your controller unit test code in Rails
[Maven] What to do if you are asked to incorporate a jar that is not in the remote repository into the war
What to do if you select a JRE in Eclipse and get "The selected JRE does not support the current compliance level 11"
[Ubuntu 20.04] What to do if the external monitor is not recognized
What to do if you get a "Mysql2 :: Error: Operand should contain 1 column (s)" error in Rails
What to do if Cloud9 is full in the Rails tutorial
What to do if the Eclipse Maven dependency Jar is wrong
What to do if you get angry with OpenSSL with pyenv install
What to do if you get a JNI shared library error when trying to build in Eclipse
What to do if you get an [An HTTP request took too long to complete.] Error in Docker.
What to do about the "cannot be read or is not a valid ZIP file" error
[Output] Learn Ruby from what you want to do at the fastest speed-Part 2 "Create a flowchart"
What to do if you forget the root password in CentOS7
[Rails] What to do if you can't get parameters with form_with
What to do if you get an error saying Cannot find a valid baseurl for repo when you use yum -y install docker in a udemy course using CentOS7
What to do if you get the error Too long with no output (exceeded 10m0s) on CircleCI
What to do if you get an error during rails db: reset
What to do if the background image is not applied after deployment
What to do if the prefix c is not bound in JSP
[Composer] [Laravel] What to do if you cannot install due to insufficient memory
What to do if you get an uninitialized constant Likes Controller error
What to do if you can't install the plugin from the Eclipse marketplace
What to do if you don't like the code generated by swagger-codegen-cli
What to do if you install Ubuntu
[Rails] What to do if you get an error saying "Could not find a JavaScript runtime." When executing the rails s command on Catalina
What to do if you have enabled Use the WSL2 based engine in Docker Desktop with insufficient WSL2 installation
What to do if you get Could not save master table to file after importing a project in Eclipse
How to translate the error message into Japanese (What to do if you cannot log in for some reason)
What to do about "A server is already running ..." that happened without turning off the rails server in the terminal
What to do when you want to delete a migration file that is "NO FILE"
What to do if you get Could not locate Gemfile or .bundle / directory
What to do if you can't activate the select box created by bootstrap-select
[Swift] What to do if the app icon is set but not reflected