swptot, swpfre Total, Available swap
atsar -r |head
Linux pi93graf 4.14.98+ #1200 Tue Feb 12 20:11:02 GMT 2019 armv6l 04/11/2019
21:16:16 memtot memfree buffers cached slabmem swptot swpfree _mem_
21:17:27 433M 91M 21M 128M 13M 2047M 2047M
21:17:32 433M 91M 21M 128M 13M 2047M 2047M
21:20:01 linux restarts
21:30:02 433M 155M 23M 103M 13M 2047M 2047M
atsar -r |sed "s/M/ /g"|uniq --skip-chars=8 |head -n50 # remove 'M' for clarity and uniquify by skipping the time
Linux pi93graf 4.14.98+ #1200 Tue Feb 12 20:11:02 G T 2019 armv6l 05/20/2019
00:00:01 memtot memfree buffers cached slabmem swptot swpfree _mem_
00:00:16 433 39 8 155 14 2047 2017
00:00:46 433 39 8 156 14 2047 2017
00:01:16 433 38 8 156 14 2047 2017 some identical entries skipped
00:01:31 433 37 8 156 14 2047 2017
00:02:16 433 36 8 157 14 2047 2017
00:03:16 433 34 8 158 14 2047 2017
atsar -r -s 12:00 -e 12:50 |sed "s/M/ /g"|uniq --skip-chars=8
Linux pi93graf 4.19.42+ #1219 Tue ay 14 21:16:38 BST 2019 armv6l 06/28/2019
12:00:02 memtot memfree buffers cached slabmem swptot swpfree _mem_
12:01:02 432 33 6 122 15 2047 1997
12:03:02 432 23 11 120 16 2047 1998
12:10:01 432 27 11 79 16 2047 1998
12:11:01 432 27 11 80 16 2047 1998
12:12:01 432 30 11 81 16 2047 1998
12:13:01 432 29 11 82 16 2047 1998
12:20:01 432 64 12 87 16 2047 1998
12:21:01 432 61 12 87 16 2047 1998
12:22:01 432 61 12 88 16 2047 1998
12:23:01 432 60 12 88 16 2047 1998
12:30:01 432 54 12 93 16 2047 1998
12:31:01 432 51 12 94 16 2047 1998
12:32:01 432 46 12 94 16 2047 1998
12:33:01 432 46 12 95 16 2047 1998
12:40:01 432 43 12 100 16 2047 1998
12:41:01 432 44 12 99 16 2047 1998
12:42:01 432 43 12 99 16 2047 1998
12:43:01 432 43 12 100 16 2047 1998
12:47:40 linux restarts
12:50:02 432 80 17 191 15 2047 2047
| -p frequency of paging and swapping:
|
|---|
pagein/s pageout/s | implies normal data-access (so not necessarily indicating lack of memory).
| swapin/s swapout/s |
| fork/s new processes started
Swapping is copying the entire process address space, or at least , the non-shareable-text data segment .
Paging is copying one or more pages of the address space.
Paging is also requires per-page memory hardware attributes (dirty, no access, read-only, read-write, no execute, executable), and various virtual memory management tricks like demand-zero-filled pages, copy-on-write pages,
paging requires page-granularity virtual memory page table hardware, which map virtual pages to the physical address, and includes flags like valid, read, write, written etc. The hardware must trigger a page fault exception if a vitrual page is unallocated.
The OS then makes page accessible and/or schedule an I/O to load it to physical RAM.
atsar -s 12:25 -e 12:40 -p
Linux pi93graf 4.14.98+ #1200 Tue Feb 12 20:11:02 GMT 2019 armv6l 05/24/2019
12:25:01 pagein/s pageout/s swapin/s swapout/s fork/s _page_
12:25:16 0.00 18.67 0.00 0.00 0.00
12:25:31 0.27 20.27 0.00 0.00 0.00
12:25:46 0.00 12.80 0.00 0.00 0.00
12:26:01 1953.60 36.80 0.00 2.13 3.07
12:26:16 0.27 21.07 0.00 0.00 0.00
12:26:31 0.00 15.20 0.00 0.00 0.00
12:26:46 0.00 26.67 0.00 0.00 0.00
12:27:01 22.13 10.40 0.00 0.00 0.00
12:27:16 944.80 140.00 0.00 1.87 0.73
12:27:31 1173.07 9.07 0.00 0.00 0.00
12:27:46 1944.27 14.93 0.00 0.00 0.60
12:28:01 15548.53 206.40 0.07 45.40 0.07
12:28:16 19104.00 30.93 0.00 7.27 0.00
12:28:31 18636.53 54.93 0.00 12.93 0.00
12:28:46 18610.13 47.47 0.00 9.47 0.00
…
12:38:29 11808.80 9.07 0.13 0.13 0.00
12:38:44 1210.67 22.67 0.00 0.00 0.53
12:38:59 173.60 24.00 0.00 0.00 0.00
12:39:14 266.67 25.87 0.00 0.00 0.00
12:39:29 298.13 13.60 0.00 0.00 0.00
12:39:44 6.13 12.27 0.00 0.00 0.00
12:39:59 148.27 26.67 0.00 0.00 0.00
12:40:01 472.00 0.00 0.00 0.00 14.00
12:40:16 4.27 23.73 0.00 0.00 0.20
12:40:31 157.87 12.80 0.00 0.00 0.00
12:40:46 16.00 22.40 0.00 0.00 0.00
atsar -p |head
Linux pi93graf 4.14.98+ #1200 Tue Feb 12 20:11:02 GMT 2019 armv6l 04/11/2019
21:16:16 pagein/s pageout/s swapin/s swapout/s fork/s _page_
21:17:27 0.45 22.48 0.00 0.00 0.99
21:17:32 0.00 32.80 0.00 0.00 0.00
21:20:01 linux restarts
21:30:02 581.67 185.21 0.00 0.00 3.03
21:30:17 0.00 19.73 0.00 0.00 0.13
21:30:32 0.00 25.33 0.00 0.00 0.00
| -I interrupt-frequency, reported per irq per cpu.
|
|---|
iq.. interrupts per second for this interrupt-type. /proc/interrupts shows device
| | -v utilization of limited kernel-resources: current and max
|
|---|
superb-sz | super-blocks which is maintained by the kernel for mounted filesystems.
| inode-sz | incore-inodes maintained by the kernel. One entry is needed for every disk-file which is currently open (at least once).
| file-sz | open-file entries maintained by the kernel. One entry is needed
for every open-request for a disk-file. If a file is currently opened by five processes, one incore-inode and five open-file entries.
| dquota-sz | occupation of the collection of disk-quota entries.
| flock-sz | file-locks.
| | -y utilization of tty's:
|
|---|
port | port-number
| xmit/s recv/s | interrupts
| frer/s | framing-errors
| parer/s | parity-errors
| ovrun/s | overrun-errors
| brk/s | breaks
|
Communications
| -l utilization of network-interfaces:
|
|---|
inpck/s tpck/s | packets
| inbyt/s otbyt/s | bytes
| incmpr/s | otcmpr/s compressed packets (SLIP).
| inmcst/s | multicast-packets received from this interface
| iface | Name of the interface.
| | -L failures for network-interfaces:
|
|---|
inerr/s| bad packets received
| oterr/s | packet-transmit problems
| coll/s | collisions encountered while transmitting packets.
| indrop/s | received packets dropped due to lack of buffer-space
| otdrop/s| transmitted packets dropped due to lack of buffer-space
| infram/s| frame alignment-errors on received packets.
| otcarr/s| carrier-errors on transmitted packets.
| iface | Name
| | -w utilization of the IPv4-layer (formal snmp-names between brackets):
|
|---|
inrecv/s | input received from interfaces , including those received in error (ipInReceives).
| outreq/s | local higher-layer protocols supplied to IP in requests for transmission (ipOutRequests).
| indeliver/s| input succesfully delivered to higher protocol-layers (ipInDelivers).
| forward/s | input for which this was not their final destination, attempted to forward (ipForwDatagrams).
| reasmok/s | reassembled (ipReasmOKs).
| fragcreat/s| fragments created (ipFragCreates).
| | -W discards in the IPv4-layer
|
|---|
indsc/s | input discards for lack of buffer space (ipInDiscards).
| hder/s | header error (ipInHdrErrors).
| ader/s | address destination not valid to be received (ipInAddrErrors).
| unkp/s | unknown or unsupported protocol inbound (ipInUnknownProtos).
| ratim/s | reassembly timeout-situations while other fragments were expected (ipReasmTimeout).
| rfail/s | reassembly algorithm (ipReasmFails).
| otdsc/s | output for lack of buffer space (ipOutDiscards).
| nort/s | no route found (ipOutNoRoutes).
| | -t TCP-layer segments, ports
|
|---|
insegs/s | incomming segments, including those in error (tcpInSegs).
| otsegs/s | output segments, excluding those containing only retransmitted octets (tcpOutSegs).
| actopen/s| active opens (tcpActiveOpens).
| pasopen/s| passive opens (tcpPassiveOpens).
| nowopen | connections open now (snapshot), ESTABLISHED or CLOSE-WAIT (tcpCurrEstab).
| socknow | sockets now open (snapshot).
| sockmax | Maximum parallel ever open.
| | -T failures which were detected in the TCP-layer
|
|---|
inerr/s | received segments per second received in error (tcpInErrs).
| retrans/s | retransmitted segments per second (tcpRetransSegs).
| attfail/s | failed connection attempts per second that have occurred at this entity (tcpAttemptFails).
| estabreset/s | resets per second that have occurred at this entity (tcpEstabResets).
| outreset/s | transmitted segments per second containing the RST flag (tcpOutRsts).
| | -U utilization of UDPv4-layer
|
|---|
indgram/s | UDP datagrams per second delivered to UDP users (udpInDatagrams),
| otdgram/s | UDP datagrams transmitted per second from this entity (udpOutDatagrams),
| inerr/s | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | |