Search code examples
memgraphdb

How to open mgconsole when running Memgraph Platform?


I run Memgraph using docker run -it -p 7687:7687 -p 7444:7444 -p 3000:3000 memgraph/memgraph-platform. Yesterday I updated it to the latest docker image using docker pull memgraph/memgraph-platform.

Now when I run the command to run the docker I get log output in my terminal, but I don't see mgconsole. How can I start it?

This is the part of the output that I get:

2023-08-25 06:14:41,015 INFO Included extra file "/etc/supervisor/programs/lab.conf" during parsing
2023-08-25 06:14:41,015 INFO Included extra file "/etc/supervisor/programs/memgraph.conf" during parsing
2023-08-25 06:14:41,015 INFO Set uid to user 0 succeeded
2023-08-25 06:14:41,016 INFO supervisord started with pid 1
2023-08-25 06:14:42,019 INFO spawned: 'memgraph' with pid 7
2023-08-25 06:14:42,021 INFO spawned: 'lab' with pid 8
You are running Memgraph v2.10.1
To get started with Memgraph, visit https://memgr.ph/start

Solution

  • If you want to run mgconsole that is part of your Docker image do one of the following:

    • get the running-container-id with docker ps and then run

      docker exec -ti <running-container-id> mgconsole

    • run docker run -ti --entrypoint=mgconsole memgraph/memgraph-platform

    If you are connecting to local Memgraph with mgconsole on Windows and Mac, make sure to provide the argument --host host.docker.internal:

    docker run -ti --entrypoint=mgconsole memgraph/memgraph-platform --host host.docker.internal