{"id":3451,"date":"2014-08-16T17:14:11","date_gmt":"2014-08-16T09:14:11","guid":{"rendered":"http:\/\/rmohan.com\/?p=3451"},"modified":"2014-08-16T17:34:29","modified_gmt":"2014-08-16T09:34:29","slug":"linux-troubleshooting-commands","status":"publish","type":"post","link":"https:\/\/mohan.sg\/?p=3451","title":{"rendered":"Linux Troubleshooting Commands"},"content":{"rendered":"<p>Biggest 10 Files<br \/>\ndu -sh * | sort -n | tail<br \/>\ndu -x -a . | sort -n -r | head -n 10<\/p>\n<p>List All the Process By memory usage<br \/>\nps -e -orss=,args= | sort -b -k1,1n | pr -TW$COLUMNS<br \/>\nps -eo pcpu,pid,user,args | sort -k 1 -r | head -10<br \/>\nps -eo pcpu,pid,user,args | sort -r -k1 | less<\/p>\n<p>find how many files an application is using<br \/>\nlsof +c 0 | cut -d&#8217; &#8216; -f1 | sort | uniq \u2013c<\/p>\n<p>Highest CPU Usage<br \/>\nps -eo pcpu,pid,user,args | sort -k 1 -r | head -10 | awk &#8220;{ print $2 }&#8221;<\/p>\n<p>Total Memory Usage<br \/>\nsar -q 1 | tail -1 | awk &#8216;{ print &#8220;&#8221; $3}&#8217; | sed &#8216;s\/%\/\/g&#8217;<\/p>\n<p>CPU Threshold<br \/>\ntop -b -n 1 | awk -F'[:,]&#8217; &#8216;\/^Cpu\/{sub(&#8220;\\\\..*&#8221;,&#8221;&#8221;,$2); print $2}&#8217;<\/p>\n<p>Current User With Session Count<br \/>\nwho | awk &#8216;{ User [$1]++; } END { for (i in User) printf &#8220;%-9s %s\\n&#8221;, i, User [i] }&#8217;<\/p>\n<p>Memory Details<br \/>\nfree -t -m | grep &#8220;Total&#8221; | awk &#8216;{ print &#8220;Total Memory space : &#8220;$2 &#8221; MB&#8221;;<br \/>\nprint &#8220;Used Memory Space : &#8220;$3&#8243; MB&#8221;;<br \/>\nprint &#8220;Free Memory : &#8220;$4&#8243; MB&#8221;;<br \/>\n}&#8217;<\/p>\n<p>Swap memory Details<br \/>\nfree -t -m | grep &#8220;Swap&#8221; | awk &#8216;{ print &#8220;Total Swap space : &#8220;$2 &#8221; MB&#8221;;<br \/>\nprint &#8220;Used Swap Space : &#8220;$3&#8243; MB&#8221;;<br \/>\nprint &#8220;Free Swap : &#8220;$4&#8243; MB&#8221;;<br \/>\n}&#8217;<\/p>\n<p>Process Using memory<br \/>\nps aux | awk &#8216;{if ($5 != 0 ) print $2,$5,$6,$11}&#8217; | sort -k2n<\/p>\n<p>Largest File Or Directory<br \/>\ndu -sk \/var\/log\/* | sort -r -n | head -10<\/p>\n<p>Processes Count Used By Users<br \/>\nps hax -o user | sort | uniq -c<\/p>\n<p>Who Started this Process<br \/>\nps -o comm= -p $(ps -o ppid= -p PID)<\/p>\n<p>How Much Ram Is Being Used<br \/>\nps -o rss -C java | tail -n +2 | (sed &#8216;s\/^\/x+=\/&#8217;; echo x) | bc<\/p>\n<p>When Was the Process Started<br \/>\nps -o lstart PID<\/p>\n<p>Environment Variables belong to a Process<br \/>\nps ewwo command PID | tr &#8216; &#8216; &#8216;\\n&#8217; | grep \\=<\/p>\n<p>List Threads by Pid along with Thread Start Time<br \/>\nps -o pid,lwp,lstart &#8211;pid PID -L<\/p>\n<p>CPU usage for EACH cores<br \/>\nps ax -L -o pid,tid,psr,pcpu,args | sort -nr -k4| head -15 | cut -c 1-90<\/p>\n<p>Memory Percentage Usage of a Process<br \/>\nps -o comm,%mem,args PID<\/p>\n<p>Total CPU Usage Percentage<br \/>\nps aux | awk {&#8216;sum+=$3;print sum&#8217;} | tail -n 1<\/p>\n<p>Find Class Files inSide the Jar Location<br \/>\nfind . -iname &#8216;*.jar&#8217; -printf &#8220;unzip -c %p | grep -q &#8216;sample Text&#8217; &#038;&#038; echo %p\\n&#8221; | sh<\/p>\n<p>Find the Class File in jars<br \/>\nfind . -name &#8220;*.jar&#8221; | while read line; do unzip -l $line; done | grep<\/p>\n<p>Search The File From Multiple Jar Files<br \/>\nfind . -name &#8220;*.jar&#8221; | xargs -tn1 jar tvf | grep &#8211;color &#8220;log4j.xml&#8221;<\/p>\n<p>List of Files That Are Open For Writing to Disk<br \/>\nlsof | grep -e &#8220;[[:digit:]]\\+w&#8221;<\/p>\n<p>See which Process is Holding the File<br \/>\nlsof -r1 \/common\/jboss.log<\/p>\n<p>List the files accessed by a program<br \/>\nstrace -f -o foo.trace su user -c &#8216;mycommand&#8217;?<\/p>\n<p>get size of data that haven&#8217;t been written to disk yet<br \/>\nThe term for that is &#8220;dirty&#8221; data (data that has been changed, but not yet flushed to permanent storage).<br \/>\ncat \/proc\/meminfo | grep Dirty<br \/>\nDirty : 188 kB<\/p>\n<p>Owner of the File<br \/>\n\/sbin\/fuser admin.lok<br \/>\nadmin.lok: 5912<br \/>\nPmap Output In Kilo Bytes<br \/>\npmap -x PID | awk &#8216;\/\\[ anon \\]\/ {total += $3} END {print total}&#8217;<\/p>\n<p>determine which application is utilizing a certain port?<br \/>\nlsof -w -n -i tcp:80 ( or any Othe Port)<br \/>\nStart Number of active, and recently torn down TCP sessions<br \/>\nnetstat -ant | egrep -i &#8216;(ESTABLISHED|WAIT|CLOSING)&#8217; | wc -l<\/p>\n<p>Number of sessions waiting for ACK (SYN Flood)<br \/>\nnetstat -ant | egrep -i &#8216;(SYN)&#8217; | wc -l<br \/>\nFind Network Connections<br \/>\nOut Going Going Connections<br \/>\nlocalhost:root002-~ $ lsof | grep omdx1971<br \/>\njava 1142 dwls977 924u IPv6 141719124 0t0 TCP localMachine :27710->eth0.remoteMachine.nova.com:54426 (ESTABLISHED)<\/p>\n<p>java 1142 dwls977 925u IPv6 141713891 0t0 TCP localMachine :27710->eth0.remoteMachine.nova.com:54141 (ESTABLISHED)<\/p>\n<p>Incoming Connections<br \/>\nOnce you got the Out Going Connections , we can get the Port and try it on the local machine to find the connection information<\/p>\n<p>remoteMachine:root002-~ $ netstat | grep 54426<br \/>\ntcp 0 0 localMachine :54426 eth0.remoteMachine.nova.co:27710 ESTABLISHED<br \/>\nAll Outgoing Connections<br \/>\nnetstat -an | grep -i tcp | grep ESTABLISHED | less<br \/>\ntalk to Other over the Network<br \/>\nDev:vx1379:djbs002-~ $ lsof -p 29118 -a -i ( Process Talk)<br \/>\nshow the number of connections active to a port and also the number of connections from that ip in order<br \/>\nnetstat -ntu | awk &#8216;{print $5}&#8217; | cut -d: -f1 | sort | uniq -c | sort -n<br \/>\nList listening TCP sockets<br \/>\nnetstat -ant | egrep -i &#8216;(LISTEN)&#8217;<br \/>\nList Per User Process<br \/>\nps -e -o uid,vsz | awk &#8216;{ usage[$1] += $2 } END { for (uid in usage) { print uid, &#8220;:&#8221;, usage[uid] } }&#8217;<br \/>\nWorking Directory of a Running process<br \/>\nlsof -bw -d cwd -a -c java<br \/>\nExtract files from war\/Ear<br \/>\njar xf abc.war log4j-test.xml WEB-INF\/<br \/>\nAll Connections from a Specific process<br \/>\nlsof -p PID -a -i<br \/>\nScan a port On a Remote Machine<br \/>\nnc -v -w 1 -z<br \/>\nShow The Java Process<br \/>\ntop -b -n 1|grep java|wc -l<br \/>\nSmallest To biggest<br \/>\nls -s | sort -nr | more<br \/>\nFind Files That Exceed a Specified Size Limit<br \/>\nfind . -size +400 -print<br \/>\nGrep All Files Of A Certain File Type For A Specific Pattern<br \/>\nfind . -type f -name &#8216;*.cs&#8217; -print0 | xargs -0 grep &#8211;color=always -n PATTERN<\/p>\n<p>Zero Length File Sizes<br \/>\nfind . -type f -size 0k -exec rm {} \\; | awk &#8216;{ print $8 }&#8217;<br \/>\nFind and Kill a Process<br \/>\nps ux | grep | grep \u2013v grep | awk \u2018{print $2}\u2019 | xargs \u2013r kill -9<br \/>\nFiles Opened By a Process<br \/>\nlsof +f | grep PID<br \/>\nFind The Command Line Of the Process Using Specific Port<br \/>\ncat \/proc\/$(lsof -ti:)\/cmdline<br \/>\nAll Open Tomcat Threads<br \/>\nps -ALcf | grep org.apache.catalina.startup.Bootstrap | wc -l<\/p>\n<p>Find The MAC Address<br \/>\n[root@vx111a test]# cat \/sys\/class\/net\/eth0\/address<\/p>\n<p>List all the Installed Perl packages<br \/>\nperl -MFile::Find=find -MFile::Spec::Functions -Tlwe &#8216;find { wanted => sub { print canonpath $_ if \/\\.pm\\z\/ }, no_chdir => 1 }, @INC&#8217;<br \/>\nFind Whether a Port is Open On a Remote Machine<br \/>\nnmap -p<br \/>\nStatus Of the HTTP<br \/>\ncurl -o \/dev\/null &#8211;silent &#8211;head &#8211;write-out &#8216;%{http_code}\\n&#8217;<br \/>\n200<br \/>\n-o \/dev\/null throws away the usual output<br \/>\n-silent throws away the progress meter<br \/>\n-head makes a HEAD HTTP request, instead of GET<br \/>\n-write-out &#8216;%{http_code}\\n&#8217; prints the required status code<br \/>\nFind Whether The Process is 32Bit or 64Bit<br \/>\nfile -L \/proc\/PID\/exe<\/p>\n<p>The Output would be some thing like this<br \/>\n\/proc\/6462\/exe: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU\/Linux 2.2.5, dynamically linked (uses shared libs), not stripped<br \/>\nConvert Of Bytes to Mbs<br \/>\nunits &#8211;terse &#8220;3415014314 bytes&#8221; &#8220;MB&#8221;<\/p>\n<p>SSh and Execute a Command<br \/>\nssh root@ -q &#8216;echo $MYDIR\u2019<br \/>\nFind out what is listening on a series of ports<br \/>\n\/sbin\/fuser -n tcp {7000..8000}<br \/>\nView details of network activity between<br \/>\nlsof -i :7000-8000<br \/>\nList all files opened by a particular command<br \/>\nlsof -c java<br \/>\nList Threads By PID along with Thread Start Time<br \/>\nps -o lwp,lstart &#8211;pid PID<\/p>\n<p>Count Threads OF a Process<br \/>\nps uH -p PID | wc \u2013l<\/p>\n<p>Print a stack trace of a running process<br \/>\nPstack PID<br \/>\nReturn Number of kernel Threads Owned by a process<br \/>\nps -o thcount \u2013p PID<br \/>\nShow Ports that belong to this PID<br \/>\nnetstat &#8211;all &#8211;program | grep PID<\/p>\n<p>Drop all the Connections available now for a Port<br \/>\niptables -I INPUT -p tcp -dport 80 -j DROP<\/p>\n<p>Find and Grep a File<br \/>\nfind $PWD -type f -exec egrep PAVAN {} \\;<\/p>\n<p>Find the Time took Process To Complete<br \/>\n\/usr\/bin\/time -v<\/p>\n<p>Memory Information ( Much Better than Free Command)<br \/>\nvmstat -s -S M<br \/>\nList all the Jars loaded by a Process<br \/>\nlsof -p PID | grep jar<\/p>\n<p>All process Running as a Specific User<br \/>\npgrep -l -f -x -u root<br \/>\nFind and Remove Files Matching a pattern<br \/>\nfind $PWD -type f -name &#8220;*Jul-*.ESS-A1.log&#8221; -exec rm -f {} \\;<\/p>\n<p>Find and Zip files matching a Pattern<br \/>\nfind $PWD \u2013type f \u2013name \u201cess_admin.controllermessages.log.\u201d | xargs tar zcvf one.tar<\/p>\n<p>How to list all unique ip address currently connected to a specific port<br \/>\nss -o state established &#8216;( dport = :10012 )&#8217;|awk -F&#8221;[\\t :]+&#8221; &#8216;NR!=1{ ip[$5]+=1 } END{ for (i in ip){n++};print n }&#8217;<\/p>\n<p>Find and Gzip<br \/>\nfind $PWD \u2013type f \u2013name \u201c*.log\u201d | xargs tar zcvf one.tar<\/p>\n<p>Find and Remove<br \/>\nfind \u2013type f \u2013name \u201c*.log\u201d | xargs rm<br \/>\nfind \u2013type f \u2013name \u201c*.log\u201d -exec rm -f {} \\;<\/p>\n<p>Find Files That are Updated in The Last 60 Minutes<br \/>\nfind $PWD -mmin -60<\/p>\n<p>Find all files Older than 2 days and gzip them<br \/>\nfind $PWD -type f -mtime +2 | xargs gzip<\/p>\n<p>How many Open Tomcat Threads<br \/>\nps -ALcf | grep org.apache.catalina.startup.Bootstrap | wc -l<\/p>\n<p>Differences between 2 files in remote hosts<br \/>\ndiff <(ssh alice cat \/etc\/apt\/sources.list) <(ssh bob cat \/etc\/apt\/sources.list)\n\nMonitor the active thread count of a process (jvm) on linux\nps uH -p 10343 | wc -l\n\nHow do I find out which service is listening on a specific port?\nlsof -Pnl +M -i4 ( IP 4 )\nlsof -Pnl +M -i6 ( IP 6 )\nnetstat -npl\n\nDisplay CPU,Memory Usages of the Users\nps axo user,pcpu,pmem,rss --no-heading | awk '{pCPU[$1]+=$2; pMEM[$1]+=$3; sRSS[$1]+=$4} END {for (user in pCPU) if (pCPU[user]>0 || sRSS[user]>10240) printf &#8220;%s:@%.1f%% of total CPU,@%.1f%% of total MEM@(%.2f GiB used)\\n&#8221;, user, pCPU[user], pMEM[user], sRSS[user]\/1024\/1024}&#8217; | column -ts@ | sort -rnk2<br \/>\nKill a Process on the Port<br \/>\nkill -9 `lsof -t -i :port_number`<br \/>\nHow Many Established Connection<br \/>\nlsof | grep -c &#8220;(ESTABLISHED)&#8221;<br \/>\nHow to enlarge existing file to specific size<br \/>\ndd if=\/dev\/zero bs=1 seek=new_filesize count=0 of=your_file<br \/>\nFor example this:<br \/>\ndd if=\/dev\/zero bs=1G seek=1000 count=0 of=test<br \/>\nwill enlarge file test to 1000G<br \/>\nTail the Last Bytes of Files<br \/>\ntail -c 400 jboss.log > jboss.log11<br \/>\nDeleted Files along with File Descriptor(FD)<br \/>\nlsof | awk &#8216;(\/deleted\/) {print &#8220;FD :-&#8220;,$4,&#8221;| File Name:-&#8220;,$9}&#8217;<br \/>\nCheck the Files For Changes From the last 1 Hour<br \/>\nawk -vDate=`date -d&#8217;now-1 hours&#8217; +[%d\/%b\/%Y:%H:%M:%S` &#8216; { if ($4 > Date) print Date FS $4}&#8217;<br \/>\nThreads in a Process<br \/>\nps -eLo pid,ppid,tid,pcpu,comm | grep PID<br \/>\nGrep Multiple Words<br \/>\ngrep -w &#8216;warning\\|error\\|critical&#8217; \/var\/log\/messages<br \/>\nFind Out What Partition a File Belongs To<br \/>\nWe can use the df command to find out what partition a file belongs,<\/p>\n<p>[root@vx111a perl]# df -T file1<br \/>\nFilesystem Type 1K-blocks Used Available Use% Mounted on<br \/>\n\/dev\/sda7 ext3 49594196 5499736 41534504 12% \/soa<br \/>\nFind Out Port<br \/>\n\/sbin\/fuser 10011\/tcp<br \/>\n10011\/tcp: 32506<\/p>\n<p>lsof -i tcp:10012<br \/>\nCOMMAND PID USER FD TYPE DEVICE SIZE\/OFF NODE NAME<br \/>\njava 32506 jbs002 67u IPv6 20552857 0t0 TCP *:10012 (LISTEN)<br \/>\nThread Ids of a process in Linux using Proc<br \/>\ncat \/proc\/PID\/task<\/p>\n<p>How To Find The Number Of Open Files for a Process Name and process pid sorted by number of open files.?<br \/>\nlsof | perl -lane &#8216;$x{&#8220;$F[0]:$F[1]&#8221;}++;END { print &#8220;$x{$_}\\t$_&#8221; for sort {$x{$a}<=>$x{$b}} keys %x}&#8217;<br \/>\nTo show connections to a specific host<br \/>\nlsof -i@192.168.1.5<\/p>\n<p>Show connections based on the host and the port using @host:port<br \/>\nlsof -i@192.168.1.5:22<br \/>\nlsof -i@eth0.omhq111a.nova.com<\/p>\n<p>Grep All Files Of A Certain File Type For A Specific Pattern<br \/>\nfind . -type f -name &#8216;*.*&#8217; -print0 | xargs -0 grep &#8211;color=always -n GCMonitor<\/p>\n<p>Top 20 Process With High File Descriptors<br \/>\nfor x in `ps -eF| awk &#8216;{ print $2 }&#8217;`;do echo `ls \/proc\/$x\/fd 2> \/dev\/null | wc -l` $x `cat \/proc\/$x\/cmdline 2> \/dev\/null`;done | sort -n -r | head -n 20<\/p>\n<p>Ping a URL to Find the HTTP Status<br \/>\nDev:Hunter@root-~ $ printf &#8220;GET \/ HTTP\/1.0\\r\\nvx111a: www\\r\\n\\r\\n&#8221; | nc vx111a 10011 | head<br \/>\nHTTP\/1.1 200 OK<br \/>\nServer: Apache-Coyote\/1.1<br \/>\nSet-Cookie: JSESSIONID=291DBACCB3596F4FBC38ABFBDE99AA7C.jasB2; Path=\/<br \/>\nETag: W\/&#8221;7857-1235874240000&#8243;<br \/>\nLast-Modified: Sun, 01 Mar 2009 02:24:00 GMT<br \/>\nContent-Type: text\/html<br \/>\nContent-Length: 7857<br \/>\nDate: Thu, 10 Oct 2013 02:33:39 GMT<br \/>\nConnection: close<\/p>\n<p>Dev:Hunter@root-~ $ nc -zw2 vx111a 10011 || echo http service is down<br \/>\nConnection to vx111a 10011 port [tcp\/*] succeeded!<\/p>\n<p>Dev:Hunter@root-~ $ curl -sL -w &#8220;%{http_code}\\\\n&#8221; &#8220;http:\/\/vx111a:10011\/wls_monitor\/&#8221; -o \/dev\/null<br \/>\n200<\/p>\n<p>Redirect and Print<br \/>\nDev:vx111a:jbs002-~ $ jmap -heap 922 2>\/dev\/null | grep MaxPermSize | awk &#8216;{print $3}&#8217;<br \/>\n268435456<\/p>\n<p>The 2>\/dev\/null at the end of the find command tells your shell to redirect the error messages (FD #2) to \/dev\/null, so you don&#8217;t have to see them on screen. Use \/dev\/null to to send any unwanted output from program\/command. All data written on a \/dev\/null special file is discarded by the system. To redirect standard error to \/dev\/null and store file list to output.txt, type:<\/p>\n<p>Find Who is Using Port<br \/>\nDev:vx111a:djbs002-~ $ \/sbin\/fuser 10011\/tcp<br \/>\n10011\/tcp: 32506<\/p>\n<p>Dev:vx111a:djbs002-~ $ lsof -i tcp:10012<br \/>\nCOMMAND PID USER FD TYPE DEVICE SIZE\/OFF NODE NAME<br \/>\njava 32506 djbs002 67u IPv6 20552857 0t0 TCP *:10012 (LISTEN)<\/p>\n<p>Search For Out Of memory<br \/>\nfind . -type f -exec grep -l java.lang.OutOfMemoryError {} \\;<br \/>\n.\/MANDY-B1_gc.log<br \/>\n.\/heap.log<br \/>\n.\/MANDY -B1.log.yyyyMMdd_HHmmss<\/p>\n<p>Conenct to the Linux Machine From windows Machine to Download Files<br \/>\npscp -i C:\\Ateam_uberkey.ppk jbs002@vx111a:\/tmp\/top.log C:\\Users\\Jag\\Desktop\\temp\\top.log<\/p>\n<p>Note : pscp is available with putty Software which is free to download<\/p>\n<p>Obtain the Number of Thread States in a Thread Dump<br \/>\ndev:vx1abc:he002:nc-Dumps $ awk &#8216;\/State: \/ { print }&#8217; < td.log.073716.013908855 | sort | uniq -c\n   10    java.lang.Thread.State: RUNNABLE\n    8    java.lang.Thread.State: TIMED_WAITING (on object monitor)\n    2    java.lang.Thread.State: TIMED_WAITING (sleeping)\n    2    java.lang.Thread.State: WAITING (on object monitor)\n   24    java.lang.Thread.State: WAITING (parking)\n\nObtain the Count of Threads based on Thread State\ndev:vx1cea:djhe002:nc-stackDetils $ awk '\/State: TIMED_WAITING\/ { getline; print }' < td.2013-10-17-03.log | sort | uniq -c\n   50         at java.lang.Object.wait(Native Method)\n   15         at java.lang.Thread.sleep(Native Method)\n    5         at sun.misc.Unsafe.park(Native Method)\n\nGrep Multiple Strings \ngrep 'RUNNABLE\\|ListenPort\\|port\\|clusters\\|broadcastchannel\\|multicastaddress\\|multicastport\\|server_cluster'  td.log.073652.957462762\n\nNumber of Connection Hits in between\nDev:vx1322:jbs002-JAS-A2 $ egrep \"2013-08-09 16:47:12|2013-08-09 16:50:00\" jboss.log  | wc -l\n3\n\nHow many Requests Happened Per Minutes\negrep \"17\/Aug\/2013:01|17\/Aug\/2013:02\" PHYRES-H1_access.log | cut -d[ -f2 | cut -d] -f1 | awk -F: '{print $2\":\"$3}' | sort -nk1 -nk2 | uniq -c | sed 's\/[ ]*\/\/'\n\nQuery packages\ndev:vx1abc:he002:nc-~ $ rpm -q --queryformat '\\n%{NAME} %{VERSION} %{RELEASE} %{ARCH}\\n' glibc\nglibc 2.12 1.80.el6_3.6 x86_64\nglibc 2.12 1.80.el6_3.6 i686\n\nProcessor and Memory Usage Per User\nps axo user,pcpu,pmem,rss --no-heading | awk '{pCPU[$1]+=$2; pMEM[$1]+=$3; sRSS[$1]+=$4} END {for (user in pCPU) if (pCPU[user]>0 || sRSS[user]>10240) printf &#8220;%s:@%.1f%% of total CPU,@%.1f%% of total MEM@(%.2f GiB used)\\n&#8221;, user, pCPU[user], pMEM[user], sRSS[user]\/1024\/1024}&#8217; | column -ts@ | sort -rnk2<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Biggest 10 Files du -sh * | sort -n | tail du -x -a . | sort -n -r | head -n 10<\/p>\n<p>List All the Process By memory usage ps -e -orss=,args= | sort -b -k1,1n | pr -TW$COLUMNS ps -eo pcpu,pid,user,args | sort -k 1 -r | head -10 ps -eo pcpu,pid,user,args | [&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4,17],"tags":[],"_links":{"self":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/3451"}],"collection":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3451"}],"version-history":[{"count":1,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/3451\/revisions"}],"predecessor-version":[{"id":3452,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/3451\/revisions\/3452"}],"wp:attachment":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3451"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3451"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3451"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}