0

For my work setup, I'm currently ssh'ing into a remote machine. I want to call a certain python program several times with different arguments, so I wrote a simple bash script that looks like this:

get_results.sh:

#!/bin/bash
python generate.py -d 10
python generate.py -d 20
...

My question is, if I run this bash script as nohup ./get_results.sh, then I disconnect from the ssh connection, will all the python programs execute normally?

1
  • ```` nohup ./get_results.sh & add ampersand at end
    – tgkprog
    Jul 31, 2022 at 18:58

1 Answer 1

1

I've since tried this, and it does execute all of the python programs as expected.

The "nohup" command does not need to be included inside the bash script (in front of "python ...".

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .