nohup Command When using Unix/Linux, we usually want a program to run in the background, so we often use & at the end of the program to make the program run automatically. For example, we want to run mysql in the background: /usr/local/mysql/bin/mysqld_safe –user=mysql &. But many programs are not like mysqld, so we need the nohup command Process and job management The nohup command can run the program in a way that ignores the hang-up signal, and the output information of the program being run will not be displayed to the terminal. Regardless of whether you redirect the output of the nohup command to a terminal, the output is appended to the nohup.out file in the current directory. If the nohup.out file in the current directory is not writable, the output is redirected to the $HOME/nohup.out file. If no file can be created or opened for appending, the command specified by the command parameter cannot be invoked. If standard error is a terminal, then all output of the specified command written to standard error is redirected to the same file descriptor as standard output. grammar nohup(option)(parameter) Options --help: online help; --version: Display version information. parameter Program and options: The program to run and the options. Examples one. Run the spring boot jar package. When the current terminal is closed, the Spring Boot project still runs in the background. two. Use the nohup command to submit a job. If you use the nohup command to submit a job, all output of the job is redirected to a file named nohup.out by default, unless an output file is specified otherwise: In the above example, the output is redirected to the file myout.file The above is the full content of this article. I hope it will be helpful for everyone’s study. I also hope that everyone will support 123WORDPRESS.COM. You may also be interested in:
|
<<: vue-pdf realizes online file preview
1. Import the basic style of external CSS files U...
let Utils = { /** * Is it the year of death? * @r...
This article shares the specific code of vue3 enc...
Preface In the previous article, we mainly learne...
Recently, when using element table, I often encou...
Table of contents Overview Is the extension neces...
First, let me introduce the meaning of some field...
DetachKeyPair Unbind SSH key pairs from one or mo...
Table of contents Table/index.js Table/model/inde...
6 solutions for network failure in Docker contain...
Table of contents 1. Installation 2. Import into ...
When we do CSS web page layout, we all know that i...
<br />What is web2.0? Web2.0 includes those ...
Table of contents Throttling and anti-shake conce...
1. The Chinese garbled characters appear in MySQL...