Starting Kibana - "No such container: monitoring-x.x.x.x" - bluedata

I'm working through the BlueData docs to enable Kibana.
To start Kibana:
Login to the Controller.
Execute the command docker exec -it monitoring-<controller_ip> bash, where <controller_ip> is the IP address of the Controller.
...
I've ssh'd into my BlueData controller and run the docker exec ... command, however, I get the following error:
Error response from daemon: No such container: monitoring-10.1.0.26
Any idea what is wrong here?
NOTE: My BlueData version is bluedata-epic-entdoc-minimal-release-3.7-2207

First, check what containers are running:
$ docker ps
CONTAINER ID IMAGE ... NAMES
60287e139b54 epic/webhdfs:1.0 ... epic-webhdfs-10.1.0.26
90f73bb7a37e epic/monitoring:1.4 ... epic-monitoring-10.1.0.26
a55758993978 epic/nagios:1.5 ... epic-nagios-10.1.0.26
309d9084df5a epic/apache-hdfs-centos:2.7.2 ... epic-apache-hdfs-centos
You can now see the correct command:
$ docker exec -it epic-monitoring-10.1.0.26 bash
The documentation appears to be missing the epic- suffix, i.e.
Instead of ...
$ docker exec -it monitoring-<controller_ip> bash
It looks like it should be ...
$ docker exec -it epic-monitoring-<controller_ip> bash

Related

Error: No such container: tgd-api_redis_1

im trying to enter my redis container with this command :
docker container exec -it tgd-api_redis_1 /bin/sh
and this
docker exec -it tgd-api_redis_1 /bin/sh
but the result is error just like the title. i run docker ps to show what container I have, and the container i go to is there.
thanks in advance
Your container names are wrong.
Check stroke and underscore in your names!
Try the container id.
docker exec -it 6a0285dcd25b /bin/sh

docker exec error "/data # ^[[2;9R" when try get shell or ash

when I'm executing a command in docker to get container bash, I'm faced with such a message and I can not enter any commands
docker exec -u 0 -t my_local_redis ash
and error is:
/data # ^[[2;9R
but when I run the below command it seems ok
docker exec -u 0 -t my_local_redis ls
Try using interactive terminal mode
docker exec -u 0 -it my_local_redis ash

How to check mysql version inside mysql docker container

Is it possible to check it without getting inside the container?
something like
docker container exec -it <container name> ....
You can check the version using Docker inspect.
docker inspect mysql8 | grep MYSQL_MAJOR
#Or to print version plus major both
docker inspect mysql8 | grep MYSQL_
or without running the container
docker run -it mysql8 bash -c "printenv | grep MYSQL_VERSION"
Or if the container is already running
docker exec mysql bash -c "mysql -V"
You can use exec to run commands against a container:
docker exec -it <container_name> bash -c "mysql -V"
get Container ID:
docker ps
Ex image: enter image description here
Remote to docker & using bash in it:
docker exec -it <container_name> bash
Input command:
mysql -V

Docker exec command without the container ID

How can do something like:
docker exec -it 06a0076fb4c0 install-smt
But use the name of the container instead
docker exec -it container/container install-smt
I am running a build on CI server so I can not manually input the container ID.
How can I achieve this?
Yes, you can do this by naming the container with --name. Note that your command with container/container is likely referencing an image name and not the container.
➜ ~ docker run --name my_nginx -p 80:80 -d nginx
d122acc37d5bc2a5e03bdb836ca7b9c69670de79063db995bfd6f66b9addfcac
➜ ~ docker exec my_nginx hostname
d122acc37d5b
Although it won't save any typing, you can do something like this if you want to use the image name instead of giving the container a name:
docker run debian
docker exec -it `docker ps -q --filter ancestor=debian` bash
This will only work if you're only running one instance of the debian image.
It does help if you're constantly amending the image when working on a new Dockerfile, and wanting to repeatedly run the same command in each new container to check your changes worked as expected.
I was able to fix this by setting a container name in the docker-compose file, and rundocker exec -it with the name form the file.
#Héctor (tnx)
These steps worked for me:
This will start the container named mytapir and spawn a shell into the docker container:
docker run -d --name mytapir -it wsmoses/tapir-built:latest bash
Upon docker ps to ensure the docker container is running:
docker exec -it mytapir /bin/bash
Will spawned a shell into an existing container named mytapir.
And you can stop the container as usual docker stop mytapir.
And starting it via docker start mytapir, if it is not running.
(check via docker ps -a)

Pull, virtualize, and bash into a docker image

I have a docker image I'd like to poke inside. How can I pull it and get access to a shell on it? I tried sudo docker exec -it verdverm/pypge-experiments bash, but it just gave me Error response from daemon: No such container: verdverm/pypge-experiments. What am I doing wrong?
Replace exec with run:
sudo docker run -it verdverm/pypge-experiments bash

Resources