xtreme-d / docker-slurm-cluster

Simple Slurm cluster in docker.
MIT License
9 stars 6 forks source link

[SOLVED] QUESTION: How works prefix-log.sh? #10

Closed m0rfeo closed 2 years ago

m0rfeo commented 2 years ago

Hi all,

I just want to know and undestand what does this wrapper (prefix-log.sh)

hackprime commented 2 years ago

@m0rfeo I use this wrapper script to prepend each log entry with the current supervisor program name. With that, it's easy to track which program generated a log entry in the output of docker logs.

I added this script because a supervisor couldn't do that some time ago. But it looks like now the supervisor can show the program name by default and there is no need to use prefix-log.sh script anymore.

Currently, you can see the following output.

slurmdbd   | slurmdbd: MySQL server version is: 10.4.22-MariaDB-1:10.4.22+maria~focal
slurmdbd   | slurmdbd: Accounting storage MYSQL plugin loaded
slurmdbd   | slurmdbd: slurmdbd version 20.02.7 started
slurmd     | slurmd: error: Node configuration differs from hardware: CPUs=2:4(hw) Boards=1:1(hw) SocketsPerBoard=2:4(hw) CoresPerSocket=1:1(hw) ThreadsPerCore=1:1(hw)

The program name became duplicated.

I will update the code soon. Thanks for your comments!

hackprime commented 2 years ago

I have removed prefix-log.sh wrapper from supervisor configs. Check changes in the master branch for details.

m0rfeo commented 2 years ago

@hackprime Okay I didn't undestand the utility of prefix-log.sh for that reason. Thanks to you mate, for your atention and your work!

Give me some hours, I'm working now and have many tasks to do. But I will check and test your updates very soon, again thanks! :)