Eu tenho três ODROID HC2s (hc2-2,3,4), todos com hardware completamente idêntico (Exynos Octa-Cores com 2 GB de RAM, 16 GB de cartão MicroSD) e software, alguns do Debian Stretch instalados recentemente e também idênticos em todos os sistemas. Se eu executar um comando de tempo de atividade (com Ansible no hc2-1) em todas as máquinas, dois deles têm uma carga pouco acima de 1.0 e um tem uma carga pouco acima de 0.
ansible@4zctrl:/etc/ansible$ ansible -m shell -a "uptime" all
hc2-1 | SUCCESS | rc=0 >>
00:33:35 up 2 days, 6:37, 4 users, load average: 1.75, 1.19, 1.05
hc2-2 | SUCCESS | rc=0 >>
00:33:35 up 2 days, 5:59, 1 user, load average: 1.01, 1.04, 1.01
hc2-3 | SUCCESS | rc=0 >>
00:33:35 up 2 days, 5:59, 1 user, load average: 0.12, 0.04, 0.01
hc2-4 | SUCCESS | rc=0 >>
23:33:35 up 2 days, 5:59, 1 user, load average: 1.00, 1.00, 1.00
Mesmo com htop
, não consigo ver nenhuma diferença entre os três sistemas hc2-2,3,4. Todos executando 20 tarefas, 8 threads com 1 executando.
Editar (adicionar saída de vmstat 5 3
):
ansible@4zctrl:/etc/ansible$ ansible -m shell -a "vmstat 5 3" all
hc2-1 | SUCCESS | rc=0 >>
procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 0 1529932 36612 309656 0 0 0 0 12 17 0 0 100 0 0
0 0 0 1529804 36612 309588 0 0 0 0 1805 2967 1 0 99 0 0
0 0 0 1529804 36612 309588 0 0 0 0 1751 2956 1 0 99 0 0
hc2-2 | SUCCESS | rc=0 >>
procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 0 1667360 15532 274732 0 0 0 0 10 12 0 0 100 0 0
0 0 0 1667112 15532 274732 0 0 0 0 756 1253 0 0 100 0 0
0 0 0 1667112 15532 274732 0 0 0 0 747 1261 0 0 100 0 0
hc2-3 | SUCCESS | rc=0 >>
procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 0 1668316 15284 274608 0 0 0 0 11 6 0 0 100 0 0
0 0 0 1667980 15284 274736 0 0 0 0 135 90 0 0 100 0 0
0 0 0 1667980 15284 274736 0 0 0 0 79 40 0 0 100 0 0
hc2-4 | SUCCESS | rc=0 >>
procs -----------memory---------- ---swap-- -----io---- -system-- ------cpu-----
r b swpd free buff cache si so bi bo in cs us sy id wa st
0 0 0 1672060 15192 271740 0 0 0 0 10 14 0 0 100 0 0
0 0 0 1671936 15192 271740 0 0 0 0 758 1273 0 0 100 0 0
0 0 0 1671936 15192 271740 0 0 0 0 744 1272 0 0 100 0 0
Se eu executar o vmstat por muito mais tempo (por exemplo, vmstat 3 10
), às vezes há um 1
na coluna-r (appox. 1 em 15 linhas). Há apenas a corrida mínima nua no alvo, como ps ax
mostra em hc2-3.
PID TTY STAT TIME COMMAND
1 ? Ss 0:10 /sbin/init
2 ? S 0:00 [kthreadd]
3 ? S 0:00 [ksoftirqd/0]
5 ? S< 0:00 [kworker/0:0H]
7 ? S 0:39 [rcu_preempt]
8 ? S 0:00 [rcu_sched]
9 ? S 0:00 [rcu_bh]
10 ? S 0:00 [migration/0]
11 ? S< 0:00 [lru-add-drain]
12 ? S 0:00 [cpuhp/0]
13 ? S 0:00 [cpuhp/1]
14 ? S 0:00 [migration/1]
15 ? S 0:00 [ksoftirqd/1]
17 ? S< 0:00 [kworker/1:0H]
18 ? S 0:00 [cpuhp/2]
19 ? S 0:00 [migration/2]
20 ? S 0:00 [ksoftirqd/2]
22 ? S< 0:00 [kworker/2:0H]
23 ? S 0:00 [cpuhp/3]
24 ? S 0:00 [migration/3]
25 ? S 0:00 [ksoftirqd/3]
26 ? S 0:00 [kworker/3:0]
27 ? S< 0:00 [kworker/3:0H]
28 ? S 0:00 [cpuhp/4]
29 ? S 0:00 [migration/4]
30 ? S 0:00 [ksoftirqd/4]
32 ? S< 0:00 [kworker/4:0H]
33 ? S 0:00 [cpuhp/5]
34 ? S 0:00 [migration/5]
35 ? S 0:00 [ksoftirqd/5]
37 ? S< 0:00 [kworker/5:0H]
38 ? S 0:00 [cpuhp/6]
39 ? S 0:00 [migration/6]
40 ? S 0:00 [ksoftirqd/6]
42 ? S< 0:00 [kworker/6:0H]
43 ? S 0:00 [cpuhp/7]
44 ? S 0:00 [migration/7]
45 ? S 0:00 [ksoftirqd/7]
47 ? S< 0:00 [kworker/7:0H]
48 ? S 0:00 [kdevtmpfs]
49 ? S< 0:00 [netns]
52 ? S 0:00 [oom_reaper]
53 ? S< 0:00 [writeback]
54 ? S 0:00 [kcompactd0]
55 ? SN 0:00 [ksmd]
56 ? S< 0:00 [crypto]
57 ? S< 0:00 [kintegrityd]
58 ? S< 0:00 [bioset]
59 ? S< 0:00 [kblockd]
60 ? S< 0:00 [devfreq_wq]
61 ? S< 0:00 [watchdogd]
62 ? S< 0:00 [rpciod]
63 ? S< 0:00 [xprtiod]
65 ? S 0:00 [kswapd0]
66 ? S< 0:00 [vmstat]
67 ? S< 0:00 [nfsiod]
68 ? S 0:00 [jfsIO]
69 ? S 0:00 [jfsCommit]
70 ? S 0:00 [jfsCommit]
71 ? S 0:00 [jfsCommit]
72 ? S 0:00 [jfsCommit]
73 ? S 0:00 [jfsCommit]
74 ? S 0:00 [jfsCommit]
75 ? S 0:00 [jfsCommit]
76 ? S 0:00 [jfsCommit]
77 ? S 0:00 [jfsSync]
78 ? S< 0:00 [bioset]
79 ? S< 0:00 [xfsalloc]
80 ? S< 0:00 [xfs_mru_cache]
118 ? S< 0:00 [kthrotld]
119 ? S 0:00 [irq/129-drm_rot]
120 ? S< 0:00 [ipp_event]
121 ? S< 0:00 [ipp_cmd]
122 ? S< 0:00 [kworker/u17:0]
123 ? S< 0:00 [kbase_job_fault]
124 ? S< 0:00 [kworker/u17:1]
125 ? S< 0:00 [bioset]
126 ? S< 0:00 [bioset]
127 ? S< 0:00 [bioset]
128 ? S< 0:00 [bioset]
129 ? S< 0:00 [bioset]
130 ? S< 0:00 [bioset]
131 ? S< 0:00 [bioset]
132 ? S< 0:00 [bioset]
133 ? S< 0:00 [bioset]
134 ? S< 0:00 [bioset]
135 ? S< 0:00 [bioset]
136 ? S< 0:00 [bioset]
137 ? S< 0:00 [bioset]
138 ? S< 0:00 [bioset]
139 ? S< 0:00 [bioset]
140 ? S< 0:00 [bioset]
141 ? S< 0:00 [bioset]
142 ? S< 0:00 [bioset]
143 ? S< 0:00 [bioset]
144 ? S< 0:00 [bioset]
145 ? S< 0:00 [bioset]
146 ? S< 0:00 [bioset]
147 ? S< 0:00 [bioset]
148 ? S< 0:00 [bioset]
149 ? S 0:00 [irq/143-s2mps11]
150 ? S 0:00 [irq/145-1220000]
154 ? S< 0:00 [bioset]
164 ? S 0:00 [irq/142-hdmi]
191 ? S< 0:00 [bioset]
193 ? S 0:04 [mmcqd/1]
199 ? S< 0:00 [kworker/2:1H]
201 ? S< 0:00 [kworker/4:1H]
203 ? S< 0:00 [kworker/7:1H]
207 ? S< 0:00 [kworker/1:1H]
212 ? S< 0:00 [kworker/0:1H]
217 ? S 0:00 [kworker/3:1]
231 ? S< 0:00 [kworker/5:1H]
246 ? S 0:00 [jbd2/mmcblk1p1-]
247 ? S< 0:00 [ext4-rsv-conver]
261 ? S< 0:00 [ipv6_addrconf]
272 ? S< 0:00 [kworker/6:1H]
305 ? S 0:00 [kauditd]
339 ? Ss 1:50 /lib/systemd/systemd-udevd
376 ? S 0:16 [w1_bus_master1]
384 ? S 0:00 [irq/91-10830000]
396 ? S 0:00 [spi1]
402 ? Ss 0:08 /lib/systemd/systemd-journald
403 ? S< 0:00 [kworker/3:1H]
435 ? S 0:00 [irq/149-ads7846]
542 ? Ss 0:09 /usr/sbin/haveged --Foreground --verbose=1 -w 1024
583 ? Ssl 0:01 /usr/sbin/rsyslogd -n
594 ? Ss 0:01 /usr/sbin/cron -f
595 ? Ss 0:01 /lib/systemd/systemd-logind
597 ? Ss 0:03 /usr/bin/dbus-daemon --system --address=systemd: --nofork --nopidfile --systemd-activation
633 ? Ssl 0:10 /usr/sbin/NetworkManager --no-daemon
840 ? Ss 0:00 /usr/sbin/sshd -D
921 ? Ss 0:00 /sbin/dhclient -4 -v -pf /run/dhclient.eth0.pid -lf /var/lib/dhcp/dhclient.eth0.leases -I -df /var/lib/dhcp/dhclient6.eth0.leases eth0
977 ? Ssl 0:00 /usr/lib/policykit-1/polkitd --no-debug
1030 tty1 Ss+ 0:00 /sbin/agetty --noclear tty1 linux
1032 ? Ss+ 0:00 /sbin/agetty --keep-baud 115200,38400,9600 ttySAC2 linux
1051 ? Ssl 0:24 /usr/sbin/ntpd -p /var/run/ntpd.pid -g -c /run/ntp.conf.dhcp -u 106:110
14363 ? S 1:19 [kworker/0:2]
16884 ? S 0:00 [kworker/0:0]
25688 ? S 0:01 [kworker/1:1]
25813 ? S 0:00 [kworker/2:2]
25836 ? S 0:17 [kworker/7:0]
26011 ? S 0:00 [kworker/2:1]
26014 ? S 0:00 [kworker/6:0]
26608 ? S 0:05 [kworker/4:2]
26677 ? S 0:00 [kworker/5:0]
27018 ? S 0:00 [kworker/5:1]
27136 ? S 0:00 [kworker/7:2]
27176 ? S 0:00 [kworker/u16:0]
27189 ? S 0:00 [kworker/4:0]
27373 ? S 0:00 [kworker/u16:2]
27385 ? S 0:00 [kworker/1:0]
27391 ? S 0:00 [kworker/6:1]
27510 ? S 0:00 [kworker/5:2]
27511 ? S 0:00 [kworker/5:3]
27513 ? Ss 0:00 sshd: ansible [priv]
27515 ? Ss 0:00 /lib/systemd/systemd --user
27516 ? S 0:00 (sd-pam)
27597 ? S 0:00 sshd: ansible@pts/0
27614 pts/0 Ss+ 0:00 sh -c /bin/sh -c '/usr/bin/python /opt/ansible/.ansible/tmp/ansible-tmp-1520359348.54-114220197176441/command.py && sleep 0'
27615 pts/0 S+ 0:00 /bin/sh -c /usr/bin/python /opt/ansible/.ansible/tmp/ansible-tmp-1520359348.54-114220197176441/command.py && sleep 0
27616 pts/0 S+ 0:00 /usr/bin/python /opt/ansible/.ansible/tmp/ansible-tmp-1520359348.54-114220197176441/command.py
27617 pts/0 S+ 0:00 /usr/bin/python /tmp/ansible_NmfkNb/ansible_module_command.py
27618 pts/0 S+ 0:00 /bin/sh -c ps ax
27619 pts/0 R+ 0:00 ps ax
Após reiniciar os três sistemas hc2-2 ... hc2-4, obtenho uma imagem diferente:
ansible@4zctrl:/etc/ansible$ ansible -m shell -a "uptime" 'all:!hc2-1'
hc2-4 | SUCCESS | rc=0 >>
18:55:48 up 2 min, 1 user, load average: 1.09, 0.55, 0.22
hc2-3 | SUCCESS | rc=0 >>
19:55:48 up 2 min, 1 user, load average: 0.04, 0.06, 0.02
hc2-2 | SUCCESS | rc=0 >>
19:55:48 up 2 min, 1 user, load average: 0.09, 0.12, 0.05
Agora também hc2-2 caiu sua carga como hc2-3. Eu acho isso realmente ligado ...
Então, minha pergunta é: o que é ou pode ser o motivo e como investigá-lo?
Tags debian arm linux load-average