If I do
nohup cmd1 | cmd2 &
is that the same as
nohup "cmd1 | cmd2" &
?
I would like that I nohup everything, as cmd1 will listen on port 8023.
nohup
cmd1
No, you need to add the nohup to the commands separately.
Something like this is recommended:
nohup sh -c "cmd1 | cmd2" &
Or alternatively:
nohup $SHELL <<EOF & cmd1 | cmd2 EOF
2.1m questions
2.1m answers
60 comments
57.0k users