1 .\" Written by Garrett Wollman
2 .\" This file is in the public domain.
9 .Nd process file system
12 proc /proc procfs rw 0 0
16 This functionality is deprecated.
17 Users are advised to use
24 The process file system, or
26 implements a view of the system process table inside the file system.
27 It is normally mounted on
32 provides a two-level view of process space, unlike the previous
36 At the highest level, processes themselves are named, according to
37 their process ids in decimal, with no leading zeros.
41 which always refers to the process making the lookup request.
43 Each node is a directory which contains the following entries:
44 .Bl -tag -width status
46 The debug registers as defined by
51 is currently only implemented on the i386 architecture.
53 The type of the executable referenced by the
57 A symbolic link to the file from which the process text was read.
58 This can be used to gain access to the process' symbol table,
59 or to start another copy of the process.
60 If the file cannot be found, the link target is
63 The floating point registers as defined by
68 is only implemented on machines which have distinct general
69 purpose and floating point register sets.
71 A collection of lines describing the memory regions of the process,
72 where each line contains the following fields:
73 .Bl -tag -compact -width private-resident
75 The starting address for the region (inclusive).
77 The ending address for the region (exclusive).
79 The number of resident pages.
81 The number of resident pages that were private to the process.
83 The virtual address of the
85 kernel data structure describing the memory region.
87 A three character string comprising the characters
92 denoting read, write, and execute permissions respectively.
93 The lack of a permission is represented by
96 The number of references to the region.
98 The number of VM objects that this region is a shadow for.
100 The flags for the object, see the flags named
105 Whether the region is copy-on-write.
107 .Bl -tag -compact -width NCOW
109 A copy-on-write region.
111 A non-copy-on-write region.
114 Whether the region needs a copy.
116 .Bl -tag -compact -width NNC
118 The region needs a copy.
120 The region does not need a copy.
123 The type of the region.
125 .Bl -tag -compact -width unknown
127 A region associated with a dead VM object.
129 A region backed by device memory.
131 A region not backed by anything.
133 A region backed by physical memory.
135 A region backed by swap.
137 A region of unknown type.
139 A region backed by a file.
142 The path to the file backing the memory region, or
144 if there is no such file.
147 .Bl -tag -compact -width NCH
149 The region is being charged to the user specified in the
153 The region is not being charged to any user.
156 The UID of the user being charged, or -1 if no user is being charged.
159 The complete virtual memory image of the process.
160 Only those address which exist in the process can be accessed.
161 Reads and writes to this file modify the process.
162 Writes to the text segment remain private to the process.
164 Used for sending signals to the process.
167 Used for sending signal to the process group.
170 Allows read and write of the kernel osrel value assigned to the process.
171 It affects the compatibility shims that are turned on and off
172 depending on the value.
173 Initial process value is read from the ABI note tag in the executed ELF image,
174 and is zero if the tag not supported by binary format or was not found.
176 Allows read and write access to the process' register set.
177 This file contains a binary data structure
182 can only be written when the process is stopped.
184 This is a read-only file containing the process current and maximum
186 Each line is of the format
187 .Ar rlimit current max ,
192 This file is read-only and returns a single line containing
193 multiple space-separated fields as follows:
208 of the controlling terminal, or
211 if there is no controlling terminal.
213 a list of process flags:
215 if there is a controlling terminal,
217 if the process is a session leader,
219 if neither of the other two flags are set.
221 the process start time in seconds and microseconds,
224 the user time in seconds and microseconds,
227 the system time in seconds and microseconds,
230 the wait channel message
232 the process credentials consisting of
233 the effective user id
234 and the list of groups (whose first member
235 is the effective group id)
238 the hostname of the jail in which the process runs, or
240 to indicate that the process is not running within a jail.
244 Each node is owned by the process's user, and belongs to that user's
247 .Bl -tag -width /proc/curproc/XXXXXXX -compact
249 normal mount point for the
252 directory containing process information for process
255 directory containing process information for the current process
256 .It Pa /proc/curproc/cmdline
257 the process executable name
258 .It Pa /proc/curproc/etype
260 .It Pa /proc/curproc/file
262 .It Pa /proc/curproc/fpregs
263 the process floating point register set
264 .It Pa /proc/curproc/map
265 virtual memory map of the process
266 .It Pa /proc/curproc/mem
267 the complete virtual address space of the process
268 .It Pa /proc/curproc/note
269 used for signaling the process
270 .It Pa /proc/curproc/notepg
271 used for signaling the process group
272 .It Pa /proc/curproc/osrel
273 the process osrel value
274 .It Pa /proc/curproc/regs
275 the process register set
276 .It Pa /proc/curproc/rlimit
277 the process current and maximum rlimit
278 .It Pa /proc/curproc/status
279 the process' current status
287 .Dl "mount -t procfs proc /proc"
298 This manual page written by
299 .An Garrett Wollman ,
300 based on the description
302 .An Jan-Simon Pendry ,
303 and revamped later by