I have started jboss and send it to background process from a particular ssh session. But as the session got timeout I did ssh (diff session) but now neither I could list the bg jobs nor jobs command returns anything.


fg/bg/jobs are only for jobs started by the current shell. Since you got a new shell when connecting again, it cannot see the jobs of the previous one.

It is also possible that your bash session got killed by the disconnect, which in turn killed its background jobs. If you want your background jobs to survive this kind of accident, start them with nohup.

| improve this answer | |
  • Thanks @xenoid But the process is alive as I could hit the endpoint of the app running on top of jboss. Is there any way to bring jobs that went background to foreground from another session – Dhar Dibya Sep 3 '19 at 13:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.