cea-hpc / pcocc

Run VMs on an HPC cluster
GNU General Public License v3.0
47 stars 14 forks source link

pcocc alloc --user-data + a directory (instead of a cloud-init config file) makes my terminal hang #17

Open ypsah opened 3 years ago

ypsah commented 3 years ago

Hi,

While trying to allocate a job interactively, I messed up and gave pcocc alloc's --user-data a directory instead of a cloud-init config file:

$ pcocc alloc -p partition --user-data path/to/dir template
salloc: Granted job allocation 123456789
Configuring hosts... (done)                     
$ VM execution error: unable to generate cloud-init iso: [Errno 21] Is a directory: 'path/to/dir'
srun: error: node123: task 0: Exited with exit code 255
The cluster terminated unexpectedly

Nothing to be surprised of, except for the fact that I never get a a hold of my session back...

I tracked the problem down to a line in my .bashrc that essentially does:

trap -- "rm -f '$(mktemp)'" EXIT

Note that the rm -f ... part is actually important, I tried replacing it with a no-op trap (trap -- ':' EXIT) and failed to reproduce.

ypsah commented 3 years ago

I realize that my setup may be unusual enough that it is not worth the effort of fixing this.

This issue is merely an attempt at helping anyone figure out what might be happening on their setup.