Read more
Run a command in the background and get no output?
setsid script.sh
Depending on what you are wanting, just add a & to the end of the command
script.sh &
command &
If you are running it in a terminal, and you want to then close the terminal, use nohup or disown
nohup
nohup script.sh &
disown
script &
disown
If that is not what you are after, please be more specific in your question.
sh /tmp/script.sh > /dev/null 2>&1 < /dev/null &
nohup /path/to/your/script.sh > /dev/null 2>&1 &
0 Reviews