Index: head/lib/libc/stdio/funopen.3 =================================================================== --- head/lib/libc/stdio/funopen.3 (revision 13510) +++ head/lib/libc/stdio/funopen.3 (revision 13511) @@ -1,168 +1,168 @@ .\" Copyright (c) 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Chris Torek. .\" 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. .\" .\" @(#)funopen.3 8.1 (Berkeley) 6/9/93 .\" .Dd June 9, 1993 .Dt FUNOPEN 3 .Os .Sh NAME .Nm funopen , .Nm fropen , .Nm fwopen .Nd open a stream .Sh SYNOPSIS .Fd #include .Ft FILE * -.Fn funopen "void *cookie" "int (*readfn)(void *, char *, int)" "int (writefn*)(void *, const char *, int)" "fpos_t (seekfn*)(void *, fpos_t, int)" "int (closefn*)(void *)" +.Fn funopen "void *cookie" "int (*readfn)(void *, char *, int)" "int (*writefn)(void *, const char *, int)" "fpos_t (*seekfn)(void *, fpos_t, int)" "int (*closefn)(void *)" .Ft FILE * .Fn fropen "void *cookie" "int (*readfn)(void *, char *, int)" .Ft FILE * .Fn fwopen "void *cookie" "int (*writefn)(void *, char *, int)" .Sh DESCRIPTION The .Fn funopen function associates a stream with up to four .Dq Tn I/O No functions . Either .Fa readfn or .Fa writefn must be specified; the others can be given as an appropriately-typed .Dv NULL pointer. These .Tn I/O functions will be used to read, write, seek and close the new stream. .Pp In general, omitting a function means that any attempt to perform the associated operation on the resulting stream will fail. If the close function is omitted, closing the stream will flush any buffered output and then succeed. .Pp The calling conventions of .Fa readfn , .Fa writefn , .Fa seekfn and .Fa closefn must match those, respectively, of .Xr read 2 , .Xr write 2 , .Xr seek 2 , and .Xr close 2 with the single exception that they are passed the .Fa cookie argument specified to .Fn funopen in place of the traditional file descriptor argument. .Pp Read and write .Tn I/O functions are allowed to change the underlying buffer on fully buffered or line buffered streams by calling .Xr setvbuf 3 . They are also not required to completely fill or empty the buffer. They are not, however, allowed to change streams from unbuffered to buffered or to change the state of the line buffering flag. They must also be prepared to have read or write calls occur on buffers other than the one most recently specified. .Pp All user .Tn I/O functions can report an error by returning \-1. Additionally, all of the functions should set the external variable .Va errno appropriately if an error occurs. .Pp An error on .Fn closefn does not keep the stream open. .Pp As a convenience, the include file .Aq Pa stdio.h defines the macros .Fn fropen and .Fn fwopen as calls to .Fn funopen with only a read or write function specified. .Sh RETURN VALUES Upon successful completion, .Fn funopen returns a .Dv FILE pointer. Otherwise, .Dv NULL is returned and the global variable .Va errno is set to indicate the error. .Sh ERRORS .Bl -tag -width [EINVAL] .It Bq Er EINVAL The .Fn funopen function was called without either a read or write function. The .Fn funopen function may also fail and set .Va errno for any of the errors specified for the routine .Xr malloc 3 . .El .Sh SEE ALSO .Xr fcntl 2 , .Xr open 2 , .Xr fclose 3 , .Xr fopen 3 , .Xr fseek 3 , .Xr setbuf 3 .Sh HISTORY The .Fn funopen functions first appeared in 4.4BSD. .Sh BUGS The .Fn funopen function may not be portable to systems other than .Bx . Index: head/share/man/man5/link.5 =================================================================== --- head/share/man/man5/link.5 (revision 13510) +++ head/share/man/man5/link.5 (revision 13511) @@ -1,561 +1,561 @@ .\" Copyright (c) 1993 Paul Kranenburg .\" 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 Paul Kranenburg. .\" 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. .\" -.\" $Id: link.5,v 1.1 1994/12/23 22:41:46 nate Exp $ +.\" $Id: link.5,v 1.2 1995/04/16 12:35:13 ats Exp $ .\" .Dd October 23, 1993 .Dt LINK 5 .Os .Sh NAME .Nm link .Nd dynamic loader and link editor interface .Sh SYNOPSIS .Fd #include .Sh DESCRIPTION The include file .Aq Pa link.h declares several structures that are present in dynamically linked programs and libraries. The structures define the interface between several components of the link-editor and loader mechanism. The layout of a number of these structures within the binaries resembles the a.out format in many places as it serves such similar functions as symbol definitions (including the accompanying string table) and relocation records needed to resolve references to external entities. It also records a number of data structures unique to the dynamic loading and linking process. These include references to other objects that are required to complete the link-editing process and indirection tables to facilitate .Em Position Independent Code (PIC for short) to improve sharing of code pages among different processes. The collection of data structures described here will be refered to as the .Em Run-time Relocation Section (RRS) and is embedded in the standard text and data segments of the dynamically linked program or shared object image as the existing .Xr a.out format offers no room for it elsewhere. .Pp Several utilities cooperate to ensure that the task of getting a program ready to run can complete successfully in a way that optimizes the use of system resources. The compiler emits PIC code from which shared libraries -can be build by -.Xr ld 1. +can be built by +.Xr ld 1 . The compiler also includes size information of any initialized data items through the .size assembler directive. PIC code differs from conventional code in that it accesses data variables through an indirection table, the Global Offset Table, by convention accessable by the reserved name .Em _GLOBAL_OFFSET_TABLE_. The exact mechanism used for this is machine dependent, usually a machine register is reserved for the purpose. The rational behind this construct is to generate code that is independent of the actual load address. Only the values contained in the Global Offset Table may need updating at run-time depending on the load addresses of the various shared objects in the address space. .Pp Likewise, procedure calls to globally defined functions are redirected through the Procedure Linkage Table (PLT) residing in the data segment of the core image. Again, this is done to avoid run-time modifications to the text segment. .Pp The linker-editor allocates the Global Offset Table and Procedure Linkage Table when combining PIC object files into an image suitable for mapping into the process address space. It also collects all symbols that may be needed by the run-time link-editor and stores these along with the image's text and data bits. Another reserved symbol, .Em _DYNAMIC is used to indicate the presence of the run-time linker structures. Whenever _DYNAMIC is relocated to 0, there is no need to invoke the run-time link-editor. If this symbol is non-zero, it points at a data structure from which the location of the necessary relocation- and symbol information can be derived. This is most notably used by the start-up module, .Em crt0. The _DYNAMIC structure is conventionally located at the start of the data segment of the image to which it pertains. .Pp .Sh DATA STRUCTURES The data structures supporting dynamic linking and run-time relocation reside both in the text and data segments of the image they apply to. The text segments contain read-only data such as symbols descriptions and names, while the data segments contain the tables that need to be modified by during the relocation process. .Pp The _DYNAMIC symbol references a .Fa _dynamic structure: .Bd -literal -offset indent struct _dynamic { int d_version; struct so_debug *d_debug; union { struct section_dispatch_table *d_sdt; } d_un; struct ld_entry *d_entry; }; .Ed .Bl -tag -width d_version .It Fa d_version This field provides for different versions of the dynamic linking implementation. The current version numbers understood by ld and ld.so are .Em LD_VERSION_SUN (3), which is used by the SunOS 4.x releases, and .Em LD_VERSION_BSD (8), which is currently in use by FreeBSD since release 1.1. .It Fa d_un Refers to a .Em d_version dependent data structure. .It Fa so_debug this field provides debuggers with a hook to access symbol tables of shared objects loaded as a result of the actions of the run-time link-editor. .El .Pp The .Fa section_dispatch_table structure is the main .Dq dispatcher table, containing offsets into the image's segments where various symbol and relocation information is located. .Bd -literal -offset indent struct section_dispatch_table { struct so_map *sdt_loaded; long sdt_sods; long sdt_filler1; long sdt_got; long sdt_plt; long sdt_rel; long sdt_hash; long sdt_nzlist; long sdt_filler2; long sdt_buckets; long sdt_strings; long sdt_str_sz; long sdt_text_sz; long sdt_plt_sz; }; .Ed .Pp .Bl -tag -width sdt_filler1 .It Fa sdt_loaded A pointer to the first link map loaded (see below). This field is set by .Xr ld.so. .It Fa sdt_sods The start of a (linked) list of shared object descriptors needed by .Em this object. .It Fa sdt_filler1 Depricated (used by SunOS to specify library search rules). .It Fa sdt_got The location of the Global Offset Table within this image. .It Fa sdt_plt The location of the Procedure Linkage Table within this image. .It Fa sdt_rel The location of an array of .Fa relocation_info structures .Po see .Xr a.out 5 .Pc specifying run-time relocations. .It Fa sdt_hash The location of the hash table for fast symbol lookup in this object's symbol table. .It Fa sdt_nzlist The location of the symbol table. .It Fa sdt_filler2 Currently unused. .It Fa sdt_buckets The number of buckets in .Fa sdt_hash .It Fa sdt_strings The location of the symbol string table that goes with .Fa sdt_nzlist. .It Fa sdt_str_sz The size of the string table. .It Fa sdt_text_sz The size of the object's text segment. .It Fa sdt_plt_sz The size of the Procedure Linkage Table. .El .Pp A .Fa sod structure descibes a shared object that is needed to complete the link edit process of the object containing it. A list of such objects .Po chained through .Fa sod_next .Pc is pointed at by the .Fa sdt_sods in the section_dispatch_table structure. .Bd -literal -offset indent struct sod { long sod_name; u_int sod_library : 1, sod_reserved : 31; short sod_major; short sod_minor; long sod_next; }; .Ed .Pp .Bl -tag -width sod_library .It Fa sod_name The offset in the text segment of a string describing this link object. .It Fa sod_library If set, .Fa sod_name specifies a library that is to be searched for by ld.so. The path name is obtained by searching a set of directories .Po see also .Xr ldconfig 8 .Pc for a shared object matching .Em lib\&\&.so.n.m. If not set, .Fa sod_name should point at a full path name for the desired shared object. .It Fa sod_major Specifies the major version number of the shared object to load. .It Fa sod_minor Specifies the prefered minor version number of the shared object to load. .El .Pp The run-time link-editor maintains a list of structures called .Em link maps to keep track of all shared objects loaded into a process' address space. These structures are only used at run-time and do not occur within the text or data segment of an executable or shared library. .Bd -literal -offset indent struct so_map { caddr_t som_addr; char *som_path; struct so_map *som_next; struct sod *som_sod; caddr_t som_sodbase; u_int som_write : 1; struct _dynamic *som_dynamic; caddr_t som_spd; }; .Ed .Bl -tag -width som_dynamic .It Fa som_addr The address at which the shared object associated with this link map has been loaded. .It Fa som_path The full path name of the loaded object. .It Fa som_next Pointer to the next link map. .It Fa som_sod The .Fa sod structure that was responsible for loading this shared object. .It Fa som_sodbase Tossed in later versions the run-time linker. .It Fa som_write Set if (some portion of) this object's text segment is currently writable. .It Fa som_dynamic Pointer to this object's .Fa _dynamic structure. .It Fa som_spd Hook for attaching private data maintained by the run-time link-editor. .El .Pp Symbol description with size. This is simply an .Fa nlist structure with one field .Pq Fa nz_size added. Used to convey size information on items in the data segment of shared objects. An array of these lives in the shared object's text segment and is addressed by the .Fa sdt_nzlist field of .Fa section_dispatch_table. .Bd -literal -offset indent struct nzlist { struct nlist nlist; u_long nz_size; #define nz_un nlist.n_un #define nz_strx nlist.n_un.n_strx #define nz_name nlist.n_un.n_name #define nz_type nlist.n_type #define nz_value nlist.n_value #define nz_desc nlist.n_desc #define nz_other nlist.n_other }; .Ed .Bl -tag -width nz_size .It Fa nlist .Po see .Xr nlist 5 .Pc . .It Fa nz_size The size of the data represented by this symbol. .El .Pp A hash table is included within the text segment of shared object to to facilitate quick lookup of symbols during run-time link-editing. The .Fa sdt_hash field of the .Fa section_dispatch_table structure points at an array of .Fa rrs_hash structures: .Bd -literal -offset indent struct rrs_hash { int rh_symbolnum; /* symbol number */ int rh_next; /* next hash entry */ }; .Ed .Pp .Bl -tag -width rh_symbolnum .It Fa rh_symbolnum The index of the symbol in the shared object's symbol table (as given by the .Fa ld_symbols field). .It Fa rh_next In case of collisions, this field is the offset of the next entry in this hash table bucket. It is zero for the last bucket element. .El The .Fa rt_symbol structure is used to keep track of run-time allocated commons and data items copied from shared objects. These items are kept on linked list and is exported through the .Fa dd_cc field in the .Fa so_debug structure (see below) for use by debuggers. .Bd -literal -offset indent struct rt_symbol { struct nzlist *rt_sp; struct rt_symbol *rt_next; struct rt_symbol *rt_link; caddr_t rt_srcaddr; struct so_map *rt_smp; }; .Ed .Pp .Bl -tag -width rt_scraddr .It Fa rt_sp The symbol description. .It Fa rt_next Virtual address of next rt_symbol. .It Fa rt_link Next in hash bucket. Used by internally by ld.so. .It Fa rt_srcaddr Location of the source of initialized data within a shared object. .It Fa rt_smp The shared object which is the original source of the data that this run-time symbol describes. .El .Pp The .Fa so_debug structure is used by debuggers to gain knowledge of any shared objects that have been loaded in the process's address space as a result of run-time link-editing. Since the run-time link-editor runs as a part of process initialization, a debugger that wishes to access symbols from shared objects can only do so after the link-editor has been called from crt0. A dynamically linked binary contains a .Fa so_debug structure which can be located by means of the .Fa d_debug field in .Fa _dynamic. .Bd -literal -offset indent struct so_debug { int dd_version; int dd_in_debugger; int dd_sym_loaded; char *dd_bpt_addr; int dd_bpt_shadow; struct rt_symbol *dd_cc; }; .Ed .Pp .Bl -tag -width dd_in_debugger .It Fa dd_version Version number of this interface. .It Fa dd_in_debugger Set by the debugger to indicate to the run-time linker that the program is run under control of a debugger. .It Fa dd_sym_loaded Set by the run-time linker whenever it adds symbols by loading shared objects. .It Fa dd_bpt_addr The address were a breakpoint will be set by the the run-time linker to divert control to the debugger. This address is determined by the start-up module, .Em crt0.o, to be some convenient place before the call to _main.<.It Fa dd_bpt_shadow Contains the original instruction that was at .Fa dd_bpt_addr. The debugger is expected to put this instruction back before continuing the program. .It Fa dd_cc A pointer to the linked list of run-time allocated symbols that the debugger may be interested in. .El .Pp The .Em ld_entry structure defines a set of service routines within ld.so. See .Xr libdl.a for more information. .Bd -literal -offset indent struct ld_entry { void *(*dlopen)(char *, int); int (*dlclose)(void *); void *(*dlsym)(void *, char *); char *(*dlerror)(void); }; .Ed The .Fa crt_ldso structure defines the interface between the start-up code in crt0 and ld.so. .Bd -literal -offset indent struct crt_ldso { int crt_ba; int crt_dzfd; int crt_ldfd; struct _dynamic *crt_dp; char **crt_ep; caddr_t crt_bp; char *crt_prog; char *crt_ldso; struct ld_entry *crt_ldentry; }; #define CRT_VERSION_SUN 1 #define CRT_VERSION_BSD_2 2 #define CRT_VERSION_BSD_3 3 #define CRT_VERSION_BSD_4 4 .Ed .Bl -tag -width crt_dzfd .It Fa crt_ba The virtual address at which ld.so was loaded by crt0. .It Fa crt_dzfd On SunOS systems, this field contains an open file descriptor to .Dq /dev/zero used to get demand paged zeroed pages. On FreeBSD systems it contains -1. .It Fa crt_ldfd Contains an open file descriptor that was used by crt0 to load ld.so. .It Fa crt_dp A pointer to main's .Fa _dynamic structure. .It Fa crt_ep A pointer to the environment strings. .It Fa crt_bp The address at which a breakpoint will be placed by the run-time linker if the main program is run by a debugger. See .Fa so_debug .It Fa crt_prog The name of the main program as determined by crt0 (CRT_VERSION_BSD3 only). .It Fa crt_ldso The path of the run-time linker as mapped by crt0 (CRT_VERSION_BSD4 only). .El .Pp The .Fa hints_header and .Fa hints_bucket structures define the layout of the library hints, normally found in .Dq /var/run/ld.so.hints, which is used by ld.so to quickly locate the shared object images in the filesystem. The organization of the hints file is not unlike that of an .Dq a.out object file, in that it contains a header determining the offset and size of a table of fixed sized hash buckets and a common string pool. .Bd -literal -offset indent struct hints_header { long hh_magic; #define HH_MAGIC 011421044151 long hh_version; #define LD_HINTS_VERSION_1 1 long hh_hashtab; long hh_nbucket; long hh_strtab; long hh_strtab_sz; long hh_ehints; }; .Ed .Bl -tag -width hh_strtab_sz .It Fa hh_magic Hints file magic number. .It Fa hh_version Interface version number. .It Fa hh_hashtab Offset of hash table. .It Fa hh_strtab Offset of string table. .It Fa hh_strtab_sz Size of strings. .It Fa hh_ehints Maximum usable offset in hints file. .El .Pp .Bd -literal -offset indent /* * Hash table element in hints file. */ struct hints_bucket { int hi_namex; int hi_pathx; int hi_dewey[MAXDEWEY]; int hi_ndewey; #define hi_major hi_dewey[0] #define hi_minor hi_dewey[1] int hi_next; }; .Ed .Bl -tag -width hi_ndewey .It Fa hi_namex Index of the string identifying the library. .It Fa hi_pathx Index of the string representing the full path name of the library. .It Fa hi_dewey The version numbers of the shared library. .It Fa hi_ndewey The number of valid entries in .Fa hi_dewey. .It Fa hi_next Next bucket in case of hashing collisions. .El .Sh CAVEATS Only the (GNU) C compiler currently supports the creation of shared libraries. Other programming languages can not be used. Index: head/usr.bin/fstat/fstat.1 =================================================================== --- head/usr.bin/fstat/fstat.1 (revision 13510) +++ head/usr.bin/fstat/fstat.1 (revision 13511) @@ -1,219 +1,219 @@ .\" 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 .\" .Dd February 25, 1994 .Dt FSTAT 1 .Os BSD 4 .Sh NAME .Nm fstat .Nd file status .Sh SYNOPSIS .Nm fstat .Op Fl fnv .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 pure text, or kernel trace file for that process. If no options are specified, .Nm fstat 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 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 fstat is running. This is normal and unavoidable since the rest of the system is running while .Nm fstat 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 -ragged -offset indent -compact text - pure text inode wd - current working directory root - root inode tr - kernel trace 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 2 ) , 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 fstat 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 systat 1 , -.Xr vmstat 1 , .Xr iostat 8 , -.Xr pstat 8 +.Xr pstat 8 , +.Xr vmstat 8 .Sh HISTORY The .Nm command appeared in .Bx 4.3 tahoe . Index: head/usr.bin/indent/indent.1 =================================================================== --- head/usr.bin/indent/indent.1 (revision 13510) +++ head/usr.bin/indent/indent.1 (revision 13511) @@ -1,452 +1,452 @@ .\" 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 .\" .Dd July 1, 1993 .Dt INDENT 1 .Os BSD 4.2 .Sh NAME .Nm indent .Nd indent and format C program source .Sh SYNOPSIS .Nm indent .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 .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 indent checks to make sure it is different from .Ar input-file . .Pp The options listed below control the formatting style imposed by .Nm indent . .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. The default is .Fl \&bc . .It Fl \&br , \&bl Specifying .Fl \&bl lines up compound statements like this: .ne 4 .Bd -literal -offset indent if (...) { code } .Ed .Pp Specifying .Fl \&br (the default) makes them look like this: .ne 3 .Bd -literal -offset indent if (...) { code } .Ed .Pp .It Fl c n The column in which comments on code start. The default is 33. .It Fl cd 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 .ne 3 /* - * this is a comment - */ + * 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 `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. The default .Fl \&d\&1 means that such comments are placed one indentation level to the left of code. Specifying .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. .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 i Ns Ar n The number of spaces for one indentation level. The default is 4. .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 75. .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: .ne 2 .Bd -literal -offset indent p1 = first_procedure(second_procedure(p2, p3), \ \ third_procedure(p4,p5)); .Ed .Pp .ne 5 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 .ne 5 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. .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 indent 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 indent can't find all instances of .Ic typedef . .It Fl troff Causes .Nm indent 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 indent 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 indent 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 indent 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 indent 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 indent 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 indent command appeared in .Bx 4.2 . .Sh BUGS .Nm Indent has even more switches than .Xr ls 1 . .Pp .ne 5 A common mistake that often causes grief is typing: .Pp .Dl indent *.c .Pp to the shell in an attempt to indent all the .Nm C programs in a directory. This is probably a bug, not a feature. Index: head/usr.bin/netstat/netstat.1 =================================================================== --- head/usr.bin/netstat/netstat.1 (revision 13510) +++ head/usr.bin/netstat/netstat.1 (revision 13511) @@ -1,297 +1,297 @@ .\" 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. .\" .\" @(#)netstat.1 8.8 (Berkeley) 4/18/94 .\" .Dd April 18, 1994 .Dt NETSTAT 1 .Os BSD 4.2 .Sh NAME .Nm netstat .Nd show network status .Sh SYNOPSIS .Nm netstat .Op Fl Aan .Op Fl f Ar address_family .Op Fl M Ar core .Op Fl N Ar system .Nm netstat .Op Fl bdghimnrs .Op Fl f Ar address_family .Op Fl M Ar core .Op Fl N Ar system .Nm netstat .Op Fl bdn .Op Fl I Ar interface .Op Fl M Ar core .Op Fl N Ar system .Op Fl w Ar wait .Nm netstat .Op Fl p Ar protocol .Op Fl M Ar core .Op Fl N Ar system .Sh DESCRIPTION The .Nm netstat command symbolically displays the contents of various network-related data structures. There are a number of output formats, depending on the options for the information presented. The first form of the command displays a list of active sockets for each protocol. The second form presents the contents of one of the other network data structures according to the option selected. Using the third form, with a .Ar wait interval specified, .Nm netstat will continuously display the information regarding packet traffic on the configured network interfaces. The fourth form displays statistics about the named protocol. .Pp The options have the following meaning: .Bl -tag -width flag .It Fl A With the default display, show the address of any protocol control blocks associated with sockets; used for debugging. .It Fl a With the default display, show the state of all sockets; normally sockets used by server processes are not shown. .It Fl b With either interface display (option .Fl i or an interval, as described below), show the number of bytes in and out. .It Fl d With either interface display (option .Fl i or an interval, as described below), show the number of dropped packets. .It Fl f Ar address_family Limit statistics or address control block reports to those of the specified .Ar address family . The following address families are recognized: .Ar inet , for .Dv AF_INET , .Ar ns , for .Dv AF_NS , .Ar iso , for .Dv AF_ISO , and .Ar unix , for .Dv AF_UNIX . .It Fl g Show information related to multicast (group address) routing. By default, show the IP Multicast virtual-interface and routing tables. If the .Fl s option is also present, show multicast routing statistics. .It Fl h Show the state of the .Tn IMP host table (obsolete). .It Fl I Ar interface Show information about the specified interface; used with a .Ar wait interval as described below. .It Fl i Show the state of interfaces which have been auto-configured (interfaces statically configured into a system, but not located at boot time are not shown). If the .Fl a options is also present, multicast addresses currently in use are shown for each Ethernet interface and for each IP interface address. Multicast addresses are shown on separate lines following the interface address with which they are associated. .It Fl M Extract values associated with the name list from the specified core instead of the default .Pa /dev/kmem . .It Fl m Show statistics recorded by the memory management routines (the network manages a private pool of memory buffers). .It Fl N Extract the name list from the specified system instead of the default .Pa /kernel . .It Fl n Show network addresses as numbers (normally .Nm netstat interprets addresses and attempts to display them symbolically). This option may be used with any of the display formats. .It Fl p Ar protocol Show statistics about .Ar protocol , which is either a well-known name for a protocol or an alias for it. Some protocol names and aliases are listed in the file .Pa /etc/protocols . A null response typically means that there are no interesting numbers to report. The program will complain if .Ar protocol is unknown or if there is no statistics routine for it. .It Fl s Show per-protocol statistics. If this option is repeated, counters with a value of zero are suppressed. .It Fl r Show the routing tables. When .Fl s is also present, show routing statistics instead. .It Fl w Ar wait Show network interface statistics at intervals of .Ar wait seconds. .El .Pp The default display, for active sockets, shows the local and remote addresses, send and receive queue sizes (in bytes), protocol, and the internal state of the protocol. Address formats are of the form ``host.port'' or ``network.port'' if a socket's address specifies a network but no specific host address. When known the host and network addresses are displayed symbolically according to the data bases .Pa /etc/hosts and .Pa /etc/networks , respectively. If a symbolic name for an address is unknown, or if the .Fl n option is specified, the address is printed numerically, according to the address family. For more information regarding the Internet ``dot format,'' refer to .Xr inet 3 ) . Unspecified, or ``wildcard'', addresses and ports appear as ``*''. .Pp The interface display provides a table of cumulative statistics regarding packets transferred, errors, and collisions. The network addresses of the interface and the maximum transmission unit (``mtu'') are also displayed. .Pp The routing table display indicates the available routes and their status. Each route consists of a destination host or network and a gateway to use in forwarding packets. The flags field shows a collection of information about the route stored as binary choices. The individual flags are discussed in more detail in the .Xr route 8 and .Xr route 4 manual pages. The mapping between letters and flags is: .Bl -column XXXX RTF_BLACKHOLE 1 RTF_PROTO2 Protocol specific routing flag #1 2 RTF_PROTO1 Protocol specific routing flag #2 3 RTF_PROTO3 Protocol specific routing flag #3 B RTF_BLACKHOLE Just discard pkts (during updates) C RTF_CLONING Generate new routes on use c RTF_PRCLONING Protocol-specified generate new routes on use D RTF_DYNAMIC Created dynamically (by redirect) G RTF_GATEWAY Destination requires forwarding by intermediary H RTF_HOST Host entry (net otherwise) L RTF_LLINFO Valid protocol to link address translation M RTF_MODIFIED Modified dynamically (by redirect) R RTF_REJECT Host or net unreachable S RTF_STATIC Manually added U RTF_UP Route usable W RTF_WASCLONED Route was generated as a result of cloning X RTF_XRESOLVE External daemon translates proto to link address .El .Pp Direct routes are created for each interface attached to the local host; the gateway field for such entries shows the address of the outgoing interface. The refcnt field gives the current number of active uses of the route. Connection oriented protocols normally hold on to a single route for the duration of a connection while connectionless protocols obtain a route while sending to the same destination. The use field provides a count of the number of packets sent using that route. The interface entry indicates the network interface utilized for the route. .Pp When .Nm netstat is invoked with the .Fl w option and a .Ar wait interval argument, it displays a running count of statistics related to network interfaces. An obsolescent version of this option used a numeric parameter with no option, and is currently supported for backward compatibility. This display consists of a column for the primary interface (the first interface found during autoconfiguration) and a column summarizing information for all interfaces. The primary interface may be replaced with another interface with the .Fl I option. The first line of each screen of information contains a summary since the system was last rebooted. Subsequent lines of output show values accumulated over the preceding interval. .Sh SEE ALSO -.Xr iostat 1 , .Xr nfsstat 1 , .Xr ps 1 , -.Xr vmstat 1 , .Xr hosts 5 , .Xr networks 5 , .Xr protocols 5 , .Xr services 5 , +.Xr iostat 8 , .Xr trpt 8 , -.Xr trsp 8 +.Xr trsp 8 , +.Xr vmstat 8 .Sh HISTORY The .Nm netstat command appeared in .Bx 4.2 . .\" .Sh FILES .\" .Bl -tag -width /dev/kmem -compact .\" .It Pa /kernel .\" default kernel namelist .\" .It Pa /dev/kmem .\" default memory file .\" .El .Sh BUGS The notion of errors is ill-defined. Index: head/usr.bin/nfsstat/nfsstat.1 =================================================================== --- head/usr.bin/nfsstat/nfsstat.1 (revision 13510) +++ head/usr.bin/nfsstat/nfsstat.1 (revision 13511) @@ -1,90 +1,90 @@ .\" 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 -.\" $Id$ +.\" $Id: nfsstat.1,v 1.3 1994/10/23 23:25:42 wollman Exp $ .\" .Dd June 6, 1993 .Dt NFSSTAT 1 .Os BSD 4.4 .Sh NAME .Nm nfsstat .Nd display .Tn NFS statistics .Sh SYNOPSIS .Nm nfsstat .Op Fl M Ar core .Op Fl N Ar system .Op Fl w Ar wait .Sh DESCRIPTION .Nm Nfsstat displays statistics kept about .Tn NFS client and server activity. .Pp The options are as follows: .Bl -tag -width Ds .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 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 vmstat 1 , .Xr sysctl 3 , .Xr iostat 8 , .Xr pstat 8 , +.Xr vmstat 8 .Sh HISTORY The .Nm nfsstat command appears in .Bx 4.4 . Index: head/usr.bin/systat/systat.1 =================================================================== --- head/usr.bin/systat/systat.1 (revision 13510) +++ head/usr.bin/systat/systat.1 (revision 13511) @@ -1,424 +1,424 @@ .\" 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 .\" .Dd December 30, 1993 .Dt SYSTAT 1 .Os BSD 4.3 .Sh NAME .Nm systat .Nd display system statistics on a crt .Sh SYNOPSIS .Nm systat .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 curses 3 . .Pp While .Nm systat 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 systat 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 1 ) , +.Xr iostat 8 ) , virtual memory statistics (a la -.Xr vmstat 1 ) , +.Xr vmstat 8 ) , network ``mbuf'' utilization, 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 pigs , .Ic iostat , .Ic swap , .Ic mbufs , .Ic vmstat or .Ic netstat . 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 systat . 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 systat . .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 systat . (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 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, kilobytes of data transferred, number of disk transactions performed, and average seek time (in milliseconds). 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 msps Toggle the display of average seek time (the default is to not display seek times). .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 the disk usage display. It reports the number of seeks, transfers, and number of kilobyte blocks transferred per second averaged over the refresh period of the display (by default, five seconds). For some disks it also reports the average milliseconds per seek. Note that the system only keeps statistics on at most four disks. .Pp Below the disk 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'). Below the 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 At the bottom left 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 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 line listing the average number of total reclaims ('Rec'), intransit blocking page faults (`It'), swap text pages found in free list (`F/S'), file system text pages found in free list (`F/F'), reclaims from free list pages freed by the clock daemon (`Fre'), and sequential process pages freed (`SFr') per second over the refresh interval. .Pp Below this line are statistics on the average number of zero filled pages (`zf') and demand filled text pages (`xf') per second over the refresh period. The first row indicates the number of requests that were resolved, the second row shows the number that were set up, and the last row shows the percentage of setup requests that were actually used. Note that this percentage is usually less than 100%, however it may exceed 100% if a large number of requests are actually used long after they were set up during a period when no new pages are being set up. Thus this figure is most interesting when observed over a long time period, such as from boot time (see below on getting such a display). .Pp Below the page fill statistics is a column that lists the average number of context switches (`Csw'), traps (`Trp'; includes page faults), system calls (`Sys'), interrupts (`Int'), characters output to DZ ports using .No pseudo Ns -DMA (`Pdm'), network software interrupts (`Sof'), page faults (`Flt'), pages scanned by the page daemon (`Scn'), and revolutions of the page daemon's hand (`Rev') per second over the refresh interval. .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 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 .Ar netstat 1 ) . .It Cm numbers Display network addresses numerically. .It Cm names Display network addresses symbolically. .It Ar protocol Display only network connections using the indicated protocol (currently either ``tcp'' or ``udp''). .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 Tx -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. .El .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 /dev/drum For information about swapped out processes. .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 systat program appeared in .Bx 4.3 . .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.sbin/ac/ac.8 =================================================================== --- head/usr.sbin/ac/ac.8 (revision 13510) +++ head/usr.sbin/ac/ac.8 (revision 13511) @@ -1,155 +1,155 @@ .\" .\" Copyright (c) 1994 Simon J. Gerraty .\" Copyright (c) 1994 Christopher G. Demetriou .\" 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 Christopher G. Demetriou. .\" 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. .\" -.\" $Id: ac.8,v 1.2 1994/09/26 22:12:25 davidg Exp $ +.\" $Id: ac.8,v 1.3 1995/10/07 12:02:33 joerg Exp $ .\" .Dd March 15, 1994 .Dt AC 8 .Os .Sh NAME .Nm ac .Nd connect time accounting .Sh SYNOPSIS .Nm ac .Op Fl dp .\".Op Fl c Ar console .Op Fl t Ar tty .Op Fl w Ar wtmp .Op Ar users ... .Sh DESCRIPTION If the file .Pa /var/log/wtmp exists, a record of individual login and logout times are written to it by .Xr login 8 and .Xr init 8 , respectively. .Nm \&Ac examines these records and writes the accumulated connect time (in hours) for all logins to the standard output. .Pp The options are as follows: .Bl -tag -width indentXXX .It Fl d Display the connect times in 24 hour chunks. .\" .It Fl c Ar console .\" Use .\" .Ar console .\" as the name of the device that local X sessions (ut_host of ":0.0") .\" originate from. If any login has been recorded on .\" .Ar console .\" then these X sessions are ignored unless COMPAT_SUNOS was defined at .\" compile time. .It Fl p Print individual users' totals. .It Fl t Ar tty Only do accounting logins on certain ttys. The .Ar tty specification can start with '!' to indicate not this .Ar tty and end with '*' to indicate all similarly named ttys. Multiple .Fl t flags may be specified. .It Fl w Ar wtmp Read connect time data from .Ar wtmp instead of the default file, .Pa /var/log/wtmp . .It Ar users ... Display totals for the given individuals only. .El .Pp If no arguments are given, .Nm ac displays the total connect time for all accounts with login sessions recorded in .Pa wtmp . .Pp The default .Pa wtmp file will increase without bound unless it is truncated. It is normally truncated by the daily scripts run by .Xr cron 8 , which rename and rotate the .Pa wtmp files, keeping a week's worth of data on hand. No login or connect time accounting is performed if .Pa /var/log/wtmp does not exist. .Pp For example, .Bd -literal -offset ac -p -t "ttyd*" > modems ac -p -t "!ttyd*" > other .Ed .Pp allows times recorded in .Pa modems to be charged out at a different rate than .Pa other . .Pp The .Nm ac utility exits 0 on success, and >0 if a fatal error occurs. .Sh FILES .Bl -tag -width /var/log/wtmp.[0-7] -compact .It Pa /var/log/wtmp connect time accounting file .It Pa /var/log/wtmp.[0-7] rotated files .El .Sh SEE ALSO .Xr init 8 , .Xr sa 8 , .Xr login 1 , -.Xr utmp +.Xr utmp 5 .\" .Sh NOTES .\" If COMPAT_SUNOS is defined .\" .Nm ac .\" ignores the fact that entries with ut_host of ":0.0" are not real .\" login sessions. Normally such entries are ignored except in the case .\" of a user being logged in when the .\" .Pa wtmp .\" file was rotated, in which case a login with ut_host of ":0.0" may .\" appear without any preceeding console logins. .\" If no one is logged in on the console, the user is deemed to have .\" logged in on at the earliest time stamp found in .\" .Pa wtmp . .\" Use of .\" .Pa console .\" allows .\" .Nm ac .\" to identify and correcty process a logout for the user. The default .\" value for .\" .Pa console .\" is usually correct at compile time. Index: head/usr.sbin/amd/amq/amq.8 =================================================================== --- head/usr.sbin/amd/amq/amq.8 (revision 13510) +++ head/usr.sbin/amd/amq/amq.8 (revision 13511) @@ -1,130 +1,131 @@ .\" .\" Copyright (c) 1990 Jan-Simon Pendry .\" Copyright (c) 1990 Imperial College of Science, Technology & Medicine .\" Copyright (c) 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. .\" .\" This code is derived from software contributed to Berkeley by .\" Jan-Simon Pendry at Imperial College, London. .\" .\" 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. .\" .\" @(#)amq.8 8.3 (Berkeley) 4/18/94 .\" -.\" $Id: amq.8,v 5.2.2.1 1992/02/09 15:11:41 jsp beta $ +.\" $Id: amq.8,v 1.1.1.1 1994/05/26 05:22:04 rgrimes Exp $ .\" .Dd March 16, 1991 .Dt AMQ 8 .Os .Sh NAME .Nm amq .Nd automounter query tool .Sh SYNOPSIS .Nm amq .Op Fl f .Op Fl h Ar hostname .Op Fl M Ar mountmap_entry .Op Fl m .Op Fl s .Op Fl u .Op Fl v .Op Ar directory .Ar ... .Sh DESCRIPTION .Nm Amq provides a simple way of determining the current state of the .Xr amd 8 program. Communication is by .Tn RPC . Three modes of operation are supported by the current protocol. By default a list of mount points and auto-mounted filesystems is output. An alternative host can be specified using the .Fl h option. .Pp If directory names are given, as output by default, then per-filesystem information is displayed. .Sh OPTIONS .Bl -tag -width Ds .It Fl f Request automounter to flush the internal caches. .It Fl h Ar hostname Query alternate host .Ar hostname . By default the local host is used. In an .Tn HP-UX cluster, the root server is queried by default, since that is the system on which the automounter is normally run. .It Fl m Request the automounter to provide a list of mounted filesystems, including the number of references to each filesystem and any error which occurred while mounting. .It Fl s Request the automounter to provide system-wide mount statistics. .It Fl u Request the automounter to unmount the named filesystems instead of providing information about them. Unmounts are requested, not forced. They merely cause the mounted filesystem to timeout, which will be picked up by .Xr amd Ns \'s main scheduler thus causing the normal timeout action to be taken. .It Fl v Request the automounter to provide version information. This is a subset of the information provided by .Xr amd Ns \'s Fl v option. .It Fl M Request automounter to add the given map entry to the root map and then trigger a mount request for it. .El .Sh FILES .Bl -tag -width amq.xxxxx -compact .Bl -tag -width Ds .It Pa amq.x .Tn RPC protocol description. .El .Sh CAVEATS .Nm Amq uses a Sun registered .Tn RPC program number (300019 decimal) which may not be in the .Pa /etc/rpc database. .Sh SEE ALSO .Xr amd 8 .Sh AUTHOR .An Jan-Simon Pendry , Department of Computing, Imperial College, London, UK. .Sh HISTORY .Nm Amq +first appeared in 4.4BSD. .At Index: head/usr.sbin/iostat/iostat.8 =================================================================== --- head/usr.sbin/iostat/iostat.8 (revision 13510) +++ head/usr.sbin/iostat/iostat.8 (revision 13511) @@ -1,144 +1,144 @@ .\" Copyright (c) 1985, 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. .\" .\" @(#)iostat.8 8.1 (Berkeley) 6/6/93 .\" .Dd June 6, 1993 .Dt IOSTAT 8 .Os BSD 4 .Sh NAME .Nm iostat .Nd report .Tn I/O statistics .Sh SYNOPSIS .Nm iostat .Op Fl c Ar count .Op Fl M Ar core .Op Fl N Ar system .Op Fl w Ar wait .Op Ar drives .Sh DESCRIPTION .Nm Iostat displays kernel .Tn I/O statistics on terminal, disk and cpu operations. .Pp The options are as follows: .Bl -tag -width flag .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 .Ar wait interval is specified, the default is 1 second. .It Fl M Extract values associated with the name list from the specified core instead of the default .Dq Pa /dev/kmem . .It Fl N Extract the name list from the specified system instead of the default .Dq Pa /kernel . .It Fl w Pause .Ar wait seconds between each display. If no repeat .Ar count is specified, the default is infinity. .El .Pp .Nm Iostat displays its information in the following format: .Bl -tag -width flag .It tty .Bl -tag -width indent -compact .It tin characters read from terminals .It tout characters written to terminals .El .It disks Disk operations (this field is system dependent). The header of the field is the disk name and unit number. If more than four disk drives are configured in the system, .Nm iostat displays only the first four drives. To force .Nm iostat to display specific drives, their names may be supplied on the command line. .Pp .Bl -tag -width indent -compact .It sps sectors transferred per second .It tps transfers per second .It msps milliseconds per average seek (including implied seeks and rotational latency) .El .It cpu .Bl -tag -width indent -compact .It \&us % of cpu time in user mode .It \&ni % of cpu time in user mode running niced processes .It \&sy % of cpu time in system mode .It \&in % of cpu time in interrupt mode .It \&id % of cpu time in idle mode .El .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 nfsstat 1 , -.Xr \&ps 1 , +.Xr ps 1 , .Xr systat 1 , -.Xr vmstat 1 , -.Xr pstat 8 +.Xr pstat 8 , +.Xr vmstat 8 .Pp The sections starting with ``Interpreting system activity'' in .%T "Installing and Operating 4.3BSD" . Index: head/usr.sbin/pstat/pstat.8 =================================================================== --- head/usr.sbin/pstat/pstat.8 (revision 13510) +++ head/usr.sbin/pstat/pstat.8 (revision 13511) @@ -1,373 +1,373 @@ .\" Copyright (c) 1980, 1991, 1993, 1994 .\" The Regents of the University of California. All rights reserved. .\" .\" @(#)pstat.8 8.4 (Berkeley) 4/19/94 .\" 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: @(#)pstat.8 8.4 (Berkeley) 4/19/94 -.\" $Id$ +.\" $Id: pstat.8,v 1.5 1995/10/06 20:58:24 bde Exp $ .\" .Dd October 7, 1995 .Dt PSTAT 8 .Os BSD 4 .Sh NAME .Nm pstat .Nd display system data structures .Sh SYNOPSIS .Nm pstat .Op Fl Tfknstv .Op Fl M Ar core .Op Fl N Ar system .Pp .Nm swapinfo .Op Fl k .Sh DESCRIPTION .Nm Pstat displays open file entry, swap space utilization, terminal state, and vnode data structures. If .Ar corefile is given, the information is sought there, otherwise in .Pa /dev/kmem . The required namelist is taken from .Pa /kernel unless .Ar system is specified. .Pp If invoked as .Nm swapinfo the .Fl s option is implied, and only the .Fl k option is legal. .Pp Options are .Bl -tag -width indent .It Fl n Print devices out by major/minor instead of name. .It Fl k Print sizes in kilobytes, regardless of the setting of the BLOCKSIZE environment variable. .It Fl T Prints the number of used and free slots in the several system tables and is useful for checking to see how large system tables have become if the system is under heavy load. .It Fl f Print the open file table with these headings: .Bl -tag -width indent .It LOC The core location of this table entry. .It TYPE The type of object the file table entry points to. .It FLG Miscellaneous state variables encoded thus: .Bl -tag -width indent .It R open for reading .It W open for writing .It A open for appending .It S shared lock present .It X exclusive lock present .It I signal pgrp when data ready .El .It CNT Number of processes that know this open file. .It MSG Number of messages outstanding for this file. .It DATA The location of the vnode table entry or socket structure for this file. .It OFFSET The file offset (see .Xr lseek 2 ) . .El .It Fl s Print 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 .Ar Available column indicates how much space is remaining on each partition. The .Ar Capacity reports the percentage of space used. .Pp If more than one partition is configured into the system, totals for all of the statistics will be reported in the final line of the report. .It Fl t Print table for terminals with these headings: .Bl -tag -width indent .It RAW Number of characters in raw input queue. .It CAN Number of characters in canonicalized input queue. .It OUT Number of characters in putput queue. .It MODE See .Xr tty 4 . .It ADDR Physical device address. .It DEL Number of delimiters (newlines) in canonicalized input queue. .It COL Calculated column position of terminal. .It STATE Miscellaneous state variables encoded thus: .Bl -tag -width indent .It T delay timeout in progress .It W waiting for open to complete .It O open .It F outq has been flushed during DMA .It C carrier is on .It c connection open .It B busy doing output .It A process is waiting for space in output queue .It a process is waiting for output to complete .It X open for exclusive use .It S output stopped (ixon flow control) .It m output stopped (carrier flow control) .It o output stopped (CTS flow control) .It d output stopped (DSR flow control) .It K input stopped .It Y send SIGIO for input events .It D state for lowercase .Ql \e work .It E within a .Ql \e.../ for PRTRUB .It L next character is literal .It P retyping suspended input (PENDIN) .It N counting tab width, ignore FLUSHO .It l block mode input routine in use .It s i/o being snooped .It Z connection lost .El .It SESS Kernel address of the session structure. .It PGID Process group for which this is controlling terminal. .It DISC Line discipline; .Ql term for TTYDISC or .Ql ntty for NTTYDISC or .Ql tab for TABLDISC or .Ql slip for SLIPDISC or .Ql ppp for PPPDISC. .El .It Fl v Print the active vnodes. Each group of vnodes corresponding to a particular filesystem is preceded by a two line header. The first line consists of the following: .Pp .Df I .No *** MOUNT Em fstype from on .Em on fsflags .De .Pp where .Em fstype is one of .Em ufs , nfs , mfs , or pc ; .Em from is the filesystem is mounted from; .Em on is the directory the filesystem is mounted on; and .Em fsflags is a list of optional flags applied to the mount (see .Xr mount 8 ) . .The second line is a header for the individual fields , the first part of which are fixed, and the second part are filesystem type specific. The headers common to all vnodes are: .Bl -tag -width indent .It ADDR Location of this vnode. .It TYP File type. .It VFLAG .Pp A list of letters representing vnode flags: .Bl -tag -width indent .It R \- VROOT .It T \- VTEXT .It L \- VXLOCK .It W \- VXWANT .It E \- VEXLOCK .It S \- VSHLOCK .It T \- VLWAIT .It A \- VALIASED .It B \- VBWAIT .El .Pp .It USE The number of references to this vnode. .It HOLD The number of I/O buffers held by this vnode. .It FILEID The vnode fileid. In the case of .Em ufs this is the inode number. .It IFLAG Miscellaneous filesystem specific state variables encoded thus: .Bl -tag -width indent .It "For ufs:" .Pp .Bl -tag -width indent .It L locked .It U update time .Pq Xr fs 5 must be corrected .It A access time must be corrected .It W wanted by another process (L flag is on) .It C changed time must be corrected .It S shared lock applied .It E exclusive lock applied .It Z someone waiting for a lock .It M contains modifications .It R has a rename in progress .El .It "For nfs:" .Bl -tag -width indent .It W waiting for I/O buffer flush to complete .It P I/O buffers being flushed .It M locally modified data exists .It E an earlier write failed .It X non-cacheable lease (nqnfs) .It O write lease (nqnfs) .It G lease was evicted (nqnfs) .El .El .It SIZ/RDEV Number of bytes in an ordinary file, or major and minor device of special file. .El .El .Sh FILES .Bl -tag -width /dev/kmemxxx -compact .It Pa /kernel namelist .It Pa /dev/kmem default source of tables .El .Sh SEE ALSO -.Xr iostat 1 , .Xr ps 1 , .Xr systat 1 , -.Xr vmstat 1 , .Xr stat 2 , .Xr fs 5 , +.Xr iostat 8 , +.Xr vmstat 8 .Rs .Rt Tn UNIX Rt Implementation , .Ra K. Thompson .Re .Sh BUGS Does not understand NFS swap servers. .Sh HISTORY The .Nm pstat command appeared in 4.0BSD. Index: head/usr.sbin/zic/zic.8 =================================================================== --- head/usr.sbin/zic/zic.8 (revision 13510) +++ head/usr.sbin/zic/zic.8 (revision 13511) @@ -1,412 +1,412 @@ .TH ZIC 8 .SH NAME zic \- time zone compiler .SH SYNOPSIS .B zic [ .B \-v ] [ .B \-d .I directory ] [ .B \-l .I localtime ] [ .B \-p .I posixrules ] [ .B \-L .I leapsecondfilename ] [ .B \-s ] [ .B \-y .I command ] [ .I filename \&... ] .SH DESCRIPTION .if t .ds lq `` .if t .ds rq '' .if n .ds lq \&"\" .if n .ds rq \&"\" .de q \\$3\*(lq\\$1\*(rq\\$2 .. .I Zic reads text from the file(s) named on the command line and creates the time conversion information files specified in this input. If a .I filename is .BR \- , the standard input is read. .PP These options are available: .TP .BI "\-d " directory Create time conversion information files in the named directory rather than in the standard directory named below. .TP .BI "\-l " timezone Use the given time zone as local time. .I Zic will act as if the input contained a link line of the form .sp .ti +.5i Link \fItimezone\fP localtime .TP .BI "\-p " timezone Use the given time zone's rules when handling POSIX-format time zone environment variables. .I Zic will act as if the input contained a link line of the form .sp .ti +.5i Link \fItimezone\fP posixrules .TP .BI "\-L " leapsecondfilename Read leap second information from the file with the given name. If this option is not used, no leap second information appears in output files. .TP .B \-v Complain if a year that appears in a data file is outside the range of years representable by .IR time (2) values. .TP .B \-s Limit time values stored in output files to values that are the same whether they're taken to be signed or unsigned. You can use this option to generate SVVS-compatible files. .TP .BI "\-y " command Use the given .I command rather than .B yearistype when checking year types (see below). .PP Input lines are made up of fields. Fields are separated from one another by any number of white space characters. Leading and trailing white space on input lines is ignored. An unquoted sharp character (#) in the input introduces a comment which extends to the end of the line the sharp character appears on. White space characters and sharp characters may be enclosed in double quotes (") if they're to be used as part of a field. Any line that is blank (after comment stripping) is ignored. Non-blank lines are expected to be of one of three types: rule lines, zone lines, and link lines. .PP A rule line has the form .nf .ti +.5i .ta \w'Rule\0\0'u +\w'NAME\0\0'u +\w'FROM\0\0'u +\w'1973\0\0'u +\w'TYPE\0\0'u +\w'Apr\0\0'u +\w'lastSun\0\0'u +\w'2:00\0\0'u +\w'SAVE\0\0'u .sp Rule NAME FROM TO TYPE IN ON AT SAVE LETTER/S .sp For example: .ti +.5i .sp Rule US 1967 1973 \- Apr lastSun 2:00 1:00 D .sp .fi The fields that make up a rule line are: .TP "\w'LETTER/S'u" .B NAME Gives the (arbitrary) name of the set of rules this rule is part of. .TP .B FROM Gives the first year in which the rule applies. Any integer year can be supplied; the Gregorian calendar is assumed. The word .B minimum (or an abbreviation) means the minimum year representable as an integer. The word .B maximum (or an abbreviation) means the maximum year representable as an integer. Rules can describe times that are not representable as time values, with the unrepresentable times ignored; this allows rules to be portable among hosts with differing time value types. .TP .B TO Gives the final year in which the rule applies. In addition to .B minimum and .B maximum (as above), the word .B only (or an abbreviation) may be used to repeat the value of the .B FROM field. .TP .B TYPE Gives the type of year in which the rule applies. If .B TYPE is .B \- then the rule applies in all years between .B FROM and .B TO inclusive; if .B TYPE is .BR uspres , the rule applies in U.S. Presidential election years; if .B TYPE is .BR nonpres , the rule applies in years other than U.S. Presidential election years. If .B TYPE is something else, then .I zic executes the command .ti +.5i \fByearistype\fP \fIyear\fP \fItype\fP .br to check the type of a year: an exit status of zero is taken to mean that the year is of the given type; an exit status of one is taken to mean that the year is not of the given type. .TP .B IN Names the month in which the rule takes effect. Month names may be abbreviated. .TP .B ON Gives the day on which the rule takes effect. Recognized forms include: .nf .in +.5i .sp .ta \w'Sun<=25\0\0'u 5 the fifth of the month lastSun the last Sunday in the month lastMon the last Monday in the month Sun>=8 first Sunday on or after the eighth Sun<=25 last Sunday on or before the 25th .fi .in -.5i .sp Names of days of the week may be abbreviated or spelled out in full. Note that there must be no spaces within the .B ON field. .TP .B AT Gives the time of day at which the rule takes effect. Recognized forms include: .nf .in +.5i .sp .ta \w'1:28:13\0\0'u 2 time in hours 2:00 time in hours and minutes 15:00 24-hour format time (for times after noon) 1:28:14 time in hours, minutes, and seconds .fi .in -.5i .sp Any of these forms may be followed by the letter .B w if the given time is local .q "wall clock" time or .B s if the given time is local .q standard time; in the absence of .B w or .BR s , wall clock time is assumed. .TP .B SAVE Gives the amount of time to be added to local standard time when the rule is in effect. This field has the same format as the .B AT field (although, of course, the .B w and .B s suffixes are not used). .TP .B LETTER/S Gives the .q "variable part" (for example, the .q S or .q D in .q EST or .q EDT ) of time zone abbreviations to be used when this rule is in effect. If this field is .BR \- , the variable part is null. .PP A zone line has the form .sp .nf .ti +.5i .ta \w'Zone\0\0'u +\w'Australia/Adelaide\0\0'u +\w'GMTOFF\0\0'u +\w'RULES/SAVE\0\0'u +\w'FORMAT\0\0'u Zone NAME GMTOFF RULES/SAVE FORMAT [UNTIL] .sp For example: .sp .ti +.5i Zone Australia/Adelaide 9:30 Aus CST 1971 Oct 31 2:00 .sp .fi The fields that make up a zone line are: .TP "\w'GMTOFF'u" .B NAME The name of the time zone. This is the name used in creating the time conversion information file for the zone. .TP .B GMTOFF The amount of time to add to GMT to get standard time in this zone. This field has the same format as the .B AT and .B SAVE fields of rule lines; begin the field with a minus sign if time must be subtracted from GMT. .TP .B RULES/SAVE The name of the rule(s) that apply in the time zone or, alternately, an amount of time to add to local standard time. If this field is .B \- then standard time always applies in the time zone. .TP .B FORMAT The format for time zone abbreviations in this time zone. The pair of characters .B %s is used to show where the .q "variable part" of the time zone abbreviation goes. .TP .B UNTIL The time at which the GMT offset or the rule(s) change for a location. It is specified as a year, a month, a day, and a time of day. If this is specified, the time zone information is generated from the given GMT offset and rule change until the time specified. .IP The next line must be a .q continuation line; this has the same form as a zone line except that the string .q Zone and the name are omitted, as the continuation line will place information starting at the time specified as the .B UNTIL field in the previous line in the file used by the previous line. Continuation lines may contain an .B UNTIL field, just as zone lines do, indicating that the next line is a further continuation. .PP A link line has the form .sp .nf .ti +.5i .if t .ta \w'Link\0\0'u +\w'LINK-FROM\0\0'u .if n .ta \w'Link\0\0'u +\w'US/Eastern\0\0'u Link LINK-FROM LINK-TO .sp For example: .sp .ti +.5i Link US/Eastern EST5EDT .sp .fi The .B LINK-FROM field should appear as the .B NAME field in some zone line; the .B LINK-TO field is used as an alternate name for that zone. .PP Except for continuation lines, lines may appear in any order in the input. .PP Lines in the file that describes leap seconds have the following form: .nf .ti +.5i .ta \w'Leap\0\0'u +\w'YEAR\0\0'u +\w'MONTH\0\0'u +\w'DAY\0\0'u +\w'HH:MM:SS\0\0'u +\w'CORR\0\0'u .sp Leap YEAR MONTH DAY HH:MM:SS CORR R/S .sp For example: .ti +.5i .sp Leap 1974 Dec 31 23:59:60 + S .sp .fi The .BR YEAR , .BR MONTH , .BR DAY , and .B HH:MM:SS fields tell when the leap second happened. The .B CORR field should be .q + if a second was added or .q - if a second was skipped. .\" There's no need to document the following, since it's impossible for more .\" than one leap second to be inserted or deleted at a time. .\" The C Standard is in error in suggesting the possibility. .\" See Terry J Quinn, The BIPM and the accurate measure of time, .\" Proc IEEE 79, 7 (July 1991), 894-905. .\" or .\" .q ++ .\" if two seconds were added .\" or .\" .q -- .\" if two seconds were skipped. The .B R/S field should be (an abbreviation of) .q Stationary if the leap second time given by the other fields should be interpreted as GMT or (an abbreviation of) .q Rolling if the leap second time given by the other fields should be interpreted as local wall clock time. .SH NOTE For areas with more than two types of local time, you may need to use local standard time in the .B AT field of the earliest transition time's rule to ensure that the earliest transition time recorded in the compiled file is correct. .SH FILE -/usr/local/etc/zoneinfo standard directory used for created files +/usr/share/zoneinfo standard directory used for created files .SH "SEE ALSO" newctime(3), tzfile(5), zdump(8) .\" @(#)zic.8 7.7