Giữ tập lệnh python chạy sau khi đóng ssh
Ampersand chạy tập lệnh trong lớp con, vì vậy nếu bạn đăng xuất khỏi lớp vỏ hiện tại, lớp con sẽ bị chấm dứt. Ngoài ra, điều này sẽ không chuyển tiếp bất kỳ đầu ra nào nên chúng tôi cần thực hiện thủ công Show
Ví dụ// this does not collect any output, but still print output to stdout (on console). // it just does not receive ctrl+c python test.py & // this writes output to specified file, does not write anything to console. python test.py > log.txt & // this writes error to specified file, but still print normal output to stdout. python test.py 2> log.txt &
|