Twitter iPhone pliant OnePlus 11 PS5 Disney+ Orange Livebox Windows 11

top (1)

7 réponses
Avatar
Patrick Lamaizière
YO,

un truc qui m'ennui :

Dans top(1) est-il possible de ne pas afficher ces trucs là :
(processus plus ou moins systemes)

3 root RT 0 0 0 0 S 0.0 0.0 0:01.75 [migration/0]
4 root 20 0 0 0 0 S 0.0 0.0 0:14.68 [ksoftirqd/0]
5 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/0]
6 root RT 0 0 0 0 S 0.0 0.0 0:00.46 [watchdog/0]
7 root RT 0 0 0 0 S 0.0 0.0 0:01.32 [migration/1]
8 root RT 0 0 0 0 S 0.0 0.0 0:00.00
[migration/1]

Parce que top n'affiche que ça en fait (y'en a des palanqués), pas super
utile. Merci.

7 réponses

Avatar
Sergio
Le Wed, 09 Jan 2013 13:57:19 +0000, Patrick Lamaizière a écrit :

YO,

un truc qui m'ennui :

Dans top(1) est-il possible de ne pas afficher ces trucs là :
(processus plus ou moins systemes)



T'as essayé avec htop ?
http://fr.wikipedia.org/wiki/Htop

(présent dans les distribs à base de Debian, au moins).
Avatar
Patrick Lamaizière
Sergio :

un truc qui m'ennui :

Dans top(1) est-il possible de ne pas afficher ces trucs là :
(processus plus ou moins systemes)



T'as essayé avec htop ?
http://fr.wikipedia.org/wiki/Htop

(présent dans les distribs à base de Debian, au moins).



y'a pas l'air d'avoir ça d'en Centos.

Je dis ça je dis rien mais le top FreeBSD a une option S (toggle
system processes) pour ça.
Avatar
Lucas Levrel
Le 9 janvier 2013, Patrick Lamaizière a écrit :

Dans top(1) est-il possible de ne pas afficher ces trucs là :
(processus plus ou moins systemes)

3 root RT 0 0 0 0 S 0.0 0.0 0:01.75 [migration/0]
4 root 20 0 0 0 0 S 0.0 0.0 0:14.68 [ksoftirqd/0]
5 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/0]
6 root RT 0 0 0 0 S 0.0 0.0 0:00.46 [watchdog/0]
7 root RT 0 0 0 0 S 0.0 0.0 0:01.32 [migration/1]
8 root RT 0 0 0 0 S 0.0 0.0 0:00.00
[migration/1]

Parce que top n'affiche que ça en fait (y'en a des palanqués), pas super
utile. Merci.



Je ne sais pas. Mais ton top a l'air classé par PID croissant, ce qui
n'est pas super utile non plus ! Si tu classes par %CPU, %MEM, PID
décroissant, etc. ils ne t'embêteront plus tant.


--
LL
Avatar
Patrick Lamaizière
Lucas Levrel :

3 root RT 0 0 0 0 S 0.0 0.0 0:01.75 [migration/0]
4 root 20 0 0 0 0 S 0.0 0.0 0:14.68 [ksoftirqd/0]
5 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/0]
6 root RT 0 0 0 0 S 0.0 0.0 0:00.46 [watchdog/0]
7 root RT 0 0 0 0 S 0.0 0.0 0:01.32 [migration/1]
8 root RT 0 0 0 0 S 0.0 0.0 0:00.00
[migration/1]

Parce que top n'affiche que ça en fait (y'en a des palanqués), pas super
utile. Merci.



Je ne sais pas. Mais ton top a l'air classé par PID croissant, ce qui
n'est pas super utile non plus ! Si tu classes par %CPU, %MEM, PID
décroissant, etc. ils ne t'embêteront plus tant.



C'est classé par CPU. C'est que je n'ai recopié que la partie qui
m'embête.

