Print this page




 401 
 402          PR_FAULTED     indicates that the lwp stopped on incurring a hardware
 403                         fault (see PCSFAULT); pr_what holds the fault number
 404                         that caused the stop.
 405 
 406          PR_SYSENTRY
 407 
 408          PR_SYSEXIT     indicate a stop on entry to or exit from a system call
 409                         (see PCSENTRY and PCSEXIT); pr_what holds the system
 410                         call number.
 411 
 412          PR_JOBCONTROL  indicates that the lwp stopped due to the default
 413                         action of a job control stop signal (see
 414                         sigaction(2)); pr_what holds the stopping signal
 415                         number.
 416 
 417          PR_SUSPENDED   indicates that the lwp stopped due to internal
 418                         synchronization of lwps within the process.  pr_what
 419                         is unused in this case.
 420 






 421      pr_cursig names the current signal, that is, the next signal to be
 422      delivered to the lwp, if any.  pr_info, when the lwp is in a PR_SIGNALLED
 423      or PR_FAULTED stop, contains additional information pertinent to the
 424      particular signal or fault (see <sys/siginfo.h>).
 425 
 426      pr_lwppend identifies any synchronous or directed signals pending for the
 427      lwp.  pr_lwphold identifies those signals whose delivery is being blocked
 428      by the lwp (the signal mask).
 429 
 430      pr_action contains the signal action information pertaining to the
 431      current signal (see sigaction(2)); it is undefined if pr_cursig is zero.
 432      pr_altstack contains the alternate signal stack information for the lwp
 433      (see sigaltstack(2)).
 434 
 435      pr_oldcontext, if not zero, contains the address on the lwp stack of a
 436      ucontext structure describing the previous user-level context (see
 437      ucontext.h(3HEAD)).  It is non-zero only if the lwp is executing in the
 438      context of a signal handler.
 439 
 440      pr_syscall is the number of the system call, if any, being executed by


 601           taskid_t pr_taskid;      /* task id */
 602           projid_t pr_projid;      /* project id */
 603           poolid_t pr_poolid;      /* pool id */
 604           zoneid_t pr_zoneid;      /* zone id */
 605           ctid_t pr_contract;      /* process contract id */
 606           lwpsinfo_t pr_lwp;       /* information for representative lwp */
 607       } psinfo_t;
 608 
 609      Some of the entries in psinfo, such as pr_addr, refer to internal kernel
 610      data structures and should not be expected to retain their meanings
 611      across different versions of the operating system.
 612 
 613      psinfo_t.pr_flag is a deprecated interface that should no longer be used.
 614      Applications currently relying on the SSYS bit in pr_flag should migrate
 615      to checking PR_ISSYS in the pstatus structure's pr_flags field.
 616 
 617      pr_pctcpu and pr_pctmem are 16-bit binary fractions in the range 0.0 to
 618      1.0 with the binary point to the right of the high-order bit (1.0 ==
 619      0x8000).  pr_pctcpu is the summation over all lwps in the process.
 620 








 621      pr_lwp contains the ps(1) information for the representative lwp.  If the
 622      process is a zombie, pr_nlwp, pr_nzomb, and pr_lwp.pr_lwpid are zero and
 623      the other fields of pr_lwp are undefined:
 624 
 625       typedef struct lwpsinfo {
 626           int pr_flag;             /* lwp flags (DEPRECATED: see below) */
 627           id_t pr_lwpid;           /* lwp id */
 628           uintptr_t pr_addr;       /* internal address of lwp */
 629           uintptr_t pr_wchan;      /* wait addr for sleeping lwp */
 630           char pr_stype;           /* synchronization event type */
 631           char pr_state;           /* numeric lwp state */
 632           char pr_sname;           /* printable character for pr_state */
 633           char pr_nice;            /* nice for cpu usage */
 634           short pr_syscall;        /* system call number (if in syscall) */
 635           char pr_oldpri;          /* pre-SVR4, low value is high priority */
 636           char pr_cpu;             /* pre-SVR4, cpu usage for scheduling */
 637           int pr_pri;              /* priority, high value = high priority */
 638           ushort_t pr_pctcpu;      /* % of recent cpu time used by this lwp */
 639           timestruc_t pr_start;    /* lwp start time, from the epoch */
 640           timestruc_t pr_time;     /* cpu time for this lwp */


 709               secflagset_t pr_inherit;        /* Inheritable flags */
 710               secflagset_t pr_lower;          /* Lower flags */
 711               secflagset_t pr_upper;          /* Upper flags */
 712       } prsecflags_t;
 713 
 714      The pr_version field is a version number for the structure, currently
 715      PRSECFLAGS_VERSION_1.
 716 
 717    sigact
 718      Contains an array of sigaction structures describing the current
 719      dispositions of all signals associated with the traced process (see
 720      sigaction(2)).  Signal numbers are displaced by 1 from array indices, so
 721      that the action for signal number n appears in position n-1 of the array.
 722 
 723    auxv
 724      Contains the initial values of the process's aux vector in an array of
 725      auxv_t structures (see <sys/auxv.h>).  The   values are those that were
 726      passed by the operating system as startup information to the dynamic
 727      linker.
 728 







 729    ldt
 730      This file exists only on x86-based machines.  It is non-empty only if the
 731      process has established a local descriptor table (LDT).  If non-empty,
 732      the file contains the array of currently active LDT entries in an array
 733      of elements of type struct ssd, defined in <sys/sysi86.h>,   one element
 734      for each active LDT entry.
 735 
 736    map, xmap
 737      Contain information about the virtual address map of the process.  The
 738      map file contains an array of prmap structures while the xmap file
 739      contains an array of prxmap structures.  Each structure describes a
 740      contiguous virtual address region in the address space of the traced
 741      process:
 742 
 743       typedef struct prmap {
 744               uintptr_tpr_vaddr;         /* virtual address of mapping */
 745               size_t pr_size;            /* size of mapping in bytes */
 746               char pr_mapname[PRMAPSZ];  /* name in /proc/pid/object */
 747               offset_t pr_offset;        /* offset into mapped object, if any */
 748               int pr_mflags;             /* protection and attribute flags */


2071      /proc/pid/lstatus
2072              array of lwp status structs
2073      /proc/pid/psinfo
2074              process ps(1) info
2075      /proc/pid/lpsinfo
2076              array of lwp ps(1) info structs
2077      /proc/pid/map
2078              address space map
2079      /proc/pid/xmap
2080              extended address space map
2081      /proc/pid/rmap
2082              reserved address map
2083      /proc/pid/cred
2084              process credentials
2085      /proc/pid/priv
2086              process privileges
2087      /proc/pid/sigact
2088              process signal actions
2089      /proc/pid/auxv
2090              process aux vector


2091      /proc/pid/ldt
2092              process LDT (x86 only)
2093      /proc/pid/usage
2094              process usage
2095      /proc/pid/lusage
2096              array of lwp usage structs
2097      /proc/pid/path
2098              symbolic links to process open files
2099      /proc/pid/pagedata
2100              process page data
2101      /proc/pid/watch
2102              active watchpoints
2103      /proc/pid/cwd
2104              alias for the current working directory
2105      /proc/pid/root
2106              alias for the root directory
2107      /proc/pid/fd
2108              directory (list of open files)
2109      /proc/pid/fd/*
2110              aliases for process's open files




 401 
 402          PR_FAULTED     indicates that the lwp stopped on incurring a hardware
 403                         fault (see PCSFAULT); pr_what holds the fault number
 404                         that caused the stop.
 405 
 406          PR_SYSENTRY
 407 
 408          PR_SYSEXIT     indicate a stop on entry to or exit from a system call
 409                         (see PCSENTRY and PCSEXIT); pr_what holds the system
 410                         call number.
 411 
 412          PR_JOBCONTROL  indicates that the lwp stopped due to the default
 413                         action of a job control stop signal (see
 414                         sigaction(2)); pr_what holds the stopping signal
 415                         number.
 416 
 417          PR_SUSPENDED   indicates that the lwp stopped due to internal
 418                         synchronization of lwps within the process.  pr_what
 419                         is unused in this case.
 420 
 421          PR_BRAND       indicates that the lwp stopped for a brand-specific
 422                         reason.  Interpretation of the value of pr_what
 423                         depends on which zone brand is in use.  It is not
 424                         generally expected that an lwp stopped in this state
 425                         will be restarted by native proc(4) consumers.
 426 
 427      pr_cursig names the current signal, that is, the next signal to be
 428      delivered to the lwp, if any.  pr_info, when the lwp is in a PR_SIGNALLED
 429      or PR_FAULTED stop, contains additional information pertinent to the
 430      particular signal or fault (see <sys/siginfo.h>).
 431 
 432      pr_lwppend identifies any synchronous or directed signals pending for the
 433      lwp.  pr_lwphold identifies those signals whose delivery is being blocked
 434      by the lwp (the signal mask).
 435 
 436      pr_action contains the signal action information pertaining to the
 437      current signal (see sigaction(2)); it is undefined if pr_cursig is zero.
 438      pr_altstack contains the alternate signal stack information for the lwp
 439      (see sigaltstack(2)).
 440 
 441      pr_oldcontext, if not zero, contains the address on the lwp stack of a
 442      ucontext structure describing the previous user-level context (see
 443      ucontext.h(3HEAD)).  It is non-zero only if the lwp is executing in the
 444      context of a signal handler.
 445 
 446      pr_syscall is the number of the system call, if any, being executed by


 607           taskid_t pr_taskid;      /* task id */
 608           projid_t pr_projid;      /* project id */
 609           poolid_t pr_poolid;      /* pool id */
 610           zoneid_t pr_zoneid;      /* zone id */
 611           ctid_t pr_contract;      /* process contract id */
 612           lwpsinfo_t pr_lwp;       /* information for representative lwp */
 613       } psinfo_t;
 614 
 615      Some of the entries in psinfo, such as pr_addr, refer to internal kernel
 616      data structures and should not be expected to retain their meanings
 617      across different versions of the operating system.
 618 
 619      psinfo_t.pr_flag is a deprecated interface that should no longer be used.
 620      Applications currently relying on the SSYS bit in pr_flag should migrate
 621      to checking PR_ISSYS in the pstatus structure's pr_flags field.
 622 
 623      pr_pctcpu and pr_pctmem are 16-bit binary fractions in the range 0.0 to
 624      1.0 with the binary point to the right of the high-order bit (1.0 ==
 625      0x8000).  pr_pctcpu is the summation over all lwps in the process.
 626 
 627      The pr_fname and pr_psargs are writable by the owner of the process.  To
 628      write to them, the psinfo file should be open for writing and the desired
 629      value for the field should be written at the file offset that corresponds
 630      to the member of structure.  No other entry may be written to; if a write
 631      is attempted to an offset that does not represent one of these two
 632      memers, or if the size of the write is not exactly the size of the member
 633      being written, no bytes will be written and zero will be returned.
 634 
 635      pr_lwp contains the ps(1) information for the representative lwp.  If the
 636      process is a zombie, pr_nlwp, pr_nzomb, and pr_lwp.pr_lwpid are zero and
 637      the other fields of pr_lwp are undefined:
 638 
 639       typedef struct lwpsinfo {
 640           int pr_flag;             /* lwp flags (DEPRECATED: see below) */
 641           id_t pr_lwpid;           /* lwp id */
 642           uintptr_t pr_addr;       /* internal address of lwp */
 643           uintptr_t pr_wchan;      /* wait addr for sleeping lwp */
 644           char pr_stype;           /* synchronization event type */
 645           char pr_state;           /* numeric lwp state */
 646           char pr_sname;           /* printable character for pr_state */
 647           char pr_nice;            /* nice for cpu usage */
 648           short pr_syscall;        /* system call number (if in syscall) */
 649           char pr_oldpri;          /* pre-SVR4, low value is high priority */
 650           char pr_cpu;             /* pre-SVR4, cpu usage for scheduling */
 651           int pr_pri;              /* priority, high value = high priority */
 652           ushort_t pr_pctcpu;      /* % of recent cpu time used by this lwp */
 653           timestruc_t pr_start;    /* lwp start time, from the epoch */
 654           timestruc_t pr_time;     /* cpu time for this lwp */


 723               secflagset_t pr_inherit;        /* Inheritable flags */
 724               secflagset_t pr_lower;          /* Lower flags */
 725               secflagset_t pr_upper;          /* Upper flags */
 726       } prsecflags_t;
 727 
 728      The pr_version field is a version number for the structure, currently
 729      PRSECFLAGS_VERSION_1.
 730 
 731    sigact
 732      Contains an array of sigaction structures describing the current
 733      dispositions of all signals associated with the traced process (see
 734      sigaction(2)).  Signal numbers are displaced by 1 from array indices, so
 735      that the action for signal number n appears in position n-1 of the array.
 736 
 737    auxv
 738      Contains the initial values of the process's aux vector in an array of
 739      auxv_t structures (see <sys/auxv.h>).  The   values are those that were
 740      passed by the operating system as startup information to the dynamic
 741      linker.
 742 
 743    argv
 744      Contains the concatenation of each of the argument strings, including
 745      their NUL terminators, in the argument vector (argv) for the process.  If
 746      the process has modified either its argument vector, or the contents of
 747      any of the strings referenced by that vector, those changes will be
 748      visible here.
 749 
 750    ldt
 751      This file exists only on x86-based machines.  It is non-empty only if the
 752      process has established a local descriptor table (LDT).  If non-empty,
 753      the file contains the array of currently active LDT entries in an array
 754      of elements of type struct ssd, defined in <sys/sysi86.h>,   one element
 755      for each active LDT entry.
 756 
 757    map, xmap
 758      Contain information about the virtual address map of the process.  The
 759      map file contains an array of prmap structures while the xmap file
 760      contains an array of prxmap structures.  Each structure describes a
 761      contiguous virtual address region in the address space of the traced
 762      process:
 763 
 764       typedef struct prmap {
 765               uintptr_tpr_vaddr;         /* virtual address of mapping */
 766               size_t pr_size;            /* size of mapping in bytes */
 767               char pr_mapname[PRMAPSZ];  /* name in /proc/pid/object */
 768               offset_t pr_offset;        /* offset into mapped object, if any */
 769               int pr_mflags;             /* protection and attribute flags */


2092      /proc/pid/lstatus
2093              array of lwp status structs
2094      /proc/pid/psinfo
2095              process ps(1) info
2096      /proc/pid/lpsinfo
2097              array of lwp ps(1) info structs
2098      /proc/pid/map
2099              address space map
2100      /proc/pid/xmap
2101              extended address space map
2102      /proc/pid/rmap
2103              reserved address map
2104      /proc/pid/cred
2105              process credentials
2106      /proc/pid/priv
2107              process privileges
2108      /proc/pid/sigact
2109              process signal actions
2110      /proc/pid/auxv
2111              process aux vector
2112      /proc/pid/argv
2113              process argument vector
2114      /proc/pid/ldt
2115              process LDT (x86 only)
2116      /proc/pid/usage
2117              process usage
2118      /proc/pid/lusage
2119              array of lwp usage structs
2120      /proc/pid/path
2121              symbolic links to process open files
2122      /proc/pid/pagedata
2123              process page data
2124      /proc/pid/watch
2125              active watchpoints
2126      /proc/pid/cwd
2127              alias for the current working directory
2128      /proc/pid/root
2129              alias for the root directory
2130      /proc/pid/fd
2131              directory (list of open files)
2132      /proc/pid/fd/*
2133              aliases for process's open files