Calculation of various attributes in MACOS server

Calculation of various attributes in MACOS server

Memory Utilization

Command: export UNIX95;top -l 1 -n 2

Sample Output:

Processes: 154 total, 2 running, 152 sleeping, 600 threads 
2020/03/04 14:49:04
Load Avg: 1.46, 1.60, 1.62 
CPU usage: 5.40% user, 8.10% sys, 86.48% idle 
SharedLibs: 202M resident, 36M data, 66M linkedit.
MemRegions: 16554 total, 3609M resident, 62M private, 234M shared.
PhysMem: 7654M used (1487M wired), 8724M unused.
VM: 450G vsize, 628M framework vsize, 0(0) swapins, 0(0) swapouts.
Networks: packets: 3223883599/296G in, 34349821/5288M out.
Disks: 470249/12G read, 8365543/124G written.

PID    COMMAND          %CPU TIME     #TH #WQ #PORTS MEM   PURG CMPRS PGRP  PPID STATE    BOOSTS  %CPU_ME %CPU_OTHRS UID FAULTS   COW    MSGSENT MSGRECV SYSBSD   SYSMACH  CSW      PAGEINS IDLEW POWER USER            #MREGS RPRVT VPRVT VSIZE KPRVT KSHRD
99828  softwareupdated  0.0  09:01.66 4   1   299+   83M+  0B   0B    99828 1    sleeping *0[75+] 0.00000 0.00000    200 1049831+ 15334+ 624920+ 315452+ 4440001+ 1191029+ 1241953+ 1+      2834  0.0   _softwareupdate N/A    N/A   N/A   N/A   N/A   N/A  
77924  periodic-wrapper 0.0  00:00.01 2   2   25+    496K+ 0B   0B    77924 1    sleeping *0[1+]  0.00000 0.00000    0   492+     86+    143+    72+     621+     343+     628+     0       14    0.0   root            N/A    N/A   N/A   N/A   N/A   N/A  

Disk Utilization

Command: /bin/df -lm

Sample Output:

Filesystem   1M-blocks  Used Available Capacity iused      ifree %iused  Mounted on
/dev/disk0s2    476282 36496    439535     8% 1087492 4293879787    0%   /

CPU Utilization

Command: export UNIX95;top -l 3 -n 1|grep 'CPU usage:'

Sample Output:
CPU usage: 2.85% user, 11.42% sys, 85.71% idle 
CPU usage: 1.78% user, 1.43% sys, 96.78% idle 
CPU usage: 0.61% user, 1.60% sys, 97.77% idle 

Process

Command: /bin/ps -axwwwwwwwwo ucomm,%cpu,%mem,command|cat

Sample Output:

UCOMM             %CPU %MEM COMMAND
launchd            0.0  0.1 /sbin/launchd
UserEventAgent     0.0  0.1 /usr/libexec/UserEventAgent (System)
syslogd            0.0  0.0 /usr/sbin/syslogd
uninstalld         0.0  0.0 /System/Library/PrivateFrameworks/Uninstall.framework/Resources/uninstalld
kextd              0.0  0.1 /usr/libexec/kextd
fseventsd          0.0  0.1  /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/FSEvents.framework/Versions/A/Support/fseventsd
mediaremoted       0.0  0.0 /System/Library/PrivateFrameworks/MediaRemote.framework/Support/mediaremoted
appleeventsd       0.0  0.0 /System/Library/CoreServices/appleeventsd --server


          • Related Articles

          • Calculation of various attributes in Linux server

            Physical memory utilization Command:  free -m   Sample Output:                       total                 used              free              shared        buff/cache         available Mem:    16338247680  6590242816  1372995584   662192128  ...
          • Calculation of various attributes in AIX server

            Page Space Command: lsps -a Sample Output: Page Space      Physical Volume   Volume Group       Size       %Used       Active     Auto        Type       Chksum ...
          • Calculation of various attributes in FreeBSD server

            Memory Utilization Command: export UNIX95;top -d 1 -n 2 Sample Output: last pid: 69468;  load averages:  0.23,  0.13,  0.09  up 439+07:00:37    18:32:00 27 processes:  2 running, 25 sleeping Mem: 8204K Active, 125M Inact, 100M Wired, 21M Buf, 109M ...
          • Calculation of various attributes in Sun Solaris server

            CPU Utilization CPU utilization = command=/usr/bin/vmstat 1 3  kthr      memory            page            disk          faults      cpu  r b w   swap  free  re  mf pi po fr de sr cd s0 -- --   in   sy   cs us sy id  0 0 0 1459384 744528 34 233 0  0  ...
          • Calculation of various attributes in HP UX server

            CPU Utilization Command: /usr/bin/vmstat 1 3                                                    Sample Output:          procs           memory                   page                              faults       cpu     r     b     w      avm    free  ...