S
S
SuperTester7772020-01-30 11:27:44
linux
SuperTester777, 2020-01-30 11:27:44

When I try to start a selenoid container with new parameters, I get an error that the container already exists with the same name, how is it fixed?

There is a list of docker containers.
5e3294f4122fd473956669.png

The selenoid container works with parameters:

"-service-startup-timeout",
            "10m",
            "-session-attempt-timeout",
            "10m",
            "-session-delete-timeout",
            "5m"

I need to set -session-delete-timeout 10m.
I execute the command sudo ./cm_linux_amd64 selenoid start --args "session-delete-timeout 10m" (I first stop the selenoid container) I get an
error:
Failed to start: failed to create container: Error response from daemon: Conflict. The container name "/selenoid" is already in use by container 15fc4feaaf050575eb36e73c7c3a1b156bf7adbe56c559287f97f2498b307b1a. You have to remove (or rename) that container to be able to reuse that name.

1) Do I understand correctly that I need to delete the container named selenoid_selenoid_1 (judging by the screenshot)?
2) It is not entirely clear why a new container is trying to be created at the start (judging by the error), we are starting an already existing container, which is simply in the foot. Those. I either do not quite understand what the command is doing, or an incorrect error
3) I'm afraid that some important settings may be lost. Or with a new start of the container in the image, everything should be restored?
4) If some other sequence of actions should be, then what?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
I
ISE73, 2020-01-30
@ISE73

1) it is not clear what is in cm_linux_am86
2) docker restart ?

S
sergey, 2020-01-30
kuzmin @sergueik

@SuperTester777
too lazy to go into the documentation?
docker container prune -fand
docker container rm <имя>
or even

CONTAINER='имя'
docker stop $CONTAINER
ID=$(docker container ls -a| grep $CONTAINER | awk '{print $1}')
docker rm $ID

by the way, it’s right there and it says
You have to remove (or rename) that container to be able to reuse that name.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question