1 root 20 0 21448 1296 976 S 0.0 0.0 0:03.04 /sbin/init
2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kthreadd]
3 root RT 0 0 0 0 S 0.0 0.0 0:01.75 [migration/0]
4 root 20 0 0 0 0 S 0.0 0.0 0:15.46 [ksoftirqd/0]
5 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/0]
6 root RT 0 0 0 0 S 0.0 0.0 0:00.47 [watchdog/0]
7 root RT 0 0 0 0 S 0.0 0.0 0:01.32 [migration/1]
8 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/1]
9 root 20 0 0 0 0 S 0.0 0.0 0:22.78 [ksoftirqd/1]
10 root RT 0 0 0 0 S 0.0 0.0 0:01.46 [watchdog/1]
11 root RT 0 0 0 0 S 0.0 0.0 0:02.48 [migration/2]
12 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/2]
13 root 20 0 0 0 0 S 0.0 0.0 0:11.57 [ksoftirqd/2]
14 root RT 0 0 0 0 S 0.0 0.0 0:00.45 [watchdog/2]
15 root RT 0 0 0 0 S 0.0 0.0 0:06.76 [migration/3]
16 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/3]
17 root 20 0 0 0 0 S 0.0 0.0 0:15.75 [ksoftirqd/3]
18 root RT 0 0 0 0 S 0.0 0.0 0:00.45 [watchdog/3]
19 root RT 0 0 0 0 S 0.0 0.0 0:00.64 [migration/4]
20 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/4]
21 root 20 0 0 0 0 S 0.0 0.0 0:10.86 [ksoftirqd/4]
22 root RT 0 0 0 0 S 0.0 0.0 0:00.44 [watchdog/4]
23 root RT 0 0 0 0 S 0.0 0.0 0:01.26 [migration/5]
24 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/5]
25 root 20 0 0 0 0 S 0.0 0.0 0:19.90 [ksoftirqd/5]
26 root RT 0 0 0 0 S 0.0 0.0 0:00.42 [watchdog/5]
27 root RT 0 0 0 0 S 0.0 0.0 0:01.31 [migration/6]
28 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/6]
29 root 20 0 0 0 0 S 0.0 0.0 0:11.36 [ksoftirqd/6]
30 root RT 0 0 0 0 S 0.0 0.0 0:00.41 [watchdog/6]
31 root RT 0 0 0 0 S 0.0 0.0 0:00.93 [migration/7]
32 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/7]
33 root 20 0 0 0 0 S 0.0 0.0 0:11.23 [ksoftirqd/7]
34 root RT 0 0 0 0 S 0.0 0.0 0:00.42 [watchdog/7]
35 root 20 0 0 0 0 S 0.0 0.0 0:26.93 [events/0]
36 root 20 0 0 0 0 S 0.0 0.0 0:26.93 [events/1]
37 root 20 0 0 0 0 S 0.0 0.0 0:24.26 [events/2]
38 root 20 0 0 0 0 S 0.0 0.0 0:21.61 [events/3]
39 root 20 0 0 0 0 S 0.0 0.0 0:25.43 [events/4]
40 root 20 0 0 0 0 S 0.0 0.0 0:25.75 [events/5]
41 root 20 0 0 0 0 S 0.0 0.0 0:31.15 [events/6]
42 root 20 0 0 0 0 S 0.0 0.0 0:28.25 [events/7]
43 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [cgroup]
44 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [khelper]
45 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [netns]
46 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [async/mgr]
47 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [pm]
48 root 20 0 0 0 0 S 0.0 0.0 0:01.66 [sync_supers]
49 root 20 0 0 0 0 S 0.0 0.0 0:01.86 [bdi-default]
50 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/0]
51 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/1]
52 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/2]
53 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/3]
54 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/4]
55 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/5]
56 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/6]
57 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kintegrityd/7]
58 root 20 0 0 0 0 S 0.0 0.0 0:57.08 [kblockd/0]
59 root 20 0 0 0 0 S 0.0 0.0 1:05.34 [kblockd/1]
60 root 20 0 0 0 0 S 0.0 0.0 0:00.66 [kblockd/2]
61 root 20 0 0 0 0 S 0.0 0.0 0:00.33 [kblockd/3]
62 root 20 0 0 0 0 S 0.0 0.0 0:20.98 [kblockd/4]
63 root 20 0 0 0 0 S 0.0 0.0 0:00.14 [kblockd/5]
64 root 20 0 0 0 0 S 0.0 0.0 0:28.42 [kblockd/6]
65 root 20 0 0 0 0 S 0.0 0.0 0:00.18 [kblockd/7]
66 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kacpid]
67 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kacpi_notify]
68 root 20 0 0 0 0 S 0.0 0.0

