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
Next, I will install Java+Tomcat on Centos7. Ther...
Download the MySQL installation package. I downlo...
Table of contents 1. Problems encountered 2. Idea...
Preface In terms of layout, Gobang is much simple...
The configuration is very simple, but I have to c...
(I) Basic concepts of web page color matching (1) ...
Includes the process of initializing the root use...
This article mainly introduces how to call desktop...
This article shares with you a small Demo that ad...
This article uses examples to illustrate the MySQ...
1. Install openssh-server yum install -y openssl ...
Introduction to MySQL logical architecture Overvi...
In-depth understanding of this in Js JavaScript s...
SQL fuzzy query statement The general fuzzy state...
The following is a picture mouse hover zoom effec...