Index: head/bin/kenv/kenv.1 =================================================================== --- head/bin/kenv/kenv.1 (revision 79534) +++ head/bin/kenv/kenv.1 (revision 79535) @@ -1,50 +1,50 @@ .\" Copyright (c) 2000 Peter Wemm .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt KENV 1 -.Os BSD 4 +.Os .Sh NAME .Nm kenv .Nd dump the kernel environment .Sh SYNOPSIS .Nm .Op Fl h .Op variable .Sh DESCRIPTION .Nm will dump the kernel environment. If the .Fl h flag is specified, it will limit the report to kernel probe hints. If an optional variable name is specified, .Nm will only report that value. .Sh SEE ALSO .Xr loader 8 .Sh HISTORY .Nm appeared in .Fx 4.1.1 . Index: head/lib/libpam/modules/pam_login_access/login.access.5 =================================================================== --- head/lib/libpam/modules/pam_login_access/login.access.5 (revision 79534) +++ head/lib/libpam/modules/pam_login_access/login.access.5 (revision 79535) @@ -1,56 +1,56 @@ .\" .\" $FreeBSD$ .\" .\" this is comment .Dd April 30, 1994 .Dt LOGIN.ACCESS 5 -.Os FreeBSD +.Os .Sh NAME .Nm login.access .Nd login access control table .Sh DESCRIPTION The .Nm file specifies (user, host) combinations and/or (user, tty) combinations for which a login will be either accepted or refused. .Pp When someone logs in, the .Nm is scanned for the first entry that matches the (user, host) combination, or, in case of non-networked logins, the first entry that matches the (user, tty) combination. The permissions field of that table entry determines whether the login will be accepted or refused. .Pp Each line of the login access control table has three fields separated by a ":" character: permission : users : origins .Pp The first field should be a "+" (access granted) or "-" (access denied) character. The second field should be a list of one or more login names, group names, or ALL (always matches). The third field should be a list of one or more tty names (for non-networked logins), host names, domain names (begin with "."), host addresses, internet network numbers (end with "."), ALL (always matches) or LOCAL (matches any string that does not contain a "." character). If you run NIS you can use @netgroupname in host or user patterns. .Pp The EXCEPT operator makes it possible to write very compact rules. .Pp The group file is searched only when a name does not match that of the logged-in user. Only groups are matched in which users are explicitly listed: the program does not look at a user's primary group id value. .Sh FILES .Bl -tag -width /etc/login.access -compact .It Pa /etc/login.access The .Nm file resides in .Pa /etc . .El .Sh SEE ALSO .Xr login 1 , .Xr pam 8 .Sh AUTHORS .An Guido van Rooij Index: head/usr.bin/apply/apply.1 =================================================================== --- head/usr.bin/apply/apply.1 (revision 79534) +++ head/usr.bin/apply/apply.1 (revision 79535) @@ -1,139 +1,139 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)apply.1 8.2 (Berkeley) 4/4/94 .\" $FreeBSD$ .\" .Dd April 4, 1994 .Dt APPLY 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm apply .Nd apply a command to a set of arguments .Sh SYNOPSIS .Nm .Op Fl a Ar c .Op Fl d .Op Fl # .Ar command argument ... .Sh DESCRIPTION .Nm runs the named .Ar command on each argument .Ar argument in turn. .Pp Character sequences of the form .Dq Li \&%d in .Ar command , where .Sq Li d is a digit from 1 to 9, are replaced by the .Li d Ns \'th following unused .Ar argument . In this case, the largest digit number of arguments are discarded for each execution of .Ar command . .Pp The options are as follows: .Bl -tag -width indent .It Fl # Normally arguments are taken singly; the optional number .Fl # specifies the number of arguments to be passed to .Ar command . If the number is zero, .Ar command is run, without arguments, once for each .Ar argument . .Pp If any sequences of .Dq Li \&%d occur in .Ar command , the .Fl # option is ignored. .It Fl a Ar c The use of the character .Sq Li % as a magic character may be changed with the .Fl a option. .It Fl d Display the commands that would have been executed, but do not actually execute them. .El .Sh ENVIRONMENT The following environment variable affects the execution of .Nm : .Bl -tag -width SHELL .It Ev SHELL Pathname of shell to use. If this variable is not defined, the Bourne shell is used. .El .Sh EXAMPLES .Bl -tag -width apply -compact .It Li "apply echo a*" is similar to .Xr ls 1 ; .It Li "apply \-2 cmp a1 b1 a2 b2 a3 b3" compares the `a' files to the `b' files; .It Li "apply \-0 who 1 2 3 4 5" runs .Xr who 1 5 times; and .It Li "apply \'ln %1 /usr/joe\'" * links all files in the current directory to the directory .Pa /usr/joe . .El .Sh FILES .Bl -tag -width /bin/sh -compact .It Pa /bin/sh default shell .El .Sh AUTHORS .An Rob Pike .Sh BUGS Shell metacharacters in .Ar command may have bizarre effects; it is best to enclose complicated commands in single quotes .Pq '' . .Sh HISTORY The .Nm command appeared in .Bx 4.2 . Index: head/usr.bin/at/at.man =================================================================== --- head/usr.bin/at/at.man (revision 79534) +++ head/usr.bin/at/at.man (revision 79535) @@ -1,274 +1,274 @@ .\" $FreeBSD$ .Dd April 12, 1995 .Dt "AT" 1 -.Os FreeBSD +.Os .Sh NAME .Nm at , .Nm batch , .Nm atq , .Nm atrm .Nd queue, examine or delete jobs for later execution .Sh SYNOPSIS .Nm at .Op Fl V .Op Fl q Ar queue .Op Fl f Ar file .Op Fl mldbv .Ar time .Nm at .Op Fl V .Fl c Ar job Op Ar job ... .Pp .Nm atq .Op Fl V .Op Fl q Ar queue .Op Fl v .Pp .Nm atrm .Op Fl V .Ar job .Op Ar job ... .Pp .Nm batch .Op Fl V .Op Fl q Ar queue .Op Fl f Ar file .Op Fl mv .Op Ar time .Sh DESCRIPTION .Nm \&At and .Nm batch read commands from standard input or a specified file which are to be executed at a later time, using .Xr sh 1 . .Bl -tag -width indent .It Nm at executes commands at a specified time; .It Nm atq lists the user's pending jobs, unless the user is the superuser; in that case, everybody's jobs are listed; .It Nm atrm deletes jobs; .It Nm batch executes commands when system load levels permit; in other words, when the load average drops below _LOADAVG_MX, or the value specified in the invocation of .Nm atrun . .El .Pp .Nm \&At allows some moderately complex .Ar time specifications. It accepts times of the form .Ar HHMM or .Ar HH:MM to run a job at a specific time of day. (If that time is already past, the next day is assumed.) You may also specify .Em midnight , .Em noon , or .Em teatime (4pm) and you can have a time-of-day suffixed with .Em AM or .Em PM for running in the morning or the evening. You can also say what day the job will be run, by giving a date in the form .Ar \%month-name day with an optional .Ar year , or giving a date of the form .Ar MMDDYY or .Ar MM/DD/YY or .Ar DD.MM.YY . The specification of a date must follow the specification of the time of day. You can also give times like .Op Em now .Em + Ar count \%time-units , where the time-units can be .Em minutes , .Em hours , .Em days , .Em weeks , .Em months or .Em years and you can tell .Nm to run the job today by suffixing the time with .Em today and to run the job tomorrow by suffixing the time with .Em tomorrow . .Pp For example, to run a job at 4pm three days from now, you would do .Nm at Ar 4pm + 3 days , to run a job at 10:00am on July 31, you would do .Nm at Ar 10am Jul 31 and to run a job at 1am tomorrow, you would do .Nm at Ar 1am tomorrow . .Pp For both .Nm and .Nm batch , commands are read from standard input or the file specified with the .Fl f option and executed. The working directory, the environment (except for the variables .Ev TERM , .Ev TERMCAP , .Ev DISPLAY and .Em _ ) and the .Ar umask are retained from the time of invocation. An .Nm or .Nm batch command invoked from a .Xr su 1 shell will retain the current userid. The user will be mailed standard error and standard output from his commands, if any. Mail will be sent using the command .Xr sendmail 8 . If .Nm is executed from a .Xr su 1 shell, the owner of the login shell will receive the mail. .Pp The superuser may use these commands in any case. For other users, permission to use at is determined by the files .Pa _PERM_PATH/at.allow and .Pa _PERM_PATH/at.deny . .Pp If the file .Pa _PERM_PATH/at.allow exists, only usernames mentioned in it are allowed to use .Nm . .Pp If .Pa _PERM_PATH/at.allow does not exist, .Pa _PERM_PATH/at.deny is checked, every username not mentioned in it is then allowed to use .Nm Ns . .Pp If neither exists, only the superuser is allowed use of .Nm Ns . This is the default configuration. .Pp An empty .Pa _PERM_PATH/at.deny means that every user is allowed use these commands. .Sh OPTIONS .Bl -tag -width indent .It Fl V Print the version number to standard error. .It Fl q Ar queue Use the specified queue. A queue designation consists of a single letter; valid queue designations range from .Ar a to .Ar z and .Ar A to .Ar Z . The .Ar _DEFAULT_AT_QUEUE queue is the default for .Nm and the .Ar _DEFAULT_BATCH_QUEUE queue for .Nm batch . Queues with higher letters run with increased niceness. If a job is submitted to a queue designated with an uppercase letter, it is treated as if it had been submitted to batch at that time. If .Nm atq is given a specific queue, it will only show jobs pending in that queue. .It Fl m Send mail to the user when the job has completed even if there was no output. .It Fl f Ar file Read the job from .Ar file rather than standard input. .It Fl l Is an alias for .Nm atq . .It Fl d Is an alias for .Nm atrm . .It Fl b Is an alias for .Nm batch . .It Fl v For .Nm atq , shows completed but not yet deleted jobs in the queue; otherwise shows the time the job will be executed. .It Fl c Cat the jobs listed on the command line to standard output. .El .Sh FILES .Bl -tag -width _ATJOB_DIR/_LOCKFILE -compact .It Pa _ATJOB_DIR directory containing job files .It Pa _ATSPOOL_DIR directory containing output spool files .It Pa /var/run/utmp login records .It Pa _PERM_PATH/at.allow allow permission control .It Pa _PERM_PATH/at.deny deny permission control .It Pa _ATJOB_DIR/_LOCKFILE job-creation lock file .El .Sh SEE ALSO .Xr nice 1 , .Xr sh 1 , .Xr umask 2 , .Xr atrun 8 , .Xr cron 8 , .Xr sendmail 8 .Sh BUGS If the file .Pa /var/run/utmp is not available or corrupted, or if the user is not logged on at the time .Nm is invoked, the mail is sent to the userid found in the environment variable .Ev LOGNAME . If that is undefined or empty, the current userid is assumed. .Pp .Nm \&At and .Nm batch as presently implemented are not suitable when users are competing for resources. If this is the case for your site, you might want to consider another batch system, such as .Em nqs . .Sh AUTHORS At was mostly written by .An Thomas Koenig Aq ig25@rz.uni-karlsruhe.de . The time parsing routines are by .An David Parsons Aq orc@pell.chi.il.us . Index: head/usr.bin/biff/biff.1 =================================================================== --- head/usr.bin/biff/biff.1 (revision 79534) +++ head/usr.bin/biff/biff.1 (revision 79535) @@ -1,90 +1,90 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)biff.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt BIFF 1 -.Os BSD 4 +.Os .Sh NAME .Nm biff .Nd "be notified if mail arrives and who it is from" .Sh SYNOPSIS .Nm .Op Cm n | y .Sh DESCRIPTION .Nm Biff informs the system whether you want to be notified when mail arrives during the current terminal session. .Pp Options supported by .Nm : .Bl -tag -width 4n .It Cm n Disables notification. .It Cm y Enables notification. .El .Pp When mail notification is enabled, the header and first few lines of the message will be printed on your screen whenever mail arrives. A .Dq Li biff y command is often included in the file .Pa \&.login or .Pa \&.profile to be executed at each login. .Pp .Nm Biff operates asynchronously. For synchronous notification use the .Ar MAIL variable of .Xr sh 1 or the .Ar mail variable of .Xr csh 1 . .Sh SEE ALSO .Xr csh 1 , .Xr mail 1 , .Xr sh 1 , .Xr comsat 8 .Sh HISTORY The .Nm command appeared in .Bx 4.0 . It was named after the dog of Heidi Stettner. He died in August 1993, at 15. Index: head/usr.bin/brandelf/brandelf.1 =================================================================== --- head/usr.bin/brandelf/brandelf.1 (revision 79534) +++ head/usr.bin/brandelf/brandelf.1 (revision 79535) @@ -1,105 +1,105 @@ .\" Copyright (c) 1997 .\" John-Mark Gurney. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. Neither the name of the author nor the names of any co-contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY John-Mark Gurney AND CONTRIBUTORS ``AS IS'' .\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd February 6, 1997 .Dt BRANDELF 1 -.Os FreeBSD +.Os .Sh NAME .Nm brandelf .Nd mark an ELF binary for a specific ABI .Sh SYNOPSIS .Nm .Op Fl lv .Op Fl f Ar ELF_ABI_number .Op Fl t Ar string .Ar .Sh DESCRIPTION This command marks an ELF binary to be run under a certain ABI for .Fx . .Pp The options are as follows: .Bl -tag -width Fl .It Fl f Ar ELF_ABI_number forces branding with the supplied ELF ABI number. Incompatible with the .Fl t option. These values are assigned by SCO/USL. .It Fl l lists all known ELF types on the standard error channel. .It Fl v turns on verbose reporting. .It Fl t Ar string Brands the given ELF binaries to be of the .Ar string ABI type. Currently supported ABIs are .Dq Fx , .Dq Tn Linux , and .Dq Tn SVR4 . .It Ar file If .Fl t Ar string is given it will brand .Ar file to be of type .Ar string , otherwise it will simply display the branding of .Ar file . .El .Sh EXAMPLES The following is an example of a typical usage of the .Nm command: .Pp .Dl % brandelf file .Dl % brandelf -t Linux file .Sh DIAGNOSTICS Exit status is 0 on success, and 1 if the command fails if a file does not exist, is too short, fails to brand properly, or the brand requested is not one of the known types and the .Fl f option is not set. .Sh SEE ALSO .Rs .%A The Santa Cruz Operation, Inc. .%T System V Application Binary Interface .%D April 29, 1998 (DRAFT) .%O http://www.sco.com/developer/devspecs/ .Re .Sh HISTORY The .Nm manual page first appeared in .Fx 2.2 . .Sh AUTHORS This manual page was written by .An John-Mark Gurney Aq gurney_j@efn.org . Index: head/usr.bin/checknr/checknr.1 =================================================================== --- head/usr.bin/checknr/checknr.1 (revision 79534) +++ head/usr.bin/checknr/checknr.1 (revision 79535) @@ -1,160 +1,160 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)checknr.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt CHECKNR 1 -.Os BSD 4 +.Os .Sh NAME .Nm checknr .Nd check nroff/troff files .Sh SYNOPSIS .Nm .Op Fl a Ns Ar \&.x1.y1.x2.y2. ... \&.xn.yn .Op Fl c Ns Ar \&.x1.x2.x3 ... \&.xn .Op Fl s .Op Fl f .Ar file .Sh DESCRIPTION .Nm Checknr checks a list of .Xr nroff 1 or .Xr troff 1 input files for certain kinds of errors involving mismatched opening and closing delimiters and unknown commands. If no files are specified, .Nm checks the standard input. .Pp Options: .Bl -tag -width Ds .It Fl a Add additional pairs of macros to the list of known macros. This must be followed by groups of six characters, each group defining a pair of macros. The six characters are a period, the first macro name, another period, and the second macro name. For example, to define a pair .BS and .ES, use .Sq Li \-a.BS.ES .It Fl c Define commands which would otherwise be complained about as undefined. .It Fl f Request .Nm to ignore .Ql \ef font changes. .It Fl s Ignore .Ql \es size changes. .El .Pp Delimiters checked are: .Bl -enum .It Font changes using \efx ... \efP. .It Size changes using \esx ... \es0. .It Macros that come in open ... close forms, for example, the .TS and .TE macros which must always come in pairs. .El .Pp .Nm Checknr is intended for use on documents that are prepared with .Nm in mind, much the same as .Xr lint 1 . It expects a certain document writing style for .Ql \ef and .Ql \es commands, in that each .Ql \efx must be terminated with .Ql \efP and each .Ql \esx must be terminated with .Ql \es0 . While it will work to directly go into the next font or explicitly specify the original font or point size, and many existing documents actually do this, such a practice will produce complaints from .Nm . Since it is probably better to use the .Ql \efP and .Ql \es0 forms anyway, you should think of this as a contribution to your document preparation style. .Pp .Nm Checknr knows about the .Xr ms 7 and .Xr me 7 macro packages. .Sh SEE ALSO .Xr nroff 1 , .Xr troff 1 , .Xr me 7 , .Xr ms 7 .\" .Xr checkeq 1 , .Sh DIAGNOSTICS .Bd -ragged -compact Complaints about unmatched delimiters. Complaints about unrecognized commands. Various complaints about the syntax of commands. .Ed .Sh BUGS There is no way to define a 1 character macro name using .Fl a . .Pp Does not correctly recognize certain reasonable constructs, such as conditionals. .Sh HISTORY The .Nm command appeared in .Bx 4.0 . Index: head/usr.bin/cksum/cksum.1 =================================================================== --- head/usr.bin/cksum/cksum.1 (revision 79534) +++ head/usr.bin/cksum/cksum.1 (revision 79535) @@ -1,186 +1,186 @@ .\" Copyright (c) 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" the Institute of Electrical and Electronics Engineers, Inc. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)cksum.1 8.2 (Berkeley) 4/28/95 .\" $FreeBSD$ .\" .Dd April 28, 1995 .Dt CKSUM 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm cksum , .Nm sum .Nd display file checksums and block counts .Sh SYNOPSIS .Nm .Op Fl o Ar 1 | 2 | 3 .Op Ar .Nm sum .Op Ar .Sh DESCRIPTION The .Nm utility writes to the standard output three whitespace separated fields for each input file. These fields are a checksum .Tn CRC , the total number of octets in the file and the file name. If no file name is specified, the standard input is used and no file name is written. .Pp The .Nm sum utility is identical to the .Nm utility, except that it defaults to using historic algorithm 1, as described below. It is provided for compatibility only. .Pp The options are as follows: .Bl -tag -width indent .It Fl o Use historic algorithms instead of the (superior) default one. .Pp Algorithm 1 is the algorithm used by historic .Bx systems as the .Xr sum 1 algorithm and by historic .At V systems as the .Xr sum 1 algorithm when using the .Fl r option. This is a 16-bit checksum, with a right rotation before each addition; overflow is discarded. .Pp Algorithm 2 is the algorithm used by historic .At V systems as the default .Xr sum 1 algorithm. This is a 32-bit checksum, and is defined as follows: .Bd -unfilled -offset indent s = sum of all bytes; r = s % 2^16 + (s % 2^32) / 2^16; cksum = (r % 2^16) + r / 2^16; .Ed .Pp Algorithm 3 is what is commonly called the .Ql 32bit CRC algorithm. This is a 32-bit checksum. .Pp Both algorithm 1 and 2 write to the standard output the same fields as the default algorithm except that the size of the file in bytes is replaced with the size of the file in blocks. For historic reasons, the block size is 1024 for algorithm 1 and 512 for algorithm 2. Partial blocks are rounded up. .El .Pp The default .Tn CRC used is based on the polynomial used for .Tn CRC error checking in the networking standard .St -iso8802-3 . The .Tn CRC checksum encoding is defined by the generating polynomial: .Pp .Bd -unfilled -offset indent G(x) = x^32 + x^26 + x^23 + x^22 + x^16 + x^12 + x^11 + x^10 + x^8 + x^7 + x^5 + x^4 + x^2 + x + 1 .Ed .Pp Mathematically, the .Tn CRC value corresponding to a given file is defined by the following procedure: .Bd -ragged -offset indent The .Ar n bits to be evaluated are considered to be the coefficients of a mod 2 polynomial M(x) of degree .Ar n Ns \-1 . These .Ar n bits are the bits from the file, with the most significant bit being the most significant bit of the first octet of the file and the last bit being the least significant bit of the last octet, padded with zero bits (if necessary) to achieve an integral number of octets, followed by one or more octets representing the length of the file as a binary value, least significant octet first. The smallest number of octets capable of representing this integer are used. .Pp M(x) is multiplied by x^32 (i.e., shifted left 32 bits) and divided by G(x) using mod 2 division, producing a remainder R(x) of degree <= 31. .Pp The coefficients of R(x) are considered to be a 32-bit sequence. .Pp The bit sequence is complemented and the result is the CRC. .Ed .Sh DIAGNOSTICS The .Nm and .Nm sum utilities exit 0 on success, and >0 if an error occurs. .Sh SEE ALSO .Xr md5 1 .Pp The default calculation is identical to that given in pseudo-code in the following .Tn ACM article. .Rs .%T "Computation of Cyclic Redundancy Checks Via Table Lookup" .%A Dilip V. Sarwate .%J "Communications of the" Tn ACM .%D "August 1988" .Re .Sh STANDARDS The .Nm utility is expected to conform to .St -p1003.2-92 . .Sh HISTORY The .Nm utility appeared in .Bx 4.4 . Index: head/usr.bin/colcrt/colcrt.1 =================================================================== --- head/usr.bin/colcrt/colcrt.1 (revision 79534) +++ head/usr.bin/colcrt/colcrt.1 (revision 79535) @@ -1,109 +1,109 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)colcrt.1 8.1 (Berkeley) 6/30/93 .\" $FreeBSD$ .\" .Dd June 30, 1993 .Dt COLCRT 1 -.Os BSD 3 +.Os .Sh NAME .Nm colcrt .Nd filter nroff output for CRT previewing .Sh SYNOPSIS .Nm .Op Fl .Op Fl \&2 .Op Ar .Sh DESCRIPTION .Nm Colcrt provides virtual half-line and reverse line feed sequences for terminals without such capability, and on which overstriking is destructive. Half-line characters and underlining (changed to dashing `\-') are placed on new lines in between the normal output lines. .Pp The following options are available: .Bl -tag -width indent .It Fl Suppress all underlining. This option is especially useful for previewing .Em allboxed tables from .Xr tbl 1 . .It Fl 2 Cause all half-lines to be printed, effectively double spacing the output. Normally, a minimal space output format is used which will suppress empty lines. The program never suppresses two consecutive empty lines, however. The .Fl 2 option is useful for sending output to the line printer when the output contains superscripts and subscripts which would otherwise be invisible. .El .Sh EXAMPLES A typical use of .Nm would be .Bd -literal tbl exum2.n \&| nroff \-ms \&| colcrt \- \&| more .Ed .Sh SEE ALSO .Xr col 1 , .Xr more 1 , .Xr nroff 1 , .Xr troff 1 , .Xr ul 1 .Sh BUGS Should fold underlines onto blanks even with the .Ql Fl option so that a true underline character would show. .Pp Can't back up more than 102 lines. .Pp General overstriking is lost; as a special case .Ql \&| overstruck with .Ql \- or underline becomes .Ql \&+ . .Pp Lines are trimmed to 132 characters. .Pp Some provision should be made for processing superscripts and subscripts in documents which are already double-spaced. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/colrm/colrm.1 =================================================================== --- head/usr.bin/colrm/colrm.1 (revision 79534) +++ head/usr.bin/colrm/colrm.1 (revision 79535) @@ -1,79 +1,79 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)colrm.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt COLRM 1 -.Os BSD 3 +.Os .Sh NAME .Nm colrm .Nd remove columns from a file .Sh SYNOPSIS .Nm .Op Ar start Op Ar stop .Sh DESCRIPTION .Nm Colrm removes selected columns from the lines of a file. A column is defined as a single character in a line. Input is read from the standard input. Output is written to the standard output. .Pp If only the .Ar start column is specified, columns numbered less than the .Ar start column will be written. If both .Ar start and .Ar stop columns are specified, columns numbered less than the .Ar start column or greater than the .Ar stop column will be written. Column numbering starts with one, not zero. .Pp Tab characters increment the column count to the next multiple of eight. Backspace characters decrement the column count by one. .Sh SEE ALSO .Xr awk 1 , .Xr column 1 , .Xr cut 1 , .Xr paste 1 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/compress/compress.1 =================================================================== --- head/usr.bin/compress/compress.1 (revision 79534) +++ head/usr.bin/compress/compress.1 (revision 79535) @@ -1,172 +1,172 @@ .\" Copyright (c) 1986, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" James A. Woods, derived from original work by Spencer Thomas .\" and Joseph Orost. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)compress.1 8.2 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" .Dd April 18, 1994 .Dt COMPRESS 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm compress , .Nm uncompress , .Nm zcat .Nd compress and expand data .Sh SYNOPSIS .Nm .Op Fl cfv .Op Fl b Ar bits .Op Ar .Nm uncompress .Op Fl cfv .Op Ar .Nm zcat .Op Ar .Sh DESCRIPTION .Nm Compress reduces the size of the named files using adaptive Lempel-Ziv coding. Each .Ar file is renamed to the same name plus the extension .Dq .Z . As many of the modification time, access time, file flags, file mode, user ID, and group ID as allowed by permissions are retained in the new file. If compression would not reduce the size of a .Ar file , the file is ignored. .Pp .Nm Uncompress restores the compressed files to their original form, renaming the files by deleting the .Dq .Z extension. .Pp .Nm Zcat is an alias for .Dq "uncompress -c" . .Pp If renaming the files would cause files to be overwritten and the standard input device is a terminal, the user is prompted (on the standard error output) for confirmation. If prompting is not possible or confirmation is not received, the files are not overwritten. .Pp If no files are specified, the standard input is compressed or uncompressed to the standard output. If either the input and output files are not regular files, the checks for reduction in size and file overwriting are not performed, the input file is not removed, and the attributes of the input file are not retained. .Pp The options are as follows: .Bl -tag -width indent .It Fl b Specify the .Ar bits code limit (see below). .It Fl c Compressed or uncompressed output is written to the standard output. No files are modified. .It Fl f Force compression of .Ar file , even if it is not actually reduced in size. Additionally, files are overwritten without prompting for confirmation. .It Fl v Print the percentage reduction of each file. .El .Pp .Nm Compress uses a modified Lempel-Ziv algorithm. Common substrings in the file are first replaced by 9-bit codes 257 and up. When code 512 is reached, the algorithm switches to 10-bit codes and continues to use more bits until the limit specified by the .Fl b flag is reached (the default is 16). .Ar Bits must be between 9 and 16. .Pp After the .Ar bits limit is reached, .Nm periodically checks the compression ratio. If it is increasing, .Nm continues to use the existing code dictionary. However, if the compression ratio decreases, .Nm discards the table of substrings and rebuilds it from scratch. This allows the algorithm to adapt to the next "block" of the file. .Pp The .Fl b flag is omitted for .Nm uncompress since the .Ar bits parameter specified during compression is encoded within the output, along with a magic number to ensure that neither decompression of random data nor recompression of compressed data is attempted. .Pp The amount of compression obtained depends on the size of the input, the number of .Ar bits per code, and the distribution of common substrings. Typically, text such as source code or English is reduced by 50\-60%. Compression is generally much better than that achieved by Huffman coding (as used in the historical command pack), or adaptive Huffman coding (as used in the historical command compact), and takes less time to compute. .Sh DIAGNOSTICS The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh SEE ALSO .Rs .%A Welch, Terry A. .%D June, 1984 .%T "A Technique for High Performance Data Compression" .%J "IEEE Computer" .%V 17:6 .%P pp. 8-19 .Re .Sh HISTORY The .Nm command appeared in .Bx 4.3 . Index: head/usr.bin/ctags/ctags.1 =================================================================== --- head/usr.bin/ctags/ctags.1 (revision 79534) +++ head/usr.bin/ctags/ctags.1 (revision 79535) @@ -1,215 +1,215 @@ .\" Copyright (c) 1987, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)ctags.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt CTAGS 1 -.Os BSD 4 +.Os .Sh NAME .Nm ctags .Nd create a tags file .Sh SYNOPSIS .Nm .Op Fl BFadtuwvx .Op Fl f Ar tagsfile .Ar name ... .Sh DESCRIPTION .Nm Ctags makes a tags file for .Xr ex 1 from the specified C, Pascal, Fortran, .Tn YACC , lex, and lisp sources. A tags file gives the locations of specified objects in a group of files. Each line of the tags file contains the object name, the file in which it is defined, and a search pattern for the object definition, separated by white-space. Using the .Ar tags file, .Xr ex 1 can quickly locate these object definitions. Depending upon the options provided to .Nm , objects will consist of subroutines, typedefs, defines, structs, enums and unions. .Bl -tag -width Ds .It Fl B use backward searching patterns .Pq Li ?...? . .It Fl F use forward searching patterns .Pq Li /.../ (the default). .It Fl a append to .Ar tags file. .It Fl d create tags for .Li #defines that don't take arguments; .Li #defines that take arguments are tagged automatically. .It Fl f Places the tag descriptions in a file called .Ar tagsfile . The default behaviour is to place them in a file called .Ar tags . .It Fl t create tags for typedefs, structs, unions, and enums. .It Fl u update the specified files in the .Ar tags file, that is, all references to them are deleted, and the new values are appended to the file. (Beware: this option is implemented in a way which is rather slow; it is usually faster to simply rebuild the .Ar tags file.) .It Fl v An index of the form expected by .Xr vgrind 1 is produced on the standard output. This listing contains the object name, file name, and page number (assuming 64 line pages). Since the output will be sorted into lexicographic order, it may be desired to run the output through .Xr sort 1 . Sample use: .Bd -literal -offset indent ctags \-v files \&| sort \-f > index vgrind \-x index .Ed .It Fl w suppress warning diagnostics. .It Fl x .Nm produces a list of object names, the line number and file name on which each is defined, as well as the text of that line and prints this on the standard output. This is a simple index which can be printed out as an off-line readable function index. .El .Pp Files whose names end in .Nm \&.c or .Nm \&.h are assumed to be C source files and are searched for C style routine and macro definitions. Files whose names end in .Nm \&.y are assumed to be .Tn YACC source files. Files whose names end in .Nm \&.l are assumed to be lisp files if their first non-blank character is `;', `(', or `[', otherwise, they are treated as lex files. Other files are first examined to see if they contain any Pascal or Fortran routine definitions, and, if not, are searched for C style definitions. .Pp The tag .Li main is treated specially in C programs. The tag formed is created by prepending .Ar M to the name of the file, with the trailing .Nm \&.c and any leading pathname components removed. This makes use of .Nm practical in directories with more than one program. .Pp Yacc and lex files each have a special tag. .Ar Yyparse is the start of the second section of the yacc file, and .Ar yylex is the start of the second section of the lex file. .Sh FILES .Bl -tag -width tags -compact .It Pa tags default output tags file .El .Sh DIAGNOSTICS .Nm Ctags exits with a value of 1 if an error occurred, 0 otherwise. Duplicate objects are not considered errors. .Sh SEE ALSO .Xr ex 1 , .Xr vi 1 .Sh BUGS Recognition of .Nm functions , .Nm subroutines and .Nm procedures for .Tn FORTRAN and Pascal is done is a very simpleminded way. No attempt is made to deal with block structure; if you have two Pascal procedures in different blocks with the same name you lose. .Nm Ctags doesn't understand about Pascal types. .Pp The method of deciding whether to look for C, Pascal or .Tn FORTRAN functions is a hack. .Pp .Nm Ctags relies on the input being well formed, and any syntactical errors will completely confuse it. It also finds some legal syntax confusing; for example, since it doesn't understand .Li #ifdef Ns 's (incidentally, that's a feature, not a bug), any code with unbalanced braces inside .Li #ifdef Ns 's will cause it to become somewhat disoriented. In a similar fashion, multiple line changes within a definition will cause it to enter the last line of the object, rather than the first, as the searching pattern. The last line of multiple line .Li typedef Ns 's will similarly be noted. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/expand/expand.1 =================================================================== --- head/usr.bin/expand/expand.1 (revision 79534) +++ head/usr.bin/expand/expand.1 (revision 79535) @@ -1,93 +1,93 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)expand.1 8.1 (Berkeley) 6/9/93 .\" $FreeBSD$ .\" .Dd June 9, 1993 .Dt EXPAND 1 -.Os BSD 4 +.Os .Sh NAME .Nm expand , .Nm unexpand .Nd expand tabs to spaces, and vice versa .Sh SYNOPSIS .Nm .Op Fl Ns Ar tabstop .Oo .Fl t .Sm off .Ar tab1 , tab2 , ... , tabn .Sm on .Oc .Op Ar .Nm unexpand .Op Fl a .Op Ar .Sh DESCRIPTION .Nm Expand processes the named files or the standard input writing the standard output with tabs changed into blanks. Backspace characters are preserved into the output and decrement the column count for tab calculations. .Nm Expand is useful for pre-processing character files (before sorting, looking at specific columns, etc.) that contain tabs. .Pp If a single .Ar tabstop argument is given, then tabs are set .Ar tabstop spaces apart instead of the default 8. If multiple tabstops are given then the tabs are set at those specific columns. .Pp .Nm Unexpand puts tabs back into the data from the standard input or the named files and writes the result on the standard output. .Pp Option (with .Nm unexpand only): .Bl -tag -width indent .It Fl a By default, only leading blanks and tabs are reconverted to maximal strings of tabs. If the .Fl a option is given, then tabs are inserted whenever they would compress the resultant file by replacing two or more characters. .El .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/false/false.1 =================================================================== --- head/usr.bin/false/false.1 (revision 79534) +++ head/usr.bin/false/false.1 (revision 79535) @@ -1,65 +1,65 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" the Institute of Electrical and Electronics Engineers, Inc. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)false.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt FALSE 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm false .Nd return false value .Sh SYNOPSIS .Nm .Sh DESCRIPTION The .Nm command is usually used in a Bourne shell script. It tests for the appropriate status "false" before running (or failing to run) a list of commands. .Pp The .Nm utility always exits with a value other than zero. .Sh SEE ALSO .Xr csh 1 , .Xr sh 1 , .Xr true 1 .Sh STANDARDS The .Nm utility is expected to be .St -p1003.2 compatible. Index: head/usr.bin/finger/finger.1 =================================================================== --- head/usr.bin/finger/finger.1 (revision 79534) +++ head/usr.bin/finger/finger.1 (revision 79535) @@ -1,239 +1,239 @@ .\" Copyright (c) 1989, 1990, 1993, 1994 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)finger.1 8.3 (Berkeley) 5/5/94 .\" $FreeBSD$ .\" .Dd August 1, 1997 .Dt FINGER 1 -.Os BSD 4 +.Os .Sh NAME .Nm finger .Nd user information lookup program .Sh SYNOPSIS .Nm .Op Fl lmpshoT .Op Ar user ...\& .Op Ar user@host ...\& .Sh DESCRIPTION The .Nm displays information about the system users. .Pp Options are: .Bl -tag -width flag .It Fl s .Nm Finger displays the user's login name, real name, terminal name and write status (as a ``*'' before the terminal name if write permission is denied), idle time, login time, and either office location and office phone number, or the remote host. If .Fl o is given, the office location and office phone number is printed (the default). If .Fl h is given, the remote host is printed instead. .Pp Idle time is in minutes if it is a single integer, hours and minutes if a ``:'' is present, or days if a ``d'' is present. If it is an .Dq * , the login time indicates the time of last login. Login time is displayed as the day name if less than 6 days, else month, day; hours and minutes, unless more than six months ago, in which case the year is displayed rather than the hours and minutes. .Pp Unknown devices as well as nonexistent idle and login times are displayed as single asterisks. .Pp .It Fl h When used in conjunction with the .Fl s option, the name of the remote host is displayed instead of the office location and office phone. .Pp .It Fl o When used in conjunction with the .Fl s option, the office location and office phone information is displayed instead of the name of the remote host. .Pp .It Fl l Produces a multi-line format displaying all of the information described for the .Fl s option as well as the user's home directory, home phone number, login shell, mail status, and the contents of the files .Dq Pa .forward , .Dq Pa .plan , .Dq Pa .project and .Dq Pa .pubkey from the user's home directory. .Pp If idle time is at least a minute and less than a day, it is presented in the form ``hh:mm''. Idle times greater than a day are presented as ``d day[s]hh:mm''. .Pp Phone numbers specified as eleven digits are printed as ``+N-NNN-NNN-NNNN''. Numbers specified as ten or seven digits are printed as the appropriate subset of that string. Numbers specified as five digits are printed as ``xN-NNNN''. Numbers specified as four digits are printed as ``xNNNN''. .Pp If write permission is denied to the device, the phrase ``(messages off)'' is appended to the line containing the device name. One entry per user is displayed with the .Fl l option; if a user is logged on multiple times, terminal information is repeated once per login. .Pp Mail status is shown as ``No Mail.'' if there is no mail at all, ``Mail last read DDD MMM ## HH:MM YYYY (TZ)'' if the person has looked at their mailbox since new mail arriving, or ``New mail received ...'', ``Unread since ...'' if they have new mail. .Pp .It Fl p Prevents the .Fl l option of .Nm from displaying the contents of the .Dq Pa .forward , .Dq Pa .plan , .Dq Pa .project and .Dq Pa .pubkey files. .It Fl m Prevent matching of .Ar user names. .Ar User is usually a login name; however, matching will also be done on the users' real names, unless the .Fl m option is supplied. All name matching performed by .Nm is case insensitive. .Pp .It Fl T Disable the piggybacking of data on the initial connection request. This option is needed to finger hosts with a broken TCP implementation. .El .Pp If no options are specified, .Nm defaults to the .Fl l style output if operands are provided, otherwise to the .Fl s style. Note that some fields may be missing, in either format, if information is not available for them. .Pp If no arguments are specified, .Nm will print an entry for each user currently logged into the system. .Pp .Nm Finger may be used to look up users on a remote machine. The format is to specify a .Ar user as .Dq Li user@host , or .Dq Li @host , where the default output format for the former is the .Fl l style, and the default output format for the latter is the .Fl s style. The .Fl l option is the only option that may be passed to a remote machine. .Pp If the file .Dq Pa .nofinger exists in the user's home directory, .Nm behaves as if the user in question does not exist. .Pp The optional .Xr finger.conf 5 configuration file can be used to specify aliases. Since .Xr finger 1 is invoked by .Xr fingerd 8 , aliases will work for both local and network queries. .Sh ENVIRONMENT .Nm Finger utilizes the following environment variable, if it exists: .Bl -tag -width Fl .It Ev FINGER This variable may be set with favored options to .Nm . .El .Sh FILES .Bl -tag -width /var/log/lastlog -compact .It Pa /etc/finger.conf alias definition data base .It Pa /var/log/lastlog last login data base .El .Sh SEE ALSO .Xr chpass 1 , .Xr w 1 , .Xr who 1 , .Xr finger.conf 5 , .Xr fingerd 8 .Rs .%A D. Zimmerman .%T The Finger User Information Protocol .%R RFC 1288 .%D December, 1991 .Re .Sh HISTORY The .Nm command appeared in .Bx 3.0 . .Sh BUGS The current FINGER protocol RFC requires that the client keep the connection fully open until the server closes. This prevents the use of the optimal three-packet T/TCP exchange. (Servers which depend on this requirement are bogus but have nonetheless been observed in the Internet at large.) Index: head/usr.bin/from/from.1 =================================================================== --- head/usr.bin/from/from.1 (revision 79534) +++ head/usr.bin/from/from.1 (revision 79535) @@ -1,96 +1,96 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)from.1 8.2 (Berkeley) 12/30/93 .\" $FreeBSD$ .\" .Dd December 30, 1993 .Dt FROM 1 -.Os BSD 4 +.Os .Sh NAME .Nm from .Nd print names of those who have sent mail .Sh SYNOPSIS .Nm .Op Fl c .Op Fl s Ar sender .Op Fl f Ar file .Op Ar user .Sh DESCRIPTION .Nm From prints out the mail header lines from the invoker's mailbox. .Pp Options: .Bl -tag -width Fl .It Fl c Just print a count of messages and exit. .It Fl f Ar file The supplied file is examined instead of the invoker's mailbox. If the .Fl f option is used, the .Ar user argument should not be used. Read from standard input if file name .Ar - is given. .It Fl s Ar sender Only mail from addresses containing the supplied string are printed. .El .Pp If .Ar user is given, the .Ar user Ns 's mailbox, is examined instead of the invoker's own mailbox. (Privileges are required.) .Sh ENVIRONMENT .Bl -tag -width Fl .It Ev MAIL If set, the location of the invoker's mailbox. Otherwise, the default in /var/mail is used. .El .Sh FILES .Bl -tag -width /var/mail/* -compact .It Pa /var/mail/* .El .Sh SEE ALSO .Xr biff 1 , .Xr mail 1 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/fstat/fstat.1 =================================================================== --- head/usr.bin/fstat/fstat.1 (revision 79534) +++ head/usr.bin/fstat/fstat.1 (revision 79535) @@ -1,227 +1,227 @@ .\" Copyright (c) 1987, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)fstat.1 8.3 (Berkeley) 2/25/94 .\" $FreeBSD$ .\" .Dd February 25, 1994 .Dt FSTAT 1 -.Os BSD 4 +.Os .Sh NAME .Nm fstat .Nd file status .Sh SYNOPSIS .Nm .Op Fl fmnv .Op Fl M Ar core .Op Fl N Ar system .Op Fl p Ar pid .Op Fl u Ar user .Op Ar filename... .Sh DESCRIPTION .Nm Fstat identifies open files. A file is considered open by a process if it was explicitly opened, is the working directory, root directory, active executable text, or kernel trace file for that process. If no options are specified, .Nm reports on all open files in the system. .Pp Options: .Bl -tag -width Ds .It Fl f Restrict examination to files open in the same filesystems as the named file arguments, or to the filesystem containing the current directory if there are no additional filename arguments. For example, to find all files open in the filesystem where the directory .Pa /usr/src resides, type .Dq Li fstat -f /usr/src . .It Fl M Extract values associated with the name list from the specified core instead of the default .Pa /dev/kmem . .It Fl N Extract the name list from the specified system instead of the default .Pa /kernel . .It Fl m Include memory-mapped files in the listing; normally these are excluded due to the extra processing required. .It Fl n Numerical format. Print the device number (maj,min) of the filesystem the file resides in rather than the mount point name; for special files, print the device number that the special device refers to rather than the filename in .Pa /dev ; and print the mode of the file in octal instead of symbolic form. .It Fl p Report all files open by the specified process. .It Fl u Report all files open by the specified user. .It Fl v Verbose mode. Print error messages upon failures to locate particular system data structures rather than silently ignoring them. Most of these data structures are dynamically created or deleted and it is possible for them to disappear while .Nm is running. This is normal and unavoidable since the rest of the system is running while .Nm itself is running. .It Ar filename ... Restrict reports to the specified files. .El .Pp The following fields are printed: .Bl -tag -width MOUNT .It Li USER The username of the owner of the process (effective uid). .It Li CMD The command name of the process. .It Li PID The process id. .It Li FD The file number in the per-process open file table or one of the following special names: .Pp .Bd -literal -offset indent -compact text - executable text inode wd - current working directory root - root inode tr - kernel trace file mmap - memory-mapped file .Ed .Pp If the file number is followed by an asterisk (``*''), the file is not an inode, but rather a socket, .Tn FIFO , or there is an error. In this case the remainder of the line doesn't correspond to the remaining headers -- the format of the line is described later under .Sx Sockets . .It Li MOUNT If the .Fl n flag wasn't specified, this header is present and is the pathname that the filesystem the file resides in is mounted on. .It Li DEV If the .Fl n flag is specified, this header is present and is the major/minor number of the device that this file resides in. .It Li INUM The inode number of the file. .It Li MODE The mode of the file. If the .Fl n flag isn't specified, the mode is printed using a symbolic format (see .Xr strmode 3 ) ; otherwise, the mode is printed as an octal number. .It Li SZ\&|DV If the file is not a character or block special, prints the size of the file in bytes. Otherwise, if the .Fl n flag is not specified, prints the name of the special file as located in .Pa /dev . If that cannot be located, or the .Fl n flag is specified, prints the major/minor device number that the special device refers to. .It Li R/W This column describes the access mode that the file allows. The letter ``r'' indicates open for reading; the letter ``w'' indicates open for writing. This field is useful when trying to find the processes that are preventing a filesystem from being down graded to read-only. .It Li NAME If filename arguments are specified and the .Fl f flag is not, then this field is present and is the name associated with the given file. Normally the name cannot be determined since there is no mapping from an open file back to the directory entry that was used to open that file. Also, since different directory entries may reference the same file (via .Xr ln 1 ) , the name printed may not be the actual name that the process originally used to open that file. .El .Sh SOCKETS The formating of open sockets depends on the protocol domain. In all cases the first field is the domain name, the second field is the socket type (stream, dgram, etc), and the third is the socket flags field (in hex). The remaining fields are protocol dependent. For tcp, it is the address of the tcpcb, and for udp, the inpcb (socket pcb). For unix domain sockets, its the address of the socket pcb and the address of the connected pcb (if connected). Otherwise the protocol number and address of the socket itself are printed. The attempt is to make enough information available to permit further analysis without duplicating .Xr netstat 1 . .Pp For example, the addresses mentioned above are the addresses which the .Dq Li netstat -A command would print for tcp, udp, and unixdomain. Note that since pipes are implemented using sockets, a pipe appears as a connected unix domain stream socket. A unidirectional unix domain socket indicates the direction of flow with an arrow (``<-'' or ``->''), and a full duplex socket shows a double arrow (``<->''). .Sh BUGS Since .Nm takes a snapshot of the system, it is only correct for a very short period of time. .Sh SEE ALSO .Xr netstat 1 , .Xr nfsstat 1 , .Xr ps 1 , .Xr sockstat 1 , .Xr systat 1 , .Xr tcp 4 , .Xr unix 4 , .Xr iostat 8 , .Xr pstat 8 , .Xr vmstat 8 .Sh HISTORY The .Nm command appeared in .Bx 4.3 tahoe . Index: head/usr.bin/ftp/ftp.1 =================================================================== --- head/usr.bin/ftp/ftp.1 (revision 79534) +++ head/usr.bin/ftp/ftp.1 (revision 79535) @@ -1,1456 +1,1456 @@ .\" $FreeBSD$ .\" $NetBSD: ftp.1,v 1.21 1997/06/10 21:59:58 lukem Exp $ .\" .\" Copyright (c) 1985, 1989, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)ftp.1 8.3 (Berkeley) 10/9/94 .\" .Dd January 27, 2000 .Dt FTP 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm ftp , pftp , gate-ftp .Nd .Tn ARPANET file transfer program .Sh SYNOPSIS .Nm .Op Fl 46adeginptUvV .Op Fl P Ar port .Op Fl s Ar src_addr .Op Ar host Op Ar port .Nm ftp://[\fIuser\fR:\fIpassword\fR@]\fIhost\fR[:\fIport\fR]/\fIfile\fR[/] .Nm http://\fIhost\fR[:\fIport\fR]/\fIfile\fR .Nm \fIhost\fR:[/\fIpath\fR/]\fIfile\fR[/] .Sh DESCRIPTION .Nm is the user interface to the .Tn ARPANET standard File Transfer Protocol. The program allows a user to transfer files to and from a remote network site. The version supports IPv6 (Internet protocol version 6), as well as IPv4. .Pp The latter three usage formats will fetch a file using either the HTTP or FTP protocols into the current directory. This is ideal for scripts. Refer to .Sx AUTO-FETCHING FILES below for more information. .Pp Options may be specified at the command line, or to the command interpreter. .Bl -tag -width Fl .It Fl 4 Forces .Nm to use IPv4 addresses only. .It Fl 6 Forces .Nm to use IPv6 addresses only. .It Fl a Causes .Nm to bypass normal login procedure, and use an anonymous login instead. .It Fl d Enables debugging. .It Fl e Disables command line editing. .It Fl g Disables file name globbing. .It Fl i Turns off interactive prompting during multiple file transfers. .It Fl n Restrains .Nm from attempting .Dq auto-login upon initial connection. If auto-login is enabled, .Nm will check the .Pa .netrc (see below) file in the user's home directory for an entry describing an account on the remote machine. If no entry exists, .Nm will prompt for the remote machine login name (default is the user identity on the local machine), and, if necessary, prompt for a password and an account with which to login. .It Fl p Enables passive mode operation for use behind connection filtering firewalls. Using the .Nm pftp command has the same effect. .It Fl P Ar port Sets the port number to .Ar port . .It Fl s Ar src_addr Sets the local IP address for all connections to .Ar src_addr , which can be an IP address or a host name. .It Fl t Enables packet tracing. .It Fl U Disable data port range restrictions. .It Fl v Enable verbose mode. This is the default if input is from a terminal. Forces .Nm to show all responses from the remote server, as well as report on data transfer statistics. .It Fl V Disable verbose mode, overriding the default of enabled when input is from a terminal. .El .Pp The client host with which .Nm is to communicate may be specified on the command line. If this is done, .Nm will immediately attempt to establish a connection to an .Tn FTP server on that host; otherwise, .Nm will enter its command interpreter and await instructions from the user. When .Nm is awaiting commands from the user the prompt .Ql ftp> is provided to the user. The following commands are recognized by .Nm : .Bl -tag -width Fl .It Ic \&! Op Ar command Op Ar args Invoke an interactive shell on the local machine. If there are arguments, the first is taken to be a command to execute directly, with the rest of the arguments as its arguments. .It Ic \&$ Ar macro-name Op Ar args Execute the macro .Ar macro-name that was defined with the .Ic macdef command. Arguments are passed to the macro unglobbed. .It Ic account Op Ar passwd Supply a supplemental password required by a remote system for access to resources once a login has been successfully completed. If no argument is included, the user will be prompted for an account password in a non-echoing input mode. .It Ic append Ar local-file Op Ar remote-file Append a local file to a file on the remote machine. If .Ar remote-file is left unspecified, the local file name is used in naming the remote file after being altered by any .Ic ntrans or .Ic nmap setting. File transfer uses the current settings for .Ic type , .Ic format , .Ic mode and .Ic structure . .It Ic ascii Set the file transfer .Ic type to network .Tn ASCII . This is the default type. .It Ic bell Arrange that a bell be sounded after each file transfer command is completed. .It Ic binary Set the file transfer .Ic type to support binary image transfer. .It Ic bye Terminate the .Tn FTP session with the remote server and exit .Nm . An end of file will also terminate the session and exit. .It Ic case Toggle remote computer file name case mapping during .Ic mget commands. When .Ic case is on (default is off), remote computer file names with all letters in upper case are written in the local directory with the letters mapped to lower case. .It Ic \&cd Ar remote-directory Change the working directory on the remote machine to .Ar remote-directory . .It Ic cdup Change the remote machine working directory to the parent of the current remote machine working directory. .It Ic chmod Ar mode file-name Change the permission modes of the file .Ar file-name on the remote system to .Ar mode . .It Ic close Terminate the .Tn FTP session with the remote server, and return to the command interpreter. Any defined macros are erased. .It Ic \&cr Toggle carriage return stripping during ascii type file retrieval. Records are denoted by a carriage return/linefeed sequence during ascii type file transfer. When .Ic \&cr is on (the default), carriage returns are stripped from this sequence to conform with the .Ux single linefeed record delimiter. Records on .Pf non\- Ns Ux remote systems may contain single linefeeds; when an ascii type transfer is made, these linefeeds may be distinguished from a record delimiter only when .Ic \&cr is off. .It Ic delete Ar remote-file Delete the file .Ar remote-file on the remote machine. .It Ic debug Op Ar debug-value Toggle debugging mode. If an optional .Ar debug-value is specified, it is used to set the debugging level. When debugging is on, .Nm prints each command sent to the remote machine, preceded by the string .Ql \-\-> .It Ic dir Op Ar remote-directory Op Ar local-file Print a listing of the contents of a directory on the remote machine. The listing includes any system-dependent information that the server chooses to include; for example, most .Ux systems will produce output from the command .Ql ls \-l . (See also .Ic ls . ) If .Ar remote-directory is left unspecified, the current working directory is used. If interactive prompting is on, .Nm will prompt the user to verify that the last argument is indeed the target local file for receiving .Ic dir output. If no local file is specified, or if .Ar local-file is .Sq Fl , the output is sent to the terminal. .Pp As this command provides extra information which is system-dependent, you should use the .Ic nlist command instead if you only want a plain list of files. .It Ic disconnect A synonym for .Ic close . .It Ic edit Toggle command line editing, and context sensitive command and file completion. This is automatically enabled if input is from a terminal, and disabled otherwise. .It Ic exit A synonym for .Ic bye . .It Ic ftp Ar host Op Ar port A synonym for .Ic open . .It Ic form Ar format Set the file transfer .Ic form to .Ar format . The default format is \*(Lqfile\*(Rq. .It Ic get Ar remote-file Op Ar local-file Retrieve the .Ar remote-file and store it on the local machine. If the local file name is not specified, it is given the same name it has on the remote machine, subject to alteration by the current .Ic case , .Ic ntrans and .Ic nmap settings. The current settings for .Ic type , .Ic form , .Ic mode and .Ic structure are used while transferring the file. .It Ic gate Op Ar host Op Ar port Toggle gate-ftp mode. This will not be permitted if the gate-ftp server hasn't been set (either explicitly by the user, or from the .Ev FTPSERVER environment variable). If .Ar host is given, then gate-ftp mode will be enabled, and the gate-ftp server will be set to .Ar host . If .Ar port is also given, that will be used as the port to connect to on the gate-ftp server. .It Ic glob Toggle filename expansion for .Ic mdelete , .Ic mget and .Ic mput . If globbing is turned off with .Ic glob , the file name arguments are taken literally and not expanded. Globbing for .Ic mput is done as in .Xr csh 1 . For .Ic mdelete and .Ic mget , each remote file name is expanded separately on the remote machine and the lists are not merged. Expansion of a directory name is likely to be different from expansion of the name of an ordinary file: the exact result depends on the foreign operating system and ftp server, and can be previewed by doing .Ql mls remote-files \- Note: .Ic mget and .Ic mput are not meant to transfer entire directory subtrees of files. That can be done by transferring a .Xr tar 1 archive of the subtree (in binary mode). .It Ic hash Op Ar size Toggle hash-sign (``#'') printing for each data block transferred. The size of a data block defaults to 1024 bytes. This can be changed by specifying .Ar size in bytes. .It Ic help Op Ar command Print an informative message about the meaning of .Ar command . If no argument is given, .Nm prints a list of the known commands. .It Ic idle Op Ar seconds Set the inactivity timer on the remote server to .Ar seconds seconds. If .Ar seconds is omitted, the current inactivity timer is printed. .It Ic lcd Op Ar directory Change the working directory on the local machine. If no .Ar directory is specified, the user's home directory is used. .It Ic less Ar file A synonym for .Ic page . .It Ic lpwd Print the working directory on the local machine. .It Ic \&ls Op Ar remote-directory Op Ar local-file A synonym for .Ic dir . .It Ic macdef Ar macro-name Define a macro. Subsequent lines are stored as the macro .Ar macro-name ; a null line (consecutive newline characters in a file or carriage returns from the terminal) terminates macro input mode. There is a limit of 16 macros and 4096 total characters in all defined macros. Macros remain defined until a .Ic close command is executed. The macro processor interprets `$' and `\e' as special characters. A `$' followed by a number (or numbers) is replaced by the corresponding argument on the macro invocation command line. A `$' followed by an `i' signals that macro processor that the executing macro is to be looped. On the first pass `$i' is replaced by the first argument on the macro invocation command line, on the second pass it is replaced by the second argument, and so on. A `\e' followed by any character is replaced by that character. Use the `\e' to prevent special treatment of the `$'. .It Ic mdelete Op Ar remote-files Delete the .Ar remote-files on the remote machine. .It Ic mdir Ar remote-files local-file Like .Ic dir , except multiple remote files may be specified. If interactive prompting is on, .Nm will prompt the user to verify that the last argument is indeed the target local file for receiving .Ic mdir output. .It Ic mget Ar remote-files Expand the .Ar remote-files on the remote machine and do a .Ic get for each file name thus produced. See .Ic glob for details on the filename expansion. Resulting file names will then be processed according to .Ic case , .Ic ntrans and .Ic nmap settings. Files are transferred into the local working directory, which can be changed with .Ql lcd directory ; new local directories can be created with .Ql "\&! mkdir directory" . .It Ic mkdir Ar directory-name Make a directory on the remote machine. .It Ic mls Ar remote-files local-file Like .Ic ls , except multiple remote files may be specified, and the .Ar local-file must be specified. If interactive prompting is on, .Nm will prompt the user to verify that the last argument is indeed the target local file for receiving .Ic mls output. .It Ic mode Op Ar mode-name Set the file transfer .Ic mode to .Ar mode-name . The default mode is \*(Lqstream\*(Rq mode. .It Ic modtime Ar file-name Show the last modification time of the file on the remote machine. .It Ic more Ar file A synonym for .Ic page . .It Ic mput Ar local-files Expand wild cards in the list of local files given as arguments and do a .Ic put for each file in the resulting list. See .Ic glob for details of filename expansion. Resulting file names will then be processed according to .Ic ntrans and .Ic nmap settings. .It Ic msend Ar local-files A synonym for .Ic mput . .It Ic newer Ar file-name Get the file only if the modification time of the remote file is more recent that the file on the current system. If the file does not exist on the current system, the remote file is considered .Ic newer . Otherwise, this command is identical to .Ar get . .It Ic nlist Op Ar remote-directory Op Ar local-file Print a list of the files in a directory on the remote machine. If .Ar remote-directory is left unspecified, the current working directory is used. If interactive prompting is on, .Nm will prompt the user to verify that the last argument is indeed the target local file for receiving .Ic ls output. If no local file is specified, or if .Ar local-file is .Fl , the output is sent to the terminal. .Pp Note that this command only returns the filenames in the remote directory. If you wish to see more information about the files (often size, modification time, and so on), you should use the .Ic dir command instead. .It Ic nmap Op Ar inpattern outpattern Set or unset the filename mapping mechanism. If no arguments are specified, the filename mapping mechanism is unset. If arguments are specified, remote filenames are mapped during .Ic mput commands and .Ic put commands issued without a specified remote target filename. If arguments are specified, local filenames are mapped during .Ic mget commands and .Ic get commands issued without a specified local target filename. This command is useful when connecting to a .No non\- Ns Ux remote computer with different file naming conventions or practices. The mapping follows the pattern set by .Ar inpattern and .Ar outpattern . .Op Ar Inpattern is a template for incoming filenames (which may have already been processed according to the .Ic ntrans and .Ic case settings). Variable templating is accomplished by including the sequences `$1', `$2', ..., `$9' in .Ar inpattern . Use `\\' to prevent this special treatment of the `$' character. All other characters are treated literally, and are used to determine the .Ic nmap .Op Ar inpattern variable values. For example, given .Ar inpattern $1.$2 and the remote file name "mydata.data", $1 would have the value "mydata", and $2 would have the value "data". The .Ar outpattern determines the resulting mapped filename. The sequences `$1', `$2', ...., `$9' are replaced by any value resulting from the .Ar inpattern template. The sequence `$0' is replace by the original filename. Additionally, the sequence .Ql Op Ar seq1 , Ar seq2 is replaced by .Op Ar seq1 if .Ar seq1 is not a null string; otherwise it is replaced by .Ar seq2 . For example, the command .Pp .Bd -literal -offset indent -compact nmap $1.$2.$3 [$1,$2].[$2,file] .Ed .Pp would yield the output filename "myfile.data" for input filenames "myfile.data" and "myfile.data.old", "myfile.file" for the input filename "myfile", and "myfile.myfile" for the input filename ".myfile". Spaces may be included in .Ar outpattern , as in the example: `nmap $1 sed "s/ *$//" > $1' . Use the `\e' character to prevent special treatment of the `$','[',']' and `,' characters. .It Ic ntrans Op Ar inchars Op Ar outchars Set or unset the filename character translation mechanism. If no arguments are specified, the filename character translation mechanism is unset. If arguments are specified, characters in remote filenames are translated during .Ic mput commands and .Ic put commands issued without a specified remote target filename. If arguments are specified, characters in local filenames are translated during .Ic mget commands and .Ic get commands issued without a specified local target filename. This command is useful when connecting to a .No non\- Ns Ux remote computer with different file naming conventions or practices. Characters in a filename matching a character in .Ar inchars are replaced with the corresponding character in .Ar outchars . If the character's position in .Ar inchars is longer than the length of .Ar outchars , the character is deleted from the file name. .It Ic open Ar host Op Ar port Establish a connection to the specified .Ar host .Tn FTP server. An optional port number may be supplied, in which case, .Nm will attempt to contact an .Tn FTP server at that port. If the .Ic auto-login option is on (default), .Nm will also attempt to automatically log the user in to the .Tn FTP server (see below). .It Ic page Ar file Retrieve .Ic file and display with the program defined in .Ev PAGER (which defaults to .Xr more 1 ) . .It Ic passive Toggle passive mode. If passive mode is turned on (default is off), the ftp client will send a .Dv PASV command for all data connections instead of the usual .Dv PORT command. The .Dv PASV command requests that the remote server open a port for the data connection and return the address of that port. The remote server listens on that port and the client connects to it. When using the more traditional .Dv PORT command, the client listens on a port and sends that address to the remote server, who connects back to it. Passive mode is useful when using .Nm through a gateway router or host that controls the directionality of traffic. (Note that though ftp servers are required to support the .Dv PASV command by RFC 1123, some do not. Please note that if you are connecting to IPv6 ftp server, the program will use .Dv EPSV/EPRT pair and .Dv LPSV/LPRT pair, instead of .Dv PASV and .Dv PORT . The meaning is the same.) .It Ic preserve Toggle preservation of modification times on retrieved files. .It Ic progress Toggle display of transfer progress bar. The progress bar will be disabled for a transfer that has .Ar local-file as .Sq Fl or a command that starts with .Sq \&| . Refer to .Sx FILE NAMING CONVENTIONS for more information. .It Ic prompt Toggle interactive prompting. Interactive prompting occurs during multiple file transfers to allow the user to selectively retrieve or store files. If prompting is turned off (default is on), any .Ic mget or .Ic mput will transfer all files, and any .Ic mdelete will delete all files. .Pp When prompting is on, the following commands are available at a prompt: .Bl -tag -width 2n -offset indent .It Ic n Do not transfer the file. .It Ic a Answer .Sq yes to the current file, and automatically answer .Sq yes to any remaining files for the current command. .It Ic p Answer .Sq yes to the current file, and turn off prompt mode (as if .Dq prompt off had been given). .El .Pp Any other reponse will answer .Sq yes to the current file. .It Ic proxy Ar ftp-command Execute an ftp command on a secondary control connection. This command allows simultaneous connection to two remote ftp servers for transferring files between the two servers. The first .Ic proxy command should be an .Ic open , to establish the secondary control connection. Enter the command "proxy ?" to see other ftp commands executable on the secondary connection. The following commands behave differently when prefaced by .Ic proxy : .Ic open will not define new macros during the auto-login process, .Ic close will not erase existing macro definitions, .Ic get and .Ic mget transfer files from the host on the primary control connection to the host on the secondary control connection, and .Ic put , .Ic mput and .Ic append transfer files from the host on the secondary control connection to the host on the primary control connection. Third party file transfers depend upon support of the ftp protocol .Dv PASV command by the server on the secondary control connection. .It Ic put Ar local-file Op Ar remote-file Store a local file on the remote machine. If .Ar remote-file is left unspecified, the local file name is used after processing according to any .Ic ntrans or .Ic nmap settings in naming the remote file. File transfer uses the current settings for .Ic type , .Ic format , .Ic mode and .Ic structure . .It Ic pwd Print the name of the current working directory on the remote machine. .It Ic quit A synonym for .Ic bye . .It Ic quote Ar arg1 arg2 ... The arguments specified are sent, verbatim, to the remote .Tn FTP server. .It Ic recv Ar remote-file Op Ar local-file A synonym for .Ic get . .It Ic reget Ar remote-file Op Ar local-file Reget acts like get, except that if .Ar local-file exists and is smaller than .Ar remote-file , .Ar local-file is presumed to be a partially transferred copy of .Ar remote-file and the transfer is continued from the apparent point of failure. This command is useful when transferring very large files over networks that are prone to dropping connections. .It Ic remotehelp Op Ar command-name Request help from the remote .Tn FTP server. If a .Ar command-name is specified it is supplied to the server as well. .It Ic rstatus Op Ar file-name With no arguments, show status of remote machine. If .Ar file-name is specified, show status of .Ar file-name on remote machine. .It Ic rename Op Ar from Op Ar to Rename the file .Ar from on the remote machine, to the file .Ar to . .It Ic reset Clear reply queue. This command re-synchronizes command/reply sequencing with the remote ftp server. Resynchronization may be necessary following a violation of the ftp protocol by the remote server. .It Ic restart Ar marker Restart the immediately following .Ic get or .Ic put at the indicated .Ar marker . On .Ux systems, marker is usually a byte offset into the file. .It Ic restrict Toggle data port range restrictions. When not operating in passive mode, the .Nm client program requests that the remote server open a connection back to the client host on a separate data port. In previous versions, that remote port fell in the range 1024..4999. However, most firewall setups filter that range of TCP ports because other services reside there. The default behavior now is for the client to request that the server connect back to the client using the port range 49152..65535. Firewall administrators can chose to allow TCP connections in that range, if they deem it to not be a security risk. .It Ic rmdir Ar directory-name Delete a directory on the remote machine. .It Ic runique Toggle storing of files on the local system with unique filenames. If a file already exists with a name equal to the target local filename for a .Ic get or .Ic mget command, a ".1" is appended to the name. If the resulting name matches another existing file, a ".2" is appended to the original name. If this process continues up to ".99", an error message is printed, and the transfer does not take place. The generated unique filename will be reported. Note that .Ic runique will not affect local files generated from a shell command (see below). The default value is off. .It Ic send Ar local-file Op Ar remote-file A synonym for .Ic put . .It Ic sendport Toggle the use of .Dv PORT commands. By default, .Nm will attempt to use a .Dv PORT command when establishing a connection for each data transfer. The use of .Dv PORT commands can prevent delays when performing multiple file transfers. If the .Dv PORT command fails, .Nm will use the default data port. When the use of .Dv PORT commands is disabled, no attempt will be made to use .Dv PORT commands for each data transfer. This is useful for certain .Tn FTP implementations which do ignore .Dv PORT commands but, incorrectly, indicate they've been accepted. .It Ic site Ar arg1 arg2 ... The arguments specified are sent, verbatim, to the remote .Tn FTP server as a .Dv SITE command. .It Ic size Ar file-name Return size of .Ar file-name on remote machine. .It Ic status Show the current status of .Nm . .It Ic struct Op Ar struct-name Set the file transfer .Ar structure to .Ar struct-name . By default \*(Lqstream\*(Rq structure is used. .It Ic sunique Toggle storing of files on remote machine under unique file names. Remote ftp server must support ftp protocol .Dv STOU command for successful completion. The remote server will report unique name. Default value is off. .It Ic system Show the type of operating system running on the remote machine. .It Ic tenex Set the file transfer type to that needed to talk to .Tn TENEX machines. .It Ic trace Toggle packet tracing. .It Ic type Op Ar type-name Set the file transfer .Ic type to .Ar type-name . If no type is specified, the current type is printed. The default type is network .Tn ASCII . .It Ic umask Op Ar newmask Set the default umask on the remote server to .Ar newmask . If .Ar newmask is omitted, the current umask is printed. .It Xo .Ic user Ar user-name .Op Ar password Op Ar account .Xc Identify yourself to the remote .Tn FTP server. If the .Ar password is not specified and the server requires it, .Nm will prompt the user for it (after disabling local echo). If an .Ar account field is not specified, and the .Tn FTP server requires it, the user will be prompted for it. If an .Ar account field is specified, an account command will be relayed to the remote server after the login sequence is completed if the remote server did not require it for logging in. Unless .Nm is invoked with \*(Lqauto-login\*(Rq disabled, this process is done automatically on initial connection to the .Tn FTP server. .It Ic verbose Toggle verbose mode. In verbose mode, all responses from the .Tn FTP server are displayed to the user. In addition, if verbose is on, when a file transfer completes, statistics regarding the efficiency of the transfer are reported. By default, verbose is on. .It Ic \&? Op Ar command A synonym for .Ic help . .El .Pp Command arguments which have embedded spaces may be quoted with quote `"' marks. .Pp Commands which toggle settings can take an explicit .Ic on or .Ic off argument to force the setting appropriately. .Pp If .Nm receives a .Dv SIGINFO (see the .Dq status argument of .Xr stty 1 ) signal whilst a transfer is in progress, the current transfer rate statistics will be written to the standard error output, in the same format as the standard completion message. .Sh AUTO-FETCHING FILES In addition to standard commands, this version of .Nm supports an auto-fetch feature. To enable auto-fetch, simply pass the list of hostnames/files on the command line. .Pp The following formats are valid syntax for an auto-fetch element: .Bl -tag -width "host:/file" .It host:/file .Dq Classic ftp format .It ftp://[user:password@]host[:port]/file An ftp URL, retrieved using the ftp protocol if .Ev ftp_proxy isn't defined. Otherwise, transfer using http via the proxy defined in .Ev ftp_proxy . If .Ar user:password@ is given and .Ev ftp_proxy isn't defined, login as .Ar user with a password of .Ar password . .It http://host[:port]/file An HTTP URL, retrieved using the http protocol. If .Ev http_proxy is defined, it is used as a URL to an HTTP proxy server. .El .Pp If a classic format or a ftp URL format has a trailing .Sq / , then .Nm will connect to the site and .Ic cd to the directory given as the path, and leave the user in interactive mode ready for further input. .Pp If successive auto-fetch ftp elements refer to the same host, then the connection is maintained between transfers, reducing overhead on connection creation and deletion. .Pp If .Ic file contains a glob character and globbing is enabled, (see .Ic glob ) , then the equivalent of .Ic "mget file" is performed. .Pp If the directory component of .Ic file contains no globbing characters, it is stored in the current directory as the .Xr basename 1 of .Ic file . Otherwise, the remote name is used as the local name. .Sh ABORTING A FILE TRANSFER To abort a file transfer, use the terminal interrupt key (usually Ctrl-C). Sending transfers will be immediately halted. Receiving transfers will be halted by sending a ftp protocol .Dv ABOR command to the remote server, and discarding any further data received. The speed at which this is accomplished depends upon the remote server's support for .Dv ABOR processing. If the remote server does not support the .Dv ABOR command, an .Ql ftp> prompt will not appear until the remote server has completed sending the requested file. .Pp The terminal interrupt key sequence will be ignored when .Nm has completed any local processing and is awaiting a reply from the remote server. A long delay in this mode may result from the ABOR processing described above, or from unexpected behavior by the remote server, including violations of the ftp protocol. If the delay results from unexpected remote server behavior, the local .Nm program must be killed by hand. .Sh FILE NAMING CONVENTIONS Files specified as arguments to .Nm commands are processed according to the following rules. .Bl -enum .It If the file name .Sq Fl is specified, the .Ar stdin (for reading) or .Ar stdout (for writing) is used. .It If the first character of the file name is .Sq \&| , the remainder of the argument is interpreted as a shell command. .Nm then forks a shell, using .Xr popen 3 with the argument supplied, and reads (writes) from the stdin (stdout). If the shell command includes spaces, the argument must be quoted; e.g. \*(Lq" ls -lt"\*(Rq. A particularly useful example of this mechanism is: \*(Lqdir \&|more\*(Rq. .It Failing the above checks, if .Dq globbing is enabled, local file names are expanded according to the rules used in the .Xr csh 1 ; c.f. the .Ic glob command. If the .Nm command expects a single local file (e.g. .Ic put ) , only the first filename generated by the "globbing" operation is used. .It For .Ic mget commands and .Ic get commands with unspecified local file names, the local filename is the remote filename, which may be altered by a .Ic case , .Ic ntrans , or .Ic nmap setting. The resulting filename may then be altered if .Ic runique is on. .It For .Ic mput commands and .Ic put commands with unspecified remote file names, the remote filename is the local filename, which may be altered by a .Ic ntrans or .Ic nmap setting. The resulting filename may then be altered by the remote server if .Ic sunique is on. .El .Sh FILE TRANSFER PARAMETERS The FTP specification specifies many parameters which may affect a file transfer. The .Ic type may be one of \*(Lqascii\*(Rq, \*(Lqimage\*(Rq (binary), \*(Lqebcdic\*(Rq and \*(Lqlocal byte size\*(Rq (for .Tn PDP Ns -10's and .Tn PDP Ns -20's mostly). .Nm supports the ascii and image types of file transfer, plus local byte size 8 for .Ic tenex mode transfers. .Pp .Nm supports only the default values for the remaining file transfer parameters: .Ic mode , .Ic form and .Ic struct . .Sh THE .netrc FILE The .Pa .netrc file contains login and initialization information used by the auto-login process. It resides in the user's home directory. The following tokens are recognized; they may be separated by spaces, tabs, or new-lines: .Bl -tag -width password .It Ic machine Ar name Identify a remote machine .Ar name . The auto-login process searches the .Pa .netrc file for a .Ic machine token that matches the remote machine specified on the .Nm command line or as an .Ic open command argument. Once a match is made, the subsequent .Pa .netrc tokens are processed, stopping when the end of file is reached or another .Ic machine or a .Ic default token is encountered. .It Ic default This is the same as .Ic machine .Ar name except that .Ic default matches any name. There can be only one .Ic default token, and it must be after all .Ic machine tokens. This is normally used as: .Pp .Dl default login anonymous password user@site .Pp thereby giving the user .Ar automatic anonymous ftp login to machines not specified in .Pa .netrc . This can be overridden by using the .Fl n flag to disable auto-login. .It Ic login Ar name Identify a user on the remote machine. If this token is present, the auto-login process will initiate a login using the specified .Ar name . .It Ic password Ar string Supply a password. If this token is present, the auto-login process will supply the specified string if the remote server requires a password as part of the login process. Note that if this token is present in the .Pa .netrc file for any user other than .Ar anonymous , .Nm will abort the auto-login process if the .Pa .netrc is readable by anyone besides the user. .It Ic account Ar string Supply an additional account password. If this token is present, the auto-login process will supply the specified string if the remote server requires an additional account password, or the auto-login process will initiate an .Dv ACCT command if it does not. .It Ic macdef Ar name Define a macro. This token functions like the .Nm .Ic macdef command functions. A macro is defined with the specified name; its contents begin with the next .Pa .netrc line and continue until a null line (consecutive new-line characters) is encountered. If a macro named .Ic init is defined, it is automatically executed as the last step in the auto-login process. .El .Sh COMMAND LINE EDITING .Nm supports interactive command line editing, via the .Xr editline 3 library. It is enabled with the .Ic edit command, and is enabled by default if input is from a tty. Previous lines can be recalled and edited with the arrow keys, and other GNU Emacs-style editing keys may be used as well. .Pp The .Xr editline 3 library is configured with a .Pa .editrc file - refer to .Xr editrc 5 for more information. .Pp An extra key binding is available to .Nm to provide context sensitive command and filename completion (including remote file completion). To use this, bind a key to the .Xr editline 3 command .Ic ftp-complete . By default, this is bound to the TAB key. .Sh ENVIRONMENT .Nm utilizes the following environment variables. .Bl -tag -width "FTP_PASSIVE_MODE" .It Ev FTP_PASSIVE_MODE If this variable is set to something else than .Sq NO , .Nm will use passive mode by default. .It Ev FTPSERVER Host to use as gate-ftp server when .Ic gate is enabled. .It Ev FTPSERVERPORT Port to use when connecting to gate-ftp server when .Ic gate is enabled. Default is port returned by a .Fn getservbyname lookup of .Dq ftpgate/tcp . .It Ev HOME For default location of a .Pa .netrc file, if one exists. .It Ev PAGER Used by .Ic page to display files. .It Ev SHELL For default shell. .It Ev ftp_proxy URL of FTP proxy to use when making FTP URL requests (if not defined, use the standard ftp protocol). .It Ev http_proxy URL of HTTP proxy to use when making HTTP URL requests. .El .Sh SEE ALSO .Xr getservbyname 3 , .Xr editrc 5 , .Xr services 5 , .Xr ftpd 8 .Sh NOTES The .Xr pftp 1 and .Xr gate-ftp 1 commands are links to .Nm . .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Pp Various features such as command line editing, context sensitive command and file completion, dynamic progress bar, automatic fetching of files, ftp and http URLs, and modification time preservation were implemented in .Nx 1.3 by Luke Mewburn, with assistance from Jason Thorpe. .Pp IPv6 support was added by WIDE/KAME Project. .Sh BUGS Correct execution of many commands depends upon proper behavior by the remote server. .Pp An error in the treatment of carriage returns in the .Bx 4.2 ascii-mode transfer code has been corrected. This correction may result in incorrect transfers of binary files to and from .Bx 4.2 servers using the ascii type. Avoid this problem by using the binary image type. .Pp Proxying functionalities, such as .Ev ftp_proxy , may not work for IPv6 connection. Index: head/usr.bin/gcore/gcore.1 =================================================================== --- head/usr.bin/gcore/gcore.1 (revision 79534) +++ head/usr.bin/gcore/gcore.1 (revision 79535) @@ -1,98 +1,98 @@ .\" Copyright (c) 1983, 1990, 1992, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)gcore.1 8.2 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" .Dd April 18, 1994 .Dt GCORE 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm gcore .Nd get core images of running process .Sh SYNOPSIS .Nm .Op Fl s .Op Fl c Ar core .Op Ar exec .Ar pid .Sh DESCRIPTION .Nm Gcore creates a core image of the specified process, suitable for use with .Xr gdb 1 . By default, the core is written to the file .Dq Pa core. . The process identifier, .Ar pid , must be given on the command line. If no executable image is specified, .Nm will use .Dq Pa /proc//file . .Pp The options are: .Bl -tag -width indent .It Fl c Write the core file to the specified file instead of .Dq Pa core. . .It Fl s Stop the process while gathering the core image, and resume it when done. This guarantees that the resulting core dump will be in a consistent state. The process is resumed even if it was already stopped. The same effect can be achieved manually with .Xr kill 1 . .El .Sh FILES .Bl -tag -width /var/log/messages -compact .It Pa core. The core image. .It Pa /proc//file The executable image. .El .Sh HISTORY .Nm Gcore appeared in .Bx 4.2 . .Sh BUGS Context switches or paging activity that occur while .Nm is running may cause the program to become confused. For best results, use .Fl s to temporarily stop the target process. .Pp .Nm Gcore is not compatible with the original .Bx 4.2 version. Index: head/usr.bin/gprof/gprof.1 =================================================================== --- head/usr.bin/gprof/gprof.1 (revision 79534) +++ head/usr.bin/gprof/gprof.1 (revision 79535) @@ -1,300 +1,300 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)gprof.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt GPROF 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm gprof .Nd display call graph profile data .Sh SYNOPSIS .Nm .Op options .Op Ar a.out Op Ar a.out.gmon ... .Sh DESCRIPTION .Nm Gprof produces an execution profile of C, Pascal, or Fortran77 programs. The effect of called routines is incorporated in the profile of each caller. The profile data is taken from the call graph profile file which is created by programs that are compiled with the .Fl pg option of .Xr cc 1 , .Xr pc 1 , and .Xr f77 1 . The .Fl pg option also links in versions of the library routines that are compiled for profiling. .Nm Gprof reads the given object file (the default is .Pa a.out) and establishes the relation between its symbol table and the call graph profile. The default graph profile file name is the name of the executable with the suffix .Pa .gmon appended. If more than one profile file is specified, the .Nm output shows the sum of the profile information in the given profile files. .Pp .Nm Gprof calculates the amount of time spent in each routine. Next, these times are propagated along the edges of the call graph. Cycles are discovered, and calls into a cycle are made to share the time of the cycle. The first listing shows the functions sorted according to the time they represent including the time of their call graph descendents. Below each function entry is shown its (direct) call graph children, and how their times are propagated to this function. A similar display above the function shows how this function's time and the time of its descendents is propagated to its (direct) call graph parents. .Pp Cycles are also shown, with an entry for the cycle as a whole and a listing of the members of the cycle and their contributions to the time and call counts of the cycle. .Pp Second, a flat profile is given, similar to that provided by .Xr prof 1 . This listing gives the total execution times, the call counts, the time in msec or usec the call spent in the routine itself, and the time in msec or usec the call spent in the routine itself including its descendents. .Pp Finally, an index of the function names is provided. .Pp The following options are available: .Bl -tag -width Fl .It Fl a Suppresses the printing of statically declared functions. If this option is given, all relevant information about the static function (e.g., time samples, calls to other functions, calls from other functions) belongs to the function loaded just before the static function in the .Pa a.out file. .It Fl b Suppresses the printing of a description of each field in the profile. .It Fl c The static call graph of the program is discovered by a heuristic that examines the text space of the object file. Static-only parents or children are shown with call counts of 0. This option is not supported on some architectures. .It Fl C Ar count Find a minimal set of arcs that can be broken to eliminate all cycles with .Ar count or more members. Caution: the algorithm used to break cycles is exponential, so using this option may cause .Nm to run for a very long time. .It Fl e Ar name Suppresses the printing of the graph profile entry for routine .Ar name and all its descendants (unless they have other ancestors that aren't suppressed). More than one .Fl e option may be given. Only one .Ar name may be given with each .Fl e option. .It Fl E Ar name Suppresses the printing of the graph profile entry for routine .Ar name (and its descendants) as .Fl e , above, and also excludes the time spent in .Ar name (and its descendants) from the total and percentage time computations. (For example, .Fl E .Ar mcount .Fl E .Ar mcleanup is the default.) .It Fl f Ar name Prints the graph profile entry of only the specified routine .Ar name and its descendants. More than one .Fl f option may be given. Only one .Ar name may be given with each .Fl f option. .It Fl F Ar name Prints the graph profile entry of only the routine .Ar name and its descendants (as .Fl f , above) and also uses only the times of the printed routines in total time and percentage computations. More than one .Fl F option may be given. Only one .Ar name may be given with each .Fl F option. The .Fl F option overrides the .Fl E option. .It Fl k Ar fromname Ar toname Will delete any arcs from routine .Ar fromname to routine .Ar toname . This can be used to break undesired cycles. More than one .Fl k option may be given. Only one pair of routine names may be given with each .Fl k option. .It Fl l Suppresses the printing of the call-graph profile. .It Fl L Suppresses the printing of the flat profile. .It Fl s A profile file .Pa gmon.sum is produced that represents the sum of the profile information in all the specified profile files. This summary profile file may be given to later executions of gprof (probably also with a .Fl s ) to accumulate profile data across several runs of an .Pa a.out file. .It Fl u Suppresses the printing of functions whose names are not visible to C programs. For the ELF object format, this means names that contain the .Ql .\& character. For the a.out object format, it means names that do not begin with a .Ql _ character. All relevant information about such functions belongs to the (non-suppressed) function with the next lowest address. This is useful for eliminating "functions" that are just labels inside other functions. .It Fl z Displays routines that have zero usage (as shown by call counts and accumulated time). This is useful with the .Fl c option for discovering which routines were never called. .El .Sh FILES .Bl -tag -width a.out.gmon -compact .It Pa a.out The namelist and text space. .It Pa a.out.gmon Dynamic call graph and profile. .It Pa gmon.sum Summarized dynamic call graph and profile. .El .Sh SEE ALSO .Xr cc 1 , .Xr profil 2 , .Xr clocks 7 .\" .Xr monitor 3 , .\" .Xr prof 1 .Rs .%T "An Execution Profiler for Modular Programs" .%A S. Graham .%A P. Kessler .%A M. McKusick .%J "Software - Practice and Experience" .%V 13 .%P pp. 671-685 .%D 1983 .Re .Rs .%T "gprof: A Call Graph Execution Profiler" .%A S. Graham .%A P. Kessler .%A M. McKusick .%J "Proceedings of the SIGPLAN '82 Symposium on Compiler Construction, SIGPLAN Notices" .%V 17 .%N 6 .%P pp. 120-126 .%D June 1982 .Re .Sh HISTORY The .Nm profiler appeared in .Bx 4.2 . .Sh BUGS The granularity of the sampling is shown, but remains statistical at best. We assume that the time for each execution of a function can be expressed by the total time for the function divided by the number of times the function is called. Thus the time propagated along the call graph arcs to the function's parents is directly proportional to the number of times that arc is traversed. .Pp Parents that are not themselves profiled will have the time of their profiled children propagated to them, but they will appear to be spontaneously invoked in the call graph listing, and will not have their time propagated further. Similarly, signal catchers, even though profiled, will appear to be spontaneous (although for more obscure reasons). Any profiled children of signal catchers should have their times propagated properly, unless the signal catcher was invoked during the execution of the profiling routine, in which case all is lost. .Pp The profiled program must call .Xr exit 3 or return normally for the profiling information to be saved in the graph profile file. Index: head/usr.bin/head/head.1 =================================================================== --- head/usr.bin/head/head.1 (revision 79534) +++ head/usr.bin/head/head.1 (revision 79535) @@ -1,73 +1,73 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)head.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt HEAD 1 -.Os BSD 3 +.Os .Sh NAME .Nm head .Nd display first lines of a file .Sh SYNOPSIS .Nm .Op Fl n Ar count .Op Fl c Ar bytes .Op Ar .Sh DESCRIPTION This filter displays the first .Ar count lines or .Ar bytes of each of the specified files, or of the standard input if no files are specified. If .Ar count is omitted it defaults to 10. .Pp If more than a single file is specified, each file is preceded by a header consisting of the string .Dq ==> XXX <== where .Dq XXX is the name of the file. .Pp The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh SEE ALSO .Xr tail 1 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/id/id.1 =================================================================== --- head/usr.bin/id/id.1 (revision 79534) +++ head/usr.bin/id/id.1 (revision 79535) @@ -1,151 +1,151 @@ .\" Copyright (c) 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" the Institute of Electrical and Electronics Engineers, Inc. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)id.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt ID 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm id .Nd return user identity .Sh SYNOPSIS .Nm .Op Ar user .Nm .Fl G Op Fl n .Op Ar user .Nm .Fl P .Op Ar user .Nm .Fl g Op Fl nr .Op Ar user .Nm .Fl p .Op Ar user .Nm .Fl u Op Fl nr .Op Ar user .Sh DESCRIPTION The .Nm utility displays the user and group names and numeric IDs, of the calling process, to the standard output. If the real and effective IDs are different, both are displayed, otherwise only the real ID is displayed. .Pp If a .Ar user (login name or user ID) is specified, the user and group IDs of that user are displayed. In this case, the real and effective IDs are assumed to be the same. .Pp The options are as follows: .Bl -tag -width indent .It Fl G Display the different group IDs (effective, real and supplementary) as white-space separated numbers, in no particular order. .It Fl P Display the id as a password file entry. .It Fl g Display the effective group ID as a number. .It Fl n Display the name of the user or group ID for the .Fl G , .Fl g and .Fl u options instead of the number. If any of the ID numbers cannot be mapped into names, the number will be displayed as usual. .It Fl p Make the output human-readable. If the user name returned by .Xr getlogin 2 is different from the login name referenced by the user ID, the name returned by .Xr getlogin 2 is displayed, preceded by the keyword .Dq login . The user ID as a name is displayed, preceded by the keyword .Dq uid . If the effective user ID is different from the real user ID, the real user ID is displayed as a name, preceded by the keyword .Dq euid . If the effective group ID is different from the real group ID, the real group ID is displayed as a name, preceded by the keyword .Dq rgid . The list of groups to which the user belongs is then displayed as names, preceded by the keyword .Dq groups . Each display is on a separate line. .It Fl r Display the real ID for the .Fl g and .Fl u options instead of the effective ID. .It Fl u Display the effective user ID as a number. .El .Sh DIAGNOSTICS The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh SEE ALSO .Xr who 1 .Sh STANDARDS The .Nm function is expected to conform to .St -p1003.2 . .Sh HISTORY The historic .Xr groups 1 command is equivalent to .Dq Nm id Fl Gn Op Ar user . .Pp The historic .Xr whoami 1 command is equivalent to .Dq Nm id Fl un . .Pp The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/indent/indent.1 =================================================================== --- head/usr.bin/indent/indent.1 (revision 79534) +++ head/usr.bin/indent/indent.1 (revision 79535) @@ -1,460 +1,460 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" Copyright (c) 1976 Board of Trustees of the University of Illinois. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)indent.1 8.1 (Berkeley) 7/1/93 .\" $FreeBSD$ .\" .Dd July 1, 1993 .Dt INDENT 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm indent .Nd indent and format C program source .Sh SYNOPSIS .Nm .Op Ar input-file Op Ar output-file .Op Fl bad | Fl nbad .Op Fl bap | Fl nbap .Bk -words .Op Fl bbb | Fl nbbb .Ek .Op Fl \&bc | Fl nbc .Op Fl \&bl .Op Fl \&br .Op Fl c Ns Ar n .Op Fl \&cd Ns Ar n .Bk -words .Op Fl cdb | Fl ncdb .Ek .Op Fl \&ce | Fl nce .Op Fl \&ci Ns Ar n .Op Fl cli Ns Ar n .Op Fl d Ns Ar n .Op Fl \&di Ns Ar n .Bk -words .Op Fl fc1 | Fl nfc1 .Op Fl fcb | Fl nfcb .Ek .Op Fl i Ns Ar n .Op Fl \&ip | Fl nip .Op Fl l Ns Ar n .Op Fl \&lc Ns Ar n .Op Fl \&lp | Fl nlp .Op Fl npro .Op Fl pcs | Fl npcs .Op Fl psl | Fl npsl .Op Fl \&sc | Fl nsc .Bk -words .Op Fl sob | Fl nsob .Ek .Op Fl \&st .Op Fl troff .Op Fl v | Fl \&nv .Sh DESCRIPTION .Nm Indent is a .Ar C program formatter. It reformats the .Ar C program in the .Ar input-file according to the switches. The switches which can be specified are described below. They may appear before or after the file names. .Pp .Sy NOTE : If you only specify an .Ar input-file , the formatting is done `in-place', that is, the formatted file is written back into .Ar input-file and a backup copy of .Ar input-file is written in the current directory. If .Ar input-file is named .Sq Pa /blah/blah/file , the backup file is named .Pa file.BAK . .Pp If .Ar output-file is specified, .Nm checks to make sure it is different from .Ar input-file . .Pp The options listed below control the formatting style imposed by .Nm . .Bl -tag -width Op .It Fl bad , nbad If .Fl bad is specified, a blank line is forced after every block of declarations. Default: .Fl nbad . .It Fl bap , nbap If .Fl bap is specified, a blank line is forced after every procedure body. Default: .Fl nbap . .It Fl bbb , nbbb If .Fl bbb is specified, a blank line is forced before every block comment. Default: .Fl nbbb . .It Fl \&bc , nbc If .Fl \&bc is specified, then a newline is forced after each comma in a declaration. .Fl nbc turns off this option. Default: .Fl \&nbc . .It Fl \&br , \&bl Specifying .Fl \&bl lines-up compound statements like this: .Bd -literal -offset indent if (...) { code } .Ed .Pp Specifying .Fl \&br (the default) makes them look like this: .Bd -literal -offset indent if (...) { code } .Ed .Pp .It Fl c Ns Ar n The column in which comments on code start. The default is 33. .It Fl cd Ns Ar n The column in which comments on declarations start. The default is for these comments to start in the same column as those on code. .It Fl cdb , ncdb Enables (disables) the placement of comment delimiters on blank lines. With this option enabled, comments look like this: .Bd -literal -offset indent /* * this is a comment */ .Ed .Pp Rather than like this: .Bd -literal -offset indent /* this is a comment */ .Ed .Pp This only affects block comments, not comments to the right of code. The default is .Fl cdb . .It Fl ce , nce Enables (disables) forcing of `else's to cuddle up to the immediately preceding `}'. The default is .Fl \&ce . .It Fl \&ci Ns Ar n Sets the continuation indent to be .Ar n . Continuation lines will be indented that far from the beginning of the first line of the statement. Parenthesized expressions have extra indentation added to indicate the nesting, unless .Fl \&lp is in effect. .Fl \&ci defaults to the same value as .Fl i . .It Fl cli Ns Ar n Causes case labels to be indented .Ar n tab stops to the right of the containing .Ic switch statement. .Fl cli0.5 causes case labels to be indented half a tab stop. The default is .Fl cli0 . .It Fl d Ns Ar n Controls the placement of comments which are not to the right of code. For example, .Fl \&d\&1 means that such comments are placed one indentation level to the left of code. Specifying the default .Fl \&d\&0 lines-up these comments with the code. See the section on comment indentation below. .It Fl \&di Ns Ar n Specifies the indentation, in character positions, from a declaration keyword to the following identifier. The default is .Fl di16 . .It Fl dj , ndj .Fl \&dj left justifies declarations. .Fl ndj indents declarations the same as code. The default is .Fl ndj . .It Fl \&ei , nei Enables (disables) special .Ic else-if processing. If it's enabled, an .Ic if following an .Ic else will have the same indentation as the preceding .Ic \&if statement. The default is .Fl ei . .It Fl fc1 , nfc1 Enables (disables) the formatting of comments that start in column 1. Often, comments whose leading `/' is in column 1 have been carefully hand formatted by the programmer. In such cases, .Fl nfc1 should be used. The default is .Fl fc1 . .It Fl fcb , nfcb Enables (disables) the formatting of block comments (ones that begin with `/*\\n'). Often, block comments have been not so carefully hand formatted by the programmer, but reformatting that would just change the line breaks is not wanted. In such cases, .Fl nfcb should be used. Block comments are then handled like box comments. The default is .Fl fcb . .It Fl i Ns Ar n The number of spaces for one indentation level. The default is 8. .It Fl \&ip , nip Enables (disables) the indentation of parameter declarations from the left margin. The default is .Fl \&ip . .It Fl l Ns Ar n Maximum length of an output line. The default is 78. .It Fl \&lp , nlp Lines-up code surrounded by parenthesis in continuation lines. If a line has a left paren which is not closed on that line, then continuation lines will be lined up to start at the character position just after the left paren. For example, here is how a piece of continued code looks with .Fl nlp in effect: .Bd -literal -offset indent p1 = first_procedure(second_procedure(p2, p3), \ \ third_procedure(p4, p5)); .Ed .Pp With .Fl lp in effect (the default) the code looks somewhat clearer: .Bd -literal -offset indent p1\ =\ first_procedure(second_procedure(p2,\ p3), \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ third_procedure(p4,\ p5)); .Ed .Pp Inserting two more newlines we get: .Bd -literal -offset indent p1\ =\ first_procedure(second_procedure(p2, \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ p3), \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ third_procedure(p4, \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ p5)); .Ed .It Fl npro Causes the profile files, .Sq Pa ./.indent.pro and .Sq Pa ~/.indent.pro , to be ignored. .It Fl pcs , npcs If true .Pq Fl pcs all procedure calls will have a space inserted between the name and the `('. The default is .Fl npcs . .It Fl psl , npsl If true .Pq Fl psl the names of procedures being defined are placed in column 1 \- their types, if any, will be left on the previous lines. The default is .Fl psl . .It Fl \&sc , nsc Enables (disables) the placement of asterisks (`*'s) at the left edge of all comments. The default is .Fl sc . .It Fl sob , nsob If .Fl sob is specified, indent will swallow optional blank lines. You can use this to get rid of blank lines after declarations. Default: .Fl nsob . .It Fl \&st Causes .Nm to take its input from stdin and put its output to stdout. .It Fl T Ns Ar typename Adds .Ar typename to the list of type keywords. Names accumulate: .Fl T can be specified more than once. You need to specify all the typenames that appear in your program that are defined by .Ic typedef \- nothing will be harmed if you miss a few, but the program won't be formatted as nicely as it should. This sounds like a painful thing to have to do, but it's really a symptom of a problem in C: .Ic typedef causes a syntactic change in the language and .Nm can't find all instances of .Ic typedef . .It Fl troff Causes .Nm to format the program for processing by .Xr troff 1 . It will produce a fancy listing in much the same spirit as .Xr vgrind 1 . If the output file is not specified, the default is standard output, rather than formatting in place. .It Fl v , \&nv .Fl v turns on `verbose' mode; .Fl \&nv turns it off. When in verbose mode, .Nm reports when it splits one line of input into two or more lines of output, and gives some size statistics at completion. The default is .Fl \&nv . .El .Pp You may set up your own `profile' of defaults to .Nm by creating a file called .Pa .indent.pro in your login directory and/or the current directory and including whatever switches you like. A `.indent.pro' in the current directory takes precedence over the one in your login directory. If .Nm is run and a profile file exists, then it is read to set up the program's defaults. Switches on the command line, though, always override profile switches. The switches should be separated by spaces, tabs or newlines. .Pp .Ss Comments .Sq Em Box .Em comments . .Nm Indent assumes that any comment with a dash or star immediately after the start of comment (that is, `/*\-' or `/**') is a comment surrounded by a box of stars. Each line of such a comment is left unchanged, except that its indentation may be adjusted to account for the change in indentation of the first line of the comment. .Pp .Em Straight text . All other comments are treated as straight text. .Nm Indent fits as many words (separated by blanks, tabs, or newlines) on a line as possible. Blank lines break paragraphs. .Pp .Ss Comment indentation If a comment is on a line with code it is started in the `comment column', which is set by the .Fl c Ns Ns Ar n command line parameter. Otherwise, the comment is started at .Ar n indentation levels less than where code is currently being placed, where .Ar n is specified by the .Fl d Ns Ns Ar n command line parameter. If the code on a line extends past the comment column, the comment starts further to the right, and the right margin may be automatically extended in extreme cases. .Pp .Ss Preprocessor lines In general, .Nm leaves preprocessor lines alone. The only reformatting that it will do is to straighten up trailing comments. It leaves embedded comments alone. Conditional compilation .Pq Ic #ifdef...#endif is recognized and .Nm attempts to correctly compensate for the syntactic peculiarities introduced. .Pp .Ss C syntax .Nm Indent understands a substantial amount about the syntax of C, but it has a `forgiving' parser. It attempts to cope with the usual sorts of incomplete and misformed syntax. In particular, the use of macros like: .Pp .Dl #define forever for(;;) .Pp is handled properly. .Sh ENVIRONMENT .Nm Indent uses the .Ev HOME environment variable. .Sh FILES .Bl -tag -width "./.indent.pro" -compact .It Pa ./.indent.pro profile file .It Pa ~/.indent.pro profile file .El .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Sh BUGS .Nm Indent has even more switches than .Xr ls 1 . .Pp A common mistake that often causes grief is typing: .Pp .Dl indent *.c .Pp to the shell in an attempt to indent all the C programs in a directory. This is probably a bug, not a feature. Index: head/usr.bin/kdump/kdump.1 =================================================================== --- head/usr.bin/kdump/kdump.1 (revision 79534) +++ head/usr.bin/kdump/kdump.1 (revision 79535) @@ -1,102 +1,102 @@ .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)kdump.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt KDUMP 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm kdump .Nd display kernel trace data .Sh SYNOPSIS .Nm .Op Fl dnlRT .Op Fl f Ar file .Op Fl m Ar maxdata .Op Fl t Op cnisuw .Sh DESCRIPTION The .Nm command displays the kernel trace files produced with .Xr ktrace 1 in human readable format. By default, the file .Pa ktrace.out in the current directory is displayed. .Pp The options are as follows: .Bl -tag -width Fl .It Fl d Display all numbers in decimal. .It Fl f Ar file Display the specified file instead of .Pa ktrace.out . .It Fl l Loop reading the trace file, once the end-of-file is reached, waiting for more data. .It Fl m Ar maxdata Display at most .Ar maxdata bytes when decoding .Tn I/O . .It Fl n Suppress ad hoc translations. Normally .Nm tries to decode many system calls into a more human readable format. For example, .Xr ioctl 2 values are replaced with the macro name and .Va errno values are replaced with the .Xr strerror 3 string. Suppressing this feature yields a more consistent output format and is easily amenable to further processing. .It Fl R Display relative timestamps (time since previous entry). .It Fl T Display absolute timestamps for each entry (seconds since epoch). .It Fl t Ar cnisuw See the .Fl t option of .Xr ktrace 1 . .El .Sh SEE ALSO .Xr ktrace 1 .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/kenv/kenv.1 =================================================================== --- head/usr.bin/kenv/kenv.1 (revision 79534) +++ head/usr.bin/kenv/kenv.1 (revision 79535) @@ -1,50 +1,50 @@ .\" Copyright (c) 2000 Peter Wemm .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt KENV 1 -.Os BSD 4 +.Os .Sh NAME .Nm kenv .Nd dump the kernel environment .Sh SYNOPSIS .Nm .Op Fl h .Op variable .Sh DESCRIPTION .Nm will dump the kernel environment. If the .Fl h flag is specified, it will limit the report to kernel probe hints. If an optional variable name is specified, .Nm will only report that value. .Sh SEE ALSO .Xr loader 8 .Sh HISTORY .Nm appeared in .Fx 4.1.1 . Index: head/usr.bin/killall/killall.1 =================================================================== --- head/usr.bin/killall/killall.1 (revision 79534) +++ head/usr.bin/killall/killall.1 (revision 79535) @@ -1,151 +1,151 @@ .\" Copyright (C) 1995 by Joerg Wunsch, Dresden .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS .\" OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED .\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE .\" DISCLAIMED. IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, .\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES .\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR .\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, .\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING .\" IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd June 25, 1995 -.Os FreeBSD +.Os .Dt KILLALL 1 .Sh NAME .Nm killall .Nd kill processes by name .Sh SYNOPSIS .Nm .Op Fl d | v .Op Fl h | ?\& .Op Fl help .Op Fl l .Op Fl m .Op Fl s .Op Fl u Ar user .Op Fl t Ar tty .Op Fl c Ar procname .Op Fl SIGNAL .Op Ar procname ... .Sh DESCRIPTION .Nm Killall kills processes selected by name, as opposed to the selection by pid as done by .Xr kill 1 . By default, it will send a .Dv TERM signal to all processes with an effective UID identical to the caller of .Nm that match the name .Ar procname . The super-user is allowed to kill any process. .Pp The options are as follows: .Bl -tag -width 10n -offset indent .It Fl d | v Be more verbose about what will be done. For a single .Fl d option, a list of the processes that will be sent the signal will be printed, or a message indicating that no matching processes have been found. .It Fl h | ?\& .It Fl help Give a help on the command usage and exit. .It Fl l List the names of the available signals and exit, like in .Xr kill 1 . .It Fl m Match the argument .Ar procname as a (case insensitive) regular expression against the names of processes found. CAUTION! This is dangerous, a single dot will match any process running under the effective UID of the caller. .It Fl s Show only what would be done, but do not send any signal. .It Fl SIGNAL Send a different signal instead of the default .Dv TERM . The signal may be specified either as a name .Pq with \&or without a leading Dv SIG , or numerically. .It Fl u Ar user Limit potentially matching processes to those belonging to the specified .Ar user . .It Fl t Ar tty Limit potentially matching processes to those running on the specified .Ar tty . .It Fl c Ar procname When used with the .Fl u or .Fl t flags, limit potentially matching processes to those matching the specified .Ar progname . .El .Sh ALL PROCESSES Sending a signal to all processes with uid .Nm XYZ is already supported by .Xr kill 1 . So use .Xr kill 1 for this job (e.g. $ kill -TERM -1 or as root $ echo kill -TERM -1 | su -m ) .Sh DIAGNOSTICS The .Nm command will respond with a short usage message and exit with a status of 2 in case of a command error. A status of 1 will be returned if either no matching process has been found or not all processes have been signalled successfully. Otherwise, a status of 0 will be returned. .Pp Diagnostic messages will only be printed if requested by .Fl d options. .Sh SEE ALSO .Xr kill 1 , .Xr sysctl 3 .Sh HISTORY The .Nm command appeared in .Fx 2.1 . It has been modeled after the .Nm command as available on other platforms. .Sh AUTHORS .An -nosplit The .Nm program was originally written in Perl and was contributed by .An Wolfram Schneider , this manual page has been written by .An J\(:org Wunsch . The current version of .Nm was rewritten in C by .An Peter Wemm using .Xr sysctl 3 . Index: head/usr.bin/ktrace/ktrace.1 =================================================================== --- head/usr.bin/ktrace/ktrace.1 (revision 79534) +++ head/usr.bin/ktrace/ktrace.1 (revision 79535) @@ -1,172 +1,172 @@ .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)ktrace.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt KTRACE 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm ktrace .Nd enable kernel process tracing .Sh SYNOPSIS .Nm .Op Fl aCcdi .Op Fl f Ar trfile .Op Fl g Ar pgrp | Fl p Ar pid .Op Fl t Ar trstr .Nm .Op Fl adi .Op Fl f Ar trfile .Op Fl t Ar trstr .Ar command .Sh DESCRIPTION The .Nm command enables kernel trace logging for the specified processes. Kernel trace data is logged to the file .Pa ktrace.out . The kernel operations that are traced include system calls, namei translations, signal processing, and .Tn I/O . .Pp Once tracing is enabled on a process, trace data will be logged until either the process exits or the trace point is cleared. A traced process can generate enormous amounts of log data quickly; It is strongly suggested that users memorize how to disable tracing before attempting to trace a process. The following command is sufficient to disable tracing on all user owned processes, and, if executed by root, all processes: .Pp .Dl \&$ ktrace -C .Pp The trace file is not human readable; use .Xr kdump 1 to decode it. .Pp The options are as follows: .Bl -tag -width indent .It Fl a Append to the trace file instead of recreating it. .It Fl C Disable tracing on all user owned processes, and, if executed by root, all processes in the system. .It Fl c Clear the trace points associated with the specified file or processes. .It Fl d Descendants; perform the operation for all current children of the designated processes. .It Fl f Ar file Log trace records to .Ar file instead of .Pa ktrace.out . .It Fl g Ar pgid Enable (disable) tracing on all processes in the process group (only one .Fl g flag is permitted). .It Fl i Inherit; pass the trace flags to all future children of the designated processes. .It Fl p Ar pid Enable (disable) tracing on the indicated process id (only one .Fl p flag is permitted). .It Fl t Ar trstr The string argument represents the kernel trace points, one per letter. The following table equates the letters with the tracepoints: .Pp .Bl -tag -width flag -compact .It Cm c trace system calls .It Cm n trace namei translations .It Cm i trace .Tn I/O .It Cm s trace signal processing .It Cm u userland traces .It Cm w context switches .El .It Ar command Execute .Ar command with the specified trace flags. .El .Pp The .Fl p , .Fl g , and .Ar command options are mutually exclusive. .Sh EXAMPLES # trace all kernel operations of process id 34 .Dl $ ktrace -p 34 .Pp # trace all kernel operations of processes in process group 15 and # pass the trace flags to all current and future children .Dl $ ktrace -idg 15 .Pp # disable all tracing of process 65 .Dl $ ktrace -cp 65 .Pp # disable tracing signals on process 70 and all current children .Dl $ ktrace -t s -cdp 70 .Pp # enable tracing of .Tn I/O on process 67 .Dl $ ktrace -ti -p 67 .Pp # run the command "w", tracing only system calls .Dl $ ktrace -tc w .Pp # disable all tracing to the file "tracedata" .Dl $ ktrace -c -f tracedata .Pp # disable tracing of all processes owned by the user .Dl $ ktrace -C .Sh SEE ALSO .Xr kdump 1 .Sh BUGS Only works if .Ar file is a regular file. .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/last/last.1 =================================================================== --- head/usr.bin/last/last.1 (revision 79534) +++ head/usr.bin/last/last.1 (revision 79535) @@ -1,212 +1,212 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)last.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd May 2, 2001 .Dt LAST 1 -.Os BSD 4 +.Os .Sh NAME .Nm last .Nd indicate last logins of users and ttys .Sh SYNOPSIS .Nm .Op Fl Ns Ar n .Oo .Fl d .Sm off .Op Oo Ar CC Oc Ar YY .Op Ar MM DD .Ar hh mm .Op Ar .SS .Sm on .Oc .Op Fl f Ar file .Op Fl h Ar host .Op Fl s .Op Fl t Ar tty .Op Fl w .Op Ar user ... .Sh DESCRIPTION .Nm Last will either list the sessions of specified .Ar users , .Ar ttys , and .Ar hosts , in reverse time order, or list the users logged in at a specified date and time. Each line of output contains the user name, the tty from which the session was conducted, any hostname, the start and stop times for the session, and the duration of the session. If the session is still continuing or was cut short by a crash or shutdown, .Nm will so indicate. .Pp .Bl -tag -width indent-two .It Fl Ar n Limits the report to .Ar n lines. .It Fl d Ar date Specify the snapshot date and time. All users logged in at the snapshot date and time will be reported. This may be used with the .Fl f option to derive the results from stored wtmp files. When this argument is provided, all other options except for .Fl f and .Fl Ar n are ignored. The argument should be in the form .Sm off .Op Oo Ar CC Oc Ar YY .Op Ar MM DD .Ar hh mm .Op Ar .SS .Sm on where each pair of letters represents the following: .Pp .Bl -tag -width Ds -compact -offset indent .It Ar CC The first two digits of the year (the century). .It Ar YY The second two digits of the year. If .Ar YY is specified, but .Ar CC is not, a value for .Ar YY between 69 and 99 results in a .Ar CC value of 19. Otherwise, a .Ar CC value of 20 is used. .It Ar MM Month of the year, from 1 to 12. .It Ar DD Day of the month, from 1 to 31. .It Ar hh Hour of the day, from 0 to 23. .It Ar mm Minute of the hour, from 0 to 59. .It Ar SS Second of the minute, from 0 to 61. .El .Pp If the .Ar CC and .Ar YY letter pairs are not specified, the values default to the current year. If the .Ar SS letter pair is not specified, the value defaults to 0. .It Fl f Ar file .Nm Last reads the file .Ar file instead of the default, .Pa /var/log/wtmp . .It Fl h Ar host .Ar Host names may be names or internet numbers. .It Fl s Report the duration of the login session in seconds, instead of the default days, hours and minutes. .It Fl t Ar tty Specify the .Ar tty . Tty names may be given fully or abbreviated, for example, .Dq Li "last -t 03" is equivalent to .Dq Li "last -t tty03" . .It Fl w Widen the duration field to show seconds, as well as the default days, hours and minutes. .El .Pp If multiple arguments are given, and a snapshot time is not specified, the information which applies to any of the arguments is printed, e.g., .Dq Li "last root -t console" would list all of .Dq Li root Ns 's sessions as well as all sessions on the console terminal. If no users, hostnames or terminals are specified, .Nm prints a record of all logins and logouts. .Pp The pseudo-user .Ar reboot logs in at reboots of the system, thus .Dq Li last reboot will give an indication of mean time between reboot. .Pp If .Nm is interrupted, it indicates to what date the search has progressed. If interrupted with a quit signal .Nm indicates how far the search has progressed and then continues. .Sh FILES .Bl -tag -width /var/log/wtmp -compact .It Pa /var/log/wtmp login data base .El .Sh SEE ALSO .Xr lastcomm 1 , .Xr utmp 5 , .Xr ac 8 .Sh BUGS If a login shell should terminate abnormally for some reason, it is likely that a logout record won't be written to the wtmp file. In this case, .Nm will indicate the logout time as "shutdown". .Sh HISTORY .Nm Last appeared in .Bx 3.0 . Index: head/usr.bin/lastcomm/lastcomm.1 =================================================================== --- head/usr.bin/lastcomm/lastcomm.1 (revision 79534) +++ head/usr.bin/lastcomm/lastcomm.1 (revision 79535) @@ -1,156 +1,156 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" From: @(#)lastcomm.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd September 18, 1996 .Dt LASTCOMM 1 -.Os BSD 3 +.Os .Sh NAME .Nm lastcomm .Nd show last commands executed in reverse order .Sh SYNOPSIS .Nm .Op Fl EScesu .Op Fl f Ar file .Op Ar command ...\& .Op Ar user ...\& .Op Ar terminal ...\& .Sh DESCRIPTION .Nm Lastcomm gives information on previously executed commands. With no arguments, .Nm prints information about all the commands recorded during the current accounting file's lifetime. .Pp The following options are available: .Pp .Bl -tag -width XXfXfileX -compact .Pp .It Fl E Print the time the process exited. .It Fl S Print the time the process started. .It Fl c Print the amount of cpu time used by the process. .It Fl e Print the amount of elapsed time used by the process. .It Fl s Print the amount of system time used by the process. .It Fl u Print the amount of user time used by the process. .It Fl f Ar file Read from .Ar file rather than the default .Pa /var/account/acct . .El .Pp If no options are specified, .Fl cS is assumed. If .Nm is invoked with arguments, only accounting entries with a matching .Ar command name, .Ar user name, or .Ar terminal name are printed. For example: .Pp .Dl lastcomm a.out root ttyd0 .Pp would produce a listing of all the executions of commands named .Pa a.out by user .Ar root on the terminal .Ar ttyd0 . .Pp For each process entry, the following are printed. .Pp .Bl -bullet -offset indent -compact .It The name of the user who ran the process. .It Flags, as accumulated by the accounting facilities in the system. .It The command name under which the process was called. .It The amount of CPU .Pq Fl c , wall .Pq Fl e , system .Pq Fl s , or user .Pq Fl u time used by the process (in seconds). .It The time the process started .Pq Fl S or exited .Pq Fl E . .El .Pp The flags are encoded as follows: ``S'' indicates the command was executed by the super-user, ``F'' indicates the command ran after a fork, but without a following .Xr exec , .\" ``C'' indicates the command was run in PDP-11 compatibility mode .\" (VAX only), ``D'' indicates the command terminated with the generation of a .Pa core file, and ``X'' indicates the command was terminated with a signal. .Sh FILES .Bl -tag -width /var/account/acct -compact .It Pa /var/account/acct Default accounting file. .El .Sh SEE ALSO .Xr last 1 , .Xr sigvec 2 , .Xr acct 5 , .Xr core 5 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/ldd/ldd.1 =================================================================== --- head/usr.bin/ldd/ldd.1 (revision 79534) +++ head/usr.bin/ldd/ldd.1 (revision 79535) @@ -1,54 +1,54 @@ .\" $FreeBSD$ .\" .Dd October 22, 1993 .Dt LDD 1 -.Os FreeBSD +.Os .Sh NAME .Nm ldd .Nd list dynamic object dependencies .Sh SYNOPSIS .Nm .Op Fl v .Op Fl f Ar format .Ar program ... .Sh DESCRIPTION .Nm displays all shared objects that are needed to run the given program. Contrary to .Xr nm 1 , the list includes .Dq indirect dependencies that are the result of needed shared objects which themselves depend on yet other shared objects. .Pp Zero, one or two .Fl f options may be given. The argument is a format string passed to .Xr rtld 1 and allows customization of .Nm Ns 's output. See .Xr rtld 1 for a list of recognized conversion characters. .Pp The .Fl v option displays an verbose listing of the dynamic linking headers encoded in the executable. See the source code and include files for the definitive meaning of all the fields. .Sh SEE ALSO .Xr ld 1 , .Xr nm 1 , .Xr rtld 1 .Sh HISTORY A .Nm utility first appeared in SunOS 4.0, it appeared in its current form in .Fx 1.1 . .Pp The .Fl v support is based on code written by .An John Polstra Aq jdp@polstra.com Index: head/usr.bin/limits/limits.1 =================================================================== --- head/usr.bin/limits/limits.1 (revision 79534) +++ head/usr.bin/limits/limits.1 (revision 79535) @@ -1,350 +1,350 @@ .\" Copyright (c) 1996 David Nugent .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, is permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice immediately at the beginning of the file, without modification, .\" this list of conditions, and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. This work was done expressly for inclusion into FreeBSD. Other use .\" is permitted provided this notation is included. .\" 4. Absolutely no warranty of function or purpose is made by the author .\" David Nugent. .\" 5. Modifications may be freely made to this file providing the above .\" conditions are met. .\" .\" $FreeBSD$ .\" .Dd January 15, 1996 .Dt LIMITS 1 -.Os FreeBSD +.Os .Sh NAME .Nm limits .Nd set or display process resource limits .Sh SYNOPSIS .Nm .Op Fl C Ar class .Op Fl SHB .Op Fl ea .Op Fl cdflmnstu Op val .Nm .Op Fl C Ar class .Op Fl SHB .Op Fl cdflmnstu Op val .Op Fl E .Op Ar name Ns = Ns Ar value ... .Op Ar command .Nm .Op Fl U Ar user .Op Fl SHB .Op Fl ea .Op Fl cdflmnstu Op val .Nm .Op Fl U Ar user .Op Fl SHB .Op Fl cdflmnstu Op val .Op Fl E .Op Ar name Ns = Ns Ar value ... .Op Ar command .Sh DESCRIPTION .Nm Limits either prints or sets kernel resource limits, and may optionally set environment variables like .Xr env 1 and run a program with the selected resources. Three uses of the .Nm command are possible: .Pp .Bl -tag -width indent .It Xo .Nm .Op Ar limitflags .Op Ar name Ns = Ns Ar value .Ar command .Xc This usage sets limits according to .Ar limitflags , optionally sets environment variables given as .Ar name Ns = Ns Ar value pairs, and then runs the specified command. .It Xo .Nm .Op Ar limitflags .Xc This usage determines values of resource settings according to .Ar limitflags , does not attempt to set them and outputs these values to standard output. By default, this will output the current kernel resource settings active for the calling process. Using the .Fl C Ar class or .Fl U Ar user flags, you may also display the current resource settings modified by the appropriate login class resource limit entries from the .Xr login.conf 5 login capabilities database. .It Xo .Nm .Fl e Op Ar limitflags .Xc This usage determines values of resource settings according to .Ar limitflags , but does not set them itself. Like the previous usage it outputs these values to standard output, except that it will emit them in .Em eval format, suitable for the calling shell. The calling shell is determined by examining the entries in the .Pa /proc filesystem for the parent process. If the shell is known (i.e. it is one of sh, csh, bash, tcsh, ksh, pdksh or rc), .Nm emits 'limit' or 'ulimit' commands in the format understood by that shell. If the name of the shell cannot be determined, then the 'ulimit' format used by .Xr sh 1 is used. .Pp This is very useful for setting limits used by scripts, or prior launching of daemons and other background tasks with specific resource limit settings, and provides the benefit of allowing global configuration of maximum resource usage by maintaining a central database of settings in the login class database. .Pp Within a shell script, .Nm will normally be used with eval within backticks as follows: .Pp .Dl eval `limits -e -C daemon` .Pp which causes the output of .Nm to be evaluated and set by the current shell. .El .Pp The value of limitflags specified in the above contains one or more of the following options: .Pp .Bl -tag -width "-d [limit]" .It Fl C Ar class Use current resource values, modified by the resource entries applicable for the login class "class". .It Fl U Ar user Use current resource values, modified by the resource entries applicable to the login class which "user" belongs to. If the user does not belong to a class, then the resource capabilities for the "default" class are used, if it exists, or the "root" class if the user is a superuser account. .It Fl S Select display or setting of "soft" (or current) resource limits. If specific limits settings follow this switch, only soft limits are affected unless overridden later with either the .Fl H or .Fl B flags. .It Fl H Select display or setting of "hard" (or maximum) resource limits. If specific limits settings follow this switch, only hard limits are affected until overridden later with either the .Fl S or .Fl B flags. .It Fl B Select display or setting of both "soft" (current) or "hard" (maximum) resource limits. If specific limits settings follow this switch, both soft and hard limits are affected until overridden later with either the .Fl S or .Fl H flags. .Fl e Select "eval mode" formatting for output. This is valid only on display mode and cannot be used when running a command. The exact syntax used for output depends upon the type of shell from which .Nm is invoked. .It Fl b Op Ar limit Selects or sets the .Em sbsize resource limit. .It Fl c Op Ar limit Select or set (if 'limit' is specified) the .Em coredumpsize resource limit. A value of 0 disables core dumps. .It Fl d Op Ar limit Select or set (if 'limit' is specified) the .Em datasize resource limit. .It Fl f Op Ar limit Select or set the .Em filesize resource limit. .It Fl l Op Ar limit Select or set the .Em memorylocked resource limit. .It Fl m Op Ar limit Select or set the .Em memoryuse size limit. .It Fl n Op Ar limit Select or set the .Em openfiles resource limit. The system-wide limit on the maximum number of open files per process can be viewed using the 'sysctl kern.maxfilesperproc' command. The total number of simultaneously open files in the entire system is limited to the value displayed by the 'sysctl kern.maxfiles' command. .It Fl s Op Ar limit Select or set the .Em stacksize resource limit. .It Fl t Op Ar limit Select or set the .Em cputime resource limit. .It Fl u Op Ar limit Select or set the .Em maxproc resource limit. The system-wide limit on the maximum number of processes allowed per UID can be viewed using the 'sysctl kern.maxprocperuid' command. The maximum number of processes that can be running simultaneously in the entire system is limited to the value given by the 'sysctl kern.maxproc' command. .Pp Valid values for .Ar limit in the above set of flags consist of either the string .Em infinity , .Em inf , .Em unlimited or .Em unlimit for an infinite (or kernel-defined maximum) limit, or a numeric value maybe followed by a suffix. Values which relate to size default to a value in bytes, or one of the following suffixes may be used as a multiplier: .Pp .Bl -tag -offset indent -width "xxxx" -compact .It b 512 byte blocks. .It k kilobytes (1024 bytes). .It m megabytes (1024*1024 bytes). .It g gigabytes. .It t terabytes. .El .Pp The .Em cputime resource defaults to a number of seconds, but a multiplier may be used, and as with size values, multiple values separated by a valid suffix are added together: .Bl -tag -offset indent -width "xxxx" -compact .It s seconds. .It m minutes. .It h hours. .It d days. .It w weeks. .It y 365 day years. .El .Pp .It Fl E The option .Sq Fl E causes .Nm to completely ignore the environment it inherits. .It Fl a This option forces all resource settings to be displayed even if other specific resource settings have been specified. For example, if you wish to disable core dumps when starting up the usenet news system, but wish to set all other resource settings as well that apply to the 'news' account, you might use: .Pp .Dl eval `limits -U news -aBec 0` .Pp As with the .Xr setrlimit 2 call, only the superuser may raise process "hard" resource limits. Non-root users may, however, lower them or change "soft" resource limits within to any value below the hard limit. When invoked to execute a program, the failure of .Nm to raise a hard limit is considered a fatal error. .El .Sh DIAGNOSTICS .Nm Limits exits with EXIT_FAILURE if usage is incorrect in any way; i.e. an invalid option, or set/display options are selected in the same invocation, .Fl e is used when running a program, etc. When run in display or eval mode, .Nm exits with a status of EXIT_SUCCESS. When run in command mode and execution of the command succeeds, the exit status will be whatever the executed program returns. .Sh SEE ALSO .Xr csh 1 , .Xr env 1 , .Xr limit 1 , .Xr sh 1 , .Xr getrlimit 2 , .Xr setrlimit 2 , .Xr login_cap 3 , .Xr login.conf 5 , .Xr sysctl 8 .Sh BUGS .Nm Limits does not handle commands with equal (``='') signs in their names, for obvious reasons. .Pp When eval output is selected, the .Pa /proc filesystem must be installed and mounted for the shell to be correctly determined, and therefore output syntax correct for the running shell. The default output is valid for .Xr sh 1 , so this means that any usage of .Nm in eval mode prior mounting .Pa /proc may only occur in standard bourne shell scripts. .Pp .Nm Limits makes no effort to ensure that resource settings emitted or displayed are valid and settable by the current user. Only a superuser account may raise hard limits, and when doing so the .Fx kernel will silently lower limits to values less than specified if the values given are too high. Index: head/usr.bin/locate/locate/locate.1 =================================================================== --- head/usr.bin/locate/locate/locate.1 (revision 79534) +++ head/usr.bin/locate/locate/locate.1 (revision 79535) @@ -1,264 +1,264 @@ .\" Copyright (c) 1995 Wolfram Schneider . Berlin. .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)locate.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt LOCATE 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm locate .Nd find filenames quickly .Sh SYNOPSIS .Nm .Op Fl Scims .Op Fl l Ar limit .Op Fl d Ar database .Ar pattern ... .Sh DESCRIPTION The .Nm program searches a database for all pathnames which match the specified .Ar pattern . The database is recomputed periodically (usually weekly or daily), and contains the pathnames of all files which are publicly accessible. .Pp Shell globbing and quoting characters .Po .Dq * , .Dq \&? , .Dq \e , .Dq \&[ and .Dq \&] .Pc may be used in .Ar pattern , although they will have to be escaped from the shell. Preceding any character with a backslash .Pq Dq \e eliminates any special meaning which it may have. The matching differs in that no characters must be matched explicitly, including slashes .Pq Dq / . .Pp As a special case, a pattern containing no globbing characters .Pq Dq foo is matched as though it were .Dq *foo* . .Pp Historically, locate store only characters between 32 and 127. The current implementation store any character except newline .Pq Sq \en and NUL .Pq Sq \e0 . The 8-bit character support doesn't waste extra space for plain ASCII file names. Characters less than 32 or greater than 127 are stored in 2 bytes. .Pp The following options are available: .Bl -tag -width 10n .It Fl S Print some statistic about the database and exit. .It Fl c Suppress normal output; instead print a count of matching file names. .It Fl d Ar database Search in .Ar database instead the default file name database. Multiple .Fl d options are allowed. Each additional .Fl d option adds the specified database to the list of databases to be searched. .Pp The option .Ar database may be a colon-separated list of databases. A single colon is a reference to the default database. .Bd -literal $ locate -d $HOME/lib/mydb: foo .Ed .Pp will first search string .Dq foo in .Pa $HOME/lib/mydb and then in .Pa /var/db/locate.database . .Bd -literal $ locate -d $HOME/lib/mydb::/cdrom/locate.database foo .Ed .Pp will first search string .Dq foo in .Pa $HOME/lib/mydb and then in .Pa /var/db/locate.database and then in .Pa /cdrom/locate.database . .Bd -literal $ locate -d db1 -d db2 -d db3 pattern .Ed .Pp is the same as .Bd -literal $ locate -d db1:db2:db3 pattern .Ed .Pp or .Bd -literal .Dq $ locate -d db1:db2 -d db3 pattern . .Ed .Pp If .Ar - is given as the database name, standard input will be read instead. For example, you can compress your database and use: .Bd -literal $ zcat database.gz | locate -d - pattern .Ed .Pp This might be useful on machines with a fast CPU and little RAM and slow I/O. Note: you can only use .Ar one pattern for stdin. .It Fl i Ignore case distinctions in both the pattern and the database. .It Fl l Ar number Limit output to .Ar number of file names and exit. .It Fl m Use .Xr mmap 2 instead of the .Xr stdio 3 library. This is the default behavior. Usually faster in most cases. .It Fl s Use the .Xr stdio 3 library instead of .Xr mmap 2 . .El .Sh FILES .Bl -tag -width /etc/periodic/weekly/310.locate -compact .It Pa /var/db/locate.database locate database .It Pa /usr/libexec/locate.updatedb Script to update the locate database .It Pa /etc/periodic/weekly/310.locate Script that starts the database rebuild .El .Sh ENVIRONMENT .Bl -tag -width LOCATE_PATH -compact .It Pa LOCATE_PATH path to the locate database if set and not empty, ignored if the .Fl d option was specified. .El .Sh SEE ALSO .Xr find 1 , .Xr whereis 1 , .Xr which 1 , .Xr fnmatch 3 , .Xr locate.updatedb 8 .Rs .%A Woods, James A. .%D 1983 .%T "Finding Files Fast" .%J ";login" .%V 8:1 .%P pp. 8-10 .Re .Sh BUGS The .Nm program may fail to list some files that are present, or may list files that have been removed from the system. This is because locate only reports files that are present in the database, which is typically only regenerated once a week by the .Pa /etc/periodic/weekly/310.locate script. Use .Xr find 1 to locate files that are of a more transitory nature. .Pp The .Nm database was built by user .Dq nobody . .Xr find 1 skips directories, which are not readable for user .Dq nobody , group .Dq nobody , or world. E.g. if your HOME directory is not world-readable, all your files are .Ar not in the database. .Pp The .Nm database is not byte order independent. It is not possible to share the databases between machines with different byte order. The current .Nm implementation understand databases in host byte order or network byte order if both architectures use the same integer size. So you can read on a .Fx Ns /i386 machine (little endian) a locate database which was built on SunOS/sparc machine (big endian, net). .Sh HISTORY The .Nm command first appeared in .Bx 4.4 . Many new features were added in .Fx 2.2 . Index: head/usr.bin/locate/locate/locate.updatedb.8 =================================================================== --- head/usr.bin/locate/locate/locate.updatedb.8 (revision 79534) +++ head/usr.bin/locate/locate/locate.updatedb.8 (revision 79535) @@ -1,74 +1,74 @@ .\" Copyright (c) 1996 .\" Mike Pritchard . All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by Mike Pritchard. .\" 4. Neither the name of the author nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd February 11, 1996 .Dt LOCATE.UPDATEDB 8 -.Os BSD 4.4 +.Os .Sh NAME .Nm locate.updatedb .Nd update locate database .Sh SYNOPSIS .Nm /usr/libexec/locate.updatedb .Sh DESCRIPTION .Nm Locate.updatedb updates the database used by .Xr locate 1 . It is typically run once a week by the .Pa /etc/periodic/weekly/310.locate script. .Pp The contents of the newly built database can be controlled by the .Pa /etc/locate.rc file. .Sh FILES .Bl -tag -width /var/db/locate.database -compact .It Pa /var/db/locate.database the default database .It Pa /etc/locate.rc the configuration file .El .Sh ENVIRONMENT .Bl -tag -width /var/db/locate.database -compact .It Pa LOCATE_CONFIG path to the configuration file .El .Sh SEE ALSO .Xr locate 1 , .Xr periodic 8 .Rs .%A Woods, James A. .%D 1983 .%T "Finding Files Fast" .%J ";login" .%V 8:1 .%P pp. 8-10 .Re Index: head/usr.bin/lockf/lockf.1 =================================================================== --- head/usr.bin/lockf/lockf.1 (revision 79534) +++ head/usr.bin/lockf/lockf.1 (revision 79535) @@ -1,120 +1,120 @@ .\" .\" Copyright (C) 1998 John D. Polstra. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY JOHN D. POLSTRA AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL JOHN D. POLSTRA OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd July 7, 1998 -.Os FreeBSD +.Os .Dt LOCKF 1 .Sh NAME .Nm lockf .Nd execute a command while holding a file lock .Sh SYNOPSIS .Nm .Op Fl ks .Op Fl t Ar seconds .Ar file .Ar command .Op Ar arguments .Sh DESCRIPTION The .Nm utility acquires an exclusive lock on a .Ar file , creating it if necessary. While holding the lock, it executes a .Ar command with optional .Ar arguments . After the .Ar command completes, .Nm releases the lock, and removes the .Ar file unless the .Fl k option is specified. BSD-style locking is used, as described in .Xr flock 2 ; the mere existence of the .Ar file is not considered to constitute a lock. .Pp The following options are supported: .Bl -tag -width Fl .It Fl k Causes the lock file to be kept (not removed) after the command completes. .It Fl s Causes .Nm to operate silently. Failure to acquire the lock is indicated only in the exit status. .It Fl t Ar seconds Specifies a timeout for waiting for the lock. By default, .Nm waits indefinitely to acquire the lock. If a timeout is specified with this option, .Nm will wait at most the given number of .Ar seconds before giving up. A timeout of 0 may be given, in which case .Nm will fail unless it can acquire the lock immediately. .El .Pp In no event will .Nm break a lock that is held by another process. .Sh DIAGNOSTICS If .Nm successfully acquires the lock, it returns the exit status produced by .Ar command . Otherwise, it returns one of the exit codes defined in .Xr sysexits 3 , as follows: .Bl -tag -width F_CANTCREATX .It Dv EX_TEMPFAIL The specified lock file was already locked by another process. .It Dv EX_CANTCREAT .Nm was unable to create the lock file, e.g., because of insufficient access privileges. .It Dv EX_USAGE There was an error on the .Nm command line. .It Dv EX_OSERR A system call (e.g., fork) failed unexpectedly. .El .Sh SEE ALSO .Xr flock 2 , .Xr sysexits 3 .Sh HISTORY .Nm first appeared in .Fx 2.2 . .Sh AUTHORS .An John Polstra Aq jdp@polstra.com . Index: head/usr.bin/logger/logger.1 =================================================================== --- head/usr.bin/logger/logger.1 (revision 79534) +++ head/usr.bin/logger/logger.1 (revision 79535) @@ -1,120 +1,120 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)logger.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt LOGGER 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm logger .Nd make entries in the system log .Sh SYNOPSIS .Nm .Op Fl 46Ais .Op Fl f Ar file .Op Fl h Ar host .Op Fl p Ar pri .Op Fl t Ar tag .Op Ar message ... .Sh DESCRIPTION .Nm Logger provides a shell command interface to the .Xr syslog 3 system log module. .Pp The following options are available: .Bl -tag -width indent .It Fl 4 Forces .Nm to use IPv4 addresses only. .It Fl 6 Forces .Nm to use IPv6 addresses only. .It Fl A .Nm tries to send the message to only one address even if the host has more than one A or AAAA record. If this option is specified, .Nm tries to send the message to all addresses. .It Fl i Log the process id of the logger process with each line. .It Fl s Log the message to standard error, as well as the system log. .It Fl f Ar file Log the specified file. .It Fl h Ar host Send the message to the remote system .Ar host instead of logging it locally. .It Fl p Ar pri Enter the message with the specified priority. The priority may be specified numerically or as a ``facility.level'' pair. For example, ``\-p local3.info'' logs the message(s) as .Ar info Ns rmational level in the .Ar local3 facility. The default is ``user.notice.'' .It Fl t Ar tag Mark every line in the log with the specified .Ar tag . .It Ar message Write the message to log; if not specified, and the .Fl f flag is not provided, standard input is logged. .El .Sh DIAGNOSTICS The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh EXAMPLES .Bd -literal -offset indent -compact logger System rebooted logger \-p local0.notice \-t HOSTIDM \-f /dev/idmc .Ed .Sh SEE ALSO .Xr syslog 3 , .Xr syslogd 8 .Sh STANDARDS The .Nm command is expected to be .St -p1003.2 compatible. Index: head/usr.bin/login/login.1 =================================================================== --- head/usr.bin/login/login.1 (revision 79534) +++ head/usr.bin/login/login.1 (revision 79535) @@ -1,209 +1,209 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)login.1 8.2 (Berkeley) 5/5/94 .\" $FreeBSD$ .\" .Dd May 5, 1994 .Dt LOGIN 1 -.Os BSD 4 +.Os .Sh NAME .Nm login .Nd log into the computer .Sh SYNOPSIS .Nm .Op Fl fp .Op Fl h Ar hostname .Op Ar user .Sh DESCRIPTION The .Nm utility logs users (and pseudo-users) into the computer system. .Pp If no user is specified, or if a user is specified and authentication of the user fails, .Nm prompts for a user name. Authentication of users is done via passwords. .Pp The options are as follows: .Bl -tag -width Ds .It Fl f The .Fl f option is used when a user name is specified to indicate that proper authentication has already been done and that no password need be requested. This option may only be used by the super-user or when an already logged in user is logging in as themselves. .It Fl h The .Fl h option specifies the host from which the connection was received. It is used by various daemons such as .Xr telnetd 8 . This option may only be used by the super-user. .It Fl p By default, .Nm discards any previous environment. The .Fl p option disables this behavior. .El .Pp If the file .Pa /var/run/nologin exists, .Nm displays its contents to the user and exits. This is used by .Xr shutdown 8 to prevent users from logging in when the system is about to go down. .Pp If the file .Pa /etc/login.access exists, .Nm checks to see if the user and host pair are specifically allowed or denied access. Login access may also be controlled via the login class, which provides allow and deny records based on time, tty and remote host name. .Pp If the file .Pa /etc/fbtab exists, .Nm changes the protection and ownership of certain devices specified in this file. .Pp If the file .Pa /etc/skeykeys exists, .Nm will offer S/key password validation if the user has an entry in the file. .Pa /etc/skey.access controls from which hosts and/or networks the use of S/key passwords are obligated. .Pp Immediately after logging a user in, .Nm displays the system copyright notice, the date and time the user last logged in, the message of the day as well as other information. If the file .Dq Pa .hushlogin exists in the user's home directory, all of these messages are suppressed. This is to simplify logins for non-human users, such as .Xr uucp 1 . .Nm Login then records an entry in the .Xr wtmp 5 and .Xr utmp 5 files and executes the user's command interpreter. .Pp .Nm Login enters information into the environment (see .Xr environ 7 ) specifying the user's home directory (HOME), command interpreter (SHELL), search path (PATH), terminal type (TERM) and user name (both LOGNAME and USER). Other environment variables may be set due to entries in the login class capabilities database, for the login class assigned in the user's system passwd record. The login class also controls the maximum and current process resource limits granted to a login, process priorities and many other aspects of a user's login environment. .Pp Some shells may provide a builtin .Nm command which is similar or identical to this utility. Consult the .Xr builtin 1 manual page. .Sh FILES .Bl -tag -width /var/mail/userXXX -compact .It Pa /etc/fbtab changes device protections .It Pa /etc/login.access login access control table .It Pa /etc/login.conf login class capabilities database .It Pa /etc/motd message-of-the-day .It Pa /var/run/nologin disallows logins .It Pa /etc/skey.access skey password control table .It Pa /etc/skeykeys skey password database .It Pa /var/run/utmp current logins .It Pa /var/log/lastlog last login account records .It Pa /var/log/wtmp login account records .It Pa /var/mail/user system mailboxes .It Pa \&.hushlogin makes login quieter .It Pa /etc/auth.conf configure authentication services .It Pa /etc/pam.conf if .Nm is configured with PAM support, it uses .Pa /etc/pam.conf entries with service name .Dq login .El .Sh SEE ALSO .Xr builtin 1 , .Xr chpass 1 , .Xr csh 1 , .Xr passwd 1 , .Xr rlogin 1 , .Xr skey 1 , .Xr getpass 3 , .Xr fbtab 5 , .Xr login.access 5 , .Xr login.conf 5 , .Xr nologin 5 , .Xr skey.access 5 , .Xr utmp 5 , .Xr environ 7 , .Xr nologin 8 , .Xr pam 8 .Sh HISTORY A .Nm utility appeared in .At v6 . Index: head/usr.bin/login/login.access.5 =================================================================== --- head/usr.bin/login/login.access.5 (revision 79534) +++ head/usr.bin/login/login.access.5 (revision 79535) @@ -1,56 +1,56 @@ .\" .\" $FreeBSD$ .\" .\" this is comment .Dd April 30, 1994 .Dt LOGIN.ACCESS 5 -.Os FreeBSD +.Os .Sh NAME .Nm login.access .Nd login access control table .Sh DESCRIPTION The .Nm file specifies (user, host) combinations and/or (user, tty) combinations for which a login will be either accepted or refused. .Pp When someone logs in, the .Nm is scanned for the first entry that matches the (user, host) combination, or, in case of non-networked logins, the first entry that matches the (user, tty) combination. The permissions field of that table entry determines whether the login will be accepted or refused. .Pp Each line of the login access control table has three fields separated by a ":" character: permission : users : origins .Pp The first field should be a "+" (access granted) or "-" (access denied) character. The second field should be a list of one or more login names, group names, or ALL (always matches). The third field should be a list of one or more tty names (for non-networked logins), host names, domain names (begin with "."), host addresses, internet network numbers (end with "."), ALL (always matches) or LOCAL (matches any string that does not contain a "." character). If you run NIS you can use @netgroupname in host or user patterns. .Pp The EXCEPT operator makes it possible to write very compact rules. .Pp The group file is searched only when a name does not match that of the logged-in user. Only groups are matched in which users are explicitly listed: the program does not look at a user's primary group id value. .Sh FILES .Bl -tag -width /etc/login.access -compact .It Pa /etc/login.access The .Nm file resides in .Pa /etc . .El .Sh SEE ALSO .Xr login 1 , .Xr pam 8 .Sh AUTHORS .An Guido van Rooij Index: head/usr.bin/logname/logname.1 =================================================================== --- head/usr.bin/logname/logname.1 (revision 79534) +++ head/usr.bin/logname/logname.1 (revision 79535) @@ -1,77 +1,77 @@ .\" Copyright (c) 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" the Institute of Electrical and Electronics Engineers, Inc. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)logname.1 8.1 (Berkeley) 6/9/93 .\" $FreeBSD$ .\" .Dd June 9, 1993 .Dt LOGNAME 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm logname .Nd display user's login name .Sh SYNOPSIS .Nm .Sh DESCRIPTION The .Nm utility writes the user's login name to standard output followed by a newline. .Pp The .Nm utility explicitly ignores the .Ev LOGNAME and .Ev USER environment variables because the environment cannot be trusted. .Sh DIAGNOSTICS The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh SEE ALSO .Xr who 1 , .Xr whoami 1 , .Xr getlogin 2 .Sh STANDARDS The .Nm function is expected to conform to .St -p1003.2 . .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/mail/mail.1 =================================================================== --- head/usr.bin/mail/mail.1 (revision 79534) +++ head/usr.bin/mail/mail.1 (revision 79535) @@ -1,1083 +1,1083 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)mail.1 8.2 (Berkeley) 12/30/93 .\" $FreeBSD$ .\" .Dd December 30, 1993 .Dt MAIL 1 -.Os BSD 4 +.Os .Sh NAME .Nm mail .Nd send and receive mail .Sh SYNOPSIS .Nm .Op Fl EiInv .Op Fl s Ar subject .Op Fl c Ar cc-addr .Op Fl b Ar bcc-addr .Ar to-addr ... .Oo .Fl .Ar sendmail-option ... .Oc .Nm .Op Fl EiInNv .Fl f .Op Ar name .Nm .Op Fl EiInNv .Op Fl u Ar user .Sh INTRODUCTION .Nm Mail is an intelligent mail processing system, which has a command syntax reminiscent of .Xr \&ed 1 with lines replaced by messages. .Pp .Bl -tag -width flag .It Fl v Verbose mode. The details of delivery are displayed on the user's terminal. .It Fl E Do not send messages with an empty body. This is useful for piping errors from .Xr cron 8 scripts. .It Fl i Ignore tty interrupt signals. This is particularly useful when using .Nm on noisy phone lines. .It Fl I Forces mail to run in interactive mode even when input is not a terminal. In particular, the .Sq Ic \&~ special character when sending mail is only active in interactive mode. .It Fl n Inhibits reading the system-wide .Pa mail.rc files upon startup. .It Fl N Inhibits the initial display of message headers when reading mail or editing a mail folder. .It Fl s Specify subject on command line (only the first argument after the .Fl s flag is used as a subject; be careful to quote subjects containing spaces.) .It Fl c Send carbon copies to .Ar list of users. .It Fl b Send blind carbon copies to .Ar list . List should be a comma-separated list of names. .It Fl f Read in the contents of your .Ar mbox (or the specified file) for processing; when you .Ar quit , .Nm writes undeleted messages back to this file. .It Fl u Is equivalent to: .Pp .Dl mail -f /var/mail/user .El .Ss Startup actions At startup time .Nm will execute commands in the system command files .Pa /usr/share/misc/mail.rc , .Pa /usr/local/etc/mail.rc and .Pa /etc/mail.rc in order, unless explicitly told not to by the use of the .Fl n option. Next, the commands in the user's personal command file .Pa ~/.mailrc are executed. .Nm then examines its command line options to determine whether a new message is to be sent, or whether an existing mailbox is to be read. .Ss Sending mail To send a message to one or more people, .Nm can be invoked with arguments which are the names of people to whom the mail will be sent. You are then expected to type in your message, followed by a .Sq Li control\-D at the beginning of a line. The section below .Ar Replying to or originating mail , describes some features of .Nm available to help you compose your letter. .Pp .Ss Reading mail In normal usage .Nm is given no arguments and checks your mail out of the post office, then prints out a one line header of each message found. The current message is initially the first message (numbered 1) and can be printed using the .Ic print command (which can be abbreviated .Ql Ic p ) . You can move among the messages much as you move between lines in .Xr \&ed 1 , with the commands .Ql Ic \&+ and .Ql Ic \&\- moving backwards and forwards, and simple numbers. .Pp .Ss Disposing of mail. After examining a message you can .Ic delete .Pq Ic d the message or .Ic reply .Pq Ic r to it. Deletion causes the .Nm program to forget about the message. This is not irreversible; the message can be .Ic undeleted .Pq Ic u by giving its number, or the .Nm session can be aborted by giving the .Ic exit .Pq Ic x command. Deleted messages will, however, usually disappear never to be seen again. .Pp .Ss Specifying messages Commands such as .Ic print and .Ic delete can be given a list of message numbers as arguments to apply to a number of messages at once. Thus .Dq Li delete 1 2 deletes messages 1 and 2, while .Dq Li delete 1\-5 deletes messages 1 through 5. The special name .Ql Li \&* addresses all messages, and .Ql Li \&$ addresses the last message; thus the command .Ic top which prints the first few lines of a message could be used in .Dq Li top \&* to print the first few lines of all messages. .Pp .Ss Replying to or originating mail. You can use the .Ic reply command to set up a response to a message, sending it back to the person who it was from. Text you then type in, up to an end-of-file, defines the contents of the message. While you are composing a message, .Nm treats lines beginning with the character .Ql Ic \&~ specially. For instance, typing .Ql Ic \&~m (alone on a line) will place a copy of the current message into the response right shifting it by a tabstop (see .Em indentprefix variable, below). Other escapes will set up subject fields, add and delete recipients to the message and allow you to escape to an editor to revise the message or to a shell to run some commands. (These options are given in the summary below.) .Pp .Ss Ending a mail processing session. You can end a .Nm session with the .Ic quit .Pq Ic q command. Messages which have been examined go to your .Ar mbox file unless they have been deleted in which case they are discarded. Unexamined messages go back to the post office. (See the .Fl f option above). .Pp .Ss Personal and system wide distribution lists. It is also possible to create a personal distribution lists so that, for instance, you can send mail to .Dq Li cohorts and have it go to a group of people. Such lists can be defined by placing a line like .Pp .Dl alias cohorts bill ozalp jkf mark kridle@ucbcory .Pp in the file .Pa \&.mailrc in your home directory. The current list of such aliases can be displayed with the .Ic alias command in .Nm . System wide distribution lists can be created by editing .Pa /etc/mail/aliases , see .Xr aliases 5 and .Xr sendmail 8 ; these are kept in a different syntax. In mail you send, personal aliases will be expanded in mail sent to others so that they will be able to .Ic reply to the recipients. System wide .Ic aliases are not expanded when the mail is sent, but any reply returned to the machine will have the system wide alias expanded as all mail goes through .Xr sendmail . .Pp .Ss Network mail (ARPA, UUCP, Berknet) See .Xr mailaddr 7 for a description of network addresses. .Pp .Nm Mail has a number of options which can be set in the .Pa .mailrc file to alter its behavior; thus .Dq Li set askcc enables the .Ar askcc feature. (These options are summarized below.) .Sh SUMMARY (Adapted from the `Mail Reference Manual') .Pp Each command is typed on a line by itself, and may take arguments following the command word. The command need not be typed in its entirety \- the first command which matches the typed prefix is used. For commands which take message lists as arguments, if no message list is given, then the next message forward which satisfies the command's requirements is used. If there are no messages forward of the current message, the search proceeds backwards, and if there are no good messages at all, .Nm types .Dq Li \&No applicable messages and aborts the command. .Bl -tag -width delete .It Ic \&\- Print out the preceding message. If given a numeric argument .Ar n , goes to the .Ar n Ns 'th previous message and prints it. .It Ic \&# ignore the remainder of the line as a comment. .It Ic \&? Prints a brief summary of commands. .It Ic \&! Executes the shell (see .Xr sh 1 and .Xr csh 1 ) command which follows. .It Ic Print .Pq Ic P Like .Ic print but also prints out ignored header fields. See also .Ic print , .Ic ignore and .Ic retain . .It Ic Reply .Pq Ic R Reply to originator. Does not reply to other recipients of the original message. .It Ic Type .Pq Ic T Identical to the .Ic Print command. .It Ic alias .Pq Ic a With no arguments, prints out all currently-defined aliases. With one argument, prints out that alias. With more than one argument, creates a new alias or changes an old one. .It Ic alternates .Pq Ic alt The .Ic alternates command is useful if you have accounts on several machines. It can be used to inform .Nm that the listed addresses are really you. When you .Ic reply to messages, .Nm will not send a copy of the message to any of the addresses listed on the .Ic alternates list. If the .Ic alternates command is given with no argument, the current set of alternate names is displayed. .It Ic chdir .Pq Ic c Changes the user's working directory to that specified, if given. If no directory is given, then changes to the user's login directory. .It Ic copy .Pq Ic co The .Ic copy command does the same thing that .Ic save does, except that it does not mark the messages it is used on for deletion when you quit. .It Ic delete .Pq Ic d Takes a list of messages as argument and marks them all as deleted. Deleted messages will not be saved in .Ar mbox , nor will they be available for most other commands. .It Ic dp (also .Ic dt ) Deletes the current message and prints the next message. If there is no next message, .Nm says .Dq Li "at EOF" . .It Ic edit .Pq Ic e Takes a list of messages and points the text editor at each one in turn. On return from the editor, the message is read back in. .It Ic exit .Ic ( ex or .Ic x ) Effects an immediate return to the Shell without modifying the user's system mailbox, his .Ar mbox file, or his edit file in .Fl f . .It Ic file .Pq Ic fi The same as .Ic folder . .It Ic folders List the names of the folders in your folder directory. .It Ic folder .Pq Ic fo The .Ic folder command switches to a new mail file or folder. With no arguments, it tells you which file you are currently reading. If you give it an argument, it will write out changes (such as deletions) you have made in the current file and read in the new file. Some special conventions are recognized for the name. # means the previous file, % means your system mailbox, %user means user's system mailbox, & means your .Ar mbox file, and \&+\&folder means a file in your folder directory. .It Ic from .Pq Ic f Takes a list of messages and prints their message headers. .It Ic headers .Pq Ic h Lists the current range of headers, which is an 18\-message group. If a .Ql \&+ argument is given, then the next 18\-message group is printed, and if a .Ql \&\- argument is given, the previous 18\-message group is printed. .It Ic help A synonym for .Ic \&? .It Ic hold .Ic ( ho , also .Ic preserve ) Takes a message list and marks each message therein to be saved in the user's system mailbox instead of in .Ar mbox . Does not override the .Ic delete command. .It Ic ignore Add the list of header fields named to the .Ar ignored list . Header fields in the ignore list are not printed on your terminal when you print a message. This command is very handy for suppression of certain machine-generated header fields. The .Ic Type and .Ic Print commands can be used to print a message in its entirety, including ignored fields. If .Ic ignore is executed with no arguments, it lists the current set of ignored fields. .It Ic mail .Pq Ic m Takes as argument login names and distribution group names and sends mail to those people. .It Ic more .Pq Ic \&mo Takes a list of messages and invokes the pager on that list. .It Ic mbox Indicate that a list of messages be sent to .Ic mbox in your home directory when you quit. This is the default action for messages if you do .Em not have the .Ic hold option set. .It Ic next .Pq Ic n like ( .Ic \&+ or .Tn CR ) Goes to the next message in sequence and types it. With an argument list, types the next matching message. .It Ic preserve .Pq Ic pre A synonym for .Ic hold . .It Ic print .Pq Ic p Takes a message list and types out each message on the user's terminal. .It Ic quit .Pq Ic q Terminates the session, saving all undeleted, unsaved messages in the user's .Ar mbox file in his login directory, preserving all messages marked with .Ic hold or .Ic preserve or never referenced in his system mailbox, and removing all other messages from his system mailbox. If new mail has arrived during the session, the message .Dq Li "You have new mail" is given. If given while editing a mailbox file with the .Fl f flag, then the edit file is rewritten. A return to the Shell is effected, unless the rewrite of edit file fails, in which case the user can escape with the .Ic exit command. .It Ic reply .Pq Ic r Takes a message list and sends mail to the sender and all recipients of the specified message. The default message must not be deleted. .It Ic respond A synonym for .Ic reply . .It Ic retain Add the list of header fields named to the .Ar retained list Only the header fields in the retain list are shown on your terminal when you print a message. All other header fields are suppressed. The .Ic Type and .Ic Print commands can be used to print a message in its entirety. If .Ic retain is executed with no arguments, it lists the current set of retained fields. .It Ic save .Pq Ic s Takes a message list and a filename and appends each message in turn to the end of the file. The filename in quotes, followed by the line count and character count is echoed on the user's terminal. .It Ic set .Pq Ic se With no arguments, prints all variable values. Otherwise, sets option. Arguments are of the form .Ar option=value (no space before or after =) or .Ar option . Quotation marks may be placed around any part of the assignment statement to quote blanks or tabs, i.e. .Dq Li "set indentprefix=\*q->\*q" .It Ic saveignore .Ic Saveignore is to .Ic save what .Ic ignore is to .Ic print and .Ic type . Header fields thus marked are filtered out when saving a message by .Ic save or when automatically saving to .Ar mbox . .It Ic saveretain .Ic Saveretain is to .Ic save what .Ic retain is to .Ic print and .Ic type . Header fields thus marked are the only ones saved with a message when saving by .Ic save or when automatically saving to .Ar mbox . .Ic Saveretain overrides .Ic saveignore . .It Ic shell .Pq Ic sh Invokes an interactive version of the shell. .It Ic size Takes a message list and prints out the size in characters of each message. .It Ic source The .Ic source command reads commands from a file. .It Ic top Takes a message list and prints the top few lines of each. The number of lines printed is controlled by the variable .Ic toplines and defaults to five. .It Ic type .Pq Ic t A synonym for .Ic print . .It Ic unalias Takes a list of names defined by .Ic alias commands and discards the remembered groups of users. The group names no longer have any significance. .It Ic undelete .Pq Ic u Takes a message list and marks each message as .Ic not being deleted. .It Ic unread .Pq Ic U Takes a message list and marks each message as .Ic not having been read. .It Ic unset Takes a list of option names and discards their remembered values; the inverse of .Ic set . .It Ic visual .Pq Ic v Takes a message list and invokes the display editor on each message. .It Ic write .Pq Ic w Similar to .Ic save , except that .Ic only the message body .Pq Ar without the header) is saved. Extremely useful for such tasks as sending and receiving source program text over the message system. .It Ic xit .Pq Ic x A synonym for .Ic exit . .It Ic z .Nm Mail presents message headers in windowfuls as described under the .Ic headers command. You can move .Nm Ns 's attention forward to the next window with the .Ic \&z command. Also, you can move to the previous window by using .Ic \&z\&\- . .El .Ss Tilde/Escapes .Pp Here is a summary of the tilde escapes, which are used when composing messages to perform special functions. Tilde escapes are only recognized at the beginning of lines. The name .Dq Em tilde\ escape is somewhat of a misnomer since the actual escape character can be set by the option .Ic escape . .Bl -tag -width Ds .It Ic \&~! Ns Ar command Execute the indicated shell command, then return to the message. .It Ic \&~b Ns Ar name ... Add the given names to the list of carbon copy recipients but do not make the names visible in the Cc: line ("blind" carbon copy). .It Ic \&~c Ns Ar name ... Add the given names to the list of carbon copy recipients. .It Ic \&~d Read the file .Dq Pa dead.letter from your home directory into the message. .It Ic \&~e Invoke the text editor on the message collected so far. After the editing session is finished, you may continue appending text to the message. .It Ic \&~f Ns Ar messages Read the named messages into the message being sent. If no messages are specified, read in the current message. Message headers currently being ignored (by the .Ic ignore or .Ic retain command) are not included. .It Ic \&~F Ns Ar messages Identical to .Ic \&~f , except all message headers are included. .It Ic \&~h Edit the message header fields by typing each one in turn and allowing the user to append text to the end or modify the field by using the current terminal erase and kill characters. .It Ic \&~m Ns Ar messages Read the named messages into the message being sent, indented by a tab or by the value of .Ar indentprefix . If no messages are specified, read the current message. Message headers currently being ignored (by the .Ic ignore or .Ic retain command) are not included. .It Ic \&~M Ns Ar messages Identical to .Ic \&~m , except all message headers are included. .It Ic \&~p Print out the message collected so far, prefaced by the message header fields. .It Ic \&~q Abort the message being sent, copying the message to .Dq Pa dead.letter in your home directory if .Ic save is set. .It Ic \&~r Ns Ar filename Read the named file into the message. .It Ic \&~R Ns Ar string Use .Ar string as the Reply-To field. .It Ic \&~s Ns Ar string Cause the named string to become the current subject field. .It Ic \&~\&t Ns Ar name ... Add the given names to the direct recipient list. .It Ic \&~\&v Invoke an alternate editor (defined by the .Ev VISUAL option) on the message collected so far. Usually, the alternate editor will be a screen editor. After you quit the editor, you may resume appending text to the end of your message. .It Ic \&~w Ns Ar filename Write the message onto the named file. .It Ic \&~\&| Ns Ar command Pipe the message through the command as a filter. If the command gives no output or terminates abnormally, retain the original text of the message. The command .Xr fmt 1 is often used as .Ic command to rejustify the message. .It Ic \&~: Ns Ar mail-command Execute the given mail command. Not all commands, however, are allowed. .It Ic \&~~ Ns Ar string Insert the string of text in the message prefaced by a single ~. If you have changed the escape character, then you should double that character in order to send it. .El .Ss Mail Options Options are controlled via .Ic set and .Ic unset commands. Options may be either binary, in which case it is only significant to see whether they are set or not; or string, in which case the actual value is of interest. If an option is not set, .Nm will look for an environment variable of the same name. The binary options include the following: .Bl -tag -width append .It Ar append Causes messages saved in .Ar mbox to be appended to the end rather than prepended. This should always be set (preferably in one of the system-wide .Pa mail.rc files). .It Ar ask Causes .Nm to prompt you for the subject of each message you send. If you respond with simply a newline, no subject field will be sent. .It Ar askcc Causes you to be prompted for additional carbon copy recipients at the end of each message. Responding with a newline indicates your satisfaction with the current list. .It Ar autoprint Causes the .Ic delete command to behave like .Ic dp \- thus, after deleting a message, the next one will be typed automatically. .It Ar debug Setting the binary option .Ar debug is the same as specifying .Fl d on the command line and causes .Nm to output all sorts of information useful for debugging .Nm . .It Ar dot The binary option .Ar dot causes .Nm to interpret a period alone on a line as the terminator of a message you are sending. .It Ar hold This option is used to hold messages in the system mailbox by default. .It Ar ignore Causes interrupt signals from your terminal to be ignored and echoed as @'s. .It Ar ignoreeof An option related to .Ar dot is .Ar ignoreeof which makes .Nm refuse to accept a control-d as the end of a message. .Ar Ignoreeof also applies to .Nm command mode. .It Ar metoo Usually, when a group is expanded that contains the sender, the sender is removed from the expansion. Setting this option causes the sender to be included in the group. .It Ar noheader Setting the option .Ar noheader is the same as giving the .Fl N flag on the command line. .It Ar nosave Normally, when you abort a message with two .Tn RUBOUT (erase or delete) .Nm copies the partial letter to the file .Dq Pa dead.letter in your home directory. Setting the binary option .Ar nosave prevents this. .It Ar Replyall Reverses the sense of .Ic reply and .Ic Reply commands. .It Ar quiet Suppresses the printing of the version when first invoked. .It Ar searchheaders If this option is set, then a message-list specifier in the form ``/x:y'' will expand to all messages containing the substring ``y'' in the header field ``x''. The string search is case insensitive. .It Ar verbose Setting the option .Ar verbose is the same as using the .Fl v flag on the command line. When mail runs in verbose mode, the actual delivery of messages is displayed on the user's terminal. .El .Ss Option String Values .Bl -tag -width Va .It Ev EDITOR Pathname of the text editor to use in the .Ic edit command and .Ic \&~e escape. If not defined, then a default editor is used. .It Ev LISTER Pathname of the directory lister to use in the .Ic folders command. Default is .Pa /bin/ls . .It Ev PAGER Pathname of the program to use in the .Ic more command or when .Ic crt variable is set. The default paginator .Xr more 1 is used if this option is not defined. .It Ev REPLYTO If set, will be used to initialize the Reply-To field for outgoing messages. .It Ev SHELL Pathname of the shell to use in the .Ic !\& command and the .Ic \&~! escape. A default shell is used if this option is not defined. .It Ev VISUAL Pathname of the text editor to use in the .Ic visual command and .Ic \&~v escape. .It Va crt The valued option .Va crt is used as a threshold to determine how long a message must be before .Ev PAGER is used to read it. If .Va crt is set without a value, then the height of the terminal screen stored in the system is used to compute the threshold (see .Xr stty 1 ) . .It Ar escape If defined, the first character of this option gives the character to use in the place of ~ to denote escapes. .It Ar folder The name of the directory to use for storing folders of messages. If this name begins with a `/', .Nm considers it to be an absolute pathname; otherwise, the folder directory is found relative to your home directory. .It Ev MBOX The name of the .Ar mbox file. It can be the name of a folder. The default is .Dq Li mbox in the user's home directory. .It Ar record If defined, gives the pathname of the file used to record all outgoing mail. If not defined, then outgoing mail is not so saved. .It Ar indentprefix String used by the ``~m'' tilde escape for indenting messages, in place of the normal tab character (^I). Be sure to quote the value if it contains spaces or tabs. .It Ar toplines If defined, gives the number of lines of a message to be printed out with the .Ic top command; normally, the first five lines are printed. .El .Sh ENVIRONMENT .Nm Mail utilizes the .Ev HOME and .Ev USER environment variables. Also, if the .Ev MAIL environment variable is set, it is used as the location of the user's mailbox instead of the default in /var/mail. .Sh FILES .Bl -tag -width /usr/share/misc/mail.*help -compact .It Pa /var/mail/* Post office. .It Pa ~/mbox User's old mail. .It Pa ~/.mailrc File giving initial mail commands. .It Pa /tmp/R* Temporary files. .It Pa /usr/share/misc/mail.*help Help files. .Pp .It Pa /usr/share/misc/mail.rc .It Pa /usr/local/etc/mail.rc .It Pa /etc/mail.rc System-wide initialization files. Each file will be sourced, in order, if it exists. .El .Sh SEE ALSO .Xr fmt 1 , .Xr newaliases 1 , .Xr vacation 1 , .Xr aliases 5 , .Xr mailaddr 7 , .Xr sendmail 8 .Rs .%T "The Mail Reference Manual" .Re .Sh HISTORY A .Nm command appeared in .At v1 . This man page is derived from .%T "The Mail Reference Manual" originally written by Kurt Shoens. .Sh BUGS There are some flags that are not documented here. Most are not useful to the general user. .Pp Usually, .Nm is just a link to .Nm Mail , which can be confusing. Index: head/usr.bin/mk_cmds/mk_cmds.1 =================================================================== --- head/usr.bin/mk_cmds/mk_cmds.1 (revision 79534) +++ head/usr.bin/mk_cmds/mk_cmds.1 (revision 79535) @@ -1,100 +1,100 @@ .\" Copyright (c) 1999 Jeroen Ruigrok van der Werven .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .Dd November 14, 1999 .Dt MK_CMDS 1 -.Os FreeBSD +.Os .Sh NAME .Nm mk_cmds .Nd generate commands from table file .Sh SYNOPSIS .Nm .Ar cmdtbl.ct .Sh DESCRIPTION The .Nm utility takes a command table file as input and produces a C source file as output which is intended to be used with the subsystem library, libss. This source file automatically includes .Aq Pa ss/ss.h . .Pp The format of the table file to be specified is as follows: .Pp command_table name_of_table .Pp keyword ss_command_name, .Qq description_of_command , command_binding .Op ,command_binding ; .Pp keyword ss_command_name, .Qq description_of_command , command_name, (dont_option .Op ", dont_option" ); .Pp end; .Pp Keyword is one of the following: .Pp .Bl -tag -width "unimplemented" -compact .It request A command that can be requested .It unimplemented An unimplemented command .El .Pp Dont_option is one of the following: .Pp .Bl -tag -width "dont_summarize" -compact .It dont_list Do not list the command .It dont_summarize Do not list the command in the command summary .El .Sh EXAMPLES request ss_testfunction, .Qq This is the explanation for testfunction , testfunction, tf; .Pp request ss_anothertest, .Qq This is the explanation for anothertest , anothertest, (dont_list, dont_summarize); .Pp unimplemented ss_lasttest, .Qq This is the explanation for lasttest , lasttest, lt; .Sh HISTORY The .Nm utility was written by the MIT Student Information Processing Board and appeared before .Fx 2.0.5 . .Sh AUTHORS This manual page was written by .An Jeroen Ruigrok van der Werven .Aq asmodai@wxs.nl Index: head/usr.bin/mkdep/mkdep.1 =================================================================== --- head/usr.bin/mkdep/mkdep.1 (revision 79534) +++ head/usr.bin/mkdep/mkdep.1 (revision 79535) @@ -1,124 +1,124 @@ .\" Copyright (c) 1987, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)mkdep.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt MKDEP 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm mkdep .Nd construct Makefile dependency list .Sh SYNOPSIS .Nm .Op Fl ap .Op Fl f Ar file .Op Ar flags .Ar .Sh DESCRIPTION .Nm Mkdep takes a set of flags for the C compiler and a list of C source files as arguments and constructs a set of include file dependencies which are written into the file ``.depend''. An example of its use in a Makefile might be: .Bd -literal -offset indent CFLAGS= -O -I../include SRCS= file1.c file2.c depend: mkdep ${CFLAGS} ${SRCS} .Ed .Pp where the macro SRCS is the list of C source files and the macro CFLAGS is the list of flags for the C compiler. .Pp The user has the ability to change the preprocessor and preprocessor options used. For instance, to use gcc as the preprocessor and to ignore system headers, one would use .Bd -literal -offset indent depend: env MKDEP_CPP="gcc -E" MKDEP_CPP_OPTS=-MM mkdep \\ ${CFLAGS} ${SRCS} .Ed .Pp The options are as follows: .Bl -tag -width Ds .It Fl a Append to the output file, so that multiple .Nm Ns 's may be run from a single Makefile. .It Fl f Write the include file dependencies to .Ar file , instead of the default ``.depend''. .It Fl p Cause .Nm to produce dependencies of the form: .Bd -literal -offset indent program: program.c .Ed .Pp so that subsequent makes will produce .Ar program directly from its C module rather than using an intermediate .Pa \&.o module. This is useful for programs whose source is contained in a single module. .El .Sh ENVIRONMENT .Bl -tag -width MKDEP_CPP_OPTS .It Ev CC Specifies the C compiler to use. The specified compiler is expected to have options consistent with the GNU C compiler. .It Ev MKDEP_CPP Specifies the preprocessor to use. The default is "${CC} -E". .It Ev MKDEP_CPP_OPTS Specifie the non-CFLAGS options for the preprocessor. The default is "-M". .El .Sh SEE ALSO .Xr cc 1 , .Xr cpp 1 , .Xr make 1 .Sh FILES .Bl -tag -width .depend -compact .It Pa .depend File containing list of dependencies. .El .Sh HISTORY The .Nm command appeared in .Bx 4.3 Tahoe . Index: head/usr.bin/mkfifo/mkfifo.1 =================================================================== --- head/usr.bin/mkfifo/mkfifo.1 (revision 79534) +++ head/usr.bin/mkfifo/mkfifo.1 (revision 79535) @@ -1,102 +1,102 @@ .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" the Institute of Electrical and Electronics Engineers, Inc. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)mkfifo.1 8.2 (Berkeley) 1/5/94 .\" $FreeBSD$ .\" .Dd January 5, 1994 .Dt MKFIFO 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm mkfifo .Nd make fifos .Sh SYNOPSIS .Nm .Op Fl m Ar mode .Ar fifo_name ... .Sh DESCRIPTION The .Nm command creates the fifos requested, in the order specified. .Pp The options are as follows: .Bl -tag -width indent .It Fl m Set the file permission bits of the created fifos to the specified mode, ignoring the .Xr umask 2 of the calling process. The mode argument takes any format that can be specified to the .Xr chmod 1 command. If a symbolic mode is specified, the op symbols .Dq + (plus) and .Dq - (hyphen) are interpreted relative to an assumed initial mode of .Dq a=rw (read and write permissions for all). .El .Pp If the .Fl m option is not specified, fifos are created with mode .Li \&0666 modified by the .Xr umask 2 of the calling process. The .Nm command requires write permission in the parent directory. .Sh DIAGNOSTICS The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh STANDARDS The .Nm utility is expected to be .St -p1003.2 compliant. .Sh SEE ALSO .Xr mkdir 1 , .Xr rm 1 , .Xr mkfifo 2 , .Xr mknod 2 , .Xr mknod 8 .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/msgs/msgs.1 =================================================================== --- head/usr.bin/msgs/msgs.1 (revision 79534) +++ head/usr.bin/msgs/msgs.1 (revision 79535) @@ -1,229 +1,229 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)msgs.1 8.2 (Berkeley) 4/28/95 .\" $FreeBSD$ .\" .Dd April 28, 1995 .Dt MSGS 1 -.Os BSD 4 +.Os .Sh NAME .Nm msgs .Nd system messages and junk mail program .Sh SYNOPSIS .Nm .Op Fl fhlpq .Op Ar number .Op Ar \-number .Nm .Op Fl s .Nm .Op Fl c .Op \-days .Sh DESCRIPTION .Nm Msgs is used to read system messages. These messages are sent by mailing to the login `msgs' and should be short pieces of information which are suitable to be read once by most users of the system. .Pp .Nm Msgs is normally invoked each time you login, by placing it in the file .Pa .login (or .Pa .profile if you use .Xr sh 1 ) . It will then prompt you with the source and subject of each new message. If there is no subject line, the first few non-blank lines of the message will be displayed. If there is more to the message, you will be told how long it is and asked whether you wish to see the rest of the message. The possible responses are: .Bl -tag -width Fl .It Fl y Type the rest of the message. .It Ic RETURN Synonym for y. .It Fl n Skip this message and go on to the next message. .It Fl Redisplay the last message. .It Fl q Drop out of .Nm ; the next time .Nm will pick up where it last left off. .It Fl s Append the current message to the file ``Messages'' in the current directory; `s\-' will save the previously displayed message. A `s' or `s\-' may be followed by a space and a file name to receive the message replacing the default ``Messages''. .It Fl m A copy of the specified message is placed in a temporary mailbox and .Xr mail 1 is invoked on that mailbox. Both `m' and `s' accept a numeric argument in place of the `\-'. .El .Pp .Nm Msgs keeps track of the next message you will see by a number in the file .Pa \&.msgsrc in your home directory. In the directory .Pa /var/msgs it keeps a set of files whose names are the (sequential) numbers of the messages they represent. The file .Pa /var/msgs/bounds shows the low and high number of the messages in the directory so that .Nm can quickly determine if there are no messages for you. If the contents of .Pa bounds is incorrect it can be fixed by removing it; .Nm will make a new .Pa bounds file the next time it is run with the .Fl s option. If .Nm is run with any option other than .Fl s , an error will be displayed if .Pa /var/msgs/bounds does not exist. .Pp The .Fl s option is used for setting up the posting of messages. The line .Pp .Dl msgs: \&"\&| /usr/bin/msgs \-s\&" .Pp should be included in .Pa /etc/mail/aliases (see .Xr newaliases 1 ) to enable posting of messages. .Pp The .Fl c option is used for performing cleanup on .Pa /var/msgs . A shell script entry to run .Nm with the .Fl c option should be placed in .Pa /etc/periodic/daily (see .Xr periodic 8 ) to run every night. This will remove all messages over 21 days old. A different expiration may be specified on the command line to override the default. .Pp Options when reading messages include: .Bl -tag -width Fl .It Fl f Do not say ``No new messages.''. This is useful in a .Pa .login file since this is often the case here. .It Fl q Queries whether there are messages, printing ``There are new messages.'' if there are. The command ``msgs \-q'' is often used in login scripts. .It Fl h Print the first part of messages only. .It Fl l Option causes only locally originated messages to be reported. .It Ar num A message number can be given on the command line, causing .Nm to start at the specified message rather than at the next message indicated by your .Pa \&.msgsrc file. Thus .Pp .Dl msgs \-h 1 .Pp prints the first part of all messages. .It Ar \-number Start .Ar number messages back from the one indicated in the .Pa \&.msgsrc file, useful for reviews of recent messages. .It Fl p Pipe long messages through .Xr more 1 . .El .Pp Within .Nm you can also go to any specific message by typing its number when .Nm requests input as to what to do. .Sh ENVIRONMENT .Nm Msgs uses the .Ev HOME and .Ev TERM environment variables for the default home directory and terminal type. .Sh FILES .Bl -tag -width /var/msgs/* -compact .It Pa /var/msgs/* database .It Pa ~/.msgsrc number of next message to be presented .El .Sh SEE ALSO .Xr mail 1 , .Xr more 1 , .Xr aliases 5 , .Xr periodic 8 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/mt/mt.1 =================================================================== --- head/usr.bin/mt/mt.1 (revision 79534) +++ head/usr.bin/mt/mt.1 (revision 79535) @@ -1,354 +1,354 @@ .\" Copyright (c) 1981, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)mt.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt MT 1 -.Os BSD 4 +.Os .Sh NAME .Nm mt .Nd magnetic tape manipulating program .Sh SYNOPSIS .Nm .Op Fl f Ar tapename .Ar command .Op Ar count .Sh DESCRIPTION .Nm \&Mt is used to give commands to a magnetic tape drive. By default .Nm performs the requested operation once. Operations may be performed multiple times by specifying .Ar count . Note that .Ar tapename must reference a raw (not block) tape device. .Pp The available commands are listed below. Only as many characters as are required to uniquely identify a command need be specified. .Bl -tag -width "eof, weof" .It Cm weof Write .Ar count end-of-file marks at the current position on the tape. .It Cm smk Write .Ar count setmarks at the current position on the tape. .It Cm fsf Forward space .Ar count files. .It Cm fsr Forward space .Ar count records. .It Cm fss Forward space .Ar count setmarks. .It Cm bsf Backward space .Ar count files. .It Cm bsr Backward space .Ar count records. .It Cm bss Backward space .Ar count setmarks. .It Cm rdhpos Read Hardware block position. Some drives do not support this. The block number reported is specific for that hardware only. The count argument is ignored. .It Cm rdspos Read SCSI logical block position. Some drives do not support this. The count argument is ignored. .It Cm sethpos Set Hardware block position. Some drives do not support this. The count argument is interpreted as a hardware block to which to position the tape. .It Cm setspos Set SCSI logical block position. Some drives do not support this. The count argument is interpreted as a SCSI logical block to which to position the tape. .It Cm rewind Rewind the tape (Count is ignored). .It Cm offline , rewoffl Rewind the tape and place the tape unit off-line (Count is ignored). .It Cm erase Erase the tape. A count of 0 disables long erase, which is on by default. .It Cm retension Re-tension the tape (one full wind forth and back, Count is ignored). .It Cm status Print status information about the tape unit. For SCSI magnetic tape devices, the current operating modes of density, blocksize, and whether compression is enabled is reported. The current state of the driver (what it thinks that it is doing with the device) is reported. If the driver knows the relative position from BOT (in terms of filemarks and records), it prints that. Note that this information is not definitive (only BOT, End of Recorded Media, and hardware or SCSI logical block position (if the drive supports such) are considered definitive tape positions). .It Cm errstat Print (and clear) error status information about this device. For every normal operation (e.g., a read or a write) and every control operation (e.g,, a rewind), the driver stores up the last command executed and it's associated status and any residual counts (if any). This command retrieves and prints this information. If possible, this also clears any latched error information. .It Cm blocksize Set the block size for the tape unit. Zero means variable-length blocks. .It Cm density Set the density for the tape unit. For the density codes, see below. The density value could be given either numerically, or as a string, corresponding to the .Dq Reference field. If the string is abbreviated, it will be resolved in the order shown in the table, and the first matching entry will be used. If the given string and the resulting canonical density name do not match exactly, an informational message is printed about what the given string has been taken for. .It Cm geteotmodel Fetch and print out the current EOT filemark model. The model states how many filemarks will be written at close if a tape was being written. .It Cm seteotmodel Set (from the .Ar count argument) and print out the current and EOT filemark model. Typically this will be .Ar 2 filemarks, but some devices (typically QIC cartridge drives) can only write .Ar 1 filemark. Currently you can only choose a value of .Ar 1 or .Ar 2 . .It Cm eom Forward space to end of recorded medium (Count is ignored). .It Cm eod Forward space to end of data, identical to .Cm eom . .It Cm comp Set compression mode. There are currently several possible values for the compression mode: .Pp .Bl -tag -width 9n -compact .It off Turn compression off. .It on Turn compression on. .It none Same as .Ar off . .It enable Same as .Ar on . .It IDRC IBM Improved Data Recording Capability compression (0x10). .It DCLZ DCLZ compression algorithm (0x20). .El .Pp In addition to the above recognized compression keywords, the user can supply a numeric compression algorithm for the tape drive to use. In most cases, simply turning the compression .Sq on will have the desired effect of enabling the default compression algorithm supported by the drive. If this is not the case (see the .Cm status display to see which compression algorithm is currently in use), the user can manually specify one of the supported compression keywords (above), or supply a numeric compression value. .El .Pp If a tape name is not specified, and the environment variable .Ev TAPE does not exist; .Nm uses the device .Pa /dev/nsa0 . .Pp .Nm \&Mt returns a 0 exit status when the operation(s) were successful, 1 if the command was unrecognized, and 2 if an operation failed. .Pp The following density table was taken from the .Sq Historical sequential access density codes table (A-1) in Revision 11 of the SCSI-3 Stream Device Commands (SSC) working draft, dated November 11, 1997. .Pp The different density codes are as follows: .Pp .Dl "0x0 default for device .Dl "0xE reserved for ECMA .Bd -literal -offset 3n Value Width Tracks Density Code Type Reference Note mm in bpmm bpi 0x01 12.7 (0.5) 9 32 (800) NRZI R X3.22-1983 2 0x02 12.7 (0.5) 9 63 (1,600) PE R X3.39-1986 2 0x03 12.7 (0.5) 9 246 (6,250) GCR R X3.54-1986 2 0x05 6.3 (0.25) 4/9 315 (8,000) GCR C X3.136-1986 1 0x06 12.7 (0.5) 9 126 (3,200) PE R X3.157-1987 2 0x07 6.3 (0.25) 4 252 (6,400) IMFM C X3.116-1986 1 0x08 3.81 (0.15) 4 315 (8,000) GCR CS X3.158-1987 1 0x09 12.7 (0.5) 18 1,491 (37,871) GCR C X3.180 2 0x0A 12.7 (0.5) 22 262 (6,667) MFM C X3B5/86-199 1 0x0B 6.3 (0.25) 4 63 (1,600) PE C X3.56-1986 1 0x0C 12.7 (0.5) 24 500 (12,690) GCR C HI-TC1 1,6 0x0D 12.7 (0.5) 24 999 (25,380) GCR C HI-TC2 1,6 0x0F 6.3 (0.25) 15 394 (10,000) GCR C QIC-120 1,6 0x10 6.3 (0.25) 18 394 (10,000) GCR C QIC-150 1,6 0x11 6.3 (0.25) 26 630 (16,000) GCR C QIC-320 1,6 0x12 6.3 (0.25) 30 2,034 (51,667) RLL C QIC-1350 1,6 0x13 3.81 (0.15) 1 2,400 (61,000) DDS CS X3B5/88-185A 5 0x14 8.0 (0.315) 1 1,703 (43,245) RLL CS X3.202-1991 5 0x15 8.0 (0.315) 1 1,789 (45,434) RLL CS ECMA TC17 5 0x16 12.7 (0.5) 48 394 (10,000) MFM C X3.193-1990 1 0x17 12.7 (0.5) 48 1,673 (42,500) MFM C X3B5/91-174 1 0x18 12.7 (0.5) 112 1,673 (42,500) MFM C X3B5/92-50 1 0x1C 6.3 (0.25) 34 1,654 (42,000) MFM C QIC-385M 1,6 0x1D 6.3 (0.25) 32 1,512 (38,400) GCR C QIC-410M 1,6 0x1E 6.3 (0.25) 30 1,385 (36,000) GCR C QIC-1000C 1,6 0x1F 6.3 (0.25) 30 2,666 (67,733) RLL C QIC-2100C 1,6 0x20 6.3 (0.25) 144 2,666 (67,733) RLL C QIC-6GB(M) 1,6 0x21 6.3 (0.25) 144 2,666 (67,733) RLL C QIC-20GB(C) 1,6 0x22 6.3 (0.25) 42 1,600 (40,640) GCR C QIC-2GB(C) ? 0x23 6.3 (0.25) 38 2,666 (67,733) RLL C QIC-875M ? 0x24 3.81 (0.15) 1 2,400 (61,000) CS DDS-2 5 0x25 3.81 (0.15) 1 3,816 (97,000) CS DDS-3 5 0x26 3.81 (0.15) 1 3,816 (97,000) CS DDS-4 5 0x27 8.0 (0.315) 1 3,056 (77,611) RLL CS Mammoth 5 0x28 12.7 (0.5) 36 1,491 (37,871) GCR C X3.224 1 0x29 12.7 (0.5) 0x2A 0x2B 12.7 (0.5) 3 ? ? ? C X3.267 5 .Ed .Bd -literal -offset 3n Code Description Type Description ---------------- ---------------- NRZI Non return to zero, change on ones R Reel-to-reel GCR Group code recording C Cartridge PE Phase encoded CS Cassette IMFM Inverted modified frequency modulation MFM Modified frequency modulation DDS DAT data storage RLL Run length limited .Ed .Bd -literal -offset 3n NOTES 1. Serial recorded. 2. Parallel recorded. 3. Old format known as QIC-11. 5. Helical scan. 6. This is not an American National Standard. The reference is based on an industry standard definition of the media format. .Ed .Sh ENVIRONMENT If the following environment variable exists, it is utilized by .Nm . .Bl -tag -width Fl .It Ev TAPE .Nm \&Mt checks the .Ev TAPE environment variable if the argument .Ar tapename is not given. .El .Sh FILES .Bl -tag -width /dev/*rst[0-9]*xx -compact .It Pa /dev/*rwt* QIC-02/QIC-36 magnetic tape interface .It Pa /dev/*rsa[0-9]* SCSI magnetic tape interface .El .Sh SEE ALSO .Xr dd 1 , .Xr ioctl 2 , .Xr ast 4 , .Xr mtio 4 , .Xr sa 4 , .Xr environ 7 .Sh HISTORY The .Nm command appeared in .Bx 4.3 . .Pp Extensions regarding the .Xr st 4 driver appeared in 386BSD 0.1 as a separate .Xr st 1 command, and have been merged into the .Nm command in .Fx 2.1 . .Pp The former .Cm eof command that used to be a synonym for .Cm weof has been abandoned in .Fx 2.1 since it was often confused with .Cm eom , which is fairly dangerous. Index: head/usr.bin/nfsstat/nfsstat.1 =================================================================== --- head/usr.bin/nfsstat/nfsstat.1 (revision 79534) +++ head/usr.bin/nfsstat/nfsstat.1 (revision 79535) @@ -1,99 +1,99 @@ .\" Copyright (c) 1989, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" From: @(#)nfsstat.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt NFSSTAT 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm nfsstat .Nd display .Tn NFS statistics .Sh SYNOPSIS .Nm .Op Fl csW .Op Fl M Ar core .Op Fl N Ar system .Op Fl w Ar wait .Sh DESCRIPTION The .Nm command displays statistics kept about .Tn NFS client and server activity. .Pp The options are as follows: .Bl -tag -width Ds .It Fl c Only display client side statistics .It Fl M Extract values associated with the name list from the specified core instead of the default .Pa /dev/kmem . .It Fl N Extract the name list from the specified system instead of the default .Pa /kernel . .It Fl s Only display server side statistics .It Fl W Use wide format with interval short summary. This option is especially useful when combined with -c or -s and a time delay. .It Fl w Display a shorter summary of .Tn NFS activity for both the client and server at .Ar wait second intervals. .El .Sh FILES .Bl -tag -width /dev/kmem -compact .It Pa /kernel default kernel namelist .It Pa /dev/kmem default memory file .El .Sh SEE ALSO .Xr fstat 1 , .Xr netstat 1 , .Xr ps 1 , .Xr systat 1 , .Xr sysctl 3 , .Xr iostat 8 , .Xr pstat 8 , .Xr vmstat 8 .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/nice/nice.1 =================================================================== --- head/usr.bin/nice/nice.1 (revision 79534) +++ head/usr.bin/nice/nice.1 (revision 79535) @@ -1,109 +1,109 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)nice.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt NICE 1 -.Os BSD 4 +.Os .Sh NAME .Nm nice .Nd execute a command at a low scheduling priority .Sh SYNOPSIS .Nm .Op Fl Ns Ar number .Ar command .Op Ar arguments .Sh DESCRIPTION .Nm Nice runs .Ar command at a low priority. (Think of low and slow). If .Fl Ns Ar number is not given, .Nm assumes the value 10. The priority is a value in the range -20 to 20. The default priority is 0, priority 20 is the lowest possible. .Nm Nice will execute .Ar command at priority .Ar number relative to the priority of .Nm . Higher priorities than the current process priority can only requested by the super-user. Negative numbers are expressed as .Fl - Ns Ar number . .Pp The returned exit status is the exit value from the command executed by .Nm . .Pp Some shells may provide a builtin .Nm command which is similar or identical to this utility. Consult the .Xr builtin 1 manual page. .Sh EXAMPLES $ nice -5 date .Pp Execute command .Sq date at priority 5 assuming the priority of the shell is 0. .Pp # nice -16 nice --35 date .Pp Execute command .Sq date at priority -19 assuming the priority of the shell is 0 and you are the super-user. .Sh SEE ALSO .Xr builtin 1 , .Xr csh 1 , .Xr idprio 1 , .Xr rtprio 1 , .Xr getpriority 2 , .Xr setpriority 2 , .Xr renice 8 .Sh HISTORY A .Nm command appeared in .At v6 . Index: head/usr.bin/nm/nm.1 =================================================================== --- head/usr.bin/nm/nm.1 (revision 79534) +++ head/usr.bin/nm/nm.1 (revision 79535) @@ -1,153 +1,153 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)nm.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt NM 1 -.Os BSD 4 +.Os .Sh NAME .Nm nm .Nd display name list (symbol table) .Sh SYNOPSIS .Nm .Op Fl agnoprtuwW .Op Ar .Sh DESCRIPTION The symbol table (name list) of each object in .Ar file Ns (s) is displayed. If a library (archive) is given, .Nm displays a list for each object archive member. If .Ar file is not present, .Nm searches for the file .Pa a.out and if present, displays the symbol table for .Pa a.out . .Bl -tag -width flag .It Fl a Display symbol table entries inserted for use by debuggers. .It Fl g Restrict display to external (global) symbols. .It Fl n Present results in numerical order. .It Fl o Display full path or library name of object on every line. .It Fl p Do not sort at all. .It Fl r Reverse order sort. .It Fl t Output in tabular format more suitable for other programs digestive system. .It Fl u Display undefined symbols only. .It Fl w Warn about non-object archive members. Normally, nm will silently ignore all archive members which are not object files. .It Fl W Include an extra column in the output with a ``W'' indicating weak symbols. .El .Pp Each symbol name is preceded by its value (a blank field if the symbol is undefined) and one of the following letters: .Pp .Bl -tag -width Ds -compact -offset indent .It Fl debugger symbol table entries (see the .Fl a option). .It Li A absolute .It Li B bss segment symbol .It Li C common symbol .It Li D data segment symbol .It Li f file name .It Li I indirect reference symbol .It Li T text segment symbol .It Li U undefined .It Li W warn if next symbol is referenced .El .Pp If the symbol is local (non-external) the type letter is in lower case. The output is sorted alphabetically. .Sh KEYWORDS The following is a complete list of keywords and their meaning. The keyword is uppercase for external, lowercase for internal symbols. Only uppercase keywords are shown here. .Pp .Bl -tag -width sigignore -compact .It A Absolute Address .It B BSS Segment .It C Common Reference .It D Data Segment .It F Filename (external only) .It w Warning refs (internal only) .It I Alias definition .It T Text Segment .It U Undefined .It ? None of the above .El .Sh SEE ALSO .Xr ar 1 , .Xr a.out 5 , .Xr ar 5 , .Xr stab 5 .Sh HISTORY An .Nm command appeared in .At v1 . Index: head/usr.bin/nm/nm.1aout =================================================================== --- head/usr.bin/nm/nm.1aout (revision 79534) +++ head/usr.bin/nm/nm.1aout (revision 79535) @@ -1,153 +1,153 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)nm.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt NM 1 -.Os BSD 4 +.Os .Sh NAME .Nm nm .Nd display name list (symbol table) .Sh SYNOPSIS .Nm .Op Fl agnoprtuwW .Op Ar .Sh DESCRIPTION The symbol table (name list) of each object in .Ar file Ns (s) is displayed. If a library (archive) is given, .Nm displays a list for each object archive member. If .Ar file is not present, .Nm searches for the file .Pa a.out and if present, displays the symbol table for .Pa a.out . .Bl -tag -width flag .It Fl a Display symbol table entries inserted for use by debuggers. .It Fl g Restrict display to external (global) symbols. .It Fl n Present results in numerical order. .It Fl o Display full path or library name of object on every line. .It Fl p Do not sort at all. .It Fl r Reverse order sort. .It Fl t Output in tabular format more suitable for other programs digestive system. .It Fl u Display undefined symbols only. .It Fl w Warn about non-object archive members. Normally, nm will silently ignore all archive members which are not object files. .It Fl W Include an extra column in the output with a ``W'' indicating weak symbols. .El .Pp Each symbol name is preceded by its value (a blank field if the symbol is undefined) and one of the following letters: .Pp .Bl -tag -width Ds -compact -offset indent .It Fl debugger symbol table entries (see the .Fl a option). .It Li A absolute .It Li B bss segment symbol .It Li C common symbol .It Li D data segment symbol .It Li f file name .It Li I indirect reference symbol .It Li T text segment symbol .It Li U undefined .It Li W warn if next symbol is referenced .El .Pp If the symbol is local (non-external) the type letter is in lower case. The output is sorted alphabetically. .Sh KEYWORDS The following is a complete list of keywords and their meaning. The keyword is uppercase for external, lowercase for internal symbols. Only uppercase keywords are shown here. .Pp .Bl -tag -width sigignore -compact .It A Absolute Address .It B BSS Segment .It C Common Reference .It D Data Segment .It F Filename (external only) .It w Warning refs (internal only) .It I Alias definition .It T Text Segment .It U Undefined .It ? None of the above .El .Sh SEE ALSO .Xr ar 1 , .Xr a.out 5 , .Xr ar 5 , .Xr stab 5 .Sh HISTORY An .Nm command appeared in .At v1 . Index: head/usr.bin/pagesize/pagesize.1 =================================================================== --- head/usr.bin/pagesize/pagesize.1 (revision 79534) +++ head/usr.bin/pagesize/pagesize.1 (revision 79535) @@ -1,57 +1,57 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)pagesize.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt PAGESIZE 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm pagesize .Nd print system page size .Sh SYNOPSIS .Nm .Sh DESCRIPTION .Nm Pagesize prints the size of a page of memory in bytes, as returned by .Xr getpagesize 3 . This program is useful in constructing portable shell scripts. .Sh SEE ALSO .Xr getpagesize 3 .Sh HISTORY The .Nm command appeared in .Bx 4.2 . Index: head/usr.bin/passwd/passwd.1 =================================================================== --- head/usr.bin/passwd/passwd.1 (revision 79534) +++ head/usr.bin/passwd/passwd.1 (revision 79535) @@ -1,249 +1,249 @@ .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)passwd.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt PASSWD 1 -.Os BSD 4 +.Os .Sh NAME .Nm passwd , yppasswd .Nd modify a user's password .Sh SYNOPSIS .Nm .Op Fl l .Op Ar user .Nm yppasswd .Op Fl l .Op Fl y .Op Fl d Ar domain .Op Fl h Ar host .Op Fl o .Sh DESCRIPTION .Nm Passwd changes the user's local, Kerberos, or NIS password. If the user is not the super-user, .Nm first prompts for the current password and will not continue unless the correct password is entered. .Pp When entering the new password, the characters entered do not echo, in order to avoid the password being seen by a passer-by. .Nm prompts for the new password twice in order to detect typing errors. .Pp The new password should be at least six characters long (which may be overridden using the .Xr login.conf 5 .Dq minpasswordlen setting for a user's login class) and not purely alphabetic. Its total length must be less than .Dv _PASSWORD_LEN (currently 128 characters). .Pp The new password should contain a mixture of upper and lower case characters (which may be overridden using the .Xr login.conf 5 .Dq mixpasswordcase setting for a user's login class). Allowing lower case passwords may be useful where the password file will be used in situations where only lower case passwords are permissible, such as when using Samba to authenticate Windows clients. In all other situations, numbers, upper case letters and meta characters are encouraged. .Pp Once the password has been verified, .Nm communicates the new password information to the Kerberos authenticating host. .Bl -tag -width flag .It Fl l This option causes the password to be updated only in the local password file, and not with the Kerberos database. When changing only the local password, .Xr pwd_mkdb 8 is used to update the password databases. .Pp .El When changing local or NIS password, the next password change date is set according to .Dq passwordtime capability in the user's login class. .Pp To change another user's Kerberos password, one must first run .Xr kinit 1 followed by .Xr passwd 1 . The super-user is not required to provide a user's current password if only the local password is modified. .Sh NIS INTERACTION .Nm Passwd has built-in support for NIS. If a user exists in the NIS password database but does not exist locally, .Nm automatically switches into .Dq yppasswd mode. If the specified user does not exist in either the local password database of the NIS password maps, .Nm returns an error. .Pp When changing an NIS password, unprivileged users are required to provide their old password for authentication (the .Xr rpc.yppasswdd 8 daemon requires the original password before it will allow any changes to the NIS password maps). This restriction applies even to the super-user, with one important exception: the password authentication is bypassed for the super-user on the NIS master server. This means that the super-user on the NIS master server can make unrestricted changes to anyone's NIS password. The super-user on NIS client systems and NIS slave servers still needs to provide a password before the update will be processed. .Pp The following additional options are supported for use with NIS: .Bl -tag -width flag .It Fl y The .Fl y flag overrides .Nm Ns 's checking heuristics and forces it into NIS mode. .It Fl l When NIS is enabled, the .Fl l flag can be used to force .Nm into .Dq local only mode. This flag can be used to change the entry for a local user when an NIS user exists with the same login name. For example, you will sometimes find entries for system .Dq placeholder users such as .Pa bin or .Pa daemon in both the NIS password maps and the local user database. By default, .Nm will try to change the NIS password. The .Fl l flag can be used to change the local password instead. .It Fl d Ar domain Specify what domain to use when changing an NIS password. By default, .Nm assumes that the system default domain should be used. This flag is primarily for use by the superuser on the NIS master server: a single NIS server can support multiple domains. It is also possible that the domainname on the NIS master may not be set (it is not necessary for an NIS server to also be a client) in which case the .Nm command needs to be told what domain to operate on. .It Fl h Ar host Specify the name of an NIS server. This option, in conjunction with the .Fl d option, can be used to change an NIS password on a non-local NIS server. When a domain is specified with the .Fl d option and .Nm is unable to determine the name of the NIS master server (possibly because the local domainname isn't set), the name of the NIS master is assumed to be .Dq localhost . This can be overridden with the .Fl h flag. The specified hostname need not be the name of an NIS master: the name of the NIS master for a given map can be determined by querying any NIS server (master or slave) in a domain, so specifying the name of a slave server will work equally well. .Pp .It Fl o Do not automatically override the password authentication checks for the super-user on the NIS master server; assume 'old' mode instead. This flag is of limited practical use but is useful for testing. .El .Sh FILES .Bl -tag -width /etc/master.passwd -compact .It Pa /etc/master.passwd The user database .It Pa /etc/passwd A Version 7 format password file .It Pa /etc/passwd.XXXXXX Temporary copy of the password file .It Pa /etc/login.conf Login class capabilities database .It Pa /etc/auth.conf configure authentication services .El .Sh SEE ALSO .Xr chpass 1 , .Xr kerberos 1 , .Xr kinit 1 , .Xr login 1 , .Xr login.conf 5 , .Xr passwd 5 , .Xr kpasswdd 8 , .Xr pwd_mkdb 8 , .Xr vipw 8 .Rs .%A Robert Morris .%A Ken Thompson .%T "UNIX password security" .Re .Sh NOTES The .Xr yppasswd 1 command is really only a link to .Nm . .Sh HISTORY A .Nm command appeared in .At v6 . Index: head/usr.bin/pr/pr.1 =================================================================== --- head/usr.bin/pr/pr.1 (revision 79534) +++ head/usr.bin/pr/pr.1 (revision 79535) @@ -1,377 +1,377 @@ .\" Copyright (c) 1991 Keith Muller. .\" Copyright (c) 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Keith Muller of the University of California, San Diego. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)pr.1 8.3 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" .Dd April 18, 1994 .Dt PR 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm pr .Nd print files .Sh SYNOPSIS .Nm .Bk -words .Op Ar \&+page .Ek .Bk -words .Op Fl Ar column .Ek .Op Fl adFmrt .Bk -words .Oo .Op Fl e .Op Ar char .Op Ar gap .Oc .Ek .Bk -words .Op Fl L Ar locale .Ek .Bk -words .Op Fl h Ar header .Ek .Bk -words .Oo .Op Fl i .Op Ar char .Op Ar gap .Oc .Ek .Bk -words .Op Fl l Ar lines .Ek .Bk -words .Op Fl o Ar offset .Ek .Bk -words .Oo .Op Fl s .Op Ar char .Oc .Ek .Bk -words .Oo .Op Fl n .Op Ar char .Op Ar width .Oc .Ek .Bk -words .Op Fl w Ar width .Ek .Op - .Op Ar .Sh DESCRIPTION The .Nm utility is a printing and pagination filter for text files. When multiple input files are specified, each is read, formatted, and written to standard output. By default, the input is separated into 66-line pages, each with .Bl -bullet .It A 5-line header with the page number, date, time, and the pathname of the file. .It A 5-line trailer consisting of blank lines. .El .Pp If standard output is associated with a terminal, diagnostic messages are suppressed until the .Nm utility has completed processing. .Pp When multiple column output is specified, text columns are of equal width. By default text columns are separated by at least one .Em . Input lines that do not fit into a text column are truncated. Lines are not truncated under single column output. .Sh OPTIONS In the following option descriptions, column, lines, offset, page, and width are positive decimal integers and gap is a nonnegative decimal integer. .Bl -tag -width 4n .It Ar \&+page Begin output at page number .Ar page of the formatted input. .It Fl Ar column Produce output that is .Ar columns wide (default is 1) that is written vertically down each column in the order in which the text is received from the input file. The options .Fl e and .Fl i are assumed. This option should not be used with .Fl m . When used with .Fl t , the minimum number of lines is used to display the output. .It Fl a Modify the effect of the .Fl column option so that the columns are filled across the page in a round-robin order (e.g., when column is 2, the first input line heads column 1, the second heads column 2, the third is the second line in column 1, etc.). This option requires the use of the .Fl column option. .It Fl d Produce output that is double spaced. An extra .Em character is output following every .Em found in the input. .It Fl e Xo .Op Ar char Ns .Op Ar gap .Xc Expand each input .Em to the next greater column position specified by the formula .Ar n*gap+1 , where .Em n is an integer > 0. If .Ar gap is zero or is omitted the default is 8. All .Em characters in the input are expanded into the appropriate number of .Em s . If any nondigit character, .Ar char , is specified, it is used as the input tab character. .It Fl F Use a .Em character for new pages, instead of the default behavior that uses a sequence of .Em characters. .It Fl h Ar header Use the string .Ar header to replace the .Ar file name in the header line. .It Fl i Xo .Op Ar char Ns .Op Ar gap .Xc In output, replace multiple .Em s with .Em s whenever two or more adjacent .Em s reach column positions .Ar gap+1 , .Ar 2*gap+1 , etc. If .Ar gap is zero or omitted, default .Em settings at every eighth column position is used. If any nondigit character, .Ar char , is specified, it is used as the output .Em character. .It Fl L Ar locale Use .Ar locale specified as argument instead of one found in environment. Use "C" to reset locale to default. .It Fl l Ar lines Override the 66 line default and reset the page length to .Ar lines . If .Ar lines is not greater than the sum of both the header and trailer depths (in lines), the .Nm utility suppresses output of both the header and trailer, as if the .Fl t option were in effect. .It Fl m Merge the contents of multiple files. One line from each file specified by a file operand is written side by side into text columns of equal fixed widths, in terms of the number of column positions. The number of text columns depends on the number of file operands successfully opened. The maximum number of files merged depends on page width and the per process open file limit. The options .Fl e and .Fl i are assumed. .It Fl n Xo .Op Ar char Ns .Op Ar width .Xc Provide .Ar width digit line numbering. The default for .Ar width , if not specified, is 5. The number occupies the first .Ar width column positions of each text column or each line of .Fl m output. If .Ar char (any nondigit character) is given, it is appended to the line number to separate it from whatever follows. The default for .Ar char is a .Em . Line numbers longer than .Ar width columns are truncated. .It Fl o Ar offset Each line of output is preceded by .Ar offset .Em s . If the .Fl o option is not specified, the default is zero. The space taken is in addition to the output line width. .It Fl r Write no diagnostic reports on failure to open a file. .It Fl s Ar char Separate text columns by the single character .Ar char instead of by the appropriate number of .Em s (default for .Ar char is the .Em character). .It Fl t Print neither the five-line identifying header nor the five-line trailer usually supplied for each page. Quit printing after the last line of each file without spacing to the end of the page. .It Fl w Ar width Set the width of the line to .Ar width column positions for multiple text-column output only. If the .Fl w option is not specified and the .Fl s option is not specified, the default width is 72. If the .Fl w option is not specified and the .Fl s option is specified, the default width is 512. .It Ar file A pathname of a file to be printed. If no .Ar file operands are specified, or if a .Ar file operand is .Sq Fl , the standard input is used. The standard input is used only if no .Ar file operands are specified, or if a .Ar file operand is .Sq Fl . .El .Pp The .Fl s option does not allow the option letter to be separated from its argument, and the options .Fl e , .Fl i , and .Fl n require that both arguments, if present, not be separated from the option letter. .Sh ERRORS If .Nm receives an interrupt while printing to a terminal, it flushes all accumulated error messages to the screen before terminating. .Pp The .Nm utility exits 0 on success, and 1 if an error occurs. .Pp Error messages are written to standard error during the printing process (if output is redirected) or after all successful file printing is complete (when printing to a terminal). .Sh SEE ALSO .Xr cat 1 , .Xr more 1 .Sh STANDARDS The .Nm utility is .St -p1003.2 compatible. .Sh HISTORY A .Nm command appeared in .At v1 . Index: head/usr.bin/quota/quota.1 =================================================================== --- head/usr.bin/quota/quota.1 (revision 79534) +++ head/usr.bin/quota/quota.1 (revision 79535) @@ -1,142 +1,142 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Robert Elz at The University of Melbourne. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" from: @(#)quota.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt QUOTA 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm quota .Nd display disk usage and limits .Sh SYNOPSIS .Nm .Op Fl g .Op Fl u .Op Fl v | Fl q .Nm .Op Fl u .Op Fl v | Fl q .Ar user .Nm .Op Fl g .Op Fl v | Fl q .Ar group .Sh DESCRIPTION .Nm Quota displays users' disk usage and limits. By default only the user quotas are printed. .Pp The following options are available: .Bl -tag -width indent .It Fl g Print group quotas for the group of which the user is a member. The optional .Fl u flag is equivalent to the default. .It Fl v .Nm Quota will display quotas on filesystems where no storage is allocated. .It Fl q Print a more terse message, containing only information on filesystems where usage is over quota. .El .Pp Specifying both .Fl g and .Fl u displays both the user quotas and the group quotas (for the user). .Pp Only the super-user may use the .Fl u flag and the optional .Ar user argument to view the limits of other users. Non-super-users can use the .Fl g flag and optional .Ar group argument to view only the limits of groups of which they are members. .Pp The .Fl q flag takes precedence over the .Fl v flag. .Pp .Nm Quota tries to report the quotas of all mounted filesystems. If the filesystem is mounted via .Tn NFS , it will attempt to contact the .Xr rpc.rquotad 8 daemon on the .Tn NFS server. For .Tn UFS filesystems, quotas must be turned on in .Pa /etc/fstab . If .Nm exits with a non-zero status, one or more filesystems are over quota. .Sh FILES .Bl -tag -width quota.group -compact .It Pa quota.user located at the filesystem root with user quotas .It Pa quota.group located at the filesystem root with group quotas .It Pa /etc/fstab to find filesystem names and locations .El .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Sh SEE ALSO .Xr quotactl 2 , .Xr fstab 5 , .Xr edquota 8 , .Xr quotacheck 8 , .Xr quotaon 8 , .Xr repquota 8 , .Xr rpc.rquotad 8 Index: head/usr.bin/renice/renice.8 =================================================================== --- head/usr.bin/renice/renice.8 (revision 79534) +++ head/usr.bin/renice/renice.8 (revision 79535) @@ -1,134 +1,134 @@ .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)renice.8 8.1 (Berkeley) 6/9/93 .\" $FreeBSD$ .\" .Dd June 9, 1993 .Dt RENICE 8 -.Os BSD 4 +.Os .Sh NAME .Nm renice .Nd alter priority of running processes .Sh SYNOPSIS .Nm .Ar priority .Oo .Op Fl p .Ar pid ... .Oc .Oo .Op Fl g .Ar pgrp ... .Oc .Oo .Op Fl u .Ar user ... .Oc .Sh DESCRIPTION .Nm Renice alters the scheduling priority of one or more running processes. The following .Ar who parameters are interpreted as process ID's, process group ID's, or user names. .Nm Renice Ns 'ing a process group causes all processes in the process group to have their scheduling priority altered. .Nm Renice Ns 'ing a user causes all processes owned by the user to have their scheduling priority altered. By default, the processes to be affected are specified by their process ID's. .Pp Options supported by .Nm : .Bl -tag -width Ds .It Fl g Force .Ar who parameters to be interpreted as process group ID's. .It Fl u Force the .Ar who parameters to be interpreted as user names. .It Fl p Resets the .Ar who interpretation to be (the default) process ID's. .El .Pp For example, .Bd -literal -offset renice +1 987 -u daemon root -p 32 .Ed .Pp would change the priority of process ID's 987 and 32, and all processes owned by users daemon and root. .Pp Users other than the super-user may only alter the priority of processes they own, and can only monotonically increase their ``nice value'' within the range 0 to .Dv PRIO_MAX (20). (This prevents overriding administrative fiats.) The super-user may alter the priority of any process and set the priority to any value in the range .Dv PRIO_MIN (\-20) to .Dv PRIO_MAX . Useful priorities are: 20 (the affected processes will run only when nothing else in the system wants to), 0 (the ``base'' scheduling priority), anything negative (to make things go very fast). .Sh FILES .Bl -tag -width /etc/passwd -compact .It Pa /etc/passwd to map user names to user ID's .El .Sh SEE ALSO .Xr nice 1 , .Xr rtprio 1 , .Xr getpriority 2 , .Xr setpriority 2 .Sh BUGS Non super-users can not increase scheduling priorities of their own processes, even if they were the ones that decreased the priorities in the first place. .Sh HISTORY The .Nm command appeared in .Bx 4.0 . Index: head/usr.bin/rlogin/rlogin.1 =================================================================== --- head/usr.bin/rlogin/rlogin.1 (revision 79534) +++ head/usr.bin/rlogin/rlogin.1 (revision 79535) @@ -1,239 +1,239 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)rlogin.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt RLOGIN 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm rlogin .Nd remote login .Sh SYNOPSIS .Ar rlogin .Op Fl 468DEKLdx .Op Fl e Ar char .Op Fl i Ar localname .Op Fl k Ar realm .Op Fl l Ar username .Ar host .Sh DESCRIPTION .Nm Rlogin starts a terminal session on a remote host .Ar host . .Pp .Nm Rlogin first attempts to use the Kerberos authorization mechanism, described below. If the remote host does not supporting Kerberos the standard Berkeley .Pa rhosts authorization mechanism is used. The options are as follows: .Bl -tag -width flag .It Fl 4 Use IPv4 addresses only. .It Fl 6 Use IPv6 addresses only. .It Fl 8 The .Fl 8 option allows an eight-bit input data path at all times; otherwise parity bits are stripped except when the remote side's stop and start characters are other than ^S/^Q. .It Fl D The .Fl D option sets the TCP_NODELAY socket option which can improve interactive response at the expense of increased network load. .It Fl E The .Fl E option stops any character from being recognized as an escape character. When used with the .Fl 8 option, this provides a completely transparent connection. .It Fl K The .Fl K option turns off all Kerberos authentication. .It Fl L The .Fl L option allows the rlogin session to be run in .Dq litout (see .Xr tty 4 ) mode. .It Fl d The .Fl d option turns on socket debugging (see .Xr setsockopt 2 ) on the TCP sockets used for communication with the remote host. .It Fl e The .Fl e option allows user specification of the escape character, which is .Dq ~ by default. This specification may be as a literal character, or as an octal value in the form \ennn. .It Fl i The .Fl i option allows the caller to specify a different local name to be used for authentication. This option is restricted to processes with uid 0. .It Fl k The .Fl k option requests rlogin to obtain tickets for the remote host in realm .Ar realm instead of the remote host's realm as determined by .Xr krb_realmofhost 3 . .It Fl l The .Fl l option specifies a different .Ar username for the remote login. If this option is not specified, your local username will be used. .It Fl x The .Fl x option turns on .Tn DES encryption for all data passed via the rlogin session. This may impact response time and .Tn CPU utilization, but provides increased security. .El .Pp A line of the form .Dq Aq escape char . disconnects from the remote host. Similarly, the line .Dq Ao escape char Ac Ns ^Z will suspend the .Nm session, and .Dq Ao escape\ char Ac Ns Ao delayed-suspend\ char Ac suspends the send portion of the rlogin, but allows output from the remote system. By default, the tilde .Pq Dq ~ character is the escape character, and normally control-Y .Pq Dq ^Y is the delayed-suspend character. .Pp All echoing takes place at the remote site, so that (except for delays) the .Nm is transparent. Flow control via ^S/^Q and flushing of input and output on interrupts are handled properly. .Sh KERBEROS AUTHENTICATION Each user may have a private authorization list in the file .Pa .klogin in their home directory. Each line in this file should contain a Kerberos principal name of the form .Ar principal.instance@realm . If the originating user is authenticated to one of the principals named in .Pa .klogin , access is granted to the account. The principal .Ar accountname.@localrealm is granted access if there is no .Pa .klogin file. Otherwise a login and password will be prompted for on the remote machine as in .Xr login 1 . To avoid certain security problems, the .Pa .klogin file must be owned by the remote user. .Pp If Kerberos authentication fails, a warning message is printed and the standard Berkeley .Nm is used instead. .Sh ENVIRONMENT The following environment variable is utilized by .Nm : .Bl -tag -width TERM .It Ev TERM Determines the user's terminal type. .El .Sh SEE ALSO .Xr login 1 , .Xr rsh 1 , .Xr telnet 1 , .Xr setsockopt 2 , .Xr kerberos 3 , .Xr krb_realmofhost 3 , .Xr krb_sendauth 3 , .Xr ruserok 3 , .Xr tty 4 , .Xr auth.conf 5 , .Xr hosts 5 , .Xr hosts.equiv 5 , .Xr rlogind 8 , .Xr rshd 8 .Sh FILES .Bl -tag -width /etc/hosts -compact .It Pa /etc/hosts .It Pa /etc/hosts.equiv .It Pa /etc/auth.conf .It Ev $HOME Ns Pa /.rhosts .It Ev $HOME Ns Pa /.klogin .El .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Pp IPv6 support was added by WIDE/KAME project. .Sh BUGS .Nm Rlogin will be replaced by .Xr telnet 1 in the near future. .Pp More of the environment should be propagated. Index: head/usr.bin/rsh/rsh.1 =================================================================== --- head/usr.bin/rsh/rsh.1 (revision 79534) +++ head/usr.bin/rsh/rsh.1 (revision 79535) @@ -1,193 +1,193 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)rsh.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt RSH 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm rsh .Nd remote shell .Sh SYNOPSIS .Nm .Op Fl 46Kdnx .Op Fl t Ar timeout .Op Fl k Ar realm .Op Fl l Ar username .Ar host .Op command .Sh DESCRIPTION .Nm Rsh executes .Ar command on .Ar host . .Pp .Nm Rsh copies its standard input to the remote command, the standard output of the remote command to its standard output, and the standard error of the remote command to its standard error. Interrupt, quit and terminate signals are propagated to the remote command; .Nm normally terminates when the remote command does. The options are as follows: .Bl -tag -width flag .It Fl 4 Use IPv4 addresses only. .It Fl 6 Use IPv6 addresses only. .It Fl K Turn off all Kerberos authentication. .It Fl d Turn on socket debugging (using .Xr setsockopt 2 ) on the .Tn TCP sockets used for communication with the remote host. .It Fl k Ar realm Cause .Nm to obtain tickets for the remote host in .Ar realm instead of the remote host's realm as determined by .Xr krb_realmofhost 3 . .It Fl l Ar username Allow the remote .Ar username to be specified. By default, the remote username is the same as the local username. Kerberos authentication is used, and authorization is determined as in .Xr rlogin 1 . .It Fl n Redirect input from the special device .Pa /dev/null (see the .Sx BUGS section of this manual page). .It Fl x Turn on .Tn DES encryption for all data exchange. This may introduce a significant delay in response time. .It Fl t Ar timeout Allow a .Ar timeout to be specified (in seconds). If no data is sent or received in this time, .Nm will exit. .El .Pp If no .Ar command is specified, you will be logged in on the remote host using .Xr rlogin 1 . .Pp Shell metacharacters which are not quoted are interpreted on local machine, while quoted metacharacters are interpreted on the remote machine. For example, the command .Pp .Dl rsh otherhost cat remotefile >> localfile .Pp appends the remote file .Ar remotefile to the local file .Ar localfile , while .Pp .Dl rsh otherhost cat remotefile \&">>\&" other_remotefile .Pp appends .Ar remotefile to .Ar other_remotefile . .\" .Pp .\" Many sites specify a large number of host names as commands in the .\" directory /usr/hosts. .\" If this directory is included in your search path, you can use the .\" shorthand ``host command'' for the longer form ``rsh host command''. .Sh FILES .Bl -tag -width /etc/hosts -compact .It Pa /etc/hosts .It Pa /etc/auth.conf .El .Sh SEE ALSO .Xr rlogin 1 , .Xr setsockopt 2 , .Xr kerberos 3 , .Xr krb_realmofhost 3 , .Xr krb_sendauth 3 , .Xr rcmd 3 , .Xr ruserok 3 , .Xr auth.conf 5 , .Xr hosts 5 , .Xr hosts.equiv 5 , .Xr rlogind 8 , .Xr rshd 8 .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Sh BUGS If you are using .Xr csh 1 and put a .Nm in the background without redirecting its input away from the terminal, it will block even if no reads are posted by the remote command. If no input is desired you should redirect the input of .Nm to .Pa /dev/null using the .Fl n option. .Pp You cannot run an interactive command (like .Xr rogue 6 or .Xr vi 1 ) using .Nm ; use .Xr rlogin 1 instead. .Pp Stop signals stop the local .Nm process only; this is arguably wrong, but currently hard to fix for reasons too complicated to explain here. Index: head/usr.bin/rup/rup.1 =================================================================== --- head/usr.bin/rup/rup.1 (revision 79534) +++ head/usr.bin/rup/rup.1 (revision 79535) @@ -1,95 +1,95 @@ .\" -*- nroff -*- .\" .\" Copyright (c) 1985, 1991 The Regents of the University of California. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd June 7, 1993 .Dt RUP 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm rup .Nd remote status display .Sh SYNOPSIS .Nm .Op Ar host ... .Sh DESCRIPTION .Nm Rup displays a summary of the current system status of a particular .Ar host or all hosts on the local network. The output shows the current time of day, how long the system has been up, and the load averages. The load average numbers give the number of jobs in the run queue averaged over 1, 5 and 15 minutes. .Pp The .Xr rpc.rstatd 8 daemon must be running on the remote host for this command to work. .Nm Rup uses an RPC protocol defined in .Pa /usr/include/rpcsvc/rstat.x . .Sh EXAMPLES .Bd -literal example% rup otherhost otherhost 7:36am up 6 days, 16:45, load average: 0.20, 0.23, 0.18 example% .Ed .Sh DIAGNOSTICS .Bl -diag .It rup: RPC: Program not registered The .Xr rpc.rstatd 8 daemon has not been started on the remote host. .It rup: RPC: Timed out A communication error occurred. Either the network is excessively congested, or the .Xr rpc.rstatd 8 daemon has terminated on the remote host. .It rup: RPC: Port mapper failure - RPC: Timed out The remote host is not running the portmapper (see .Xr rpcbind 8 ) , and cannot accommodate any RPC-based services. The host may be down. .El .Sh SEE ALSO .Xr rpc.rstatd 8 , .Xr rpcbind 8 .Sh HISTORY The .Nm command appeared in .Em Sun-OS . .Sh BUGS The sorting options are not implemented. Index: head/usr.bin/ruptime/ruptime.1 =================================================================== --- head/usr.bin/ruptime/ruptime.1 (revision 79534) +++ head/usr.bin/ruptime/ruptime.1 (revision 79535) @@ -1,83 +1,83 @@ .\" Copyright (c) 1983, 1990, 1993, 1994 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)ruptime.1 8.2 (Berkeley) 4/5/94 .\" $FreeBSD$ .\" .Dd April 5, 1994 .Dt RUPTIME 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm ruptime .Nd show host status of local machines .Sh SYNOPSIS .Nm .Op Fl alrtu .Sh DESCRIPTION .Nm Ruptime gives a status line like .Xr uptime 1 for each machine on the local network; these are formed from packets broadcast by each host on the network once every three minutes. .Pp Machines for which no status report has been received for 11 minutes are shown as being down, and machines for which no status report has been received for 4 days are not shown in the list at all. .Pp The options are as follows: .Bl -tag -width Ds .It Fl a Include all users. By default, if a user hasn't typed to the system for an hour or more, then the user will be omitted from the output. .It Fl l Sort by load average. .It Fl r Reverse the sort order. .It Fl t Sort by uptime. .It Fl u Sort by number of users. .El .Pp The default listing is sorted by host name. .Sh FILES .Bl -tag -width /var/rwho/whod.* -compact .It Pa /var/rwho/whod.* data files .El .Sh SEE ALSO .Xr rwho 1 , .Xr uptime 1 , .Xr rwhod 8 .Sh HISTORY .Nm Ruptime appeared in .Bx 4.2 . Index: head/usr.bin/rusers/rusers.1 =================================================================== --- head/usr.bin/rusers/rusers.1 (revision 79534) +++ head/usr.bin/rusers/rusers.1 (revision 79535) @@ -1,106 +1,106 @@ .\" Copyright (c) 1983, 1990 The Regents of the University of California. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" from: @(#)rusers.1 6.7 (Berkeley) 4/23/91 .\" $FreeBSD$ .\" .Dd April 23, 1991 .Dt RUSERS 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm rusers .Nd who is logged in to machines on local network .Sh SYNOPSIS .Nm .Op Fl al .Op Ar host ... .Sh DESCRIPTION The .Nm command produces output similar to .Xr who 1 , but for the list of .Ar host Ns s or all machines on the local network. For each .Ar host responding to the .Nm query, the hostname with the names of the users currently logged on is printed on each line. The .Nm command will wait for one minute to catch late responders. .Pp The following options are available: .Bl -tag -width indent .It Fl a Print all machines responding even if no one is currently logged in. .It Fl l Print a long format listing. This includes the user name, host name, tty that the user is logged in to, the date and time the user logged in, the amount of time since the user typed on the keyboard, and the remote host they logged in from (if applicable). .El .Sh DIAGNOSTICS .Bl -diag .It rusers: RPC: Program not registered The .Xr rpc.rusersd 8 daemon has not been started on the remote host. .It rusers: RPC: Timed out A communication error occurred. Either the network is excessively congested, or the .Xr rpc.rusersd 8 daemon has terminated on the remote host. .It rusers: "RPC: Port mapper failure - RPC: Timed out" The remote host is not running the portmapper (see .Xr rpcbind 8 ) , and cannot accommodate any RPC-based services. The host may be down. .El .Sh SEE ALSO .Xr rwho 1 , .Xr users 1 , .Xr who 1 , .Xr rpc.rusersd 8 , .Xr rpcbind 8 .Sh HISTORY The .Nm command appeared in .Em Sun-OS . .Sh BUGS The sorting options are not implemented. Index: head/usr.bin/rwall/rwall.1 =================================================================== --- head/usr.bin/rwall/rwall.1 (revision 79534) +++ head/usr.bin/rwall/rwall.1 (revision 79535) @@ -1,81 +1,81 @@ .\" Copyright (c) 1983, 1990 The Regents of the University of California. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" from: @(#)rwall.1 6.7 (Berkeley) 4/23/91 .\" $FreeBSD$ .\" .Dd April 23, 1991 .Dt RWALL 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm rwall .Nd send a message to users logged on a host .Sh SYNOPSIS .Nm .Ar host .Op Ar file .Sh DESCRIPTION The .Nm command sends a message to the users logged into the specified .Ar host . The message to be sent can be typed in and terminated with EOF or it can be in a .Ar file . .Sh DIAGNOSTICS .Bl -diag .It rwall: RPC: Program not registered The .Xr rpc.rwalld 8 daemon has not been started on the remote host. .It rwall: RPC: Timed out A communication error occurred. Either the network is excessively congested, or the .Xr rpc.rwalld 8 daemon has terminated on the remote host. .It rwall: RPC: Port mapper failure - RPC: Timed out The remote host is not running the portmapper (see .Xr rpcbind 8 ) , and cannot accomodate any RPC-based services. The host may be down. .El .Sh SEE ALSO .Xr who 1 , .Xr rpc.rwalld 8 , .Xr rpcbind 8 .Sh HISTORY The .Nm command appeared in .Em Sun-OS . .Sh BUGS The sorting options are not implemented. Index: head/usr.bin/rwho/rwho.1 =================================================================== --- head/usr.bin/rwho/rwho.1 (revision 79534) +++ head/usr.bin/rwho/rwho.1 (revision 79535) @@ -1,84 +1,84 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)rwho.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt RWHO 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm rwho .Nd who is logged in on local machines .Sh SYNOPSIS .Nm .Op Fl a .Sh DESCRIPTION The .Nm command produces output similar to .Xr who 1 , but for all machines on the local network. If no report has been received from a machine for 5 minutes then .Nm assumes the machine is down, and does not report users last known to be logged into that machine. .Pp If a user has not typed to the system for a minute or more, then .Nm reports this idle time. .Pp The following option is available: .Bl -tag -width indent .It Fl a Include all users. By default, if a user hasn't typed to the system for an hour or more, then the user will be omitted from the output. .El .Sh FILES .Bl -tag -width /var/rwho/whod.* -compact .It Pa /var/rwho/whod.* information about other machines .El .Sh SEE ALSO .Xr ruptime 1 , .Xr who 1 , .Xr rwhod 8 .Sh HISTORY The .Nm command appeared in .Bx 4.3 . .Sh BUGS This is unwieldy when the number of machines on the local net is large. Index: head/usr.bin/script/script.1 =================================================================== --- head/usr.bin/script/script.1 (revision 79534) +++ head/usr.bin/script/script.1 (revision 79535) @@ -1,154 +1,154 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)script.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt SCRIPT 1 -.Os BSD 4 +.Os .Sh NAME .Nm script .Nd make typescript of terminal session .Sh SYNOPSIS .Nm .Op Fl a .Op Fl k .Op Fl q .Op Fl t Ar time .Op Ar file Op command ... .Sh DESCRIPTION .Nm Script makes a typescript of everything printed on your terminal. It is useful for students who need a hardcopy record of an interactive session as proof of an assignment, as the typescript file can be printed out later with .Xr lpr 1 . .Pp If the argument .Ar file is given, .Nm saves all dialogue in .Ar file . If no file name is given, the typescript is saved in the file .Pa typescript . .Pp If the argument .Ar command ... is given, .Nm will run the specified command with an optional argument vector instead of an interactive shell. .Pp Options: .Bl -tag -width xxxxxxx .It Fl a Append the output to .Ar file or .Pa typescript , retaining the prior contents. .It Fl k Log keys sent to program as well as output. .It Fl q Run in quiet mode, omit the start and stop status messages. .It Fl t Ar time Specify time interval between flushing script output file. A value of 0 causes .Nm to flush for every character I/O event. The default interval is 30 seconds. .El .Pp The script ends when the forked shell (or command) exits (a .Em control-D to exit the Bourne shell .Pf ( Xr sh 1 ) , and .Em exit , .Em logout or .Em control-d (if .Em ignoreeof is not set) for the C-shell, .Xr csh 1 ) . .Pp Certain interactive commands, such as .Xr vi 1 , create garbage in the typescript file. .Nm Script works best with commands that do not manipulate the screen. The results are meant to emulate a hardcopy terminal, not an addressable one. .Sh ENVIRONMENT The following environment variable is utilized by .Nm : .Bl -tag -width SHELL .It Ev SHELL If the variable .Ev SHELL exists, the shell forked by .Nm will be that shell. If .Ev SHELL is not set, the Bourne shell is assumed. (Most shells set this variable automatically). .El .Sh SEE ALSO .Xr csh 1 (for the .Em history mechanism). .Sh HISTORY The .Nm command appeared in .Bx 3.0 . .Sh BUGS .Nm Script places .Sy everything in the log file, including linefeeds and backspaces. This is not what the naive user expects. .Pp It is not possible to specify a command without also naming the script file because of argument parsing compatibility issues. .Pp When running in .Fl k mode, echo cancelling is far from ideal. The slave terminal mode is checked for ECHO mode to check when to avoid manual echo logging. This does not work when in a raw mode where the program being run is doing manual echo. Index: head/usr.bin/shar/shar.1 =================================================================== --- head/usr.bin/shar/shar.1 (revision 79534) +++ head/usr.bin/shar/shar.1 (revision 79535) @@ -1,111 +1,111 @@ .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)shar.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt SHAR 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm shar .Nd create a shell archive of files .Sh SYNOPSIS .Nm .Ar .Sh DESCRIPTION The .Nm command writes a .Xr sh 1 shell script to the standard output which will recreate the file hierarchy specified by the command line operands. Directories will be recreated and must be specified before the files they contain (the .Xr find 1 utility does this correctly). .Pp The .Nm command is normally used for distributing files by .Xr ftp 1 or .Xr mail 1 . .Sh SEE ALSO .Xr compress 1 , .Xr mail 1 , .Xr tar 1 , .Xr uuencode 1 .Sh BUGS The .Nm command makes no provisions for special types of files or files containing magic characters. The .Nm command cannot handle files without a newline ('\\n') as the last character. .Pp It is easy to insert trojan horses into .Nm files. It is strongly recommended that all shell archive files be examined before running them through .Xr sh 1 . Archives produced using this implementation of .Nm may be easily examined with the command: .Bd -literal -offset indent egrep -v '^[X#]' shar.file .Ed .Sh EXAMPLES To create a shell archive of the program .Xr ls 1 and mail it to Rick: .Bd -literal -offset indent cd ls shar `find . -print` \&| mail -s "ls source" rick .Ed .Pp To recreate the program directory: .Bd -literal -offset indent mkdir ls cd ls \&... \&... sh archive .Ed .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/showmount/showmount.8 =================================================================== --- head/usr.bin/showmount/showmount.8 (revision 79534) +++ head/usr.bin/showmount/showmount.8 (revision 79535) @@ -1,97 +1,97 @@ .\" Copyright (c) 1989, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Rick Macklem at The University of Guelph. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)showmount.8 8.3 (Berkeley) 3/29/95 .\" $FreeBSD$ .\" .Dd March 29, 1995 .Dt SHOWMOUNT 8 -.Os BSD 4 +.Os .Sh NAME .Nm showmount .Nd show remote nfs mounts on host .Sh SYNOPSIS .Nm .Op Fl ade3 .Op Ar host .Sh DESCRIPTION .Nm Showmount shows status information about the .Tn NFS server on .Ar host . By default it prints the names of all hosts that have .Tn NFS file systems mounted on the host. See .%T "NFS: Network File System Protocol Specification" , RFC 1094, Appendix A, and .%T "NFS: Network File System Version 3 Protocol Specification" , Appendix I, for a detailed description of the protocol. .Bl -tag -width Ds .It Fl a List all mount points in the form: .Bd -ragged -offset indent -compact .Ar host : Ns Ar dirpath . .Ed .It Fl d List directory paths of mount points instead of hosts. .It Fl e Show the .Ar host Ns 's exports list. .It Fl 3 Use mount protocol Version 3, compatible with NFS Version 3. .El .Sh SEE ALSO .Xr mount 8 , .Xr mountd 8 , .Xr mount_nfs 8 .Sh BUGS The mount daemon running on the server only has an idea of the actual mounts, since the .Tn NFS server is stateless. .Nm Showmount will only display the information as accurately as the mount daemon reports it. .Sh HISTORY The .Nm utility first appeared in .Bx 4.4 . Index: head/usr.bin/sockstat/sockstat.1 =================================================================== --- head/usr.bin/sockstat/sockstat.1 (revision 79534) +++ head/usr.bin/sockstat/sockstat.1 (revision 79535) @@ -1,117 +1,117 @@ .\"- .\" Copyright (c) 1999 Dag-Erling Coïdan Smørgrav .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer .\" in this position and unchanged. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. The name of the author may not be used to endorse or promote products .\" derived from this software without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD$ .\" .Dd April 13, 1999 .Dt SOCKSTAT 1 -.Os FreeBSD +.Os .Sh NAME .Nm sockstat .Nd list open sockets .Sh SYNOPSIS .Nm .Op Fl 46clu .Sh DESCRIPTION The .Nm command lists open Internet or Unix domain sockets. .Pp The following options are available: .Bl -tag -width Fl .It Fl 4 Show AF_INET (IPv4) sockets. .It Fl 6 Show AF_INET6 (IPv6) sockets. .It Fl c Show connected sockets. .It Fl l Show listening sockets. .It Fl u Show AF_LOCAL (Unix) sockets. .El .Pp If neither .Fl 4 , .Fl 6 or .Fl u is specified, .Nm will list sockets in all three domains. .Pp If neither .Fl c or .Fl l is specified, .Nm will list both listening and connected sockets. .Pp The information listed for each socket is: .Bl -tag -width "FOREIGN ADDRESS" .It Li USER The user who owns the socket. .It Li COMMAND The command which holds the socket. .It Li PID The process ID of the command which holds the socket. .It Li FD The file descriptor number of the socket. .It Li PROTO The transport protocol associated with the socket for Internet sockets, or the type of socket (stream or datagram) for Unix sockets. .It Li ADDRESS (Unix sockets only) For bound sockets, this is the filename of the socket. For other sockets, it is the name, PID and file descriptor number of the peer, or "(none)" if the socket is neither bound nor connected. .It Li LOCAL ADDRESS (Internet sockets only) The address the local end of the socket is bound to (see .Xr getsockname 2 ) . .It Li FOREIGN ADDRESS (Internet sockets only) The address the foreign end of the socket is bound to (see .Xr getpeername 2 ) . .El .Sh SEE ALSO .Xr fstat 1 , .Xr netstat 1 , .Xr inet 4 , .Xr inet6 4 .Sh HISTORY The .Nm command appeared in .Fx 3.1 . .Sh AUTHORS The .Nm command and this manual page were written by .An Dag-Erling Sm\(/orgrav Aq des@freebsd.org . Index: head/usr.bin/soelim/soelim.1 =================================================================== --- head/usr.bin/soelim/soelim.1 (revision 79534) +++ head/usr.bin/soelim/soelim.1 (revision 79535) @@ -1,89 +1,89 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)soelim.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt SOELIM 1 -.Os BSD 3 +.Os .Sh NAME .Nm soelim .Nd eliminate \&.so's from nroff input .Sh SYNOPSIS .Nm .Op Ar .Sh DESCRIPTION .Nm Soelim reads the specified files or the standard input and performs the textual inclusion implied by the .Xr nroff 1 directives of the form: .Pp .Dl \&.so somefile .Pp The directives need to appear at the beginning of input lines. This is useful since programs such as .Xr tbl 1 do not normally do this; it allows the placement of individual tables in separate files to be run as a part of a large document. .Pp An argument consisting of a single minus .Ql Fl is taken to be a file name corresponding to the standard input. .Pp Note that inclusion can be suppressed by using .Ql \e' instead of .Ql \e. , i.e. .Pp .Dl \'so /usr/lib/tmac.s .Pp A sample usage of .Nm would be .Pp .Bd -literal -offset indent -compact soelim exum?.n \&| tbl \&| nroff \-ms \&| col \&| lpr .Ed .Sh SEE ALSO .Xr colcrt 1 , .Xr more 1 .Sh BUGS The format of the source commands must involve no strangeness \- exactly one blank must precede and no blanks follow the file name. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/strings/strings.1 =================================================================== --- head/usr.bin/strings/strings.1 (revision 79534) +++ head/usr.bin/strings/strings.1 (revision 79535) @@ -1,97 +1,97 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)strings.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt STRINGS 1 -.Os BSD 3 +.Os .Sh NAME .Nm strings .Nd find printable strings in a file .Sh SYNOPSIS .Nm .Op Fl afo .Op Fl n Ar number .Op Ar .Sh DESCRIPTION .Nm Strings displays the sequences of printable characters in each of the specified files, or in the standard input, by default. By default, a sequence must be at least four characters in length before being displayed. .Pp The options are as follows: .Bl -tag -width Ds .It Fl a By default, .Nm only searches the text and data segments of object files. The .Fl a option causes .Nm to search the entire object file. .It Fl f Each string is preceded by the name of the file in which it was found. .It Fl n Specifies the minimum number of characters in a sequence to be .Ar number , instead of four. .It Fl o Each string is preceded by its decimal offset in the file. .El .Pp .Nm Strings is useful for identifying random binaries, among other things. .Sh SEE ALSO .Xr hexdump 1 .Sh BUGS The algorithm for identifying strings is extremely primitive. In particular, machine code instructions on certain architectures can resemble sequences of ASCII bytes, which will fool the algorithm. .Sh COMPATIBILITY Historic implementations of .Nm only search the initialized data portion of the object file. This was reasonable as strings were normally stored there. Given new compiler technology which installs strings in the text portion of the object file, the default behavior was changed. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/strings/strings.1aout =================================================================== --- head/usr.bin/strings/strings.1aout (revision 79534) +++ head/usr.bin/strings/strings.1aout (revision 79535) @@ -1,96 +1,97 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)strings.1 8.1 (Berkeley) 6/6/93 +.\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt STRINGS 1 -.Os BSD 3 +.Os .Sh NAME .Nm strings .Nd find printable strings in a file .Sh SYNOPSIS .Nm .Op Fl afo .Op Fl n Ar number .Op Ar .Sh DESCRIPTION .Nm Strings displays the sequences of printable characters in each of the specified files, or in the standard input, by default. By default, a sequence must be at least four characters in length before being displayed. .Pp The options are as follows: .Bl -tag -width Ds .It Fl a By default, .Nm only searches the text and data segments of object files. The .Fl a option causes .Nm to search the entire object file. .It Fl f Each string is preceded by the name of the file in which it was found. .It Fl n Specifies the minimum number of characters in a sequence to be .Ar number , instead of four. .It Fl o Each string is preceded by its decimal offset in the file. .El .Pp .Nm Strings is useful for identifying random binaries, among other things. .Sh SEE ALSO .Xr hexdump 1 .Sh BUGS The algorithm for identifying strings is extremely primitive. In particular, machine code instructions on certain architectures can resemble sequences of ASCII bytes, which will fool the algorithm. .Sh COMPATIBILITY Historic implementations of .Nm only search the initialized data portion of the object file. This was reasonable as strings were normally stored there. Given new compiler technology which installs strings in the text portion of the object file, the default behavior was changed. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/symorder/symorder.1 =================================================================== --- head/usr.bin/symorder/symorder.1 (revision 79534) +++ head/usr.bin/symorder/symorder.1 (revision 79535) @@ -1,96 +1,96 @@ .\" Copyright (c) 1980, 1990 The Regents of the University of California. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)symorder.1 6.5 (Berkeley) 4/22/91 .\" $FreeBSD$ .\" .Dd April 22, 1991 .Dt SYMORDER 1 -.Os BSD 3 +.Os .Sh NAME .Nm symorder .Nd rearrange name list .Sh SYNOPSIS .Nm .Op Fl c .Op Fl m .Op Fl t .Op Fl x Ar excludelist .Ar symlist file .Sh DESCRIPTION The file .Ar symlist contains a list of symbols to be found in .Ar file , one symbol per line. .Pp The symbol table of .Ar file is updated in place; symbols read from .Ar symlist are relocated to the beginning of the table and in the order given. .Bl -tag -width flag .It Fl c Makes all any symbols not in .Ar symlist local to this file. .It Fl t Restrict the symbol table to the symbols listed in .Ar symlist . .It Fl x Ar excludelist Exclude the symbols listed in .Ar excludelist from the symbol table. .It Fl m Exit with status zero, even if some symbols are missing. .El .Pp This program was specifically designed to cut down on the overhead of getting symbols from .Pa /kernel . .Sh DIAGNOSTICS The .Nm utility exits 0 on success, 1 if a symbol listed in the .Ar symlist file was not found in the symbol table, and >1 if an error occurs. .Sh SEE ALSO .Xr nm 1 , .Xr strip 1 , .Xr nlist 3 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/systat/systat.1 =================================================================== --- head/usr.bin/systat/systat.1 (revision 79534) +++ head/usr.bin/systat/systat.1 (revision 79535) @@ -1,548 +1,548 @@ .\" Copyright (c) 1985, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)systat.1 8.2 (Berkeley) 12/30/93 .\" $FreeBSD$ .\" .Dd September 9, 1997 .Dt SYSTAT 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm systat .Nd display system statistics on a crt .Sh SYNOPSIS .Nm .Op Fl display .Op Ar refresh-interval .Sh DESCRIPTION .Nm Systat displays various system statistics in a screen oriented fashion using the curses screen display library, .Xr ncurses 3 . .Pp While .Nm is running the screen is usually divided into two windows (an exception is the vmstat display which uses the entire screen). The upper window depicts the current system load average. The information displayed in the lower window may vary, depending on user commands. The last line on the screen is reserved for user input and error messages. .Pp By default .Nm displays the processes getting the largest percentage of the processor in the lower window. Other displays show swap space usage, disk .Tn I/O statistics (a la .Xr iostat 8 ) , virtual memory statistics (a la .Xr vmstat 8 ) , network ``mbuf'' utilization, .Tn TCP/IP statistics, and network connections (a la .Xr netstat 1 ) . .Pp Input is interpreted at two different levels. A ``global'' command interpreter processes all keyboard input. If this command interpreter fails to recognize a command, the input line is passed to a per-display command interpreter. This allows each display to have certain display-specific commands. .Pp Command line options: .Bl -tag -width "refresh_interval" .It Fl Ns Ar display The .Fl flag expects .Ar display to be one of: .Ic icmp , .Ic iostat , .Ic ip , .Ic mbufs , .Ic netstat , .Ic pigs , .Ic swap , .Ic tcp , or .Ic vmstat . These displays can also be requested interactively (without the .Dq Fl ) and are described in full detail below. .It Ar refresh-interval The .Ar refresh-value specifies the screen refresh time interval in seconds. .El .Pp Certain characters cause immediate action by .Nm . These are .Bl -tag -width Fl .It Ic \&^L Refresh the screen. .It Ic \&^G Print the name of the current ``display'' being shown in the lower window and the refresh interval. .It Ic \&^Z Stop .Nm . .It Ic \&: Move the cursor to the command line and interpret the input line typed as a command. While entering a command the current character erase, word erase, and line kill characters may be used. .El .Pp The following commands are interpreted by the ``global'' command interpreter. .Bl -tag -width Fl .It Ic help Print the names of the available displays on the command line. .It Ic load Print the load average over the past 1, 5, and 15 minutes on the command line. .It Ic stop Stop refreshing the screen. .It Xo .Op Ic start .Op Ar number .Xc Start (continue) refreshing the screen. If a second, numeric, argument is provided it is interpreted as a refresh interval (in seconds). Supplying only a number will set the refresh interval to this value. .It Ic quit Exit .Nm . (This may be abbreviated to .Ic q . ) .El .Pp The available displays are: .Bl -tag -width Ic .It Ic pigs Display, in the lower window, those processes resident in main memory and getting the largest portion of the processor (the default display). When less than 100% of the processor is scheduled to user processes, the remaining time is accounted to the ``idle'' process. .It Ic icmp Display, in the lower window, statistics about messages received and transmitted by the Internet Control Message Protocol .Pq Dq Tn ICMP . The left half of the screen displays information about received packets, and the right half displays information regarding transmitted packets. .Pp The .Ic icmp display understands two commands: .Ic mode and .Ic reset . The .Ic mode command is used to select one of four display modes, given as its argument: .Bl -tag -width absoluteXX -compact .It Ic rate : show the rate of change of each value in packets (the default) per second .It Ic delta : show the rate of change of each value in packets per refresh interval .It Ic since : show the total change of each value since the display was last reset .It Ic absolute : show the absolute value of each statistic .El .Pp The .Ic reset command resets the baseline for .Ic since mode. The .Ic mode command with no argument will display the current mode in the command line. .It Ic ip Otherwise identical to the .Ic icmp display, except that it displays .Tn IP and .Tn UDP statistics. .It Ic tcp Like .Ic icmp , but with .Tn TCP statistics. .It Ic iostat Display, in the lower window, statistics about processor use and disk throughput. Statistics on processor use appear as bar graphs of the amount of time executing in user mode (``user''), in user mode running low priority processes (``nice''), in system mode (``system''), in interrupt mode (``interrupt''), and idle (``idle''). Statistics on disk throughput show, for each drive, megabytes per second, average number of disk transactions per second, and average kilobytes of data per transaction. This information may be displayed as bar graphs or as rows of numbers which scroll downward. Bar graphs are shown by default. .Pp The following commands are specific to the .Ic iostat display; the minimum unambiguous prefix may be supplied. .Pp .Bl -tag -width Fl -compact .It Cm numbers Show the disk .Tn I/O statistics in numeric form. Values are displayed in numeric columns which scroll downward. .It Cm bars Show the disk .Tn I/O statistics in bar graph form (default). .It Cm kbpt Toggle the display of kilobytes per transaction. (the default is to not display kilobytes per transaction). .El .It Ic swap Show information about swap space usage on all the swap areas compiled into the kernel. The first column is the device name of the partition. The next column is the total space available in the partition. The .Ar Used column indicates the total blocks used so far; the graph shows the percentage of space in use on each partition. If there are more than one swap partition in use, a total line is also shown. Areas known to the kernel, but not in use are shown as not available. .It Ic mbufs Display, in the lower window, the number of mbufs allocated for particular uses, i.e. data, socket structures, etc. .It Ic vmstat Take over the entire display and show a (rather crowded) compendium of statistics related to virtual memory usage, process scheduling, device interrupts, system name translation cacheing, disk .Tn I/O etc. .Pp The upper left quadrant of the screen shows the number of users logged in and the load average over the last one, five, and fifteen minute intervals. Below this line are statistics on memory utilization. The first row of the table reports memory usage only among active processes, that is processes that have run in the previous twenty seconds. The second row reports on memory usage of all processes. The first column reports on the number of physical pages claimed by processes. The second column reports the number of physical pages that are devoted to read only text pages. The third and fourth columns report the same two figures for virtual pages, that is the number of pages that would be needed if all processes had all of their pages. Finally the last column shows the number of physical pages on the free list. .Pp Below the memory display is a list of the average number of processes (over the last refresh interval) that are runnable (`r'), in page wait (`p'), in disk wait other than paging (`d'), sleeping (`s'), and swapped out but desiring to run (`w'). The row also shows the average number of context switches (`Csw'), traps (`Trp'; includes page faults), system calls (`Sys'), interrupts (`Int'), network software interrupts (`Sof'), and page faults (`Flt'). .Pp Below the process queue length listing is a numerical listing and a bar graph showing the amount of system (shown as `='), interrupt (shown as `+'), user (shown as `>'), nice (shown as `-'), and idle time (shown as ` '). .Pp Below the process display are statistics on name translations. It lists the number of names translated in the previous interval, the number and percentage of the translations that were handled by the system wide name translation cache, and the number and percentage of the translations that were handled by the per process name translation cache. .Pp At the bottom left is the disk usage display. It reports the number of kilobytes per transaction, transactions per second, megabytes per second and the percentage of the time the disk was busy averaged over the refresh period of the display (by default, five seconds). The system keeps statistics on most every storage device. In general, up to seven devices are displayed. The devices displayed by default are the first devices in the kernel's device list. See .Xr devstat 3 and .Xr devstat 9 for details on the devstat system. .Pp Under the date in the upper right hand quadrant are statistics on paging and swapping activity. The first two columns report the average number of pages brought in and out per second over the last refresh interval due to page faults and the paging daemon. The third and fourth columns report the average number of pages brought in and out per second over the last refresh interval due to swap requests initiated by the scheduler. The first row of the display shows the average number of disk transfers per second over the last refresh interval; the second row of the display shows the average number of pages transferred per second over the last refresh interval. .Pp Below the paging statistics is a column of lines regarding the virtual memory system which list the average number of pages copied on write (`cow'), pages zero filled on demand (`zfod'), slow (on-the-fly) zero fills percentage (`%slo-z'), pages wired down (`wire'), active pages (`act'), inactive pages (`inact'), pages on the buffer cache queue (`cache'), number of free pages (`free'), pages freed by the page daemon (`daefr'), pages freed by exiting processes (`prcfr'), pages reactivated from the free list (`react'), times the page daemon was awakened (`pdwak'), pages analyzed by the page daemon (`pdpgs'), and intransit blocking page faults (`intrn') per second over the refresh interval. .Pp At the bottom of this column are lines showing the amount of memory, in kilobytes, used for the buffer cache (`buf'), the number of dirty buffers in the buffer cache (`dirtybuf'), desired maximum size of vnode cache (`desiredvnodes') (mostly unused, except to size the name cache), number of vnodes actually allocated (`numvnodes'), and number of allocated vnodes that are free (`freevnodes'). .Pp Running down the right hand side of the display is a breakdown of the interrupts being handled by the system. At the top of the list is the total interrupts per second over the time interval. The rest of the column breaks down the total on a device by device basis. Only devices that have interrupted at least once since boot time are shown. .Pp The following commands are specific to the .Ic vmstat display; the minimum unambiguous prefix may be supplied. .Pp .Bl -tag -width Ar -compact .It Cm boot Display cumulative statistics since the system was booted. .It Cm run Display statistics as a running total from the point this command is given. .It Cm time Display statistics averaged over the refresh interval (the default). .It Cm want_fd Toggle the display of fd devices in the disk usage display. .It Cm zero Reset running statistics to zero. .El .It Ic netstat Display, in the lower window, network connections. By default, network servers awaiting requests are not displayed. Each address is displayed in the format ``host.port'', with each shown symbolically, when possible. It is possible to have addresses displayed numerically, limit the display to a set of ports, hosts, and/or protocols (the minimum unambiguous prefix may be supplied): .Pp .Bl -tag -width Ar -compact .It Cm all Toggle the displaying of server processes awaiting requests (this is the equivalent of the .Fl a flag to .Xr netstat 1 ) . .It Cm numbers Display network addresses numerically. .It Cm names Display network addresses symbolically. .It Cm proto Ar protocol Display only network connections using the indicated .Ar protocol . Supported protocols are ``tcp'', ``udp'', and ``all''. .It Cm ignore Op Ar items Do not display information about connections associated with the specified hosts or ports. Hosts and ports may be specified by name (``vangogh'', ``ftp''), or numerically. Host addresses use the Internet dot notation (``128.32.0.9''). Multiple items may be specified with a single command by separating them with spaces. .It Cm display Op Ar items Display information about the connections associated with the specified hosts or ports. As for .Ar ignore , .Op Ar items may be names or numbers. .It Cm show Op Ar ports\&|hosts Show, on the command line, the currently selected protocols, hosts, and ports. Hosts and ports which are being ignored are prefixed with a `!'. If .Ar ports or .Ar hosts is supplied as an argument to .Cm show , then only the requested information will be displayed. .It Cm reset Reset the port, host, and protocol matching mechanisms to the default (any protocol, port, or host). .El .El .Pp Commands to switch between displays may be abbreviated to the minimum unambiguous prefix; for example, ``io'' for ``iostat''. Certain information may be discarded when the screen size is insufficient for display. For example, on a machine with 10 drives the .Ic iostat bar graph displays only 3 drives on a 24 line terminal. When a bar graph would overflow the allotted screen space it is truncated and the actual value is printed ``over top'' of the bar. .Pp The following commands are common to each display which shows information about disk drives. These commands are used to select a set of drives to report on, should your system have more drives configured than can normally be displayed on the screen. .Pp .Bl -tag -width Ar -compact .It Cm ignore Op Ar drives Do not display information about the drives indicated. Multiple drives may be specified, separated by spaces. .It Cm display Op Ar drives Display information about the drives indicated. Multiple drives may be specified, separated by spaces. .It Cm only Op Ar drives Display only the specified drives. Multiple drives may be specified, separated by spaces. .It Cm drives Display a list of available devices. .It Cm match Xo .Ar type , Ns Ar if , Ns Ar pass .Op | Ar ... .Xc Display devivces matching the given pattern. The basic matching expressions are the same as those used in .Xr iostat 8 with one difference. Instead of specifying multiple .Fl t arguments which are then ORed together, the user instead specifys multiple matching expressions joined by the pipe .Pq Ql \&| character. The comma separated arguments within each matching expression are ANDed together, and then the pipe separated matching expressions are ORed together. Any device matching the combined expression will be displayed, if there is room to display it. For example: .Pp .Dl match da,scsi | cd,ide .Pp This will display all SCSI Direct Access devices and all IDE CDROM devices. .Pp .Dl match da | sa | cd,pass .Pp This will display all Direct Access devices, all Sequential Access devices, and all passthrough devices that provide access to CDROM drives. .El .Sh SEE ALSO .Xr netstat 1 , .Xr kvm 3 , .Xr icmp 4 , .Xr ip 4 , .Xr tcp 4 , .Xr udp 4 , .Xr iostat 8 , .Xr vmstat 8 .Sh FILES .Bl -tag -width /etc/networks -compact .It Pa /kernel For the namelist. .It Pa /dev/kmem For information in main memory. .It Pa /etc/hosts For host names. .It Pa /etc/networks For network names. .It Pa /etc/services For port names. .El .Sh HISTORY The .Nm program appeared in .Bx 4.3 . The .Ic icmp , .Ic ip , and .Ic tcp displays appeared in .Fx 3.0 ; the notion of having different display modes for the .Tn ICMP , .Tn IP , .Tn TCP , and .Tn UDP statistics was stolen from the .Fl C option to .Xr netstat 1 in Silicon Graphics' .Tn IRIX system. .Sh BUGS Takes 2-10 percent of the cpu. Certain displays presume a minimum of 80 characters per line. The .Ic vmstat display looks out of place because it is (it was added in as a separate display rather than created as a new program). Index: head/usr.bin/tail/tail.1 =================================================================== --- head/usr.bin/tail/tail.1 (revision 79534) +++ head/usr.bin/tail/tail.1 (revision 79535) @@ -1,186 +1,186 @@ .\" Copyright (c) 1980, 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" the Institute of Electrical and Electronics Engineers, Inc. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)tail.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt TAIL 1 -.Os BSD 4 +.Os .Sh NAME .Nm tail .Nd display the last part of a file .Sh SYNOPSIS .Nm .Oo .Fl F | .Fl f | .Fl r .Oc .Oo .Fl b Ar number | .Fl c Ar number | .Fl n Ar number .Oc .Op Ar .Sh DESCRIPTION The .Nm utility displays the contents of .Ar file or, by default, its standard input, to the standard output. .Pp The display begins at a byte, line or 512-byte block location in the input. Numbers having a leading plus (``+'') sign are relative to the beginning of the input, for example, .Dq -c +2 starts the display at the second byte of the input. Numbers having a leading minus (``-'') sign or no explicit sign are relative to the end of the input, for example, .Dq -n 2 displays the last two lines of the input. The default starting location is .Dq -n 10 , or the last 10 lines of the input. .Pp The options are as follows: .Bl -tag -width Ds .It Fl b Ar number The location is .Ar number 512-byte blocks. .It Fl c Ar number The location is .Ar number bytes. .It Fl f The .Fl f option causes .Nm to not stop when end of file is reached, but rather to wait for additional data to be appended to the input. The .Fl f option is ignored if the standard input is a pipe, but not if it is a FIFO. .It Fl F The .Fl F option implies the .Fl f option, but .Nm will also check to see if the file being followed has been renamed or rotated. The file is closed and reopened when .Nm detects that the filename being read from has a new inode number. The .Fl F option is ignored if reading from standard input rather than a file. .It Fl n Ar number The location is .Ar number lines. .It Fl r The .Fl r option causes the input to be displayed in reverse order, by line. Additionally, this option changes the meaning of the .Fl b , .Fl c and .Fl n options. When the .Fl r option is specified, these options specify the number of bytes, lines or 512-byte blocks to display, instead of the bytes, lines or blocks from the beginning or end of the input from which to begin the display. The default for the .Fl r option is to display all of the input. .El .Pp If more than a single file is specified, each file is preceded by a header consisting of the string .Dq ==> XXX <== where .Dq XXX is the name of the file. .Sh DIAGNOSTICS The .Nm utility exits 0 on success, and >0 if an error occurs. .Sh SEE ALSO .Xr cat 1 , .Xr head 1 , .Xr sed 1 .Sh STANDARDS The .Nm utility is expected to be a superset of the .St -p1003.2-92 specification. In particular, the .Fl F , .Fl b and .Fl r options are extensions to that standard. .Pp The historic command line syntax of .Nm is supported by this implementation. The only difference between this implementation and historic versions of .Nm , once the command line syntax translation has been done, is that the .Fl b , .Fl c and .Fl n options modify the .Fl r option, i.e. ``-r -c 4'' displays the last 4 characters of the last line of the input, while the historic tail (using the historic syntax ``-4cr'') would ignore the .Fl c option and display the last 4 lines of the input. .Sh HISTORY A .Nm command appeared in .At v7 . Index: head/usr.bin/talk/talk.1 =================================================================== --- head/usr.bin/talk/talk.1 (revision 79534) +++ head/usr.bin/talk/talk.1 (revision 79535) @@ -1,134 +1,134 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)talk.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt TALK 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm talk .Nd talk to another user .Sh SYNOPSIS .Nm .Ar person .Op Ar ttyname .Sh DESCRIPTION .Nm Talk is a visual communication program which copies lines from your terminal to that of another user. .Pp Options available: .Bl -tag -width ttyname .It Ar person If you wish to talk to someone on your own machine, then .Ar person is just the person's login name. If you wish to talk to a user on another host, then .Ar person is of the form .Ql user@host or .Ql host!user or .Ql host:user . .It Ar ttyname If you wish to talk to a user who is logged in more than once, the .Ar ttyname argument may be used to indicate the appropriate terminal name, where .Ar ttyname is of the form .Ql ttyXX . .El .Pp When first called, .Nm sends the message .Bd -literal -offset indent -compact Message from TalkDaemon@his_machine... talk: connection requested by your_name@your_machine. talk: respond with: talk your_name@your_machine .Ed .Pp to the user you wish to talk to. At this point, the recipient of the message should reply by typing .Pp .Dl talk \ your_name@your_machine .Pp It doesn't matter from which machine the recipient replies, as long as his login-name is the same. Once communication is established, the two parties may type simultaneously, with their output appearing in separate windows. Typing control-L .Ql ^L will cause the screen to be reprinted, while your erase, kill, and word kill characters will behave normally. To exit, just type your interrupt character; .Nm then moves the cursor to the bottom of the screen and restores the terminal to its previous state. .Pp Permission to talk may be denied or granted by use of the .Xr mesg 1 command. At the outset talking is allowed. Certain commands, in particular .Xr nroff 1 and .Xr pr 1 , disallow messages in order to prevent messy output. .Sh FILES .Bl -tag -width /var/run/utmp -compact .It Pa /etc/hosts to find the recipient's machine .It Pa /var/run/utmp to find the recipient's tty .El .Sh SEE ALSO .Xr mail 1 , .Xr mesg 1 , .Xr who 1 , .Xr write 1 .Sh BUGS The version of .Xr talk 1 released with .Bx 4.3 uses a protocol that is incompatible with the protocol used in the version released with .Bx 4.2 . .Sh HISTORY The .Nm command appeared in .Bx 4.2 . Index: head/usr.bin/tcopy/tcopy.1 =================================================================== --- head/usr.bin/tcopy/tcopy.1 (revision 79534) +++ head/usr.bin/tcopy/tcopy.1 (revision 79535) @@ -1,112 +1,112 @@ .\" Copyright (c) 1985, 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)tcopy.1 8.2 (Berkeley) 4/17/94 .\" $FreeBSD$ .\" .Dd April 17, 1994 .Dt TCOPY 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm tcopy .Nd copy and/or verify mag tapes .Sh SYNOPSIS .Nm .Op Fl cvx .Op Fl s Ar maxblk .Oo Ar src Op Ar dest .Oc .Sh DESCRIPTION .Nm Tcopy is designed to copy magnetic tapes. The only assumption made about the tape is that there are two tape marks at the end. .Nm Tcopy with only a source tape .Pf ( Ar /dev/rsa0 by default) specified will print information about the sizes of records and tape files. If a destination is specified a copy will be made of the source tape. The blocking on the destination tape will be identical to that used on the source tape. Copying a tape will yield the same output as if just printing the sizes. .Pp Options: .Bl -tag -width s_maxblk .It Fl c Copy .Ar src to .Ar dest and then verify that the two tapes are identical. .It Fl s Ar maxblk Specify a maximum block size, .Ar maxblk . .It Fl v Given the two tapes, .Ar src and .Ar dest verify that they are identical. .It Fl x Output all informational messages to the standard error. This option is useful when .Ar dest is .Pa /dev/stdout . .El .Sh SEE ALSO .Xr mtio 4 .Sh HISTORY The .Nm command appeared in .Bx 4.3 . .Sh BUGS .Bl -item .It Writting an image of a tape to a file does not preserve much more than the raw data. Block size(s) and tape EOF marks are lost which would otherwise be preserved in a tape-to-tape copy. .It EOD is determined by two sequential EOF marks with no data between. There are old systems which typically wrote three EOF's between tape files. .Xr tcopy 1 will erroneously stop copying early in this case. .It When using the copy/verify option \-c .Xr tcopy 1 does not rewind the tapes prior to start. A rewind is performed after writing prior to the verification stage. If one doesn't start at BOT then the comparison may not be of the intended data. .El Index: head/usr.bin/telnet/telnet.1 =================================================================== --- head/usr.bin/telnet/telnet.1 (revision 79534) +++ head/usr.bin/telnet/telnet.1 (revision 79535) @@ -1,1432 +1,1432 @@ .\" Copyright (c) 1983, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)telnet.1 8.5 (Berkeley) 3/1/94 .\" $FreeBSD$ .\" .Dd January 27, 2000 .Dt TELNET 1 -.Os BSD 4.2 +.Os .Sh NAME .Nm telnet .Nd user interface to the .Tn TELNET protocol .Sh SYNOPSIS .Nm .Op Fl 468EFKLNacdfrux .Op Fl S Ar tos .Op Fl X Ar authtype .Op Fl e Ar escapechar .Op Fl k Ar realm .Op Fl l Ar user .Op Fl n Ar tracefile .Op Fl s Ar src_addr .Oo .Ar host .Op Ar port .Oc .Sh DESCRIPTION The .Nm command is used to communicate with another host using the .Tn TELNET protocol. If .Nm is invoked without the .Ar host argument, it enters command mode, indicated by its prompt .Pq Dq Li telnet\&> . In this mode, it accepts and executes the commands listed below. If it is invoked with arguments, it performs an .Ic open command with those arguments. .Pp Options: .Bl -tag -width indent .It Fl 4 Forces .Nm to use IPv4 addresses only. .It Fl 6 Forces .Nm to use IPv6 addresses only. .It Fl 8 Specifies an 8-bit data path. This causes an attempt to negotiate the .Dv TELNET BINARY option on both input and output. .It Fl E Stops any character from being recognized as an escape character. .It Fl F If Kerberos V5 authentication is being used, the .Fl F option allows the local credentials to be forwarded to the remote system, including any credentials that have already been forwarded into the local environment. .It Fl K Specifies no automatic login to the remote system. .It Fl L Specifies an 8-bit data path on output. This causes the .Dv BINARY option to be negotiated on output. .It Fl N Prevents IP address to name lookup when destination host is given as an IP address. .It Fl S Ar tos Sets the IP type-of-service (TOS) option for the telnet connection to the value .Ar tos , which can be a numeric TOS value or, on systems that support it, a symbolic TOS name found in the .Pa /etc/iptos file. .It Fl X Ar atype Disables the .Ar atype type of authentication. .It Fl a Attempt automatic login. Currently, this sends the user name via the .Ev USER variable of the .Ev ENVIRON option if supported by the remote system. The name used is that of the current user as returned by .Xr getlogin 2 if it agrees with the current user ID, otherwise it is the name associated with the user ID. .It Fl c Disables the reading of the user's .Pa \&.telnetrc file. (See the .Ic toggle skiprc command on this man page.) .It Fl d Sets the initial value of the .Ic debug toggle to .Dv TRUE . .It Fl e Ar escapechar Sets the initial .Nm escape character to .Ar escapechar . If .Ar escapechar is omitted, then there will be no escape character. .It Fl f If Kerberos V5 authentication is being used, the .Fl f option allows the local credentials to be forwarded to the remote system. .It Fl k Ar realm If Kerberos authentication is being used, the .Fl k option requests that .Nm obtain tickets for the remote host in realm .Ar realm instead of the remote host's realm, as determined by .Xr krb_realmofhost 3 . .It Fl l Ar user When connecting to the remote system, if the remote system understands the .Ev ENVIRON option, then .Ar user will be sent to the remote system as the value for the variable .Ev USER . This option implies the .Fl a option. This option may also be used with the .Ic open command. .It Fl n Ar tracefile Opens .Ar tracefile for recording trace information. See the .Ic set tracefile command below. .It Fl r Specifies a user interface similar to .Xr rlogin 1 . In this mode, the escape character is set to the tilde (~) character, unless modified by the .Fl e option. .It Fl s Ar src_addr Set the source IP address for the .Nm connection to .Ar src_addr , which can be an IP address or a host name. .It Fl u Forces .Nm to use .Dv AF_UNIX addresses only (e.g., .Ux domain sockets, accessed with a file path). .It Fl x Turns on encryption of the data stream if possible. This option is not available outside of the United States and Canada. .It Ar host Indicates the official name, an alias, or the Internet address of a remote host. If .Ar host starts with a .Ql / , .Nm establishes a connection to the corresponding named socket. .It Ar port Indicates a port number (address of an application). If a number is not specified, the default .Nm port is used. .El .Pp When in rlogin mode, a line of the form ~. disconnects from the remote host; ~ is the .Nm escape character. Similarly, the line ~^Z suspends the .Nm session. The line ~^] escapes to the normal .Nm escape prompt. .Pp Once a connection has been opened, .Nm will attempt to enable the .Dv TELNET LINEMODE option. If this fails, then .Nm will revert to one of two input modes: either \*(Lqcharacter at a time\*(Rq or \*(Lqold line by line\*(Rq depending on what the remote system supports. .Pp When .Dv LINEMODE is enabled, character processing is done on the local system, under the control of the remote system. When input editing or character echoing is to be disabled, the remote system will relay that information. The remote system will also relay changes to any special characters that happen on the remote system, so that they can take effect on the local system. .Pp In \*(Lqcharacter at a time\*(Rq mode, most text typed is immediately sent to the remote host for processing. .Pp In \*(Lqold line by line\*(Rq mode, all text is echoed locally, and (normally) only completed lines are sent to the remote host. The \*(Lqlocal echo character\*(Rq (initially \*(Lq^E\*(Rq) may be used to turn off and on the local echo (this would mostly be used to enter passwords without the password being echoed). .Pp If the .Dv LINEMODE option is enabled, or if the .Ic localchars toggle is .Dv TRUE (the default for \*(Lqold line by line\*(Rq; see below), the user's .Ic quit , .Ic intr , and .Ic flush characters are trapped locally, and sent as .Tn TELNET protocol sequences to the remote side. If .Dv LINEMODE has ever been enabled, then the user's .Ic susp and .Ic eof are also sent as .Tn TELNET protocol sequences, and .Ic quit is sent as a .Dv TELNET ABORT instead of .Dv BREAK . There are options (see .Ic toggle .Ic autoflush and .Ic toggle .Ic autosynch below) which cause this action to flush subsequent output to the terminal (until the remote host acknowledges the .Tn TELNET sequence) and flush previous terminal input (in the case of .Ic quit and .Ic intr ) . .Pp While connected to a remote host, .Nm command mode may be entered by typing the .Nm \*(Lqescape character\*(Rq (initially \*(Lq^]\*(Rq). When in command mode, the normal terminal editing conventions are available. .Pp The following .Nm commands are available. Only enough of each command to uniquely identify it need be typed (this is also true for arguments to the .Ic mode , .Ic set , .Ic toggle , .Ic unset , .Ic slc , .Ic environ , and .Ic display commands). .Pp .Bl -tag -width "mode type" .It Ic auth Ar argument ... The auth command manipulates the information sent through the .Dv TELNET AUTHENTICATE option. Valid arguments for the .Ic auth command are: .Bl -tag -width "disable type" .It Ic disable Ar type Disables the specified type of authentication. To obtain a list of available types, use the .Ic auth disable ?\& command. .It Ic enable Ar type Enables the specified type of authentication. To obtain a list of available types, use the .Ic auth enable ?\& command. .It Ic status Lists the current status of the various types of authentication. .El .It Ic close Close a .Tn TELNET session and return to command mode. .It Ic display Ar argument ... Displays all, or some, of the .Ic set and .Ic toggle values (see below). .It Ic encrypt Ar argument ... The encrypt command manipulates the information sent through the .Dv TELNET ENCRYPT option. .Pp Note: Because of export controls, the .Dv TELNET ENCRYPT option is not supported outside of the United States and Canada. .Pp Valid arguments for the .Ic encrypt command are: .Bl -tag -width Ar .It Ic disable Ar type Xo .Op Cm input | output .Xc Disables the specified type of encryption. If you omit the input and output, both input and output are disabled. To obtain a list of available types, use the .Ic encrypt disable ?\& command. .It Ic enable Ar type Xo .Op Cm input | output .Xc Enables the specified type of encryption. If you omit input and output, both input and output are enabled. To obtain a list of available types, use the .Ic encrypt enable ?\& command. .It Ic input This is the same as the .Ic encrypt start input command. .It Ic -input This is the same as the .Ic encrypt stop input command. .It Ic output This is the same as the .Ic encrypt start output command. .It Ic -output This is the same as the .Ic encrypt stop output command. .It Ic start Op Cm input | output Attempts to start encryption. If you omit .Ic input and .Ic output , both input and output are enabled. To obtain a list of available types, use the .Ic encrypt enable ?\& command. .It Ic status Lists the current status of encryption. .It Ic stop Op Cm input | output Stops encryption. If you omit input and output, encryption is on both input and output. .It Ic type Ar type Sets the default type of encryption to be used with later .Ic encrypt start or .Ic encrypt stop commands. .El .It Ic environ Ar arguments ... The .Ic environ command is used to manipulate the variables that my be sent through the .Dv TELNET ENVIRON option. The initial set of variables is taken from the users environment, with only the .Ev DISPLAY and .Ev PRINTER variables being exported by default. The .Ev USER variable is also exported if the .Fl a or .Fl l options are used. .Pp Valid arguments for the .Ic environ command are: .Bl -tag -width Fl .It Ic define Ar variable value Define the variable .Ar variable to have a value of .Ar value . Any variables defined by this command are automatically exported. The .Ar value may be enclosed in single or double quotes so that tabs and spaces may be included. .It Ic undefine Ar variable Remove .Ar variable from the list of environment variables. .It Ic export Ar variable Mark the variable .Ar variable to be exported to the remote side. .It Ic unexport Ar variable Mark the variable .Ar variable to not be exported unless explicitly asked for by the remote side. .It Ic list List the current set of environment variables. Those marked with a .Cm * will be sent automatically, other variables will only be sent if explicitly requested. .It Ic ?\& Prints out help information for the .Ic environ command. .El .It Ic logout Sends the .Dv TELNET LOGOUT option to the remote side. This command is similar to a .Ic close command; however, if the remote side does not support the .Dv LOGOUT option, nothing happens. If, however, the remote side does support the .Dv LOGOUT option, this command should cause the remote side to close the .Tn TELNET connection. If the remote side also supports the concept of suspending a user's session for later reattachment, the logout argument indicates that you should terminate the session immediately. .It Ic mode Ar type .Ar Type is one of several options, depending on the state of the .Tn TELNET session. The remote host is asked for permission to go into the requested mode. If the remote host is capable of entering that mode, the requested mode will be entered. .Bl -tag -width Ar .It Ic character Disable the .Dv TELNET LINEMODE option, or, if the remote side does not understand the .Dv LINEMODE option, then enter \*(Lqcharacter at a time\*(Rq mode. .It Ic line Enable the .Dv TELNET LINEMODE option, or, if the remote side does not understand the .Dv LINEMODE option, then attempt to enter \*(Lqold-line-by-line\*(Rq mode. .It Ic isig Pq Ic \-isig Attempt to enable (disable) the .Dv TRAPSIG mode of the .Dv LINEMODE option. This requires that the .Dv LINEMODE option be enabled. .It Ic edit Pq Ic \-edit Attempt to enable (disable) the .Dv EDIT mode of the .Dv LINEMODE option. This requires that the .Dv LINEMODE option be enabled. .It Ic softtabs Pq Ic \-softtabs Attempt to enable (disable) the .Dv SOFT_TAB mode of the .Dv LINEMODE option. This requires that the .Dv LINEMODE option be enabled. .It Ic litecho Pq Ic \-litecho Attempt to enable (disable) the .Dv LIT_ECHO mode of the .Dv LINEMODE option. This requires that the .Dv LINEMODE option be enabled. .It Ic ?\& Prints out help information for the .Ic mode command. .El .It Xo .Ic open Ar host .Op Fl l Ar user .Op Oo Fl Oc Ns Ar port .Xc Open a connection to the named host. If no port number is specified, .Nm will attempt to contact a .Tn TELNET server at the default port. The host specification may be either a host name (see .Xr hosts 5 ) , an Internet address specified in the \*(Lqdot notation\*(Rq (see .Xr inet 3 ) , or IPv6 host name or IPv6 coloned-hexadecimal addreess. The .Fl l option may be used to specify the user name to be passed to the remote system via the .Ev ENVIRON option. When connecting to a non-standard port, .Nm omits any automatic initiation of .Tn TELNET options. When the port number is preceded by a minus sign, the initial option negotiation is done. After establishing a connection, the file .Pa \&.telnetrc in the users home directory is opened. Lines beginning with a # are comment lines. Blank lines are ignored. Lines that begin without white space are the start of a machine entry. The first thing on the line is the name of the machine that is being connected to. The rest of the line, and successive lines that begin with white space are assumed to be .Nm commands and are processed as if they had been typed in manually to the .Nm command prompt. .It Ic quit Close any open .Tn TELNET session and exit .Nm . An end of file (in command mode) will also close a session and exit. .It Ic send Ar arguments Sends one or more special character sequences to the remote host. The following are the arguments which may be specified (more than one argument may be specified at a time): .Pp .Bl -tag -width escape .It Ic abort Sends the .Dv TELNET ABORT (Abort processes) sequence. .It Ic ao Sends the .Dv TELNET AO (Abort Output) sequence, which should cause the remote system to flush all output .Em from the remote system .Em to the user's terminal. .It Ic ayt Sends the .Dv TELNET AYT (Are You There) sequence, to which the remote system may or may not choose to respond. .It Ic brk Sends the .Dv TELNET BRK (Break) sequence, which may have significance to the remote system. .It Ic ec Sends the .Dv TELNET EC (Erase Character) sequence, which should cause the remote system to erase the last character entered. .It Ic el Sends the .Dv TELNET EL (Erase Line) sequence, which should cause the remote system to erase the line currently being entered. .It Ic eof Sends the .Dv TELNET EOF (End Of File) sequence. .It Ic eor Sends the .Dv TELNET EOR (End of Record) sequence. .It Ic escape Sends the current .Nm escape character (initially \*(Lq^\*(Rq). .It Ic ga Sends the .Dv TELNET GA (Go Ahead) sequence, which likely has no significance to the remote system. .It Ic getstatus If the remote side supports the .Dv TELNET STATUS command, .Ic getstatus will send the subnegotiation to request that the server send its current option status. .It Ic ip Sends the .Dv TELNET IP (Interrupt Process) sequence, which should cause the remote system to abort the currently running process. .It Ic nop Sends the .Dv TELNET NOP (No OPeration) sequence. .It Ic susp Sends the .Dv TELNET SUSP (SUSPend process) sequence. .It Ic synch Sends the .Dv TELNET SYNCH sequence. This sequence causes the remote system to discard all previously typed (but not yet read) input. This sequence is sent as .Tn TCP urgent data (and may not work if the remote system is a .Bx 4.2 system -- if it doesn't work, a lower case \*(Lqr\*(Rq may be echoed on the terminal). .It Ic do Ar cmd .It Ic dont Ar cmd .It Ic will Ar cmd .It Ic wont Ar cmd Sends the .Dv TELNET DO .Ar cmd sequence. .Ar Cmd can be either a decimal number between 0 and 255, or a symbolic name for a specific .Dv TELNET command. .Ar Cmd can also be either .Ic help or .Ic ?\& to print out help information, including a list of known symbolic names. .It Ic ?\& Prints out help information for the .Ic send command. .El .It Ic set Ar argument value .It Ic unset Ar argument value The .Ic set command will set any one of a number of .Nm variables to a specific value or to .Dv TRUE . The special value .Ic off turns off the function associated with the variable, this is equivalent to using the .Ic unset command. The .Ic unset command will disable or set to .Dv FALSE any of the specified functions. The values of variables may be interrogated with the .Ic display command. The variables which may be set or unset, but not toggled, are listed here. In addition, any of the variables for the .Ic toggle command may be explicitly set or unset using the .Ic set and .Ic unset commands. .Bl -tag -width escape .It Ic ayt If .Tn TELNET is in localchars mode, or .Dv LINEMODE is enabled, and the status character is typed, a .Dv TELNET AYT sequence (see .Ic send ayt preceding) is sent to the remote host. The initial value for the \*(LqAre You There\*(Rq character is the terminal's status character. .It Ic echo This is the value (initially \*(Lq^E\*(Rq) which, when in \*(Lqline by line\*(Rq mode, toggles between doing local echoing of entered characters (for normal processing), and suppressing echoing of entered characters (for entering, say, a password). .It Ic eof If .Nm is operating in .Dv LINEMODE or \*(Lqold line by line\*(Rq mode, entering this character as the first character on a line will cause this character to be sent to the remote system. The initial value of the eof character is taken to be the terminal's .Ic eof character. .It Ic erase If .Nm is in .Ic localchars mode (see .Ic toggle .Ic localchars below), .Sy and if .Nm is operating in \*(Lqcharacter at a time\*(Rq mode, then when this character is typed, a .Dv TELNET EC sequence (see .Ic send .Ic ec above) is sent to the remote system. The initial value for the erase character is taken to be the terminal's .Ic erase character. .It Ic escape This is the .Nm escape character (initially \*(Lq^[\*(Rq) which causes entry into .Nm command mode (when connected to a remote system). .It Ic flushoutput If .Nm is in .Ic localchars mode (see .Ic toggle .Ic localchars below) and the .Ic flushoutput character is typed, a .Dv TELNET AO sequence (see .Ic send .Ic ao above) is sent to the remote host. The initial value for the flush character is taken to be the terminal's .Ic flush character. .It Ic forw1 .It Ic forw2 If .Nm is operating in .Dv LINEMODE , these are the characters that, when typed, cause partial lines to be forwarded to the remote system. The initial value for the forwarding characters are taken from the terminal's eol and eol2 characters. .It Ic interrupt If .Nm is in .Ic localchars mode (see .Ic toggle .Ic localchars below) and the .Ic interrupt character is typed, a .Dv TELNET IP sequence (see .Ic send .Ic ip above) is sent to the remote host. The initial value for the interrupt character is taken to be the terminal's .Ic intr character. .It Ic kill If .Nm is in .Ic localchars mode (see .Ic toggle .Ic localchars below), .Ic and if .Nm is operating in \*(Lqcharacter at a time\*(Rq mode, then when this character is typed, a .Dv TELNET EL sequence (see .Ic send .Ic el above) is sent to the remote system. The initial value for the kill character is taken to be the terminal's .Ic kill character. .It Ic lnext If .Nm is operating in .Dv LINEMODE or \*(Lqold line by line\*(Rq mode, then this character is taken to be the terminal's .Ic lnext character. The initial value for the lnext character is taken to be the terminal's .Ic lnext character. .It Ic quit If .Nm is in .Ic localchars mode (see .Ic toggle .Ic localchars below) and the .Ic quit character is typed, a .Dv TELNET BRK sequence (see .Ic send .Ic brk above) is sent to the remote host. The initial value for the quit character is taken to be the terminal's .Ic quit character. .It Ic reprint If .Nm is operating in .Dv LINEMODE or \*(Lqold line by line\*(Rq mode, then this character is taken to be the terminal's .Ic reprint character. The initial value for the reprint character is taken to be the terminal's .Ic reprint character. .It Ic rlogin This is the rlogin escape character. If set, the normal .Nm escape character is ignored unless it is preceded by this character at the beginning of a line. This character, at the beginning of a line followed by a "." closes the connection; when followed by a ^Z it suspends the .Nm command. The initial state is to disable the .Nm rlogin escape character. .It Ic start If the .Dv TELNET TOGGLE-FLOW-CONTROL option has been enabled, then this character is taken to be the terminal's .Ic start character. The initial value for the start character is taken to be the terminal's .Ic start character. .It Ic stop If the .Dv TELNET TOGGLE-FLOW-CONTROL option has been enabled, then this character is taken to be the terminal's .Ic stop character. The initial value for the stop character is taken to be the terminal's .Ic stop character. .It Ic susp If .Nm is in .Ic localchars mode, or .Dv LINEMODE is enabled, and the .Ic suspend character is typed, a .Dv TELNET SUSP sequence (see .Ic send .Ic susp above) is sent to the remote host. The initial value for the suspend character is taken to be the terminal's .Ic suspend character. .It Ic tracefile This is the file to which the output, caused by .Ic netdata or .Ic option tracing being .Dv TRUE , will be written. If it is set to .Dq Fl , then tracing information will be written to standard output (the default). .It Ic worderase If .Nm is operating in .Dv LINEMODE or \*(Lqold line by line\*(Rq mode, then this character is taken to be the terminal's .Ic worderase character. The initial value for the worderase character is taken to be the terminal's .Ic worderase character. .It Ic ?\& Displays the legal .Ic set .Pq Ic unset commands. .El .It Ic skey Ar sequence challenge The .Ic skey command computes a response to the S/Key challenge. .It Ic slc Ar state The .Ic slc command (Set Local Characters) is used to set or change the state of the special characters when the .Dv TELNET LINEMODE option has been enabled. Special characters are characters that get mapped to .Tn TELNET commands sequences (like .Ic ip or .Ic quit ) or line editing characters (like .Ic erase and .Ic kill ) . By default, the local special characters are exported. .Bl -tag -width Fl .It Ic check Verify the current settings for the current special characters. The remote side is requested to send all the current special character settings, and if there are any discrepancies with the local side, the local side will switch to the remote value. .It Ic export Switch to the local defaults for the special characters. The local default characters are those of the local terminal at the time when .Nm was started. .It Ic import Switch to the remote defaults for the special characters. The remote default characters are those of the remote system at the time when the .Tn TELNET connection was established. .It Ic ?\& Prints out help information for the .Ic slc command. .El .It Ic status Show the current status of .Nm . This includes the peer one is connected to, as well as the current mode. .It Ic toggle Ar arguments ... Toggle (between .Dv TRUE and .Dv FALSE ) various flags that control how .Nm responds to events. These flags may be set explicitly to .Dv TRUE or .Dv FALSE using the .Ic set and .Ic unset commands listed above. More than one argument may be specified. The state of these flags may be interrogated with the .Ic display command. Valid arguments are: .Bl -tag -width Ar .It Ic authdebug Turns on debugging information for the authentication code. .It Ic autoflush If .Ic autoflush and .Ic localchars are both .Dv TRUE , then when the .Ic ao , or .Ic quit characters are recognized (and transformed into .Tn TELNET sequences; see .Ic set above for details), .Nm refuses to display any data on the user's terminal until the remote system acknowledges (via a .Dv TELNET TIMING MARK option) that it has processed those .Tn TELNET sequences. The initial value for this toggle is .Dv TRUE if the terminal user had not done an "stty noflsh", otherwise .Dv FALSE (see .Xr stty 1 ) . .It Ic autodecrypt When the .Dv TELNET ENCRYPT option is negotiated, by default the actual encryption (decryption) of the data stream does not start automatically. The autoencrypt (autodecrypt) command states that encryption of the output (input) stream should be enabled as soon as possible. .Pp Note: Because of export controls, the .Dv TELNET ENCRYPT option is not supported outside the United States and Canada. .It Ic autologin If the remote side supports the .Dv TELNET AUTHENTICATION option .Nm attempts to use it to perform automatic authentication. If the .Dv AUTHENTICATION option is not supported, the user's login name are propagated through the .Dv TELNET ENVIRON option. This command is the same as specifying .Fl a option on the .Ic open command. .It Ic autosynch If .Ic autosynch and .Ic localchars are both .Dv TRUE , then when either the .Ic intr or .Ic quit characters is typed (see .Ic set above for descriptions of the .Ic intr and .Ic quit characters), the resulting .Tn TELNET sequence sent is followed by the .Dv TELNET SYNCH sequence. This procedure .Ic should cause the remote system to begin throwing away all previously typed input until both of the .Tn TELNET sequences have been read and acted upon. The initial value of this toggle is .Dv FALSE . .It Ic binary Enable or disable the .Dv TELNET BINARY option on both input and output. .It Ic inbinary Enable or disable the .Dv TELNET BINARY option on input. .It Ic outbinary Enable or disable the .Dv TELNET BINARY option on output. .It Ic crlf If this is .Dv TRUE , then carriage returns will be sent as .Li . If this is .Dv FALSE , then carriage returns will be send as .Li . The initial value for this toggle is .Dv FALSE . .It Ic crmod Toggle carriage return mode. When this mode is enabled, most carriage return characters received from the remote host will be mapped into a carriage return followed by a line feed. This mode does not affect those characters typed by the user, only those received from the remote host. This mode is not very useful unless the remote host only sends carriage return, but never line feed. The initial value for this toggle is .Dv FALSE . .It Ic debug Toggles socket level debugging (useful only to the .Ic super user ) . The initial value for this toggle is .Dv FALSE . .It Ic encdebug Turns on debugging information for the encryption code. .It Ic localchars If this is .Dv TRUE , then the .Ic flush , .Ic interrupt , .Ic quit , .Ic erase , and .Ic kill characters (see .Ic set above) are recognized locally, and transformed into (hopefully) appropriate .Tn TELNET control sequences (respectively .Ic ao , .Ic ip , .Ic brk , .Ic ec , and .Ic el ; see .Ic send above). The initial value for this toggle is .Dv TRUE in \*(Lqold line by line\*(Rq mode, and .Dv FALSE in \*(Lqcharacter at a time\*(Rq mode. When the .Dv LINEMODE option is enabled, the value of .Ic localchars is ignored, and assumed to always be .Dv TRUE . If .Dv LINEMODE has ever been enabled, then .Ic quit is sent as .Ic abort , and .Ic eof and .Ic suspend are sent as .Ic eof and .Ic susp (see .Ic send above). .It Ic netdata Toggles the display of all network data (in hexadecimal format). The initial value for this toggle is .Dv FALSE . .It Ic options Toggles the display of some internal .Nm protocol processing (having to do with .Tn TELNET options). The initial value for this toggle is .Dv FALSE . .It Ic prettydump When the .Ic netdata toggle is enabled, if .Ic prettydump is enabled the output from the .Ic netdata command will be formatted in a more user readable format. Spaces are put between each character in the output, and the beginning of any .Nm escape sequence is preceded by a '*' to aid in locating them. .It Ic skiprc When the skiprc toggle is .Dv TRUE , .Nm skips the reading of the .Pa \&.telnetrc file in the users home directory when connections are opened. The initial value for this toggle is .Dv FALSE . .It Ic termdata Toggles the display of all terminal data (in hexadecimal format). The initial value for this toggle is .Dv FALSE . .It Ic verbose_encrypt When the .Ic verbose_encrypt toggle is .Dv TRUE , .Nm prints out a message each time encryption is enabled or disabled. The initial value for this toggle is .Dv FALSE . Note: Because of export controls, data encryption is not supported outside of the United States and Canada. .It Ic ?\& Displays the legal .Ic toggle commands. .El .It Ic z Suspend .Nm . This command only works when the user is using the .Xr csh 1 . .It Ic \&! Op Ar command Execute a single command in a subshell on the local system. If .Ar command is omitted, then an interactive subshell is invoked. .It Ic ?\& Op Ar command Get help. With no arguments, .Nm prints a help summary. If .Ar command is specified, .Nm will print the help information for just that command. .El .Sh ENVIRONMENT .Nm uses at least the .Ev HOME , .Ev SHELL , .Ev DISPLAY , and .Ev TERM environment variables. Other environment variables may be propagated to the other side via the .Dv TELNET ENVIRON option. .Sh SEE ALSO .Xr rlogin 1 , .Xr rsh 1 , .Xr hosts 5 , .Xr nologin 5 , .Xr telnetd 8 .Sh FILES .Bl -tag -width ~/.telnetrc -compact .It Pa ~/.telnetrc user customized telnet startup values .El .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Pp IPv6 support was added by WIDE/KAME project. .Sh NOTES On some remote systems, echo has to be turned off manually when in \*(Lqold line by line\*(Rq mode. .Pp In \*(Lqold line by line\*(Rq mode or .Dv LINEMODE the terminal's .Ic eof character is only recognized (and sent to the remote system) when it is the first character on a line. Index: head/usr.bin/tftp/tftp.1 =================================================================== --- head/usr.bin/tftp/tftp.1 (revision 79534) +++ head/usr.bin/tftp/tftp.1 (revision 79535) @@ -1,176 +1,176 @@ .\" Copyright (c) 1990, 1993, 1994 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)tftp.1 8.2 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" .Dd April 18, 1994 .Dt TFTP 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm tftp .Nd trivial file transfer program .Sh SYNOPSIS .Nm .Op Ar host .Sh DESCRIPTION .Nm Tftp is the user interface to the Internet .Tn TFTP (Trivial File Transfer Protocol), which allows users to transfer files to and from a remote machine. The remote .Ar host may be specified on the command line, in which case .Nm uses .Ar host as the default host for future transfers (see the .Cm connect command below). .Sh COMMANDS Once .Nm is running, it issues the prompt .Dq Li tftp> and recognizes the following commands: .Pp .Bl -tag -width verbose -compact .It Cm \&? Ar command-name ... Print help information. .Pp .It Cm ascii Shorthand for "mode ascii" .Pp .It Cm binary Shorthand for "mode binary" .Pp .It Cm connect Ar host-name Op Ar port Set the .Ar host (and optionally .Ar port ) for transfers. Note that the .Tn TFTP protocol, unlike the .Tn FTP protocol, does not maintain connections between transfers; thus, the .Cm connect command does not actually create a connection, but merely remembers what host is to be used for transfers. You do not have to use the .Cm connect command; the remote host can be specified as part of the .Cm get or .Cm put commands. .Pp .It Cm get Ar filename .It Cm get Ar remotename localname .It Cm get Ar file1 file2 ... fileN Get a file or set of files from the specified .Ar sources . .Ar Source can be in one of two forms: a filename on the remote host, if the host has already been specified, or a string of the form .Ar hosts:filename to specify both a host and filename at the same time. If the latter form is used, the last hostname specified becomes the default for future transfers. .Pp .It Cm mode Ar transfer-mode Set the mode for transfers; .Ar transfer-mode may be one of .Em ascii or .Em binary . The default is .Em ascii . .Pp .It Cm put Ar file .It Cm put Ar localfile remotefile .It Cm put Ar file1 file2 ... fileN remote-directory Put a file or set of files to the specified remote file or directory. The destination can be in one of two forms: a filename on the remote host, if the host has already been specified, or a string of the form .Ar hosts:filename to specify both a host and filename at the same time. If the latter form is used, the hostname specified becomes the default for future transfers. If the remote-directory form is used, the remote host is assumed to be a .Tn UNIX machine. .Pp .It Cm quit Exit .Nm . An end of file also exits. .Pp .It Cm rexmt Ar retransmission-timeout Set the per-packet retransmission timeout, in seconds. .Pp .It Cm status Show current status. .Pp .It Cm timeout Ar total-transmission-timeout Set the total transmission timeout, in seconds. .Pp .It Cm trace Toggle packet tracing. .Pp .It Cm verbose Toggle verbose mode. .El .Sh BUGS Because there is no user-login or validation within the .Tn TFTP protocol, the remote site will probably have some sort of file-access restrictions in place. The exact methods are specific to each site and therefore difficult to document here. .Pp Files larger than 33488896 octets (65535 blocks) cannot be transferred without client and server supporting blocksize negotiation (RFC1783). .Sh HISTORY The .Nm command appeared in .Bx 4.3 . Index: head/usr.bin/time/time.1 =================================================================== --- head/usr.bin/time/time.1 (revision 79534) +++ head/usr.bin/time/time.1 (revision 79535) @@ -1,134 +1,134 @@ .\" Copyright (c) 1980, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)time.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt TIME 1 -.Os BSD 4 +.Os .Sh NAME .Nm time .Nd time command execution .Sh SYNOPSIS .Nm .Op Fl al .Op Fl h | Fl p .Op Fl o Ar file .Ar command .Sh DESCRIPTION The .Nm utility executes and times .Ar command by initiating a timer and passing the .Ar command to the shell. After the .Ar command finishes, .Nm writes to the standard error stream, (in seconds): the total time elapsed, the time used to execute the .Ar command process and the time consumed by system overhead. .Pp Available options: .Bl -tag -width Ds .It Fl a If the .Fl o flag is used, append to the specified file rather than overwriting it. Otherwise, this option has no effect. .It Fl h Print times in a human friendly format. Times are printed in minutes, hours, etc. as appropiate. .It Fl l The contents of the .Em rusage structure are printed as well. .It Fl o Ar file Write the output to .Ar file instead of stderr. If .Ar file exists and the .Fl a flag is not specified, the file will be overwritten. .It Fl p Makes .Nm output POSIX.2 compliant (each time is printed on its own line). .El .Pp Some shells may provide a builtin .Nm command which is similar or identical to this utility. Consult the .Xr builtin 1 manual page. .Sh DIAGNOSTICS If .Ar command could be timed successfully, its exit status is returned. If .Ar command terminated abnormally, a warning message is output to stderr. If the .Ar command was found but could not be run, the exit status is 126. If no .Ar command could be found at all, the exit status is 127. If .Nm encounters any other error, the exit status is between 1 and 125 included. .Sh SEE ALSO .Xr builtin 1 , .Xr csh 1 , .Xr getrusage 2 , .Xr wait 2 .Sh STANDARDS The .Nm utility is expected to conform to ISO/IEC 9945-2:1993 (``POSIX''). .Sh HISTORY A .Nm command appeared in .At v6 . Index: head/usr.bin/tip/tip/modems.5 =================================================================== --- head/usr.bin/tip/tip/modems.5 (revision 79534) +++ head/usr.bin/tip/tip/modems.5 (revision 79535) @@ -1,143 +1,143 @@ .\" Copyright (c) 1983, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)modems.5 3/24/95 .\" $FreeBSD$ .\" .Dd March 24, 1995 .Dt MODEMS 5 -.Os BSD 4.4 +.Os .Sh NAME .Nm modems .Nd modem configuration data base .Sh DESCRIPTION The modems known by .Xr tip 1 and their attributes are stored in an .Tn ASCII file which is structured somewhat like the .Xr termcap 5 file. Each line in the file provides a description for a single .Em modem . Fields are separated by a colon (``:''). Lines ending in a \e character with an immediately following newline are continued on the next line. .Pp The first entry is the name(s) of the modem. If there is more than one name for a modem, the names are separated by vertical bars. After the name of the modem comes the fields of the description. A field name followed by an `=' sign indicates a string value follows. A field name followed by a `#' sign indicates a following numeric value. .Pp When .Xr tip 1 is invoked, an entry for a remote system is looked up in the .Pa /etc/remote database. If the entry includes an "ACU" type capability (abbreviated at), .Xr tip 1 looks up the specified modem in .Pa /etc/modems . If a modem entry is found, the corresponding capabilities determine how .Xr tip 1 programs the modem when connecting to and disconnecting from the remote system. .Sh CAPABILITIES Capabilities are either strings (str), numbers (num), or boolean flags (bool). A string capability is specified by .Em capability Ns Ar = Ns Em value ; for example, ``reset_command=ATZ\\r''. A numeric capability is specified by .Em capability Ns Ar # Ns Em value ; for example, ``intercharacter_delay#50''. A boolean capability is specified by simply listing the capability. .Bl -tag -width intercharacter_delay .It Cm \&dial_command (str) AT command used to dial remote system (typically, "ATDT") .It Cm \&echo_off_command (str) AT command to turn off command echo. .It Cm \&escape_guard_time (num) The delay, expressed in milliseconds, used to frame return-to-command escape sequences. .It Cm \&escape_sequence (str) The return-to-command escape sequence. .It Cm \&hangup_command (str) AT command used to hangup modem. .It Cm \&hw_flow_control (bool) Enable hardware (RTS/CTS) flow control between computer and modem (DTE/DCE). .It Cm \&init_string (str) AT command used to initialize modem before dialing. .It Cm \&intercharacter_delay (num) Delay value, expressed in milliseconds, between characters when sending commands to the modem. .It Cm \&intercommand_delay (num) Minimum delay value, expressed in milliseconds, to impose between commands issued to the modem. .It Cm \&lock_baud (bool) Use a fixed bit rate between the computer and the modem (DTE / DCE). The bit rate is specified in .Pa /etc/remote . .It Cm \&reset_command (str) AT command to reset the modem. .It Cm \&reset_delay (num) The time, expressed in milliseconds, required by the modem to complete a reset and return to a ready condition. .El .Sh FILES .Bl -tag -width /etc/modems -compact .It Pa /etc/modems The .Nm configuration database file resides in .Pa /etc . .El .Sh SEE ALSO .Xr tip 1 , .Xr remote 5 .Sh HISTORY The .Nm file format appeared in .Bx 4.4 . Index: head/usr.bin/tip/tip/tip.1 =================================================================== --- head/usr.bin/tip/tip/tip.1 (revision 79534) +++ head/usr.bin/tip/tip/tip.1 (revision 79535) @@ -1,454 +1,454 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)tip.1 8.4 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" .Dd April 18, 1994 .Dt TIP 1 -.Os BSD 4 +.Os .Sh NAME .Nm tip .Nd connect to a remote system .Sh SYNOPSIS .Nm .Op Fl v .Fl Ns Ns Ar speed .Ar system\-name .Nm .Op Fl v .Fl Ns Ns Ar speed .Ar phone\-number .Sh DESCRIPTION The .Nm command establishes a full-duplex connection to another machine, giving the appearance of being logged in directly on the remote cpu. It goes without saying that you must have a login on the machine (or equivalent) to which you wish to connect. .Pp Available Option: .Bl -tag -width indent .It Fl v Set verbose mode. .El .Pp Typed characters are normally transmitted directly to the remote machine (which does the echoing as well). A tilde (`~') appearing as the first character of a line is an escape signal; the following are recognized: .Bl -tag -width flag .It Ic \&~^D No or Ic \&~ . Drop the connection and exit (you may still be logged in on the remote machine). .It Ic \&~c Op Ar name Change directory to .Ar name (no argument implies change to your home directory). .It Ic \&~! Escape to a shell (exiting the shell will return you to tip). .It Ic \&~> Copy file from local to remote. .Nm Tip prompts for the name of a local file to transmit. .It Ic \&~< Copy file from remote to local. .Nm Tip prompts first for the name of the file to be sent, then for a command to be executed on the remote machine. .It Ic \&~p Ar from Op Ar to Send a file to a remote .Ux host. The put command causes the remote .Ux system to run the command string ``cat > 'to''', while .Nm sends it the ``from'' file. If the ``to'' file isn't specified the ``from'' file name is used. This command is actually a .Ux specific version of the ``~>'' command. .It Ic \&~t Ar from Op Ar to Take a file from a remote .Ux host. As in the put command the ``to'' file defaults to the ``from'' file name if it isn't specified. The remote host executes the command string ``cat 'from';echo ^A'' to send the file to .Nm . .It Ic \&~| Pipe the output from a remote command to a local .Ux process. The command string sent to the local .Ux system is processed by the shell. .It Ic \&~$ Pipe the output from a local .Ux process to the remote host. The command string sent to the local .Ux system is processed by the shell. .It Ic \&~C Fork a child process on the local system to perform special protocols such as \s-1XMODEM\s+1. The child program will be run with the following somewhat unusual arrangement of file descriptors: .Bd -literal -offset indent -compact 0 <-> local tty in 1 <-> local tty out 2 <-> local tty out 3 <-> remote tty in 4 <-> remote tty out .Ed .It Ic \&~# Send a .Dv BREAK to the remote system. For systems which don't support the necessary .Ar ioctl call the break is simulated by a sequence of line speed changes and .Dv DEL characters. .It Ic \&~s Set a variable (see the discussion below). .It Ic \&~^Z Stop .Nm (only available with job control). .It Ic \&~^Y Stop only the ``local side'' of .Nm (only available with job control); the ``remote side'' of .Nm , the side that displays output from the remote host, is left running. .It Ic \&~? Get a summary of the tilde escapes .El .Pp .Nm Tip uses the file .Pa /etc/remote to find how to reach a particular system and to find out how it should operate while talking to the system; refer to .Xr remote 5 for a full description. Each system has a default baud rate with which to establish a connection. If this value is not suitable, the baud rate to be used may be specified on the command line, e.g. .Ql "tip -300 mds" . .Pp When .Nm establishes a connection it sends out a connection message to the remote system; the default value, if any, is defined in .Pa /etc/remote (see .Xr remote 5 ) . .Pp When .Nm prompts for an argument (e.g. during setup of a file transfer) the line typed may be edited with the standard erase and kill characters. A null line in response to a prompt, or an interrupt, will abort the dialogue and return you to the remote machine. .Pp .Nm Tip guards against multiple users connecting to a remote system by opening modems and terminal lines with exclusive access, and by honoring the locking protocol used by .Xr uucico 8 . .Pp During file transfers .Nm provides a running count of the number of lines transferred. When using the ~> and ~< commands, the ``eofread'' and ``eofwrite'' variables are used to recognize end-of-file when reading, and specify end-of-file when writing (see below). File transfers normally depend on tandem mode for flow control. If the remote system does not support tandem mode, ``echocheck'' may be set to indicate .Nm should synchronize with the remote system on the echo of each transmitted character. .Pp When .Nm must dial a phone number to connect to a system it will print various messages indicating its actions. .Nm Tip supports modems that use the AT command set. .Nm Tip uses the file .Pa /etc/modems to find out how to operate with a particular modem; refer to .Xr modems 5 for a full description. .Ss VARIABLES .Nm Tip maintains a set of .Ar variables which control its operation. Some of these variables are read-only to normal users (root is allowed to change anything of interest). Variables may be displayed and set through the ``s'' escape. The syntax for variables is patterned after .Xr vi 1 and .Xr Mail 1 . Supplying ``all'' as an argument to the set command displays all variables readable by the user. Alternatively, the user may request display of a particular variable by attaching a `?' to the end. For example ``escape?'' displays the current escape character. .Pp Variables are numeric, string, character, or boolean values. Boolean variables are set merely by specifying their name; they may be reset by prepending a `!' to the name. Other variable types are set by concatenating an `=' and the value. The entire assignment must not have any blanks in it. A single set command may be used to interrogate as well as set a number of variables. Variables may be initialized at run time by placing set commands (without the ``~s'' prefix in a file .Pa .tiprc in one's home directory). The .Fl v option causes .Nm to display the sets as they are made. Certain common variables have abbreviations. The following is a list of common variables, their abbreviations, and their default values. .Bl -tag -width Ar .It Ar beautify (bool) Discard unprintable characters when a session is being scripted; abbreviated .Ar be . .It Ar baudrate (num) The baud rate at which the connection was established; abbreviated .Ar ba . .It Ar chardelay (num) Number of milliseconds to delay after the transmission of each character; abbreviated .Ar cdelay . .It Ar dialtimeout (num) When dialing a phone number, the time (in seconds) to wait for a connection to be established; abbreviated .Ar dial . .It Ar echocheck (bool) Synchronize with the remote host during file transfer by waiting for the echo of the last character transmitted; default is .Ar off . .It Ar eofread (str) The set of characters which signify an end-of-transmission during a ~< file transfer command; abbreviated .Ar eofr . .It Ar eofwrite (str) The string sent to indicate end-of-transmission during a ~> file transfer command; abbreviated .Ar eofw . .It Ar eol (str) The set of characters which indicate an end-of-line. .Nm Tip will recognize escape characters only after an end-of-line. .It Ar escape (char) The command prefix (escape) character; abbreviated .Ar es ; default value is `~'. .It Ar exceptions (str) The set of characters which should not be discarded due to the beautification switch; abbreviated .Ar ex ; default value is ``\et\en\ef\eb''. .It Ar force (char) The character used to force literal data transmission; abbreviated .Ar fo ; default value is `^P'. .It Ar framesize (num) The amount of data (in bytes) to buffer between file system writes when receiving files; abbreviated .Ar fr . .It Ar host (str) The name of the host to which you are connected; abbreviated .Ar ho . .It Ar linedelay (num) Number of milliseconds to delay after the transmission of each line; abbreviated .Ar ldelay . .It Ar login (str) Pathname of a login shell script to run once connected; standard input and output are redirected to the remote host. Leading tildes in the pathname are expanded expansion; abbreviated .Ar li . .It Ar logout (str) Pathname of a shell script to run before disconnecting; standard input and output are redirected to the remote host. Leading tildes in the pathname are expanded expansion; abbreviated .Ar lo . .It Ar prompt (char) The character which indicates an end-of-line on the remote host; abbreviated .Ar pr ; default value is `\en'. This value is used to synchronize during data transfers. The count of lines transferred during a file transfer command is based on receipt of this character. .It Ar raise (bool) Upper case mapping mode; abbreviated .Ar ra ; default value is .Ar off . When this mode is enabled, all lower case letters will be mapped to upper case by .Nm for transmission to the remote machine. .It Ar raisechar (char) The input character used to toggle upper case mapping mode; abbreviated .Ar rc ; default value is `^A'. .It Ar record (str) The name of the file in which a session script is recorded; abbreviated .Ar rec ; default value is ``tip.record''. .It Ar script (bool) Session scripting mode; abbreviated .Ar sc ; default is .Ar off . When .Ar script is .Li true , .Nm will record everything transmitted by the remote machine in the script record file specified in .Ar record . If the .Ar beautify switch is on, only printable .Tn ASCII characters will be included in the script file (those characters between 040 and 0177). The variable .Ar exceptions is used to indicate characters which are an exception to the normal beautification rules. .It Ar tabexpand (bool) Expand tabs to spaces during file transfers; abbreviated .Ar tab ; default value is .Ar false . Each tab is expanded to 8 spaces. .It Ar verbose (bool) Verbose mode; abbreviated .Ar verb ; default is .Ar true . When verbose mode is enabled, .Nm prints messages while dialing, shows the current number of lines transferred during a file transfer operations, and more. .El .Sh ENVIRONMENT .Nm Tip uses the following environment variables: .Bl -tag -width Fl .It Ev SHELL (str) The name of the shell to use for the ~! command; default value is ``/bin/sh'', or taken from the environment. .It Ev HOME (str) The home directory to use for the ~c command; default value is taken from the environment. .It Ev HOST Check for a default host if none specified. .El .Pp The variables .Ev ${REMOTE} and .Ev ${PHONES} are also exported. .Sh FILES .Bl -tag -width /var/spool/lock/LCK..* -compact .It Pa /etc/modems Global modem configuration data base. .It Pa /etc/remote Global system descriptions. .It Pa /etc/phones Global phone number data base. .It Ev ${REMOTE} Private system descriptions. .It Ev ${PHONES} Private phone numbers. .It Pa ~/.tiprc Initialization file. .It Pa tip.record Record file. .It Pa /var/log/aculog Line access log. .It Pa /var/spool/lock/LCK..* Lock file to avoid conflicts with .Xr uucp 1 . .El .Sh DIAGNOSTICS Diagnostics are, hopefully, self explanatory. .Sh SEE ALSO .Xr cu 1 , .Xr phones 5 , .Xr remote 5 .Sh HISTORY The .Nm command appeared in .Bx 4.2 . .Sh BUGS The full set of variables is undocumented and should, probably, be pared down. Index: head/usr.bin/tput/tput.1 =================================================================== --- head/usr.bin/tput/tput.1 (revision 79534) +++ head/usr.bin/tput/tput.1 (revision 79535) @@ -1,145 +1,145 @@ .\" Copyright (c) 1989, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)tput.1 8.2 (Berkeley) 3/19/94 .\" $FreeBSD$ .\" .Dd March 19, 1994 .Dt TPUT 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm tput , .Nm clear .Nd terminal capability interface .Sh SYNOPSIS .Nm .Op Fl T Ar term .Ar attribute .Nm clear .Sh DESCRIPTION The .Nm command makes terminal-dependent information available to users or shell applications. When invoked as the .Nm clear utility, the screen will be cleared as if .Dl tput clear had been executed. The options to .Nm are as follows: .Bl -tag -width Ds .It Fl T The terminal name as specified in the .Xr termcap database, for example, .Dq vt100 or .Dq xterm . If not specified, .Nm retrieves the .Dq Ev TERM variable from the environment. .El .Pp The .Nm command outputs a string if the .Ar attribute is of type string; a number if it is of type integer. Otherwise, .Nm exits 0 if the terminal has the capability and 1 if it does not, without further action. .Pp If the .Ar attribute is of type string, and takes arguments (e.g. cursor movement, the termcap .Dq cm sequence) the arguments are taken from the command line immediately following the attribute. .Pp The following special attributes are available: .Bl -tag -width Ar .It clear Clear the screen (the .Xr termcap .Dq cl sequence). .It init Initialize the terminal (the .Xr termcap .Dq is sequence). .It longname Print the descriptive name of the user's terminal type. .It reset Reset the terminal (the .Xr termcap .Dq rs sequence). .El .Sh DIAGNOSTICS The exit value of .Nm is based on the last attribute specified. If the attribute is of type string or of type integer, .Nm exits 0 if the attribute is defined for this terminal type and 1 if it is not. If the attribute is of type boolean, .Nm exits 0 if the terminal has this attribute, and 1 if it does not. The .Nm command exits 2 if any error occurred. .Sh SEE ALSO .Xr termcap 3 , .Xr termcap 5 .Sh BUGS The .Nm command can't really distinguish between different types of attributes. .Pp Some termcap entries depend upon having a .Sq % in them that is just a .Sq % and nothing more. Right now we just warn about them if they don't have a valid type declaration. These warnings are sent to stderr. .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/truss/truss.1 =================================================================== --- head/usr.bin/truss/truss.1 (revision 79534) +++ head/usr.bin/truss/truss.1 (revision 79535) @@ -1,70 +1,70 @@ .\" $FreeBSD$ .\" .Dd November 23, 1997 .Dt TRUSS 1 -.Os FreeBSD +.Os .Sh NAME .Nm truss .Nd trace system calls .Sh SYNOPSIS .Nm .Op Fl S .Op Fl o Ar file .Fl p Ar pid .Nm .Op Fl S .Op Fl o Ar file command .Op args .Sh DESCRIPTION .Nm Truss traces the system calls called by the specified process or program. Output is to the specified output file, or standard error by default. It does this by stopping and restarting the process being monitored via .Xr procfs 5 . .Pp The options are as follows: .Bl -tag -width indent .It Fl S Do not display information about signals received by the process. (Normally, .Nm displays signal as well as system call events.) .It Fl o Ar file Print the output to the specified .Ar file instead of standard error. .It Fl p Ar pid Follow the process specified by .Ar pid instead of a new command. .It Ar command Op args Execute .Ar command and trace the system calls of it. (The .Fl p and .Ar command options are mutually exclusive.) .El .Sh EXAMPLES # Follow the system calls used in echoing "hello" .Dl $ truss /bin/echo hello # Do the same, but put the output into a file .Dl $ truss -o /tmp/truss.out /bin/echo hello # Follow an already-running process .Dl $ truss -p 1 .Sh SEE ALSO .Xr kdump 1 , .Xr ktrace 1 , .Xr procfs 5 .Sh HISTORY The .Nm command was written by .An Sean Eric Fagan for .Fx . It was modeled after similar commands available for System V Release 4 and SunOS. Index: head/usr.bin/tset/tset.1 =================================================================== --- head/usr.bin/tset/tset.1 (revision 79534) +++ head/usr.bin/tset/tset.1 (revision 79535) @@ -1,406 +1,406 @@ .\" Copyright (c) 1985, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)tset.1 8.1 (Berkeley) 6/9/93 .\" $FreeBSD$ .\" .Dd June 9, 1993 .Dt TSET 1 -.Os BSD 4 +.Os .Sh NAME .Nm tset , .Nm reset .Nd terminal initialization .Sh SYNOPSIS .Nm .Op Fl IQrSs .Op Fl .Op Fl e Ar ch .Op Fl i Ar ch .Op Fl k Ar ch .Op Fl m Ar mapping .Op Ar terminal .Nm reset .Op Fl IQrSs .Op Fl .Op Fl e Ar ch .Op Fl i Ar ch .Op Fl k Ar ch .Op Fl m Ar mapping .Op Ar terminal .Sh DESCRIPTION .Nm Tset initializes terminals. .Nm Tset first determines the type of terminal that you are using. This determination is done as follows, using the first terminal type found. .Pp .Bl -bullet -compact -offset indent .It The .Ar terminal argument specified on the command line. .It The value of the .Ev TERM environment variable. .It The terminal type associated with the standard error output device in the .Pa /etc/ttys file. .It The default terminal type, ``unknown''. .El .Pp If the terminal type was not specified on the command-line, the .Fl m option mappings are then applied (see below for more information). Then, if the terminal type begins with a question mark (``?''), the user is prompted for confirmation of the terminal type. An empty response confirms the type, or, another type can be entered to specify a new type. Once the terminal type has been determined, the termcap entry for the terminal is retrieved. If no termcap entry is found for the type, the user is prompted for another terminal type. .Pp Once the termcap entry is retrieved, the window size, backspace, interrupt and line kill characters (among many other things) are set and the terminal and tab initialization strings are sent to the standard error output. Finally, if the erase, interrupt and line kill characters have changed, or are not set to their default values, their values are displayed to the standard error output. .Pp When invoked as .Nm reset , .Nm sets cooked and echo modes, turns off cbreak and raw modes, turns on newline translation and resets any unset special characters to their default values before doing the terminal initialization described above. This is useful after a program dies leaving a terminal in a abnormal state. Note, you may have to type .Dq Li reset (the line-feed character is normally control-J) to get the terminal to work, as carriage-return may no longer work in the abnormal state. Also, the terminal will often not echo the command. .Pp The options are as follows: .Bl -tag -width flag .It Fl The terminal type is displayed to the standard output, and the terminal is not initialized in any way. .It Fl e Set the erase character to .Ar ch . .It Fl I Do not send the terminal or tab initialization strings to the terminal. .It Fl i Set the interrupt character to .Ar ch . .It Fl k Set the line kill character to .Ar ch . .It Fl m Specify a mapping from a port type to a terminal. See below for more information. .It Fl Q Don't display any values for the erase, interrupt and line kill characters. .It Fl r Print the terminal type to the standard error output. .It Fl S Print the terminal type and the termcap entry to the standard output. See the section below on setting the environment for details. .It Fl s Print the sequence of shell commands to initialize the environment variables .Ev TERM and .Ev TERMCAP to the standard output. See the section below on setting the environment for details. .El .Pp The arguments for the .Fl e , .Fl i and .Fl k options may either be entered as actual characters or by using the .Dq hat notation, i.e. control-h may be specified as .Dq Li ^H or .Dq Li ^h . .Sh SETTING THE ENVIRONMENT It is often desirable to enter the terminal type and information about the terminal's capabilities into the shell's environment. This is done using the .Fl S and .Fl s options. .Pp When the .Fl S option is specified, the terminal type and the termcap entry are written to the standard output, separated by a space and without a terminating newline. This can be assigned to an array by .Nm csh and .Nm ksh users and then used like any other shell array. .Pp When the .Fl s option is specified, the commands to enter the information into the shell's environment are written to the standard output. If the .Ev SHELL environment variable ends in ``csh'', the commands are for the .Nm csh , otherwise, they are for .Xr sh . Note, the .Nm csh commands set and unset the shell variable .Dq noglob , leaving it unset. The following line in the .Pa .login or .Pa .profile files will initialize the environment correctly: .Bd -literal -offset indent eval \`tset -s options ... \` .Ed .Pp To demonstrate a simple use of the .Fl S option, the following lines in the .Pa .login file have an equivalent effect: .Bd -literal -offset indent set noglob set term=(`tset -S options ...`) setenv TERM $term[1] setenv TERMCAP "$term[2]" unset term unset noglob .Ed .Sh TERMINAL TYPE MAPPING When the terminal is not hardwired into the system (or the current system information is incorrect) the terminal type derived from the .Pa /etc/ttys file or the .Ev TERM environment variable is often something generic like .Dq network , .Dq dialup , or .Dq unknown . When .Nm is used in a startup script .Pf ( Pa .profile for .Xr sh 1 users or .Pa .login for .Xr csh 1 users) it is often desirable to provide information about the type of terminal used on such ports. The purpose of the .Fl m option is to .Dq map from some set of conditions to a terminal type, that is, to tell .Nm ``If I'm on this port at a particular speed, guess that I'm on that kind of terminal''. .Pp The argument to the .Fl m option consists of an optional port type, an optional operator, an optional baud rate specification, an optional colon (``:'') character and a terminal type. The port type is a string (delimited by either the operator or the colon character). The operator may be any combination of: .Dq Li \&> , .Dq Li \&< , .Dq Li \&@ , and .Dq Li \&! ; .Dq Li \&> means greater than, .Dq Li \&< means less than, .Dq Li \&@ means equal to and .Dq Li !\& inverts the sense of the test. The baud rate is specified as a number and is compared with the speed of the standard error output (which should be the control terminal). The terminal type is a string. .Pp If the terminal type is not specified on the command line, the .Fl m mappings are applied to the terminal type. If the port type and baud rate match the mapping, the terminal type specified in the mapping replaces the current type. If more than one mapping is specified, the first applicable mapping is used. .Pp For example, consider the following mapping: .Dq Li dialup>9600:vt100 . The port type is .Dq Li dialup , the operator is .Dq Li > , the baud rate specification is .Dq Li 9600 , and the terminal type is .Dq Li vt100 . The result of this mapping is to specify that if the terminal type is .Dq Li dialup , and the baud rate is greater than 9600 baud, a terminal type of .Dq Li vt100 will be used. .Pp If no port type is specified, the terminal type will match any port type, for example, .Dq Li -m dialup:vt100 -m :?xterm will cause any dialup port, regardless of baud rate, to match the terminal type .Dq Li vt100 , and any non-dialup port type to match the terminal type .Dq Li ?xterm . Note, because of the leading question mark, the user will be queried on a default port as to whether they are actually using an .Ar xterm terminal. .Pp No whitespace characters are permitted in the .Fl m option argument. Also, to avoid problems with metacharacters, it is suggested that the entire .Fl m option argument be placed within single quote characters, and that .Nm csh users insert a backslash character (``\e'') before any exclamation marks (``!''). .Sh ENVIRONMENT The .Nm command utilizes the .Ev SHELL and .Ev TERM environment variables. .Sh FILES .Bl -tag -width /usr/share/misc/termcap -compact .It Pa /etc/ttys system port name to terminal type mapping database .It Pa /usr/share/misc/termcap terminal capability database .El .Sh SEE ALSO .Xr csh 1 , .Xr sh 1 , .Xr stty 1 , .Xr tty 4 , .Xr termcap 5 , .Xr ttys 5 , .Xr environ 7 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . .Sh COMPATIBILITY The .Fl A , .Fl E , .Fl h , .Fl u and .Fl v options have been deleted from the .Nm utility. None of them were documented in 4.3BSD and all are of limited utility at best. The .Fl a , .Fl d and .Fl p options are similarly not documented or useful, but were retained as they appear to be in widespread use. It is strongly recommended that any usage of these three options be changed to use the .Fl m option instead. The .Fl n option remains, but has no effect. It is still permissible to specify the .Fl e , .Fl i and .Fl k options without arguments, although it is strongly recommended that such usage be fixed to explicitly specify the character. .Pp Executing .Nm as .Nm reset no longer implies the .Fl Q option. Also, the interaction between the .Fl option and the .Ar terminal argument in some historic implementations of .Nm has been removed. .Pp Finally, the .Nm implementation has been completely redone (as part of the addition to the system of a .St -p1003.1-88 compliant terminal interface) and will no longer compile on systems with older terminal interfaces. Index: head/usr.bin/ul/ul.1 =================================================================== --- head/usr.bin/ul/ul.1 (revision 79534) +++ head/usr.bin/ul/ul.1 (revision 79535) @@ -1,109 +1,109 @@ .\" Copyright (c) 1980, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)ul.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt UL 1 -.Os BSD 4 +.Os .Sh NAME .Nm ul .Nd do underlining .Sh SYNOPSIS .Nm .Op Fl i .Op Fl t Ar terminal .Op Ar name Ar ... .Sh DESCRIPTION .Nm Ul reads the named files (or standard input if none are given) and translates occurrences of underscores to the sequence which indicates underlining for the terminal in use, as specified by the environment variable .Ev TERM . The file .Pa /etc/termcap is read to determine the appropriate sequences for underlining. If the terminal is incapable of underlining, but is capable of a standout mode then that is used instead. If the terminal can overstrike, or handles underlining automatically, .Nm degenerates to .Xr cat 1 . If the terminal cannot underline, underlining is ignored. .Pp The following options are available: .Bl -tag -width Ds .It Fl i Underlining is indicated by a separate line containing appropriate dashes `\-'; this is useful when you want to look at the underlining which is present in an .Xr nroff output stream on a crt-terminal. .It Fl t Ar terminal Overrides the terminal type specified in the environment with .Ar terminal . .El .Sh ENVIRONMENT The following environment variable is used: .Bl -tag -width TERM .It Ev TERM The .Ev TERM variable is used to relate a tty device with its device capability description (see .Xr termcap 5 ) . .Ev TERM is set at login time, either by the default terminal type specified in .Pa /etc/ttys or as set during the login process by the user in their .Pa login file (see .Xr environ 7 ) . .El .Sh SEE ALSO .Xr colcrt 1 , .Xr man 1 , .Xr nroff 1 .Sh BUGS The .Xr nroff 1 command usually outputs a series of backspaces and underlines intermixed with the text to indicate underlining. No attempt is made to optimize the backward motion. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/unifdef/unifdef.1 =================================================================== --- head/usr.bin/unifdef/unifdef.1 (revision 79534) +++ head/usr.bin/unifdef/unifdef.1 (revision 79535) @@ -1,169 +1,169 @@ .\" Copyright (c) 1985, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Dave Yost. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)unifdef.1 8.2 (Berkeley) 4/1/94 .\" $FreeBSD$ .\" .Dd April 1, 1994 .Dt UNIFDEF 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm unifdef .Nd remove ifdef'ed lines .Sh SYNOPSIS .Nm .Op Fl clt .Oo .Fl D Ns Ar sym .Fl U Ns Ar sym .Fl iD Ns Ar sym .Fl iU Ns Ar sym .Oc .Ar ... .Op Ar file .Sh DESCRIPTION .Nm Unifdef is useful for removing ifdef'ed lines from a file while otherwise leaving the file alone. .Nm Unifdef acts on #ifdef, #ifndef, #else, and #endif lines, and it knows only enough about C to know when one of these is inactive because it is inside a comment, or a single or double quote. Parsing for quotes is very simplistic: when it finds an open quote, it ignores everything (except escaped quotes) until it finds a close quote, and it will not complain if it gets to the end of a line and finds no backslash for continuation. .Pp Available options: .Bl -tag -width Ds -compact .It Fl D Ns Ar sym .It Fl U Ns Ar sym Specify which symbols to define or undefine. The lines inside those ifdefs will be copied to the output or removed as appropriate. The ifdef, ifndef, else, and endif lines associated with .Ar sym will also be removed. Ifdefs involving symbols you don't specify and ``#if'' control lines are untouched and copied out along with their associated ifdef, else, and endif lines. If an ifdef X occurs nested inside another ifdef X, then the inside ifdef is treated as if it were an unrecognized symbol. If the same symbol appears in more than one argument, the last occurrence dominates. .Pp .It Fl c If the .Fl c flag is specified, then the operation of .Nm is complemented, i.e. the lines that would have been removed or blanked are retained and vice versa. .Pp .It Fl l Replace removed lines with blank lines instead of deleting them. .It Fl t Disables parsing for C comments and quotes, which is useful for plain text. .Pp .It Fl iD Ns Ar sym .It Fl iU Ns Ar sym Ignore ifdefs. If your C code uses ifdefs to delimit non-C lines, such as comments or code which is under construction, then you must tell .Nm which symbols are used for that purpose so that it won't try to parse for quotes and comments inside those ifdefs. One specifies ignored ifdefs with .Fl iD Ns Ar sym and .Fl iU Ns Ar sym similar to .Fl D Ns Ar sym and .Fl U Ns Ar sym above. .El .Pp .Nm Unifdef copies its output to .Em stdout and will take its input from .Em stdin if no .Ar file argument is given. .Pp .Nm Unifdef works nicely with the .Fl D Ns Ar sym option added to .Xr diff 1 as of the 4.1 Berkeley Software Distribution. .Sh SEE ALSO .Xr diff 1 .Sh DIAGNOSTICS .Bl -item -compact .It Inappropriate else or endif. .It Premature .Tn EOF with line numbers of the unterminated #ifdefs. .El .Pp Exit status is 0 if output is exact copy of input, 1 if not, 2 if trouble. .Sh BUGS Should try to deal with ``#if'' lines. .Pp Doesn't work correctly if input contains null characters. .Sh HISTORY The .Nm command appeared in .Bx 4.3 . Index: head/usr.bin/unvis/unvis.1 =================================================================== --- head/usr.bin/unvis/unvis.1 (revision 79534) +++ head/usr.bin/unvis/unvis.1 (revision 79535) @@ -1,58 +1,58 @@ .\" Copyright (c) 1989, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)unvis.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt UNVIS 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm unvis .Nd "revert a visual representation of data back to original form" .Sh SYNOPSIS .Nm .Op Ar .Sh DESCRIPTION .Nm Unvis is the inverse function of .Xr vis 1 . It reverts a visual representation of data back to its original form on standard output. .Sh SEE ALSO .Xr vis 1 , .Xr unvis 3 , .Xr vis 3 .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/users/users.1 =================================================================== --- head/usr.bin/users/users.1 (revision 79534) +++ head/usr.bin/users/users.1 (revision 79535) @@ -1,60 +1,60 @@ .\" Copyright (c) 1980, 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)users.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt USERS 1 -.Os BSD 3 +.Os .Sh NAME .Nm users .Nd list current users .Sh SYNOPSIS .Nm .Sh DESCRIPTION .Nm Users lists the login names of the users currently on the system, in sorted order, space separated, on a single line. .Sh FILES .Bl -tag -width /var/run/utmp .It Pa /var/run/utmp .El .Sh SEE ALSO .Xr finger 1 , .Xr last 1 , .Xr who 1 , .Xr utmp 5 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/uuencode/uuencode.1 =================================================================== --- head/usr.bin/uuencode/uuencode.1 (revision 79534) +++ head/usr.bin/uuencode/uuencode.1 (revision 79535) @@ -1,144 +1,144 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)uuencode.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt UUENCODE 1 -.Os BSD 4 +.Os .Sh NAME .Nm uuencode , .Nm uudecode .Nd encode/decode a binary file .Sh SYNOPSIS .Nm .Op Ar file .Ar name .Nm uudecode .Op Fl cips .Op Ar .Sh DESCRIPTION .Nm Uuencode and .Nm uudecode are used to transmit binary files over transmission mediums that do not support other than simple .Tn ASCII data. .Pp .Nm Uuencode reads .Ar file (or by default the standard input) and writes an encoded version to the standard output. The encoding uses only printing .Tn ASCII characters and includes the mode of the file and the operand .Ar name for use by .Nm uudecode . .Pp .Nm Uudecode transforms .Em uuencoded files (or by default, the standard input) into the original form. The resulting file is named .Ar name and will have the mode of the original file except that setuid and execute bits are not retained. .Nm Uudecode ignores any leading and trailing lines. .Pp The following options are available for .Nm uudecode : .Bl -tag -width ident .It Fl c Decode more than one uuencode'd file from .Ar file if possible. .It Fl i Do not overwrite files. .It Fl p Decode .Ar file and write output to standard output. .It Fl s Do not strip output pathname to base filename. By default .Nm uudecode deletes any prefix ending with the last slash '/' for security purpose. .El .Sh EXAMPLES The following example packages up a source tree, compresses it, uuencodes it and mails it to a user on another system. When .Nm uudecode is run on the target system, the file ``src_tree.tar.Z'' will be created which may then be uncompressed and extracted into the original tree. .Pp .Bd -literal -offset indent -compact tar cf \- src_tree \&| compress \&| uuencode src_tree.tar.Z \&| mail sys1!sys2!user .Ed .Pp The following example unpack all uuencode'd files from your mailbox into your current working directory. .Pp .Bd -literal -offset indent -compact uudecode -c < $MAIL .Ed .Pp The following example extract a compress'ed tar archive from your mailbox .Pp .Bd -literal -offset indent -compact uudecode -p < $MAIL | zcat | tar xfv - .Ed .Sh SEE ALSO .Xr basename 1 , .Xr compress 1 , .Xr mail 1 , .Xr uucp 1 , .Xr uuencode 5 .Sh BUGS The encoded form of the file is expanded by 35% (3 bytes become 4 plus control information). .Sh HISTORY The .Nm uudecode and .Nm utilities appeared in .Bx 4.0 . Index: head/usr.bin/uuencode/uuencode.format.5 =================================================================== --- head/usr.bin/uuencode/uuencode.format.5 (revision 79534) +++ head/usr.bin/uuencode/uuencode.format.5 (revision 79535) @@ -1,106 +1,106 @@ .\" Copyright (c) 1989, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)uuencode.format.5 8.2 (Berkeley) 1/12/94 .\" $FreeBSD$ .\" .Dd January 12, 1994 .Dt UUENCODE 5 -.Os BSD 4 +.Os .Sh NAME .Nm uuencode .Nd format of an encoded uuencode file .Sh DESCRIPTION Files output by .Xr uuencode 1 consist of a header line, followed by a number of body lines, and a trailer line. The .Xr uudecode 1 command will ignore any lines preceding the header or following the trailer. Lines preceding a header must not, of course, look like a header. .Pp The header line is distinguished by having the first 6 characters .Dq begin\ \& (note the trailing space). The word .Em begin is followed by a mode (in octal), and a string which names the remote file. A space separates the three items in the header line. .Pp The body consists of a number of lines, each at most 62 characters long (including the trailing newline). These consist of a character count, followed by encoded characters, followed by a newline. The character count is a single printing character, and represents an integer, the number of bytes the rest of the line represents. Such integers are always in the range from 1 to 45 or 64 and can be determined by subtracting the character space (octal 40) from the character. Character 64 represents a count of zero. .Pp Groups of 3 bytes are stored in 4 characters, 6 bits per character. All characters are always in range from 1 to 64 and are offset by a space (octal 40) to make the characters printing. Character 64 represents a count of zero. The last line may be shorter than the normal 45 bytes. If the size is not a multiple of 3, this fact can be determined by the value of the count on the last line. Extra garbage will be included to make the character count a multiple of 4. The body is terminated by a line with a count of zero. This line consists of one .Tn ASCII backquote (octal 140) character. .Pp The trailer line consists of .Dq end on a line by itself. .Sh SEE ALSO .Xr mail 1 , .Xr uucp 1 , .Xr uudecode 1 , .Xr uuencode 1 .Sh HISTORY The .Nm file format appeared in .Bx 4.0 . .\" It was named uuencode.5 prior to 4.3 Index: head/usr.bin/vgrind/vgrind.1 =================================================================== --- head/usr.bin/vgrind/vgrind.1 (revision 79534) +++ head/usr.bin/vgrind/vgrind.1 (revision 79535) @@ -1,237 +1,237 @@ .\" Copyright (c) 1980, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)vgrind.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt VGRIND 1 -.Os BSD 4 +.Os .Sh NAME .Nm vgrind .Nd grind nice listings of programs .Sh SYNOPSIS .Nm .Op Fl .Op Fl W .Op Fl d Ar file .Op Fl f .Op Fl h Ar header .Op Fl l Ns Ar language .Op Fl n .Op Fl p Ar postproc .Op Fl sn .Op Fl t .Op Fl x .Ar name Ar ... .Sh DESCRIPTION .Nm Vgrind formats the program sources which are arguments in a nice style using .Xr troff 1 Comments are placed in italics, keywords in bold face, and the name of the current function is listed down the margin of each page as it is encountered. .Pp .Nm Vgrind runs in two basic modes, filter mode (see the .Fl f option) or regular mode. In filter mode .Nm acts as a filter in a manner similar to .Xr tbl 1 . The standard input is passed directly to the standard output except for lines bracketed by the .Em troff-like macros: .Bl -tag -width Ds .It \&.vS starts processing .It \&.vE ends processing .El .Pp These lines are formatted as described above. The output from this filter can be passed to .Xr troff for output. There need be no particular ordering with .Xr eqn 1 or .Xr tbl 1 . .Pp In regular mode .Nm accepts input files, processes them, and passes them to the postprocessor for output, .Xr psroff 1 by default. .Pp In both modes .Nm passes any lines beginning with a decimal point without conversion. .Pp The options are: .Bl -tag -width Ar .It Fl forces input to be taken from standard input (default if .Fl f is specified ) .It Fl W forces output to the (wide) Versatec printer rather than the (narrow) Varian .It Fl d Ar file specifies an alternate language definitions file (default is .Pa /usr/share/misc/vgrindefs ) .It Fl f forces filter mode .It Fl h Ar header specifies a particular header to put on every output page (default is the file name) .It Fl l specifies the language to use. Currently known are .Tn PASCAL .Pq Fl l Ns Ar p , .Tn MODEL .Pq Fl l Ns Ar m , C .Pf ( Fl l Ns Ar c or the default), .Tn C++ .Pq Fl l Ns Ar c++ , .Tn CSH .Pq Fl l Ns Ar csh , .Tn SHELL .Pq Fl l Ns Ar sh , .Tn RATFOR .Pq Fl l Ns Ar r , .Tn MODULA2 .Pq Fl l Ns Ar mod2 , .Tn YACC .Pq Fl l Ns Ar yacc , .Tn LISP .Pq Fl l Ns Ar isp , .Tn ICON .Pq Fl l Ns Ar I , and .Tn PERL .Pq Fl l Ns Ar perl . .It Fl n forces no keyword bolding .It Fl p Ar postproc use .Ar postproc to post-process the output, .Xr psroff 1 by default. .It Fl s specifies a point size to use on output (exactly the same as the argument of a .ps) .It Fl t similar to the same option in .Xr troff causing formatted text to go to the standard output .It Fl x outputs the index file in a ``pretty'' format. The index file itself is produced whenever .Nm is run with a file called .Pa index in the current directory. The index of function definitions can then be run off by giving .Nm the .Fl x option and the file .Pa index as argument. .El .Sh FILES .Bl -tag -width /usr/share/misc/vgrindefsxx -compact .It Pa index file where source for index is created .It Pa /usr/share/tmac/tmac.vgrind macro package .It Pa /usr/libexec/vfontedpr preprocessor .It Pa /usr/share/misc/vgrindefs language descriptions .El .Sh SEE ALSO .Xr getcap 3 , .Xr vgrindefs 5 .Sh BUGS Vfontedpr assumes that a certain programming style is followed: .Pp For .Tn C \- function names can be preceded on a line only by spaces, tabs, or an asterisk. The parenthesized arguments must also be on the same line. .Pp For .Tn PASCAL \- function names need to appear on the same line as the keywords .Em function or .Em procedure . .Pp For .Tn MODEL \- function names need to appear on the same line as the keywords .Em is beginproc . .Pp If these conventions are not followed, the indexing and marginal function name comment mechanisms will fail. .Pp More generally, arbitrary formatting styles for programs mostly look bad. The use of spaces to align source code fails miserably; if you plan to .Nm your program you should use tabs. This is somewhat inevitable since the font used by .Nm is variable width. .Pp The mechanism of .Xr ctags 1 in recognizing functions should be used here. .Pp Filter mode does not work in documents using the .Fl me or .Fl ms macros. (So what use is it anyway?) .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/vgrind/vgrindefs.5 =================================================================== --- head/usr.bin/vgrind/vgrindefs.5 (revision 79534) +++ head/usr.bin/vgrind/vgrindefs.5 (revision 79535) @@ -1,170 +1,170 @@ .\" Copyright (c) 1989, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)vgrindefs.5 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt VGRINDEFS 5 -.Os BSD 4.2 +.Os .Sh NAME .Nm vgrindefs .Nd language definition data base for .Xr vgrind 1 .Sh SYNOPSIS .Nm .Sh DESCRIPTION The .Nm file contains all language definitions for .Xr vgrind 1 . The data base is very similar to .Xr termcap 5 . .Sh FIELDS The following table names and describes each field. .Pp .Bl -column Namexxx Tpexxx .It Sy "Name Type Description .It "ab str regular expression for the start of an alternate comment" .It "ae str regular expression for the end of an alternate comment" .It "pb str regular expression for start of a procedure" .It "bb str regular expression for start of a lexical block" .It "be str regular expression for the end of a lexical block" .It "cb str regular expression for the start of a comment" .It "ce str regular expression for the end of a comment" .It "sb str regular expression for the start of a string" .It "se str regular expression for the end of a string" .It "lb str regular expression for the start of a character constant" .It "le str regular expression for the end of a character constant" .It "nc str regular expression for a non-comment (see below)" .It "tl bool present means procedures are only defined at the top lexical level" .It "oc bool present means upper and lower case are equivalent" .It "kw str a list of keywords separated by spaces" .El .Pp Non-comments are required to describe a certain context where a sequence that would normally start a comment loses its special meaning. A typical example for this can be found in Perl, where comments are normally starting with .Ql # , while the string .Ql $# is an operator on an array. .Sh EXAMPLES The following entry, which describes the C language, is typical of a language entry. .Bd -literal C|c:\ :pb=^\ed?*?\ed?\ep\ed?\e(\ea?\e):bb={:be=}:cb=/*:ce=*/:sb=":se=\ee":\e :lb=':le=\ee':tl:\e :kw=asm auto break case char continue default do double else enum\e extern float for fortran goto if int long register return short\e sizeof static struct switch typedef union unsigned while #define\e #else #endif #if #ifdef #ifndef #include #undef # define else endif\e if ifdef ifndef include undef: .Ed .Pp Note that the first field is just the language name (and any variants of it). Thus the C language could be specified to .Xr vgrind 1 as "c" or "C". .Pp Entries may continue onto multiple lines by giving a \e as the last character of a line. Capabilities in .Nm are of two types: Boolean capabilities which indicate that the language has some particular feature and string capabilities which give a regular expression or keyword list. .Sh REGULAR EXPRESSIONS .Nm Vgrindefs uses regular expression which are very similar to those of .Xr ex 1 and .Xr lex 1 . The characters `^', `$', `:' and `\e' are reserved characters and must be "quoted" with a preceding .Ql \e if they are to be included as normal characters. The metasymbols and their meanings are: .Bl -tag -width indent .It $ the end of a line .It \&^ the beginning of a line .It \ed a delimiter (space, tab, newline, start of line) .It \ea matches any string of symbols (like .* in lex) .It \ep matches any alphanumeric name. In a procedure definition (pb) the string that matches this symbol is used as the procedure name. .It () grouping .It \&| alternation .It ? last item is optional .It \ee preceding any string means that the string will not match an input string if the input string is preceded by an escape character (\e). This is typically used for languages (like C) which can include the string delimiter in a string by escaping it. .El .Pp Unlike other regular expressions in the system, these match words and not characters. Hence something like "(tramp|steamer)flies?" would match "tramp", "steamer", "trampflies", or "steamerflies". .Sh KEYWORD LIST The keyword list is just a list of keywords in the language separated by spaces. If the "oc" boolean is specified, indicating that upper and lower case are equivalent, then all the keywords should be specified in lower case. .Sh FILES .Bl -tag -width /usr/share/misc/vgrindefs -compact .It Pa /usr/share/misc/vgrindefs File containing terminal descriptions. .El .Sh SEE ALSO .Xr troff 1 , .Xr vgrind 1 .Sh HISTORY The .Nm file format appeared in .Bx 4.2 . Index: head/usr.bin/vis/vis.1 =================================================================== --- head/usr.bin/vis/vis.1 (revision 79534) +++ head/usr.bin/vis/vis.1 (revision 79535) @@ -1,125 +1,125 @@ .\" Copyright (c) 1989, 1991, 1993, 1994 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)vis.1 8.4 (Berkeley) 4/19/94 .\" $FreeBSD$ .\" .Dd April 19, 1994 .Dt VIS 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm vis .Nd display non-printable characters in a visual format .Sh SYNOPSIS .Nm .Op Fl cbflnostw .Op Fl F Ar foldwidth .Op Ar .Sh DESCRIPTION .Nm Vis is a filter for converting non-printable characters into a visual representation. It differs from .Ql cat -v in that the form is unique and invertible. By default, all non-graphic characters except space, tab, and newline are encoded. A detailed description of the various visual formats is given in .Xr vis 3 . .Pp The options are as follows: .Bl -tag -width Ds .It Fl b Turns off prepending of backslash before up-arrow control sequences and meta characters, and disables the doubling of backslashes. This produces output which is neither invertible or precise, but does represent a minimum of change to the input. It is similar to .Dq Li cat -v . .It Fl c Request a format which displays a small subset of the non-printable characters using C-style backslash sequences. .It Fl F Causes .Nm to fold output lines to foldwidth columns (default 80), like .Xr fold 1 , except that a hidden newline sequence is used, (which is removed when inverting the file back to its original form with .Xr unvis 1 ) . If the last character in the encoded file does not end in a newline, a hidden newline sequence is appended to the output. This makes the output usable with various editors and other utilities which typically don't work with partial lines. .It Fl f Same as .Fl F . .It Fl l Mark newlines with the visible sequence .Ql \e$ , followed by the newline. .It Fl n Turns off any encoding, except for the fact that backslashes are still doubled and hidden newline sequences inserted if .Fl f or .Fl F is selected. When combined with the .Fl f flag, .Nm becomes like an invertible version of the .Xr fold 1 utility. That is, the output can be unfolded by running the output through .Xr unvis 1 . .It Fl o Request a format which displays non-printable characters as an octal number, \eddd. .It Fl s Only characters considered unsafe to send to a terminal are encoded. This flag allows backspace, bell, and carriage return in addition to the default space, tab and newline. .It Fl t Tabs are also encoded. .It Fl w White space (space-tab-newline) is also encoded. .El .Sh SEE ALSO .Xr unvis 1 , .Xr vis 3 .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/vmstat/vmstat.8 =================================================================== --- head/usr.bin/vmstat/vmstat.8 (revision 79534) +++ head/usr.bin/vmstat/vmstat.8 (revision 79535) @@ -1,323 +1,323 @@ .\" Copyright (c) 1986, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)vmstat.8 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1996 .Dt VMSTAT 8 -.Os BSD 4 +.Os .Sh NAME .Nm vmstat .Nd report virtual memory statistics .Sh SYNOPSIS .Nm .\" .Op Fl fimst .Op Fl imsz .Op Fl c Ar count .Op Fl M Ar core .Op Fl N Ar system .Op Fl w Ar wait .Op Fl n Ar devs .Oo .Fl p .Sm off .Ar type , if , pass .Sm on .Oc .Op Ar disks .Sh DESCRIPTION .Nm Vmstat reports certain kernel statistics kept about process, virtual memory, disk, trap and cpu activity. .Pp The options are as follows: .Bl -tag -width indent .It Fl c Repeat the display .Ar count times. The first display is for the time since a reboot and each subsequent report is for the time period since the last display. If no repeat .Ar count is specified, and .Fl w is specified, the default is infinity, otherwise the default is one. .\" .It Fl f .\" Report on the number .\" .Xr fork 2 .\" and .\" .Xr vfork 2 .\" system calls since system startup, and the number of pages of virtual memory .\" involved in each. .It Fl i Report on the number of interrupts taken by each device since system startup. .It Fl M Extract values associated with the name list from the specified .Ar core instead of the default .Pa /dev/kmem . .It Fl N Extract the name list from the specified .Ar system instead of the default .Pa /kernel . .It Fl m Report on the usage of kernel dynamic memory listed first by size of allocation and then by type of usage. .It Fl n Change the maximum number of disks to display from the default of 2. .It Fl p Specify which types of devices to display. There are three different categories of devices: .Pp .Bl -tag -width indent -compact .It device type: .Bl -tag -width 9n -compact .It da Direct Access devices .It sa Sequential Access devices .It printer Printers .It proc Processor devices .It worm Write Once Read Multiple devices .It cd CD devices .It scanner Scanner devices .It optical Optical Memory devices .It changer Medium Changer devices .It comm Communication devices .It array Storage Array devices .It enclosure Enclosure Services devices .It floppy Floppy devices .El .Pp .It interface: .Bl -tag -width 9n -compact .It IDE Integrated Drive Electronics devices .It SCSI Small Computer System Interface devices .It other Any other device interface .El .Pp .It passthrough: .Bl -tag -width 9n -compact .It pass Passthrough devices .El .El .Pp The user must specify at least one device type, and may specify at most one device type from each category. Multiple device types in a single device type statement must be separated by commas. .Pp Any number of .Fl p arguments may be specified on the command line. All .Fl p arguments are ORed together to form a matching expression against which all devices in the system are compared. Any device that fully matches any .Fl p argument will be included in the .Nm output, up to three devices, or the maximum number of devices specified by the user. .It Fl s Display the contents of the .Em sum structure, giving the total number of several kinds of paging related events which have occurred since system startup. .\" .It Fl t .\" Report on the number of page in and page reclaims since system startup, .\" and the amount of time required by each. .It Fl w Pause .Ar wait seconds between each display. If no repeat .Ar wait interval is specified, the default is 1 second. .It Fl z Report on memory used by the kernel zone allocator, by zone. The information shown is the same as that returned by the .Va vm.zone sysctl variable. .El .Pp By default, .Nm displays the following information: .Pp .Bl -tag -width indent .It procs Information about the numbers of processes in various states. .Pp .Bl -tag -width indent -compact .It r in run queue .It b blocked for resources (i/o, paging, etc.) .It w runnable or short sleeper (< 20 secs) but swapped .El .It memory Information about the usage of virtual and real memory. Virtual pages (reported in units of 1024 bytes) are considered active if they belong to processes which are running or have run in the last 20 seconds. .Pp .Bl -tag -width indent -compact .It avm active virtual pages .It fre size of the free list .El .It page Information about page faults and paging activity. These are averaged each five seconds, and given in units per second. .Pp .Bl -tag -width indent -compact .It flt total number of page faults .It re page reclaims (simulating reference bits) .\" .It at .\" pages attached (found in free list) .It pi pages paged in .It po pages paged out .It fr pages freed per second .\" .It de .\" anticipated short term memory shortfall .It sr pages scanned by clock algorithm, per-second .El .It disks Disk operations per second (this field is system dependent). Typically paging will be split across the available drives. The header of the field is the first two characters of the disk name and the unit number. If more than three disk drives are configured in the system, .Nm displays only the first three drives, unless the user specifies the .Fl n argument to increase the number of drives displayed. This will probably cause the display to exceed 80 columns, however. To force .Nm to display specific drives, their names may be supplied on the command line. .Nm defaults to show disks first, and then various other random devices in the system to add up to three devices, if there are that many devices in the system. If devices are specified on the command line, or if a device type matching pattern is specified (see above), .Nm will only display the given devices or the devices matching the pattern, and will not randomly select other devices in the system. .It faults Trap/interrupt rate averages per second over last 5 seconds. .Pp .Bl -tag -width indent -compact .It in device interrupts per interval (including clock interrupts) .It sy system calls per interval .It cs cpu context switch rate (switches/interval) .El .It cpu Breakdown of percentage usage of CPU time. .Pp .Bl -tag -width indent -compact .It us user time for normal and low priority processes .It sy system time .It id cpu idle .El .El .Sh EXAMPLES The command: .Dl vmstat -w 5 will print what the system is doing every five seconds; this is a good choice of printing interval since this is how often some of the statistics are sampled in the system. Others vary every second and running the output for a while will make it apparent which are recomputed every second. .Pp The command: .Dl vmstat -p da -p cd -w 1 will tell vmstat to select the first three direct access or CDROM devices and display statistics on those devices, as well as other systems statistics every second. .Sh FILES .Bl -tag -width /dev/kmemxxx -compact .It Pa /kernel default kernel namelist .It Pa /dev/kmem default memory file .El .Sh SEE ALSO .Xr fstat 1 , .Xr netstat 1 , .Xr nfsstat 1 , .Xr ps 1 , .Xr systat 1 , .Xr iostat 8 , .Xr pstat 8 , .Xr sysctl 8 .Pp The sections starting with ``Interpreting system activity'' in .%T "Installing and Operating 4.3BSD" . .Sh BUGS The .Fl c and .Fl w options are only available with the default output. Index: head/usr.bin/w/uptime.1 =================================================================== --- head/usr.bin/w/uptime.1 (revision 79534) +++ head/usr.bin/w/uptime.1 (revision 79535) @@ -1,61 +1,61 @@ .\" Copyright (c) 1980, 1990, 1993, 1994 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)uptime.1 8.2 (Berkeley) 4/18/94 .\" $FreeBSD$ .\" .Dd April 18, 1994 .Dt UPTIME 1 -.Os BSD 3 +.Os .Sh NAME .Nm uptime .Nd show how long system has been running .Sh SYNOPSIS .Nm .Sh DESCRIPTION The .Nm utility displays the current time, the length of time the system has been up, the number of users, and the load average of the system over the last 1, 5, and 15 minutes. .Sh FILES .Bl -tag -width /kernel .It Pa /kernel system name list .El .Sh SEE ALSO .Xr w 1 .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/w/w.1 =================================================================== --- head/usr.bin/w/w.1 (revision 79534) +++ head/usr.bin/w/w.1 (revision 79535) @@ -1,145 +1,145 @@ .\" Copyright (c) 1980, 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)w.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt W 1 -.Os BSD 4 +.Os .Sh NAME .Nm w .Nd "display who is logged in and what they are doing" .Sh SYNOPSIS .Nm .Op Fl dhin .Op Fl M Ar core .Op Fl N Ar system .Op Ar user ... .Sh DESCRIPTION The .Nm utility prints a summary of the current activity on the system, including what each user is doing. The first line displays the current time of day, how long the system has been running, the number of users logged into the system, and the load averages. The load average numbers give the number of jobs in the run queue averaged over 1, 5 and 15 minutes. .Pp The fields output are the user's login name, the name of the terminal the user is on, the host from which the user is logged in, the time the user logged on, the time since the user last typed anything, and the name and arguments of the current process. .Pp The options are as follows: .Bl -tag -width Ds .It Fl d dumps out the entire process list on a per controlling tty basis, instead of just the top level process. .It Fl h Suppress the heading. .It Fl i Output is sorted by idle time. .It Fl M Extract values associated with the name list from the specified core instead of the default .Dq /dev/kmem . .It Fl N Extract the name list from the specified system instead of the default .Dq /kernel . .It Fl n Show network addresses as numbers (normally .Nm interprets addresses and attempts to display them symbolically). .El .Pp If one or more .Ar user names are specified, the output is restricted to those users. .Sh FILES .Bl -tag -width /var/run/utmp -compact .It Pa /var/run/utmp list of users on the system .El .Sh SEE ALSO .Xr finger 1 , .Xr ps 1 , .Xr uptime 1 , .Xr who 1 .Sh BUGS The notion of the .Dq current process is muddy. The current algorithm is ``the highest numbered process on the terminal that is not ignoring interrupts, or, if there is none, the highest numbered process on the terminal''. This fails, for example, in critical sections of programs like the shell and editor, or when faulty programs running in the background fork and fail to ignore interrupts. (In cases where no process can be found, .Nm prints .Dq \- . ) .Pp The .Tn CPU time is only an estimate, in particular, if someone leaves a background process running after logging out, the person currently on that terminal is .Dq charged with the time. .Pp Background processes are not shown, even though they account for much of the load on the system. .Pp Sometimes processes, typically those in the background, are printed with null or garbaged arguments. In these cases, the name of the command is printed in parentheses. .Pp The .Nm utility does not know about the new conventions for detection of background jobs. It will sometimes find a background job instead of the right one. .Sh COMPATIBILITY The .Fl f , .Fl l , .Fl s , and .Fl w flags are no longer supported. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/wall/wall.1 =================================================================== --- head/usr.bin/wall/wall.1 (revision 79534) +++ head/usr.bin/wall/wall.1 (revision 79535) @@ -1,71 +1,71 @@ .\" Copyright (c) 1989, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)wall.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt WALL 1 -.Os BSD 4 +.Os .Sh NAME .Nm wall .Nd write a message to users .Sh SYNOPSIS .Nm .Op Fl g Ar group .Op Ar file .Sh DESCRIPTION .Nm Wall displays the contents of .Ar file or, by default, its standard input, on the terminals of all currently logged in users. .Pp Only the super-user can write on the terminals of users who have chosen to deny messages or are using a program which automatically denies messages. .Bl -tag -width indent .It Fl g Send messages to users in this group. This option may be specified multiple times, and any user in any of the specified groups will receive the message. .El .Sh SEE ALSO .Xr mesg 1 , .Xr talk 1 , .Xr write 1 , .Xr shutdown 8 .Sh HISTORY A .Nm command appeared in .At v7 . Index: head/usr.bin/what/what.1 =================================================================== --- head/usr.bin/what/what.1 (revision 79534) +++ head/usr.bin/what/what.1 (revision 79535) @@ -1,78 +1,78 @@ .\" Copyright (c) 1980, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)what.1 8.1 (Berkeley) 6/6/93 .\" .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt WHAT 1 -.Os BSD 4 +.Os .Sh NAME .Nm what .Nd "show what versions of object modules were used to construct a file" .Sh SYNOPSIS .Nm .Op Fl s .Ar file Ar ... .Sh DESCRIPTION The .Nm utility searches each specified .Ar file for sequences of the form .Dq \&@(#) as inserted by the source code control system. It prints the remainder of the string following this marker, up to a NUL character, newline, double quote, .Dq \&> character, or backslash. .Pp The following option is available: .Bl -tag -width Ds .It Fl s Stop searching each file after the first match. .El .Pp Exit status is 0 if any matches were found, otherwise 1. .Sh BUGS This is a rewrite of the .Tn SCCS command of the same name, and behavior may not be identical. .Sh SEE ALSO .Xr ident 1 , .Xr strings 1 .Sh HISTORY The .Nm command appeared in .Bx 4.0 . Index: head/usr.bin/whereis/whereis.1 =================================================================== --- head/usr.bin/whereis/whereis.1 (revision 79534) +++ head/usr.bin/whereis/whereis.1 (revision 79535) @@ -1,141 +1,141 @@ .\" Copyright (c) 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)whereis.1 8.2 (Berkeley) 12/30/93 .\" .\" $FreeBSD$ .\" .Dd June 15, 1996 .Dt WHEREIS 1 -.Os FreeBSD +.Os .Sh NAME .Nm whereis .Nd locate programs .Sh SYNOPSIS .Nm .Op Fl bms .Op Fl u .Op Fl BMS dir ... Fl f .Ar program ... .Sh DESCRIPTION The .Nm utility checks the standard binary, manual page, and source directories for the specified programs, printing out the paths of any it finds. The supplied names are first stripped of leading path name components, any single trailing extension added by .Xr gzip 1 or .Xr compress 1 , and the leading .Ql s.\& or trailing .Ql ,v from a source code control system. .Pp The default path searched is the string returned by the .Xr sysctl 8 utility for the .Dq user.cs_path string, with .Pa /usr/libexec and the current user's .Ev $PATH appended. Manual pages are searched by default along the .Ev $MANPATH . Program sources are located in a list of known standard places, including all the subdirectories of .Pa /usr/src and .Pa /usr/ports . .Pp The following options are available: .Bl -tag -width indent .It Fl B Specify directories to search for binaries. Requires the .Fl f option. .It Fl M Specify directories to search for manual pages. Requires the .Fl f option. .It Fl S Specify directories to search for program sources. Requires the .Fl f option. .It Fl b Search for binaries. .It Fl f Delimits the list of directories after the .Fl B , .Fl M , or .Fl S options, and indicates the beginning of the .Ar name list. .It Fl m Search for manual pages. .It Fl s Search for source directories. .It Fl u Search for .Dq unusual entries. A file is said to be unusual if it does not have one entry of each requested type. .El .Sh EXAMPLES The following finds all utilities under .Pa /usr/bin that do not have documentation: .Dl whereis -m -u /usr/bin/* .Sh SEE ALSO .Xr find 1 , .Xr locate 1 , .Xr man 1 , .Xr which 1 , .Xr sysctl 8 .Sh BUGS The search for sources is implemented as a quick search as the first-level subdirectory of each element of the list of source directories first. If this didn't succeed, the utility .Xr locate 1 is requested to do the search in deeper nested subdirectories. This might take some time, and will only succeed if the locate database is up-to-date. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . This version re-implements the historical functionality that was lost in .Bx 4.4 . Index: head/usr.bin/which/which.1 =================================================================== --- head/usr.bin/which/which.1 (revision 79534) +++ head/usr.bin/which/which.1 (revision 79535) @@ -1,79 +1,79 @@ .\" Manpage Copyright (c) 1995, Jordan Hubbard .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the FreeBSD Project .\" its contributors. .\" 4. Neither the name of the FreeBSD Project nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE CONTRIBUTOR ``AS IS'' AND ANY EXPRESS OR .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. .\" IN NO EVENT SHALL THE CONTRIBUTOR BE LIABLE FOR ANY DIRECT, INDIRECT, .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE .\" OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD$ .Dd January 26, 1995 .Dt WHICH 1 -.Os FreeBSD +.Os .Sh NAME .Nm which .Nd "locate a program file in the user's path" .Sh SYNOPSIS .Nm .Op Fl as .Op Ar command .Ar ... .Sh DESCRIPTION .Nm Which takes a list of command names and searches the path for each executable file that would be run had these commands actually been invoked. .Pp The following options are available: .Bl -tag -width indent .It Fl a List all instances of executables found (instead of just the first one of each). .It Fl s No output, just return 0 if any of the executables are found, or 1 if none are found. .El .Pp Some shells may provide a builtin .Nm command which is similar or identical to this utility. Consult the .Xr builtin 1 manual page. .Sh HISTORY The .Nm command first appeared in .Fx 2.1 . .Sh SEE ALSO .Xr builtin 1 , .Xr csh 1 , .Xr find 1 , .Xr locate 1 , .Xr perl 1 , .Xr whereis 1 .Sh AUTHORS The PERL script for this more modern version of .Nm was written by .An Wolfram Schneider Aq wosch@FreeBSD.org . Index: head/usr.bin/window/window.1 =================================================================== --- head/usr.bin/window/window.1 (revision 79534) +++ head/usr.bin/window/window.1 (revision 79535) @@ -1,949 +1,949 @@ .\" Copyright (c) 1985, 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Edward Wang at The University of California, Berkeley. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)window.1 8.2 (Berkeley) 12/30/93 .\" $FreeBSD$ .\" .Dd December 30, 1993 .Dt WINDOW 1 -.Os BSD 4.3 +.Os .Sh NAME .Nm window .Nd window environment .Sh SYNOPSIS .Nm .Op Fl t .Op Fl f .Op Fl d .Op Fl e Ar escape-char .Op Fl c Ar command .Sh DESCRIPTION .Nm Window implements a window environment on .Tn ASCII terminals. .Pp A window is a rectangular portion of the physical terminal screen associated with a set of processes. Its size and position can be changed by the user at any time. Processes communicate with their window in the same way they normally interact with a terminal\-through their standard input, output, and diagnostic file descriptors. The window program handles the details of redirecting input and output to and from the windows. At any one time, only one window can receive input from the keyboard, but all windows can simultaneously send output to the display. .Pp When .Nm starts up, the commands (see long commands below) contained in the file .Pa .windowrc in the user's home directory are executed. If it does not exist, two equal sized windows spanning the terminal screen are created by default. .Pp The command line options are .Bl -tag -width Fl .It Fl t Turn on terse mode (see .Ic terse command below). .It Fl f Fast. Don't perform any startup action. .It Fl d Ignore .Pa .windowrc and create the two default windows instead. .It Fl e Ar escape-char Set the escape character to .Ar escape-char . .Ar Escape-char can be a single character, or in the form .Ic ^X where .Ar X is any character, meaning .No control\- Ns Ar X . .It Fl c Ar command Execute the string .Ar command as a long command (see below) before doing anything else. .El .Pp Windows can overlap and are framed as necessary. Each window is named by one of the digits ``1'' to ``9''. This one-character identifier, as well as a user definable label string, are displayed with the window on the top edge of its frame. A window can be designated to be in the .Ar foreground , in which case it will always be on top of all normal, non-foreground windows, and can be covered only by other foreground windows. A window need not be completely within the edges of the terminal screen. Thus a large window (possibly larger than the screen) may be positioned to show only a portion of its full size. .Pp Each window has a cursor and a set of control functions. Most intelligent terminal operations such as line and character deletion and insertion are supported. Display modes such as underlining and reverse video are available if they are supported by the terminal. In addition, similar to terminals with multiple pages of memory, each window has a text buffer which can have more lines than the window itself. .Ss Process Environment With each newly created window, a shell program is spawned with its process environment tailored to that window. Its standard input, output, and diagnostic file descriptors are bound to one end of either a pseudo-terminal (see .Xr pty 4 ) or a .Ux domain socket (see .Xr socketpair 2 ) . If a pseudo-terminal is used, then its special characters and modes (see .Xr stty 1 ) are copied from the physical terminal. A .Xr termcap 5 entry tailored to this window is created and passed as environment (see .Xr environ 7 ) variable .Ev TERMCAP . The termcap entry contains the window's size and characteristics as well as information from the physical terminal, such as the existence of underline, reverse video, and other display modes, and the codes produced by the terminal's function keys, if any. In addition, the window size attributes of the pseudo-terminal are set to reflect the size of this window, and updated whenever it is changed by the user. In particular, the editor .Xr vi 1 uses this information to redraw its display. .Ss Operation During normal execution, .Nm can be in one of two states: conversation mode and command mode. In conversation mode, the terminal's real cursor is placed at the cursor position of a particular window--called the current window--and input from the keyboard is sent to the process in that window. The current window is always on top of all other windows, except those in foreground. In addition, it is set apart by highlighting its identifier and label in reverse video. .Pp Typing .Nm Ns 's escape character (normally .Ic ^P ) in conversation mode switches it into command mode. In command mode, the top line of the terminal screen becomes the command prompt window, and .Nm interprets input from the keyboard as commands to manipulate windows. .Pp There are two types of commands: short commands are usually one or two key strokes; long commands are strings either typed by the user in the command window (see the .Dq Ic \&: command below), or read from a file (see .Ic source below). .Ss Short Commands Below, .Ar \&# represents one of the digits ``1'' to ``9'' corresponding to the windows 1 to 9. .Ic ^X means .No control\- Ns Ar X , where .Ar X is any character. In particular, .Ic ^^ is .Li control\-^ . .Ar Escape is the escape key, or .Ic ^\&[ . .Bl -tag -width Ds .It Ar # Select window .Ar # as the current window and return to conversation mode. .It Ic \&% Ns Ar # Select window .Ar # but stay in command mode. .It Ic ^^ Select the previous window and return to conversation mode. This is useful for toggling between two windows. .It Ic escape Return to conversation mode. .It Ic ^P Return to conversation mode and write .Ic ^P to the current window. Thus, typing two .Ic ^P Ns 's in conversation mode sends one to the current window. If the .Nm escape is changed to some other character, that character takes the place of .Ic ^P here. .It Ic \&? List a short summary of commands. .It Ic ^L Refresh the screen. .It Ic q Exit .Nm . Confirmation is requested. .It Ic ^Z Suspend .Nm . .It Ic w Create a new window. The user is prompted for the positions of the upper left and lower right corners of the window. The cursor is placed on the screen and the keys ``h'', ``j'', ``k'', and ``l'' move the cursor left, down, up, and right, respectively. The keys ``H'', ``J'', ``K'', and ``L'' move the cursor to the respective limits of the screen. Typing a number before the movement keys repeats the movement that number of times. Return enters the cursor position as the upper left corner of the window. The lower right corner is entered in the same manner. During this process, the placement of the new window is indicated by a rectangular box drawn on the screen, corresponding to where the new window will be framed. Typing escape at any point cancels this command. .Pp This window becomes the current window, and is given the first available ID. The default buffer size is used (see .Ar default_nline command below). .Pp Only fully visible windows can be created this way. .It Ic c Ns Ar # Close window .Ar # . The process in the window is sent the hangup signal (see .Xr kill 1 ) . .Xr Csh 1 should handle this signal correctly and cause no problems. .It Ic m Ns Ar # Move window .Ar # to another location. A box in the shape of the window is drawn on the screen to indicate the new position of the window, and the same keys as those for the .Ic w command are used to position the box. The window can be moved partially off-screen. .It Ic M Ns Ar # Move window .Ar # to its previous position. .It Ic s Ns Ar # Change the size of window .Ar # . The user is prompted to enter the new lower right corner of the window. A box is drawn to indicate the new window size. The same keys used in .Ic w and .Ic m are used to enter the position. .It Ic S Ns Ar # Change window .Ar # to its previous size. .It Ic ^Y Scroll the current window up by one line. .It Ic ^E Scroll the current window down by one line. .It Ic ^U Scroll the current window up by half the window size. .It Ic ^D Scroll the current window down by half the window size. .It Ic ^B Scroll the current window up by the full window size. .It Ic ^F Scroll the current window down by the full window size. .It Ic h Move the cursor of the current window left by one column. .It Ic j Move the cursor of the current window down by one line. .It Ic k Move the cursor of the current window up by one line. .It Ic l Move the cursor of the current window right by one column. .It Ic y Yank. The user is prompted to enter two points within the current window. Then the content of the current window between those two points is saved in the yank buffer. .It Ic p Put. The content of the yank buffer is written to the current window as input. .It Ic ^S Stop output in the current window. .It Ic ^Q Start output in the current window. .It Ic : Enter a line to be executed as long commands. Normal line editing characters (erase character, erase word, erase line) are supported. .El .Ss Long Commands Long commands are a sequence of statements parsed much like a programming language, with a syntax similar to that of C. Numeric and string expressions and variables are supported, as well as conditional statements. .Pp There are two data types: string and number. A string is a sequence of letters or digits beginning with a letter. ``_'' and ``.'' are considered letters. Alternately, non-alphanumeric characters can be included in strings by quoting them in ``"'' or escaping them with ``\\''. In addition, the ``\\'' sequences of C are supported, both inside and outside quotes (e.g., ``\\n'' is a new line, ``\\r'' a carriage return). For example, these are legal strings: abcde01234, "&#$^*&#", ab"$#"cd, ab\\$\\#cd, "/usr/ucb/window". .Pp A number is an integer value in one of three forms: a decimal number, an octal number preceded by ``0'', or a hexadecimal number preceded by ``0x'' or ``0X''. The natural machine integer size is used (i.e., the signed integer type of the C compiler). As in C, a non-zero number represents a boolean true. .Pp The character ``#'' begins a comment which terminates at the end of the line. .Pp A statement is either a conditional or an expression. Expression statements are terminated with a new line or ``;''. To continue an expression on the next line, terminate the first line with ``\\''. .Ss Conditional Statement .Nm Window has a single control structure: the fully bracketed if statement in the form .Pp .Bd -literal -offset indent -compact if then \t \t... elsif then \t \t... else \t \t... endif .Ed .Pp The .Ic else and .Ic elsif parts are optional, and the latter can be repeated any number of times. must be numeric. .Ss Expressions Expressions in .Nm are similar to those in the C language, with most C operators supported on numeric operands. In addition, some are overloaded to operate on strings. .Pp When an expression is used as a statement, its value is discarded after evaluation. Therefore, only expressions with side effects (assignments and function calls) are useful as statements. .Pp Single valued (no arrays) variables are supported, of both numeric and string values. Some variables are predefined. They are listed below. .Pp The operators in order of increasing precedence: .Bl -tag -width Fl .It Xo .Aq Va expr1 .Ic = .Aq Va expr2 .Xc Assignment. The variable of name .Aq Va expr1 , which must be string valued, is assigned the result of .Aq Va expr2 . Returns the value of .Aq Va expr2 . .It Xo .Aq Va expr1 .Ic \&? .Aq Va expr2 .Ic : .Aq Va expr3 .Xc Returns the value of .Aq Va expr2 if .Aq Va expr1 evaluates true (non-zero numeric value); returns the value of .Aq Va expr3 otherwise. Only one of .Aq Va expr2 and .Aq Va expr3 is evaluated. .Aq Va Expr1 must be numeric. .It Xo .Aq Va expr1 .Ic \&|\&| .Aq Va expr2 .Xc Logical or. Numeric values only. Short circuit evaluation is supported (i.e., if .Aq Va expr1 evaluates true, then .Aq Va expr2 is not evaluated). .It Xo .Aq Va expr1 .Ic \&&\&& .Aq Va expr2 .Xc Logical and with short circuit evaluation. Numeric values only. .It Xo .Aq Va expr1 .Ic \&| .Aq Va expr2 .Xc Bitwise or. Numeric values only. .It Xo .Aq Va expr1 .Ic ^ .Aq Va expr2 .Xc Bitwise exclusive or. Numeric values only. .It Xo .Aq Va expr1 .Ic \&& .Aq Va expr2 .Xc Bitwise and. Numeric values only. .It Xo .Aq Va expr1 .Ic == .Aq Va expr2 , .Aq Va expr1 .Ic != .Aq expr2 .Xc Comparison (equal and not equal, respectively). The boolean result (either 1 or 0) of the comparison is returned. The operands can be numeric or string valued. One string operand forces the other to be converted to a string in necessary. .It Xo .Aq Va expr1 .Ic < .Aq Va expr2 , .Aq Va expr1 .Ic > .Aq Va expr2 , .Aq Va expr1 .Ic <= .Aq Va expr2 , .Xc Less than, greater than, less than or equal to, greater than or equal to. Both numeric and string values, with automatic conversion as above. .It Xo .Aq Va expr1 .Ic << .Aq Va expr2 , .Aq Va expr1 .Ic >> .Aq Va expr2 .Xc If both operands are numbers, .Aq Va expr1 is bit shifted left (or right) by .Aq Va expr2 bits. If .Aq Va expr1 is a string, then its first (or last) .Aq Va expr2 characters are returns (if .Aq Va expr2 is also a string, then its length is used in place of its value). .It Xo .Aq Va expr1 .Ic + .Aq Va expr2 , .Aq Va expr1 .Ic - .Aq Va expr2 .Xc Addition and subtraction on numbers. For ``+'', if one argument is a string, then the other is converted to a string, and the result is the concatenation of the two strings. .It Xo .Aq Va expr1 .Ic \&* .Aq Va expr2 , .Aq Va expr1 .Ic \&/ .Aq Va expr2 , .Aq Va expr1 .Ic \&% .Aq Va expr2 .Xc Multiplication, division, modulo. Numbers only. .It Xo .Ic \- Ns Aq Va expr , .Ic ~ Ns Aq Va expr , .Ic \&! Ns Aq Va expr , .Ic \&$ Ns Aq Va expr , .Ic \&$? Ns Aq Va expr .Xc The first three are unary minus, bitwise complement and logical complement on numbers only. The operator, ``$'', takes .Aq Va expr and returns the value of the variable of that name. If .Aq Va expr is numeric with value .Ar n and it appears within an alias macro (see below), then it refers to the nth argument of the alias invocation. ``$?'' tests for the existence of the variable .Aq Va expr , and returns 1 if it exists or 0 otherwise. .It Xo .Ao Va expr Ac Ns Pq Aq Ar arglist .Xc Function call. .Aq Va Expr must be a string that is the unique prefix of the name of a builtin .Nm function or the full name of a user defined alias macro. In the case of a builtin function, .Aq Ar arglist can be in one of two forms: .Bd -literal -offset indent , , ... argname1 = , argname2 = , ... .Ed .Pp The two forms can in fact be intermixed, but the result is unpredictable. Most arguments can be omitted; default values will be supplied for them. The .Ar argnames can be unique prefixes of the argument names. The commas separating arguments are used only to disambiguate, and can usually be omitted. .Pp Only the first argument form is valid for user defined aliases. Aliases are defined using the .Ic alias builtin function (see below). Arguments are accessed via a variant of the variable mechanism (see ``$'' operator above). .Pp Most functions return value, but some are used for side effect only and so must be used as statements. When a function or an alias is used as a statement, the parentheses surrounding the argument list may be omitted. Aliases return no value. .El .Ss Builtin Functions The arguments are listed by name in their natural order. Optional arguments are in square brackets .Sq Op . Arguments that have no names are in angle brackets .Sq <> . An argument meant to be a boolean flag (often named .Ar flag ) can be one of .Ar on , .Ar off , .Ar yes , .Ar no , .Ar true , or .Ar false , with obvious meanings, or it can be a numeric expression, in which case a non-zero value is true. .Bl -tag -width Fl .It Xo .Ic alias Ns Po Bq Aq Ar string , .Bq Aq Ar string\-list Pc .Xc If no argument is given, all currently defined alias macros are listed. Otherwise, .Aq Ar string is defined as an alias, with expansion .Aq Ar string\-list > . The previous definition of .Aq Ar string , if any, is returned. Default for .Aq Ar string\-list is no change. .It Ic close Ns Pq Aq Ar window\-list Close the windows specified in .Aq Ar window\-list . If .Aq Ar window\-list is the word .Ar all , than all windows are closed. No value is returned. .It Ic cursormodes Ns Pq Bq Ar modes Set the window cursor to .Ar modes . .Ar Modes is the bitwise or of the mode bits defined as the variables .Ar m_ul (underline), .Ar m_rev (reverse video), .Ar m_blk (blinking), and .Ar m_grp (graphics, terminal dependent). Return value is the previous modes. Default is no change. For example, .Li cursor($m_rev$m_blk) sets the window cursors to blinking reverse video. .It Ic default_nline Ns Pq Bq Ar nline Set the default buffer size to .Ar nline . Initially, it is 48 lines. Returns the old default buffer size. Default is no change. Using a very large buffer can slow the program down considerably. .It Ic default_shell Ns Pq Bq Aq Ar string\-list Set the default window shell program to .Aq Ar string\-list . Returns the first string in the old shell setting. Default is no change. Initially, the default shell is taken from the environment variable .Ev SHELL . .It Ic default_smooth Ns Pq Bq Ar flag Set the default value of the .Ar smooth argument to the command .Nm (see below). The argument is a boolean flag (one of .Ar on , .Ar off , .Ar yes , .Ar no , .Ar true , .Ar false , or a number, as described above). Default is no change. The old value (as a number) is returned. The initial value is 1 (true). .It Xo .Ic echo Ns ( Op Ar window , .Bq Aq Ar string\-list ) .Xc Write the list of strings, .Aq Ar string-list , to .Nm , separated by spaces and terminated with a new line. The strings are only displayed in the window, the processes in the window are not involved (see .Ic write below). No value is returned. Default is the current window. .It Ic escape Ns Pq Bq Ar escapec Set the escape character to .Ar escape-char . Returns the old escape character as a one-character string. Default is no change. .Ar Escapec can be a string of a single character, or in the form .Fl ^X , meaning .No control\- Ns Ar X . .It Xo .Ic foreground Ns ( Bq Ar window , .Bq Ar flag ) .Xc Move .Nm in or out of foreground. .Ar Flag is a boolean value. The old foreground flag is returned. Default for .Nm is the current window, default for .Ar flag is no change. .It Xo .Ic label Ns ( Bq Ar window , .Bq Ar label ) .Xc Set the label of .Nm to .Ar label . Returns the old label as a string. Default for .Nm is the current window, default for .Ar label is no change. To turn off a label, set it to an empty string (""). .It Ic list Ns Pq No arguments. List the identifiers and labels of all windows. No value is returned. .It Ic select Ns Pq Bq Ar window Make .Nm the current window. The previous current window is returned. Default is no change. .It Ic source Ns Pq Ar filename Read and execute the long commands in .Ar filename . Returns \-1 if the file cannot be read, 0 otherwise. .It Ic terse Ns Pq Bq flag Set terse mode to .Ar flag . In terse mode, the command window stays hidden even in command mode, and errors are reported by sounding the terminal's bell. .Ar Flag can take on the same values as in .Ar foreground above. Returns the old terse flag. Default is no change. .It Ic unalias Ns Pq Ar alias Undefine .Ar alias . Returns -1 if .Ar alias does not exist, 0 otherwise. .It Ic unset Ns Pq Ar variable Undefine .Ar variable . Returns -1 if .Ar variable does not exist, 0 otherwise. .It Ic variables Ns Pq No arguments. List all variables. No value is returned. .It Xo .Ic window Ns ( Bq Ar row , .Bq Ar column , .Bq Ar nrow , .Bq Ar ncol , .Bq Ar nline , .Bq Ar label , .Bq Ar pty , .Bq Ar frame , .Bq Ar mapnl , .Bq Ar keepopen , .Bq Ar smooth , .Bq Ar shell ) . .Xc Open a window with upper left corner at .Ar row , .Ar column and size .Ar nrow , .Ar ncol . If .Ar nline is specified, then that many lines are allocated for the text buffer. Otherwise, the default buffer size is used. Default values for .Ar row , .Ar column , .Ar nrow , and .Ar ncol are, respectively, the upper, left-most, lower, or right-most extremes of the screen. .Ar Label is the label string. .Ar Frame , .Ar pty , and .Ar mapnl are flag values interpreted in the same way as the argument to .Ar foreground (see above); they mean, respectively, put a frame around this window (default true), allocate pseudo-terminal for this window rather than socketpair (default true), and map new line characters in this window to carriage return and line feed (default true if socketpair is used, false otherwise). Normally, a window is automatically closed when its process exits. Setting .Ar keepopen to true (default false) prevents this action. When .Ar smooth is true, the screen is updated more frequently (for this window) to produce a more terminal-like behavior. The default value of .Ar smooth is set by the .Ar default_smooth command (see above). .Ar Shell is a list of strings that will be used as the shell program to place in the window (default is the program specified by .Ar default_shell , see above). The created window's identifier is returned as a number. .It Xo .Ic write Ns ( Bq Ar window , .Bq Aq Ar string\-list ) .Xc Send the list of strings, .Aq Ar string-list , to .Nm , separated by spaces but not terminated with a new line. The strings are actually given to the window as input. No value is returned. Default is the current window. .El .Ss Predefined Variables These variables are for information only. Redefining them does not affect the internal operation of .Nm . .Bl -tag -width modes .It Ar baud The baud rate as a number between 50 and 38400. .It Ar modes The display modes (reverse video, underline, blinking, graphics) supported by the physical terminal. The value of .Ar modes is the bitwise or of some of the one bit values, .Ar m_blk , .Ar m_grp , .Ar m_rev , and .Ar m_ul (see below). These values are useful in setting the window cursors' modes (see .Ar cursormodes above). .It Ar m_blk The blinking mode bit. .It Ar m_grp The graphics mode bit (not very useful). .It Ar m_rev The reverse video mode bit. .It Ar m_ul The underline mode bit. .It Ar ncol The number of columns on the physical screen. .It Ar nrow The number of rows on the physical screen. .It Ar term The terminal type. The standard name, found in the second name field of the terminal's .Ev TERMCAP entry, is used. .El .Sh ENVIRONMENT .Nm Window utilizes these environment variables: .Ev HOME , .Ev SHELL , .Ev TERM , .Ev TERMCAP , .Ev WINDOW_ID . .Sh FILES .Bl -tag -width /dev/[pt]ty[pq]? -compact .It Pa ~/.windowrc startup command file. .It Pa /dev/[pt]ty[pq]? pseudo-terminal devices. .El .Sh HISTORY The .Nm command appeared in .Bx 4.3 . .Sh DIAGNOSTICS Should be self explanatory. Index: head/usr.bin/xstr/xstr.1 =================================================================== --- head/usr.bin/xstr/xstr.1 (revision 79534) +++ head/usr.bin/xstr/xstr.1 (revision 79535) @@ -1,163 +1,163 @@ .\" Copyright (c) 1980, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)xstr.1 8.2 (Berkeley) 12/30/93 .\" $FreeBSD$ .\" .Dd December 30, 1993 .Dt XSTR 1 -.Os BSD 3 +.Os .Sh NAME .Nm xstr .Nd "extract strings from C programs to implement shared strings" .Sh SYNOPSIS .Nm .Op Fl c .Op Fl .Op Fl v .Op Ar file .Sh DESCRIPTION .Nm Xstr maintains a file .Pa strings into which strings in component parts of a large program are hashed. These strings are replaced with references to this common area. This serves to implement shared constant strings, most useful if they are also read-only. .Pp Available options: .Bl -tag -width Ds .It Fl .Nm Xstr reads from the standard input. .It Fl c .Nm Xstr will extract the strings from the C source .Ar file or the standard input .Pq Fl , replacing string references by expressions of the form (&xstr[number]) for some number. An appropriate declaration of .Nm is prepended to the file. The resulting C text is placed in the file .Pa x.c , to then be compiled. The strings from this file are placed in the .Pa strings data base if they are not there already. Repeated strings and strings which are suffixes of existing strings do not cause changes to the data base. .It Fl v Verbose mode. .El .Pp After all components of a large program have been compiled a file .Pa xs.c declaring the common .Nm space can be created by a command of the form .Bd -literal -offset indent xstr .Ed .Pp The file .Pa xs.c should then be compiled and loaded with the rest of the program. If possible, the array can be made read-only (shared) saving space and swap overhead. .Pp .Nm Xstr can also be used on a single file. A command .Bd -literal -offset indent xstr name .Ed .Pp creates files .Pa x.c and .Pa xs.c as before, without using or affecting any .Pa strings file in the same directory. .Pp It may be useful to run .Nm after the C preprocessor if any macro definitions yield strings or if there is conditional code which contains strings which may not, in fact, be needed. An appropriate command sequence for running .Nm after the C preprocessor is: .Pp .Bd -literal -offset indent -compact cc \-E name.c | xstr \-c \- cc \-c x.c mv x.o name.o .Ed .Pp .Nm Xstr does not touch the file .Pa strings unless new items are added, thus .Xr make 1 can avoid remaking .Pa xs.o unless truly necessary. .Sh FILES .Bl -tag -width /tmp/xsxx* -compact .It Pa strings Data base of strings .It Pa x.c Massaged C source .It Pa xs.c C source for definition of array `xstr' .It Pa /tmp/xs* Temp file when `xstr name' doesn't touch .Pa strings .El .Sh SEE ALSO .Xr mkstr 1 .Sh BUGS If a string is a suffix of another string in the data base, but the shorter string is seen first by .Nm both strings will be placed in the data base, when just placing the longer one there will do. .Sh HISTORY The .Nm command appeared in .Bx 3.0 . Index: head/usr.bin/yacc/yyfix.1 =================================================================== --- head/usr.bin/yacc/yyfix.1 (revision 79534) +++ head/usr.bin/yacc/yyfix.1 (revision 79535) @@ -1,114 +1,114 @@ .\" Copyright (c) 1990, 1991 The Regents of the University of California. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)yyfix.1 5.4 (Berkeley) 3/23/93 .\" $FreeBSD$ .\" .Dd March 23, 1993 .Dt YYFIX 1 -.Os BSD 4.4 +.Os .Sh NAME .Nm yyfix .Nd extract tables from y.tab.c .Sh SYNOPSIS .Nm .Ar file .Op Ar tables .Sh DESCRIPTION Programs have historically used a script (often named .Dq :yyfix ) to extract tables from the .Xr yacc 1 generated file .Pa y.tab.c . As the names of the tables generated by the current version of .Xr yacc are different from those of historical versions of .Xr yacc , the shell script .Nm is provided to simplify the transition. .Pp The first (and required) argument to .Nm is the name of the file where the extracted tables should be stored. .Pp If further command line arguments are specified, they are taken as the list of tables to be extracted. Otherwise, .Nm attempts to determine if the .Pa y.tab.c file is from an old or new .Xr yacc , and extracts the appropriate tables. .Pp The tables .Dq yyexca , .Dq yyact , .Dq yypact , .Dq yypgo , .Dq yyr1 , .Dq yyr2 , .Dq yychk , and .Dq yydef are extracted from historical versions of .Xr yacc . .Pp The tables .Dq yylhs , .Dq yylen , .Dq yydefred , .Dq yydgoto , .Dq yysindex , .Dq yyrindex , .Dq yygindex , .Dq yytable , .Dq yyname , .Dq yyrule , and .Dq yycheck , are extracted from the current version of .Xr yacc . .Sh FILES .Bl -tag -width y.tab.c .It Pa y.tab.c File from which tables are extracted. .El .Sh SEE ALSO .Xr yacc 1 .Sh HISTORY The .Nm command appeared in .Bx 4.4 . Index: head/usr.bin/yes/yes.1 =================================================================== --- head/usr.bin/yes/yes.1 (revision 79534) +++ head/usr.bin/yes/yes.1 (revision 79535) @@ -1,55 +1,55 @@ .\" Copyright (c) 1980, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)yes.1 8.1 (Berkeley) 6/6/93 .\" $FreeBSD$ .\" .Dd June 6, 1993 .Dt YES 1 -.Os BSD 4 +.Os .Sh NAME .Nm yes .Nd be repetitively affirmative .Sh SYNOPSIS .Nm .Op Ar expletive .Sh DESCRIPTION .Nm Yes outputs .Ar expletive , or, by default, .Dq y , forever. .Sh HISTORY The .Nm command appeared in .At 32v .