[BACK]Return to nohup.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / nohup

Annotation of src/usr.bin/nohup/nohup.1, Revision 1.12

1.12    ! jmc         1: .\"    $OpenBSD: nohup.1,v 1.11 2007/05/30 04:41:34 jmc Exp $
1.1       deraadt     2: .\"    $NetBSD: nohup.1,v 1.5 1995/08/31 23:35:24 jtc Exp $
                      3: .\"
                      4: .\" Copyright (c) 1989, 1990, 1993
                      5: .\"    The Regents of the University of California.  All rights reserved.
                      6: .\"
                      7: .\" This code is derived from software contributed to Berkeley by
                      8: .\" the Institute of Electrical and Electronics Engineers, Inc.
                      9: .\"
                     10: .\" Redistribution and use in source and binary forms, with or without
                     11: .\" modification, are permitted provided that the following conditions
                     12: .\" are met:
                     13: .\" 1. Redistributions of source code must retain the above copyright
                     14: .\"    notice, this list of conditions and the following disclaimer.
                     15: .\" 2. Redistributions in binary form must reproduce the above copyright
                     16: .\"    notice, this list of conditions and the following disclaimer in the
                     17: .\"    documentation and/or other materials provided with the distribution.
1.8       millert    18: .\" 3. Neither the name of the University nor the names of its contributors
1.1       deraadt    19: .\"    may be used to endorse or promote products derived from this software
                     20: .\"    without specific prior written permission.
                     21: .\"
                     22: .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
                     23: .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
                     24: .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
                     25: .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
                     26: .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
                     27: .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
                     28: .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
                     29: .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
                     30: .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
                     31: .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
                     32: .\" SUCH DAMAGE.
                     33: .\"
                     34: .\"    @(#)nohup.1     8.1 (Berkeley) 6/6/93
                     35: .\"
1.12    ! jmc        36: .Dd $Mdocdate$
1.1       deraadt    37: .Dt NOHUP 1
                     38: .Os
                     39: .Sh NAME
                     40: .Nm nohup
                     41: .Nd invoke a command immune to hangups
                     42: .Sh SYNOPSIS
                     43: .Nm nohup
                     44: .Ar utility
                     45: .Op Ar arg ...
                     46: .Sh DESCRIPTION
                     47: The
1.10      jmc        48: .Nm
                     49: command allows the specified utility to be protected from termination
                     50: if the user should become logged out
                     51: (for example, due to a modem line or TCP/IP connection being dropped).
                     52: To do this,
                     53: .Nm
                     54: sets the
                     55: .Dv SIGHUP
                     56: .Xr signal 3
                     57: .Pq Dq terminal line hangup
                     58: to be ignored,
                     59: then executes
1.9       jmc        60: .Ar utility
1.10      jmc        61: along with any arguments.
                     62: .Pp
1.1       deraadt    63: If the standard output is a terminal, the standard output is
                     64: appended to the file
                     65: .Pa nohup.out
                     66: in the current directory.
                     67: If standard error is a terminal, it is directed to the same place
                     68: as the standard output.
1.6       aaron      69: .Pp
1.10      jmc        70: If the output file
                     71: .Pa nohup.out
                     72: cannot be created in the current directory,
                     73: .Nm
                     74: attempts to create the file in the user's home directory.
                     75: If the file
                     76: .Pa nohup.out
                     77: cannot be created,
                     78: either in the current directory or the user's home directory,
                     79: .Nm
                     80: will exit without invoking
                     81: .Ar utility ,
                     82: with an exit value as described below.
                     83: .Pp
1.1       deraadt    84: The
                     85: .Nm nohup
1.9       jmc        86: command shall exit with one of the following values:
1.6       aaron      87: .Pp
                     88: .Bl -tag -width Ds -offset indent -compact
1.1       deraadt    89: .It 126
                     90: The
                     91: .Ar utility
                     92: was found but could not be invoked.
                     93: .It 127
                     94: The
                     95: .Ar utility
1.5       aaron      96: could not be found or an error occurred in
1.10      jmc        97: .Nm .
1.1       deraadt    98: .El
                     99: .Pp
1.5       aaron     100: Otherwise, the exit status of
1.10      jmc       101: .Nm
1.5       aaron     102: shall be that of
1.1       deraadt   103: .Ar utility .
1.6       aaron     104: .Sh ENVIRONMENT
1.10      jmc       105: .Bl -tag -width Ds
1.6       aaron     106: .It Ev HOME
1.10      jmc       107: User's home directory.
1.6       aaron     108: .El
1.1       deraadt   109: .Sh SEE ALSO
                    110: .Xr signal 3
                    111: .Sh STANDARDS
                    112: The
1.10      jmc       113: .Nm
1.11      jmc       114: utility is compliant with the
                    115: .St -p1003.1-2004
                    116: specification.