Whats the purpose of the nohup command?
DBAsupport.com Forums - Powered by vBulletin
Results 1 to 3 of 3

Thread: Whats the purpose of the nohup command?

Hybrid View

  1. #1
    Join Date
    Dec 2000
    Posts
    95

    Whats the purpose of the nohup command?

    Hi,

    In one of the shell script, nohup command used to connect to the SQLPLUS from the Operating System as follows

    nohup sqlplus -s /nolog @staging1.sql ${WORK_SCHEMA} ${WORK_PWD} ${WORK_SID} ${DATE_MARK}

    Whats the purpose of the "nohup" command ?

    Operating Sysytem : Solaris
    Databse : Oracle 9i

    Thank you in advance

    Srinivas Medukonduru

  2. #2
    Join Date
    Sep 2001
    Location
    Düsseldorf, Germany.
    Posts
    588

  3. #3
    Join Date
    Nov 2000
    Location
    Israel
    Posts
    268
    The nohup utility invokes a command with the arguments supplied. When the command is invoked, nohup arranges for the SIGHUP signal to be ignored by the process.
    Hi,
    The nohup utility can be used when it is known that command will take a long time to run and the user wants to logout of the terminal.
    When a shell exits, the system sends its children SIGHUP signals, which by default cause them to be killed.
    All stopped, running, and background jobs will ignore SIGHUP and continue running, if their invocation is preceded by the nohup command or if the process programmatically has chosen to ignore SIGHUP.

    /usr/bin/nohup
    Processes run by /usr/bin/nohup are immune to SIGHUP (hangup) and SIGQUIT (quit) signals.

    /usr/xpg4/bin/nohup
    Processes run by /usr/xpg4/bin/nohup are immune to SIGHUP.
    The nohup utility does not arrange to make processes immune to a SIGTERM (terminate) signal, so unless they arrange to be immune to SIGTERM or the shell makes them immune to SIGTERM, they will receive it.

    Cheers.
    It is better to ask and appear ignorant, than to remain silent and remain ignorant.

    Oracle OCP DBA 9i,
    C++, Java developer

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width