What if your long tasks never stopped just because you closed the terminal?
Why nohup for persistent processes in Linux CLI? - Purpose & Use Cases
Imagine you start a long task on your computer, like downloading a big file or running a script. Then you close the terminal or log out. Suddenly, the task stops and you lose all progress.
Manually running commands without protection means your work stops when the terminal closes. You must restart tasks again and again, wasting time and risking errors.
The nohup command lets your task keep running even if you close the terminal. It ignores hangup signals, so your process stays alive and finishes without interruption.
python long_script.py
# closes terminal -> script stopsnohup python long_script.py &
# script keeps running after terminal closesYou can start important tasks and safely disconnect, knowing they will finish on their own.
Starting a backup or data processing job on a remote server, then logging out without stopping the job.
Closing terminals usually stops running tasks.
nohup keeps tasks running after logout.
This saves time and avoids restarting work.