2014-03-24 11:17:15 +01:00
|
|
|
# nohup
|
|
|
|
|
2016-01-07 18:31:27 +01:00
|
|
|
> Allows for a process to live when the terminal gets killed.
|
2025-01-18 18:45:33 +05:30
|
|
|
> More information: <https://www.gnu.org/software/coreutils/manual/html_node/nohup-invocation.html>.
|
2014-03-24 11:17:15 +01:00
|
|
|
|
2021-08-15 19:59:09 +02:00
|
|
|
- Run a process that can live beyond the terminal:
|
2014-03-24 11:17:15 +01:00
|
|
|
|
2022-11-17 03:41:30 +03:00
|
|
|
`nohup {{command}} {{argument1 argument2 ...}}`
|
2021-10-19 13:06:42 +02:00
|
|
|
|
2022-10-26 07:51:09 +03:00
|
|
|
- Launch `nohup` in background mode:
|
2021-10-19 13:06:42 +02:00
|
|
|
|
2022-11-17 03:41:30 +03:00
|
|
|
`nohup {{command}} {{argument1 argument2 ...}} &`
|
2021-10-19 13:06:42 +02:00
|
|
|
|
|
|
|
- Run a shell script that can live beyond the terminal:
|
|
|
|
|
|
|
|
`nohup {{path/to/script.sh}} &`
|
|
|
|
|
|
|
|
- Run a process and write the output to a specific file:
|
|
|
|
|
2022-11-17 03:41:30 +03:00
|
|
|
`nohup {{command}} {{argument1 argument2 ...}} > {{path/to/output_file}} &`
|