(après ça sort de l'écran...)
(c'est débile ce comportement)
Avatar
Damien Wyart
* Patrick Lamaizière in fr.comp.os.linux.configuration:
y'a pas l'air d'avoir ça d'en Centos.



On peut l'installer facilement à parir d'un dépôt tiers qui est
fiable : http://pkgs.repoforge.org/htop/

Je dis ça je dis rien mais le top FreeBSD a une option S (toggle
system processes) pour ça.



htop aussi (touche K) mais pas top...

--
DW
Avatar
mcc
Patrick Lamaizière wrote:

YO,

un truc qui m'ennui :

Dans top(1) est-il possible de ne pas afficher ces trucs là :
(processus plus ou moins systemes)

3 root RT 0 0 0 0 S 0.0 0.0 0:01.75 [migration/0]
4 root 20 0 0 0 0 S 0.0 0.0 0:14.68 [ksoftirqd/0]
5 root RT 0 0 0 0 S 0.0 0.0 0:00.00 [migration/0]
6 root RT 0 0 0 0 S 0.0 0.0 0:00.46 [watchdog/0]
7 root RT 0 0 0 0 S 0.0 0.0 0:01.32 [migration/1]
8 root RT 0 0 0 0 S 0.0 0.0 0:00.00
[migration/1]

Parce que top n'affiche que ça en fait (y'en a des palanqués), pas super
utile. Merci.



top -u nom_utilisateur
ça te débarasse déjà de tous les processus root
Avatar
Lucas Levrel
Le 9 janvier 2013, Patrick Lamaizière a écrit :

Lucas Levrel :
Je ne sais pas. Mais ton top a l'air classé par PID croissant, ce qui
n'est pas super utile non plus ! Si tu classes par %CPU, %MEM, PID
décroissant, etc. ils ne t'embêteront plus tant.



C'est classé par CPU. C'est que je n'ai recopié que la partie qui
m'embête.

1 root 20 0 21448 1296 976 S 0.0 0.0 0:03.04 /sbin/init
2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kthreadd]
3 root RT 0 0 0 0 S 0.0 0.0 0:01.75 [migration/0]
4 root 20 0 0 0 0 S 0.0 0.0 0:15.46 [ksoftirqd/0]


...
64 root 20 0 0 0 0 S 0.0 0.0 0:28.42 [kblockd/6]
65 root 20 0 0 0 0 S 0.0 0.0 0:00.18 [kblockd/7]
66 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kacpid]
67 root 20 0 0 0 0 S 0.0 0.0 0:00.00 [kacpi_notify]
68 root 20 0 0 0 0 S 0.0 0.0



Ils sont de fait classés par PID (1 à 68), donc si tu as bien demandé
le classement par %CPU (en tapant 'P' par exemple), c'est que tous tes
processus sont exactement au même % CPU, même top. Mon top à moi que j'ai,
classé par %CPU, donne :

PID PPID PR VIRT SWAP nFLT %MEM %CPU P TIME COMMAND
1828 1670 20 22124 20m 1 0.1 0 1 0:01 hald-addon-stor
2556 2516 20 289m 241m 19 4.9 0 1 0:08 X
3012 2966 20 112m 106m 2 0.7 0 1 0:07 xfce4-systemloa
3476 3054 20 8568 7404 0 0.1 0 0 0:00 top
1 0 20 8100 7364 4 0.1 0 0 0:00 init
2 0 15 0 0 0 0.0 0 0 0:00 kthreadd
3 2 RT 0 0 0 0.0 0 0 0:00 migration/0
4 2 15 0 0 0 0.0 0 0 0:00 ksoftirqd/0
5 2 RT 0 0 0 0.0 0 0 0:00 watchdog/0

Même un %CPU arrondi à 0 pour tous les processus ne donne pas un
classement effectif par PID.

(c'est débile ce comportement)



Quel est ton usage de top ? Si tu veux voir les processus les plus
consommateurs de CPU/RAM/swap..., dès qu'il y en aura d'actifs ils se
placeront avant les [xxx]. Si tu veux une vision temps réel des processus
lancés, classe par PID décroissant et tu ne verras plus les [xxx] non
plus.

Bref, je ne vois pas d'usage concret où ça pose problème (je ne dis pas
qu'il n'y en a pas).

--
LL