nohup command &> /dev/null &
This command still creates nohup.out
file. Could you please help on how to avoid it?
nohup command &> /dev/null &
This command still creates nohup.out
file. Could you please help on how to avoid it?
&>
is not POSIX standard. You need to use this syntax:
nohup command >/dev/null 2>&1 &
Related: Difference between 2>&-, 2>/dev/null, |&, &>/dev/null and >/dev/null 2>&1
nohup > /dev/null
should be enough. The OP was probably bitten by the &>
bashism (which will silently fail to redirect anything in other shells). This answer is right for that part.
–
Jun 27 '19 at 10:17