diff options
| author | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2026-04-25 19:55:43 -0400 |
|---|---|---|
| committer | Jacob McDonnell <jacob@jacobmcdonnell.com> | 2026-04-25 19:55:43 -0400 |
| commit | ac5e55f5f2af5b92794c2aded46c6bae85b5f5ed (patch) | |
| tree | 9367490586c84cba28652e443e3166d66c33b0d9 /static/freebsd/man4/procfs.4 3.html | |
| parent | 253e67c8b3a72b3a4757fdbc5845297628db0a4a (diff) | |
docs: Added All FreeBSD Manuals
Diffstat (limited to 'static/freebsd/man4/procfs.4 3.html')
| -rw-r--r-- | static/freebsd/man4/procfs.4 3.html | 266 |
1 files changed, 266 insertions, 0 deletions
diff --git a/static/freebsd/man4/procfs.4 3.html b/static/freebsd/man4/procfs.4 3.html new file mode 100644 index 00000000..8d08ccc5 --- /dev/null +++ b/static/freebsd/man4/procfs.4 3.html @@ -0,0 +1,266 @@ +<table class="head"> + <tr> + <td class="head-ltitle">PROCFS(4)</td> + <td class="head-vol">Device Drivers Manual</td> + <td class="head-rtitle">PROCFS(4)</td> + </tr> +</table> +<div class="manual-text"> +<section class="Sh"> +<h1 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h1> +<p class="Pp"><code class="Nm">procfs</code> — <span class="Nd">process + file system</span></p> +</section> +<section class="Sh"> +<h1 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h1> +<div class="Bd Li"> +<pre>proc /proc procfs rw 0 0</pre> +</div> +</section> +<section class="Sh"> +<h1 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h1> +<div class="Bf Sy">This functionality is deprecated. Users are advised to use + <a class="Xr">libprocstat(3)</a> and <a class="Xr">kvm(3)</a> instead.</div> +<p class="Pp">The process file system, or <code class="Nm">procfs</code>, + implements a view of the system process table inside the file system. It is + normally mounted on <span class="Pa">/proc</span>.</p> +<p class="Pp">The <code class="Nm">procfs</code> provides a two-level view of + process space, unlike the previous <span class="Ux">FreeBSD 1.1</span> + <code class="Nm">procfs</code> implementation. At the highest level, + processes themselves are named, according to their process ids in decimal, + with no leading zeros. There is also a special node called + <span class="Pa">curproc</span> which always refers to the process making + the lookup request.</p> +<p class="Pp">Each node is a directory which contains the following entries:</p> +<dl class="Bl-tag"> + <dt><span class="Pa">dbregs</span></dt> + <dd>The debug registers as defined by <code class="Dv">struct dbregs</code> in + <code class="In"><<a class="In">machine/reg.h</a>></code>. + <span class="Pa">dbregs</span> is currently only implemented on the i386 + architecture.</dd> + <dt><span class="Pa">etype</span></dt> + <dd>The type of the executable referenced by the <span class="Pa">file</span> + entry.</dd> + <dt><span class="Pa">file</span></dt> + <dd>A symbolic link to the file from which the process text was read. This can + be used to gain access to the process' symbol table, or to start another + copy of the process. If the file cannot be found, the link target is + ‘<code class="Li">unknown</code>’.</dd> + <dt><span class="Pa">fpregs</span></dt> + <dd>The floating point registers as defined by <code class="Dv">struct + fpregs</code> in + <code class="In"><<a class="In">machine/reg.h</a>></code>. + <span class="Pa">fpregs</span> is only implemented on machines which have + distinct general purpose and floating point register sets.</dd> + <dt><span class="Pa">map</span></dt> + <dd>A collection of lines describing the memory regions of the process, where + each line contains the following fields: + <dl class="Bl-tag Bl-compact"> + <dt>start-address</dt> + <dd>The starting address for the region (inclusive).</dd> + <dt>end-address</dt> + <dd>The ending address for the region (exclusive).</dd> + <dt>resident</dt> + <dd>The number of resident pages.</dd> + <dt>private-resident</dt> + <dd>The number of resident pages that were private to the process.</dd> + <dt>obj</dt> + <dd>The virtual address of the <var class="Vt">struct vm_object</var> + kernel data structure describing the memory region.</dd> + <dt>access</dt> + <dd>A three character string comprising the characters ‘r’, + ‘w’ and ‘x’, denoting read, write, and + execute permissions respectively. The lack of a permission is + represented by ‘-’.</dd> + <dt>ref_count</dt> + <dd>The number of references to the region.</dd> + <dt>shadow_count</dt> + <dd>The number of VM objects that this region is a shadow for.</dd> + <dt id="OBJ_*">flags</dt> + <dd>The flags for the object, see the flags named + <a class="permalink" href="#OBJ_*"><b class="Sy">OBJ_*</b></a> in + <code class="In"><<a class="In">vm/vm_object.h</a>></code>.</dd> + <dt>copy-on-write</dt> + <dd>Whether the region is copy-on-write. One of: + <dl class="Bl-tag Bl-compact"> + <dt>COW</dt> + <dd>A copy-on-write region.</dd> + <dt>NCOW</dt> + <dd>A non-copy-on-write region.</dd> + </dl> + </dd> + <dt>needs-copy</dt> + <dd>Whether the region needs a copy. One of: + <dl class="Bl-tag Bl-compact"> + <dt>NC</dt> + <dd>The region needs a copy.</dd> + <dt>NNC</dt> + <dd>The region does not need a copy.</dd> + </dl> + </dd> + <dt>type</dt> + <dd>The type of the region. One of: + <dl class="Bl-tag Bl-compact"> + <dt>dead</dt> + <dd>A region associated with a dead VM object.</dd> + <dt>device</dt> + <dd>A region backed by device memory.</dd> + <dt>none</dt> + <dd>A region not backed by anything.</dd> + <dt>phys</dt> + <dd>A region backed by physical memory.</dd> + <dt>swap</dt> + <dd>A region backed by swap.</dd> + <dt>unknown</dt> + <dd>A region of unknown type.</dd> + <dt>vnode</dt> + <dd>A region backed by a file.</dd> + </dl> + </dd> + <dt>fullpath</dt> + <dd>The path to the file backing the memory region, or ‘-’ + if there is no such file.</dd> + <dt>cred</dt> + <dd>One of: + <dl class="Bl-tag Bl-compact"> + <dt>CH</dt> + <dd>The region is being charged to the user specified in the + ‘charged-uid’ field.</dd> + <dt>NCH</dt> + <dd>The region is not being charged to any user.</dd> + </dl> + </dd> + <dt>charged-uid</dt> + <dd>The UID of the user being charged, or -1 if no user is being + charged.</dd> + </dl> + </dd> + <dt><span class="Pa">mem</span></dt> + <dd>The complete virtual memory image of the process. Only those address which + exist in the process can be accessed. Reads and writes to this file modify + the process. Writes to the text segment remain private to the + process.</dd> + <dt><span class="Pa">note</span></dt> + <dd>Used for sending signals to the process. Not implemented.</dd> + <dt><span class="Pa">notepg</span></dt> + <dd>Used for sending signal to the process group. Not implemented.</dd> + <dt><span class="Pa">osrel</span></dt> + <dd>Allows read and write of the kernel osrel value assigned to the process. + It affects the compatibility shims that are turned on and off depending on + the value. Initial process value is read from the ABI note tag in the + executed ELF image, and is zero if the tag not supported by binary format + or was not found.</dd> + <dt><span class="Pa">regs</span></dt> + <dd>Allows read and write access to the process' register set. This file + contains a binary data structure <code class="Dv">struct regs</code> + defined in + <code class="In"><<a class="In">machine/reg.h</a>></code>. + <span class="Pa">regs</span> can only be written when the process is + stopped.</dd> + <dt><span class="Pa">rlimit</span></dt> + <dd>This is a read-only file containing the process current and maximum + limits. Each line is of the format <var class="Ar">rlimit current + max</var>, with -1 indicating infinity.</dd> + <dt><span class="Pa">status</span></dt> + <dd>The process status. This file is read-only and returns a single line + containing multiple space-separated fields as follows: + <p class="Pp"></p> + <ul class="Bl-bullet Bl-compact"> + <li>command name</li> + <li>process id</li> + <li>parent process id</li> + <li>process group id</li> + <li>session id</li> + <li>device name of the controlling terminal, or a minus sign + (“-”) if there is no controlling terminal.</li> + <li>a list of process flags: <code class="Dv">ctty</code> if there is a + controlling terminal, <code class="Dv">sldr</code> if the process is a + session leader, <code class="Dv">noflags</code> if neither of the + other two flags are set.</li> + <li>the process start time in seconds and microseconds, comma + separated.</li> + <li>the user time in seconds and microseconds, comma separated.</li> + <li>the system time in seconds and microseconds, comma separated.</li> + <li>the wait channel message</li> + <li>the process effective UID</li> + <li>the process real UID</li> + <li>group list, starting with the effective GID, comma-separated</li> + <li>the hostname of the jail in which the process runs, or + ‘<code class="Li">-</code>’ to indicate that the process + is not running within a jail.</li> + </ul> + </dd> +</dl> +<p class="Pp">Each node is owned by the process's user, and belongs to that + user's primary group.</p> +</section> +<section class="Sh"> +<h1 class="Sh" id="FILES"><a class="permalink" href="#FILES">FILES</a></h1> +<dl class="Bl-tag Bl-compact"> + <dt><span class="Pa">/proc</span></dt> + <dd>normal mount point for the <code class="Nm">procfs</code>.</dd> + <dt><span class="Pa">/proc/pid</span></dt> + <dd>directory containing process information for process + <span class="Pa">pid</span>.</dd> + <dt><span class="Pa">/proc/curproc</span></dt> + <dd>directory containing process information for the current process</dd> + <dt><span class="Pa">/proc/self</span></dt> + <dd>directory containing process information for the current process</dd> + <dt><span class="Pa">/proc/curproc/cmdline</span></dt> + <dd>the process executable name</dd> + <dt><span class="Pa">/proc/curproc/etype</span></dt> + <dd>executable type</dd> + <dt><span class="Pa">/proc/curproc/exe</span></dt> + <dd>executable image</dd> + <dt><span class="Pa">/proc/curproc/file</span></dt> + <dd>executable image</dd> + <dt><span class="Pa">/proc/curproc/fpregs</span></dt> + <dd>the process floating point register set</dd> + <dt><span class="Pa">/proc/curproc/map</span></dt> + <dd>virtual memory map of the process</dd> + <dt><span class="Pa">/proc/curproc/mem</span></dt> + <dd>the complete virtual address space of the process</dd> + <dt><span class="Pa">/proc/curproc/note</span></dt> + <dd>used for signaling the process</dd> + <dt><span class="Pa">/proc/curproc/notepg</span></dt> + <dd>used for signaling the process group</dd> + <dt><span class="Pa">/proc/curproc/osrel</span></dt> + <dd>the process osrel value</dd> + <dt><span class="Pa">/proc/curproc/regs</span></dt> + <dd>the process register set</dd> + <dt><span class="Pa">/proc/curproc/rlimit</span></dt> + <dd>the process current and maximum rlimit</dd> + <dt><span class="Pa">/proc/curproc/status</span></dt> + <dd>the process' current status</dd> +</dl> +</section> +<section class="Sh"> +<h1 class="Sh" id="EXAMPLES"><a class="permalink" href="#EXAMPLES">EXAMPLES</a></h1> +<p class="Pp">To mount a <code class="Nm">procfs</code> file system on + <span class="Pa">/proc</span>:</p> +<p class="Pp"></p> +<div class="Bd Bd-indent"><code class="Li">mount -t procfs proc + /proc</code></div> +</section> +<section class="Sh"> +<h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE + ALSO</a></h1> +<p class="Pp"><a class="Xr">procstat(1)</a>, <a class="Xr">mount(2)</a>, + <a class="Xr">sigaction(2)</a>, <a class="Xr">unmount(2)</a>, + <a class="Xr">kvm(3)</a>, <a class="Xr">libprocstat(3)</a>, + <a class="Xr">pseudofs(9)</a></p> +</section> +<section class="Sh"> +<h1 class="Sh" id="AUTHORS"><a class="permalink" href="#AUTHORS">AUTHORS</a></h1> +<p class="Pp">This manual page written by <span class="An">Garrett + Wollman</span>, based on the description provided by + <span class="An">Jan-Simon Pendry</span>, and revamped later by + <span class="An">Mike Pritchard</span>.</p> +</section> +</div> +<table class="foot"> + <tr> + <td class="foot-date">June 23, 2024</td> + <td class="foot-os">FreeBSD 15.0</td> + </tr> +</table> |
