Pregunta

Hi I am trying to run a script/runner process which failed because of SignalException: SIGHUP:

The process nearly takes 4-5hrs. Can someone please let me know what exactly is happening and what would be a work around.

Thanks

¿Fue útil?

Solución

The shell the process was started from is dying. You can either disown the process from the calling shell or call it with nohup, which will cause the process to ignore SIGHUPs.

Something like nohup script/runner "YourCodeHere.run" & would make the script/runner task impervious to SIGHUPs.

Edit: Say you ssh into a server. You'll spawn a new shell (running /bin/bash would work similarly). If you drop connection, the shell you started with ssh also dies. When it does, it sends SIGHUP to all of the attached processes. SIGHUP is a UNIX signal. There are a few of them. Another you're probably (perhaps unknowingly) familiar with is SIGINT, which is what is sent to the process when you hit ctrl-c.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top