aboutsummaryrefslogtreecommitdiff
path: root/bin/ps
Commit message (Collapse)AuthorAgeFilesLines
* Fix spelling, as recommended by igor tool.Craig Rodrigues2015-12-011-1/+1
| | | | Notes: svn path=/head/; revision=291608
* Add more text to explain --libxo flag.Craig Rodrigues2015-12-011-1/+8
| | | | Notes: svn path=/head/; revision=291607
* Update dependencies after r291406 added libelf to libkvm.Bryan Drewery2015-12-011-0/+1
| | | | | | | | | | | Unfortunately filemon/meta mode tracks all indirect dependencies here since ld(1) is reading libelf when linking in libkvm. Churn would be reduced if this was able to be limited to direct dependencies. Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=291558
* Make libxo depend on libutil because it uses humanize_number after r287111Enji Cooper2015-10-181-1/+1
| | | | | | | | | | | Remove overlinking in lib/libxo/tests, sbin/savecore, and usr.bin/{iscsictl,wc,xo} PR: 203673 Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=289490
* Update META_MODE dependencies.Bryan Drewery2015-09-171-0/+1
| | | | Notes: svn path=/head/; revision=287905
* Upgrade libxo to 0.4.5.Marcel Moolenaar2015-08-241-1/+1
| | | | | | | | | | Local changes incorporated by 0.4.5: r284340 Local changes retained: r276260, r282117 Obtained from: https://github.com/Juniper/libxo Notes: svn path=/head/; revision=287111
* mdoc: minor Xr fixesJoel Dahl2015-07-141-2/+2
| | | | Notes: svn path=/head/; revision=285556
* Add META_MODE support.Simon J. Gerraty2015-06-131-0/+22
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | Off by default, build behaves normally. WITH_META_MODE we get auto objdir creation, the ability to start build from anywhere in the tree. Still need to add real targets under targets/ to build packages. Differential Revision: D2796 Reviewed by: brooks imp Notes: svn path=/head/; revision=284345
| * dirdeps.mk now sets DEP_RELDIRSimon J. Gerraty2015-06-081-2/+0
| | | | | | | | Notes: svn path=/projects/bmake/; revision=284172
| * Merge sync of headSimon J. Gerraty2015-05-277-177/+260
| |\ | | | | | | | | | Notes: svn path=/projects/bmake/; revision=283595
| * \ Merge from head@274682Simon J. Gerraty2014-11-192-2/+4
| |\ \ | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=274683
| * \ \ Merge head from 7/28Simon J. Gerraty2014-08-192-1/+15
| |\ \ \ | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=270164
| * | | | Updated dependenciesSimon J. Gerraty2014-05-161-1/+0
| | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=266219
| * | | | Updated dependenciesSimon J. Gerraty2014-05-101-0/+3
| | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265802
| * | | | Merge from headSimon J. Gerraty2014-05-083-7/+62
| |\ \ \ \ | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265720
| * \ \ \ \ Merge headSimon J. Gerraty2014-04-282-10/+5
| |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=265044
| * \ \ \ \ \ Merge from headSimon J. Gerraty2013-09-052-0/+4
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=255263
| * \ \ \ \ \ \ sync from headSimon J. Gerraty2013-04-121-1/+5
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=249429
| * | | | | | | | Updated dependenciesSimon J. Gerraty2013-03-111-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=248169
| * | | | | | | | Updated dependenciesSimon J. Gerraty2013-02-161-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=246868
| * | | | | | | | Sync with HEAD.David E. O'Brien2013-02-084-14/+35
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=246555
| * \ \ \ \ \ \ \ \ Sync from headSimon J. Gerraty2012-11-044-7/+15
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/projects/bmake/; revision=242545
| * | | | | | | | | | Sync FreeBSD's bmake branch with Juniper's internal bmake branch.Marcel Moolenaar2012-08-221-0/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Requested by: Simon Gerraty <sjg@juniper.net> Notes: svn path=/projects/bmake/; revision=239572
* | | | | | | | | | | Remove unused variable, this variable fmtstr was introduced at revision r225868Marcelo Araujo2015-06-011-6/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | and it is not used anymore after the convertion to use libxo at revision r283304. Differential Revision: D2678 Reviewed by: marcel Notes: svn path=/head/; revision=283867
* | | | | | | | | | | Document recent p_flag2 additions.Sergey Kandaurov2015-05-271-1/+4
| |_|_|_|_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Notes: svn path=/head/; revision=283606
* | | | | | | | | | Convert to use libxo. Document use of libxo as well.Marcel Moolenaar2015-05-226-166/+253
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Obtained from: Phil Shafer <phil@juniper.net> Sponsored by: Juniper Networks, Inc. Notes: svn path=/head/; revision=283304
* | | | | | | | | | Use 24h timestamps in the ps(1) STARTED columnMark Felder2015-03-172-9/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The previous 12h AM/PM format was perplexing as it didn't follow the locale of the user and was a minor annoyance to FreeBSD users coming from Linux. Additionally, the man page was incorrect about the strftime format. There are three time formats that may be displayed in the STARTED column depending on the age of the process. Below is an example. For a process started at 14:30 on Monday 16 March 2015, the following formats may be used: 14:30 for process < 24h old (24h Timestamp) Mon14 for process > 24h, < 1 week old (Weekday Hour) 16Mar15 for process > 1 week old (Day Month Year) Differential Revision: https://reviews.freebsd.org/D1620 Reviewed by: brd Approved by: trasz Notes: svn path=/head/; revision=280171
* | | | | | | | | | Prevent access to an uninitialized variablePedro F. Giffuni2015-01-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The "-h" option may access an uninitialized value. Prevent it by properly initializing the value. CID: 1006559 Notes: svn path=/head/; revision=277979
* | | | | | | | | | Add facility to stop all userspace processes. The supposed use of theKonstantin Belousov2014-12-131-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | feature is to quisce the system before suspend. Stop is implemented by reusing the thread_single(9) with the special mode SINGLE_ALLPROC. SINGLE_ALLPROC differs from the existing single-threading modes by allowing (requiring) caller to operate on other process. Interruptible sleeps for !TDF_SBDRY threads are suspended like SIGSTOP does it, instead of aborting the sleep, like SINGLE_NO_EXIT, to avoid spurious EINTRs on resume. Provide debugging sysctl debug.stop_all_proc, which causes total stop and suspends syncer, while waiting for variable reset for resume. It is used for debugging; should be removed after the real use of the interface is added. In collaboration with: pho Discussed with: avg Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Notes: svn path=/head/; revision=275745
* | | | | | | | | | Convert bin/ to LIBADD, reduce overlinking allow to build all components asBaptiste Daroussin2014-11-251-2/+1
| |_|_|_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | static Notes: svn path=/head/; revision=275028
* | | | | | | | | Return real parent pid in kinfo (used by e.g. ps)Mateusz Guzik2014-08-282-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a separate field which exports tracer pid and add a new keyword ("tracer") for ps to display it. This is a follow up to r270444. Reviewed by: kib MFC after: 1 week Relnotes: yes Notes: svn path=/head/; revision=270745
* | | | | | | | | Correct the problems with the ptrace(2) making the debuggee an orphan.Konstantin Belousov2014-08-071-2/+1
| |_|_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | One problem is inferior(9) looping due to the process tree becoming a graph instead of tree if the parent is traced by child. Another issue is due to the use of p_oppid to restore the original parent/child relationship, because real parent could already exited and its pid reused (noted by mjg). Add the function proc_realparent(9), which calculates the parent for given process. It uses the flag P_TREE_FIRST_ORPHAN to detect the head element of the p_orphan list and than stepping back to its container to find the parent process. If the parent has already exited, the init(8) is returned. Move the P_ORPHAN and the new helper flag from the p_flag* to new p_treeflag field of struct proc, which is protected by proctree lock instead of proc lock, since the orphans relationship is managed under the proctree_lock already. The remaining uses of p_oppid in ptrace(PT_DETACH) and process reapping are replaced by proc_realparent(9). Phabric: D417 Reviewed by: jhb Tested by: pho Sponsored by: The FreeBSD Foundation MFC after: 2 weeks Notes: svn path=/head/; revision=269656
* | | | | | | | Add support for inspecting process flags set in p_flag2.Sergey Kandaurov2014-06-062-1/+15
| |_|_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reviewed by: jhb MFC after: 1 week Notes: svn path=/head/; revision=267196
* | | | | | | Add -J to filter by matching jail IDs and names.Bryan Drewery2014-05-023-7/+62
| |_|_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | -J 0 can be used to show only host processes. Patch partially based on work by bz@ PR: bin/78763 MFC after: 2 weeks Relnotes: yes Notes: svn path=/head/; revision=265229
* | | | | | Correct the description of the V state, which indicates that the process'Mark Johnston2013-12-281-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | parent is suspended, not the process itself. MFC after: 3 days Notes: svn path=/head/; revision=259995
* | | | | | Don't test arrays for being NULL.Edward Tomasz Napierala2013-10-211-7/+1
| |_|_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | MFC after: 1 month Notes: svn path=/head/; revision=256838
* | | | | Add the ability to display the default FIB number for a process to theWill Andrews2013-08-262-0/+4
| |_|_|/ |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ps(1) utility, e.g. "ps -O fib". bin/ps/keyword.c: Add the "fib" keyword and default its column name to "FIB". bin/ps/ps.1: Add "fib" as a supported keyword. sys/compat/freebsd32/freebsd32.h: sys/kern/kern_proc.c: sys/sys/user.h: Add the default fib number for a process (p->p_fibnum) to the user land accessible process data of struct kinfo_proc. Submitted by: Oliver Fromme <olli@fromme.com>, gibbs Notes: svn path=/head/; revision=254943
* | | | Add a few examples.Joel Dahl2013-03-151-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Obtained from: OpenBSD Notes: svn path=/head/; revision=248342
* | | | Document P_PPTRACE.Konstantin Belousov2013-02-071-1/+2
| |_|/ |/| | | | | | | | | | | | | | | | | MFC after: 2 weeks Notes: svn path=/head/; revision=246486
* | | - Move 'showthreads' check out of fmt.c.John Baldwin2013-01-192-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | - Update shadow copy of fmt_argv() prototype in w.c and fix calls for additional parameter. Notes: svn path=/head/; revision=245635
* | | Include the thread name along with the command name when displaying theJohn Baldwin2013-01-183-10/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | command name of a thread from a multi-threaded process that doesn't have an available argument list (such as kernel processes) and threads display is enabled via -H. Reviewed by: alfred, delphij, eric@vangyzen.net MFC after: 1 week Notes: svn path=/head/; revision=245610
* | | Use kern.max_pid sysctl to obtain maximum PID number instead of using localPawel Jakub Dawidek2012-12-121-3/+17
| |/ |/| | | | | | | | | | | | | | | define. Reviewed by: jhb Notes: svn path=/head/; revision=244154
* | - Bump date.Andrey Zonov2012-09-181-1/+1
| | | | | | | | | | | | | | | | | | Submitted by: pluknet Approved by: kib (mentor) X-MFC-With: r240645 Notes: svn path=/head/; revision=240649
* | - Add 'dsiz' and 'ssiz' keywords to show data and stack size respectively.Andrey Zonov2012-09-182-0/+6
| | | | | | | | | | | | | | | | Approved by: kib (mentor) MFC after: 1 week Notes: svn path=/head/; revision=240645
* | Avoid passing uninitialized stack to addelem() if called with an empty arg.Ed Maste2012-08-291-2/+2
| | | | | | | | | | | | | | PR: bin/171174 Notes: svn path=/head/; revision=239883
* | ps: Fix memory leak when showing start/lstart for swapped-out process.Jilles Tjoelker2012-07-151-4/+6
|/ | | | | | | Spotted by: scan-build (uqs) Notes: svn path=/head/; revision=238488
* Add 'cow' keyword to show per-process cow count.Konstantin Belousov2012-05-232-1/+4
| | | | | | | | Submitted by: Andrey Zonov <andrey zonov org> MFC after: 1 week Notes: svn path=/head/; revision=235851
* mandoc complains loudly when <TAB>s are misused in columnated lists. FixJoel Dahl2012-03-291-31/+31
| | | | | | | | this syntax violation and while I'm here also convert <TAB> to Ta and adjust quotation marks in order to prevent this problem in the future. Notes: svn path=/head/; revision=233665
* Document P_ORPHAN.Konstantin Belousov2012-03-081-1/+2
| | | | | | | MFC after: 3 days Notes: svn path=/head/; revision=232694
* Remove unused variables.Ed Schouten2012-01-171-96/+30
| | | | | | | | Simply annotate the function parameters with __unused, instead of adding the ve-variables. This makes the code build with GCC 4.7 and -Werror. Notes: svn path=/head/; revision=230287