Why do I get the information of “suspended (tty input)” when I run my script in the background
I've written a tcsh script to clear garbage data in a cluster, the code is : set hosts = $1 set clear_path = $2 foreach i ($hosts) rsh $i rm -rvf $clear_path end When I run this script in the background like this : disk_clean.sh hosts_all /u0/data/tmp > log & The job will get stuck and show the information like this: [1] + Suspended (tty input) If I run this in foreground, it can finish normally. Why does this happen? How can I run this script in the background and redirect the output into a log file? 来源: https://stackoverflow.com/questions/42361200/why-do-i-get-the-information-of-suspended