giovtorres / slurm-docker-cluster

A Slurm cluster using docker-compose
MIT License
319 stars 188 forks source link

interactive jobs output not showing in docker logs #12

Closed Masber closed 2 months ago

Masber commented 4 years ago

Hi,

lets say I have slurm cluster like:

$ docker ps
CONTAINER ID        IMAGE                          COMMAND                  CREATED             STATUS              PORTS                 NAMES
d1c8d0834138        slurm-docker-cluster:19.05.1   "/usr/local/bin/dock…"   2 minutes ago       Up 2 minutes        6818/tcp              c2
233e2046c817        slurm-docker-cluster:19.05.1   "/usr/local/bin/dock…"   2 minutes ago       Up 2 minutes        6818/tcp              c1
34defa70798e        slurm-docker-cluster:19.05.1   "/usr/local/bin/dock…"   2 minutes ago       Up 2 minutes        6817/tcp              slurmctld
74c00f465f24        slurm-docker-cluster:19.05.1   "/usr/local/bin/dock…"   2 minutes ago       Up 2 minutes        6819/tcp              slurmdbd
a6fb4a0a4d6c        mysql:5.7                      "docker-entrypoint.s…"   2 minutes ago       Up 2 minutes        3306/tcp, 33060/tcp   mysql

And I want to run an interactive job like the example below:

$ docker exec -it slurmctld srun echo "helloworld"
helloworld

docker logs won't show anything in regards the previous job:

$ docker logs slurmctld | grep -r "helloworld"

Is there a way to show stdout from interactive jobs in the container logs?

thank you

giovtorres commented 2 months ago

I wasn't able to get it to work. Please let me know if you do, and how. Thanks. Closing for now.