Use of Linux nohup command

Source: Internet
Author: User


Nohup command usage: LINUX command usage. Run the command without hanging up. Syntax: nohup Command [Arg...] [&] Description: The nohup Command runs the Command specified by the Command parameter and any relevant Arg parameter, ignoring all SIGHUP signals. After logging out, run the nohup command to run the program in the background. To run the nohup command in the background, add the & (symbol indicating "and") to the end of the command. If www.2cto.com does not redirect the output of the nohup command, the output will be appended to the nohup. out file in the current directory. If the nohup. out file in the current directory cannot be written, the output will be redirected to the $ HOME/nohup. out file. If no file can be created or opened for append, the Command specified by the Command Parameter cannot be called. If a standard error is a terminal, write the specified command to all outputs of the standard error as the standard output and redirect it to the same file descriptor. Exit status: This Command returns the following export value: 126 can be searched but cannot call the Command specified by the Command parameter. 127 The nohup Command has an error or cannot find the Command specified by the Command parameter. Otherwise, the exit status of the nohup Command is the exit status of the Command specified by the Command parameter.
Nohup command and its output file nohup command: If you are running a process and you think the process will not end when you exit the account, you can use the nohup command. This command can continue running the corresponding process after you exit the account/Close the terminal. Nohup means no hang up ). Www.2cto.com: nohup command &
Use the nohup command to submit a job. If the nohup command is used to submit a job, all output of the job is redirected to a job named nohup by default. unless the output file: nohup command> myout is specified. file 2> & 1 & in the preceding example, the output is redirected to myout. file. Use jobs to view tasks. Disable using fg % n. Two other ftp tools, ncftpget and ncftpput, can be used to upload and download files in the background through ftp, so that I can use these commands to upload and download files in the background. Author: snilwong

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.