FSTAT(1) 1990 FSTAT(1) NNAAMMEE fstat - file status SSYYNNOOPPSSIISS ffssttaatt [ --uu user ] [ --pp pid ] [ ffiilleennaammee...... ] DDEESSCCRRIIPPTTIIOONN _F_s_t_a_t identifies open files. A file is considered open if a process has it open, if it is the working directory for a process, or if it is an active pure text file. If no options are specified, _f_s_t_a_t reports on all open files. Options: --uu Report all files open by the specified user. --pp Report all files open by the specified process. ffiilleennaammee...... Restrict reports to the specified files. If the file is a block special file, _f_s_t_a_t additionally reports on any open files on that device, treating it as a mounted file system. The following fields are printed: UUSSEERR The username of the owner of the process. CCMMDD The command name of the process. PPIIDD The process id. FFDD The file number in the per-process open file table. The special names ``text'' and ``wd'' mean that the file is the pure text inode or the working directory for the process. If the file number is followed by an asterisk (``*''), then the file is not an inode, but is a socket or a FIFO or has an error of some kind. In this case the rest of the entry is in variable for- mat, doesn't correspond to the rest of the headings, and is enclosed in parentheses. If the file resides on a remote filesystem, the device, inode, and size fields are replaced by the text ``from remote filesys- tem''. DDEEVVIICCEE Major/minor number of the device this file exists on. IINNOODDEE The inode number of the file. SSIIZZEE The size, in bytes, of the file. Printed 7/27/90 June 1 FSTAT(1) 1990 FSTAT(1) TTYYPPEE The type of the file (see _s_t_a_t(2)). SSoocckkeettss 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). Other- wise the protocol number and address of the socket itself are printed. The attempt is to not duplicate _n_e_t_s_t_a_t(1), but rather to make enough information available to permit further analysis. For example, the addresses mentioned above are the addresses which the ``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 (``<->''). BBUUGGSS Since _f_s_t_a_t takes a snapshot of the system, it is only correct for a very short period of time. SSEEEE AALLSSOO netstat(1), ps(1), systat(1), stat(2), pstat(8) Printed 7/27/90 June 2