merge 2>&1

Merge stderr into stdout so both go to the same place

2>&1 means redirect stderr to wherever stdout currently goes. nohup long-command > /tmp/out.log 2>&1 & captures both stdout and stderr.

Example

$ nohup python3 app.py > /tmp/app.log 2>&1 &
[1] 5892
Tip: Type it yourself in the terminal below - reading is not the same as doing.