Process affinity. Number of cores
--- a/stat.rst Tue Jan 12 21:42:30 2016 +0200
+++ b/stat.rst Wed Jan 13 00:28:19 2016 +0200
@@ -24,6 +24,10 @@
$ ps -e -o pid,cmd
+View parent process id of selected process::
+
+ $ ps -p $PID -o ppid=
+
Show processes with same substring in command::
$ pgrep -f $SUBSTR
@@ -126,9 +130,24 @@
Linux static.
-------------
+
+Number of cores::
+
+ $ nproc
+
+Process affinity::
+
+ $ taskset -p $PID
+
::
$ ps -eo %cpu,pid,cmd --sort=%cpu
+ $ pidstat
+ $ mpstat
+
+CPU context switches::
+
+ $ pidstat -w
FreeBSD interactive.
--------------------