tech:suivre_la_conso_cpu_par_utilisateurs
Différences
Ci-dessous, les différences entre deux révisions de la page.
| Prochaine révision | Révision précédente | ||
| tech:suivre_la_conso_cpu_par_utilisateurs [2026/06/07 19:12] – créée - modification externe 127.0.0.1 | tech:suivre_la_conso_cpu_par_utilisateurs [2026/09/18 13:58] (Version actuelle) – Jean-Baptiste | ||
|---|---|---|---|
| Ligne 4: | Ligne 4: | ||
| # Suivre la conso CPU par utilisateurs | # Suivre la conso CPU par utilisateurs | ||
| - | Voir atop | + | Voir aussi : |
| + | * atop | ||
| Source : | Source : | ||
| - | * http://la-vache-libre.org/monitoring-gardez-un-oeil-sur-les-utilisateurs-de-votre-systeme-gnulinux-avec-psacct-acct-tools/ | + | * https://www.redhat.com/en/ |
| * http:// | * http:// | ||
| + | * https:// | ||
| GNU Accounting Utilities est un ensemble d' | GNU Accounting Utilities est un ensemble d' | ||
| Ligne 16: | Ligne 18: | ||
| - | Version RPM : | + | Install RedHat |
| ~~~bash | ~~~bash | ||
| - | yum install psacct | + | dnf install psacct |
| + | |||
| + | # accton on | ||
| + | systemctl enable --now psacct.service | ||
| + | |||
| + | # Tester | ||
| + | ls # Une commande bidon | ||
| + | lastcomm | ||
| ~~~ | ~~~ | ||
| - | Version DEB : | + | Install Debian |
| ~~~bash | ~~~bash | ||
| apt-get install acct | apt-get install acct | ||
| + | # TODO: à compléter | ||
| ~~~ | ~~~ | ||
| Ligne 84: | Ligne 94: | ||
| ~~~bash | ~~~bash | ||
| lastcomm roger | lastcomm roger | ||
| + | ~~~ | ||
| + | |||
| + | |||
| + | ## Diagnostic | ||
| + | |||
| + | ~~~bash | ||
| + | journalctl -u acct -u psacct --since "10 minutes ago" --no-pager | ||
| + | ~~~ | ||
| + | |||
| + | |||
| + | ## Exemple commande sa - mémoire Linux | ||
| + | |||
| + | ~~~bash | ||
| + | # sa -u --other-acct-file / | ||
| + | sa -u | ||
| + | sa -m | ||
| + | sa -p | ||
| + | sa -P | ||
| + | ~~~ | ||
| + | |||
| + | ~~~ | ||
| + | # sa -u --other-acct-file / | ||
| + | ansible | ||
| + | root 0.14 cpu 25104k mem 0 io vdo | ||
| + | root 0.02 cpu 30736k mem 0 io gmain | ||
| + | ansible | ||
| + | ansible | ||
| + | root 0.00 cpu 43920k mem 0 io (sd-sync) | ||
| + | root 0.93 cpu | ||
| + | root 0.00 cpu | ||
| + | polkitd | ||
| + | ~~~ | ||
| + | |||
| + | ~~~ | ||
| + | # sa -m --other-acct-file / | ||
| + | 421 | ||
| + | libstoragemgmt | ||
| + | 500 | ||
| + | root 107 | ||
| + | sshd 7 | ||
| + | ansible | ||
| + | polkitd | ||
| + | ~~~ | ||
| + | |||
| + | ~~~ | ||
| + | # sa -a --other-acct-file / | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | ~~~ | ||
| + | |||
| + | ~~~ | ||
| + | # sa -c --other-acct-file / | ||
| + | | ||
| + | 29 6.89% 84.00re | ||
| + | | ||
| + | | ||
| + | ~~~ | ||
| + | |||
| + | ~~~ | ||
| + | # sa --sort-cpu-avmem --other-acct-file / | ||
| + | | ||
| + | 29 84.00re | ||
| + | 25 | ||
| + | | ||
| + | ~~~ | ||
| + | |||
| + | ~~~bash | ||
| + | lastcomm --show-paging --pid | ||
| ~~~ | ~~~ | ||
tech/suivre_la_conso_cpu_par_utilisateurs.1780852327.txt.gz · Dernière modification : de 127.0.0.1
