Important! This is an automatic machine translated page. If you can read english, you should Click Here to read the original English version of the article.

Get CPU / System Load Average on Ubuntu Linux Pobierz CPU / System Średnie obciążenie na Ubuntu Linux

Ubuntu linux has a rich set of commands for getting system info. Ubuntu Linux posiada bogaty zestaw poleceń na uzyskanie informacji systemu. One of the useful pieces of information that a system administrator might need is to know what the overall system load on a server is. Jednym z elementów przydatnych informacji, które administrator systemu może być konieczne jest, aby wiedzieć, co ogólne obciążenie systemu na serwer.

There are a couple of ways to get this information, which may or may not be enabled on your system. Istnieje kilka sposobów, aby uzyskać te informacje, które mogą lub nie mogą być aktywne w systemie. It's useful to know more than one way to get the uptime information in case the commands are disabled on your shared hosting server. Warto wiedzieć więcej niż jeden sposób, aby uzyskać informacje uptime w przypadku polecenia są wyłączone na współdzielonych hosting serwera.

uptime Uptime

The uptime command gives information on system load averages for the past 1, 5, and 15 minutes: Uptime polecenia podaje informacje o średnie obciążenie systemu minut po 1, 5 i 15:

Example: Przykład:

[root@ubuntu geek]# uptime [root @ geek Ubuntu] # uptime
05:59:07 up 87 days, 13:13, 1 user, load average: 0.00, 0.00, 0.39 05:59:07 up 87 dni, 13:13, 1 user, load average: 0.00, 0.00, 0.39

w w

The w command shows who is logged on and what they are doing, including system load averages for the past 1, 5, and 15 minutes. Polecenia w pokazuje kto jest zalogowany i co robią, w tym średnie obciążenie systemu minut po 1, 5 i 15.

[root@ubuntu geek]# uptime [root @ geek Ubuntu] # uptime
05:59:56 up 87 days, 13:13, 1 user, load average: 0.00, 0.00, 0.39 05:59:56 up 87 dni, 13:13, 1 user, load average: 0.00, 0.00, 0.39
USER TTY FROM LOGIN@ IDLE JCPU PCPU WHAT USER TTY FROM LOGIN @ IDLE JCPU PCPU CO
geek pts/0 192.168.1.115 6:31pm 0.00s 0.62s 0.03s /usr/sbin/sshd geek pts / 0 192.168.1.115 6:31 pm 0.00s 0.62s 0.03s / usr / sbin / sshd

/proc/loadavg / proc / buty

The /proc/loadavg file contains information on the system load. / Proc / buty plik zawiera informacje na temat obciążenia systemu. Most likely the uptime/w commands utilize this information. Najprawdopodobniej uptime / polecenia w wykorzystać te informacje. The first 3 values contain system load averages for the past 1, 5, and 15 minutes. Pierwsze 3 zawiera wartości średnie obciążenie systemu minut po 1, 5 i 15.

[root@ubuntu geek]# cat /proc/loadavg [root @ geek Ubuntu] # cat / proc / buty
0.00 0.00 0.39 1/49 15352 0,00 0,00 0,39 1 / 49 15352

There are probably some more commands, but these are the ones off the top of my head that I know of. Prawdopodobnie jest kilka poleceń, ale są te z góry na głowę, że znam.

This article was originally written on 11/28/06 Tagged with: Ten artykuł został napisany na 11/28/06 Tagged with: Ubuntu Ubuntu , , Ubuntu Tips & Tweaks Ubuntu Tips & Tweaks

Daily Email Updates Daily Email Updates

You can get our how-to articles in your inbox each day for free. Możesz pobrać nasze instrukcje postępowania w skrzynce odbiorczej codziennie za darmo. Just enter your name and email below: Wystarczy podać swoje imię i adres e-mail:


Name: Imię i nazwisko:
Email: E-mail:

Comments (5) Komentarze (5)

  1. netking netking

    there's also the top command Istnieje także najlepsze polecenia ;-)

  2. oliver oliver

    Hi, Cześć,
    do you know how to get the load on each processor on a server. wiesz jak uzyskać obciążenie dla każdego procesora na serwerze. Not the global load but the specific one ? Nie globalnego obciążenia, ale specyficzny?
    thx for the answer thx za odpowiedzi

  3. Steve Steve

    I know top can give you the usage for each core. Wiem, że najlepsze może dać ci korzystania dla każdego rdzenia. I'm not sure if it does it out of the box, or if there's any special configuration required. Ja Nie wiem czy to po wyjęciu z pudełka, lub jeśli nie ma żadnych specjalnych konfiguracji wymaganej.

    1787 processes: 1782 sleeping, 2 running, 3 zombie, 0 stopped 1787 procesy: 1782 sleeping, 2 running, 3 zombie, 0 stopped
    CPU0 states: 7.0% user 5.1% system 0.0% nice 0.0% iowait 87.0% idle CPU0 stanowi: 7.0% 5.1% użytkowników systemu 0.0% nice 0,0 iowait% 87.0% idle
    CPU1 states: 18.1% user 1.0% system 0.0% nice 0.0% iowait 80.0% idle CPU1 stanowi: 18,1% 1,0% użytkowników systemu 0.0% nice 0,0 iowait% 80.0% idle
    CPU2 states: 33.1% user 0.1% system 0.0% nice 0.0% iowait 65.0% idle CPU2 stanowi: 33,1% 0,1% użytkowników systemu 0.0% nice 0,0 iowait% 65.0% idle
    CPU3 states: 40.0% user 2.0% system 0.0% nice 0.0% iowait 57.0% idle CPU3 stanowi: 40,0% 2,0% użytkowników systemu 0.0% nice 0,0 iowait% 57.0% idle
    CPU4 states: 7.1% user 0.1% system 0.0% nice 3.0% iowait 88.0% idle CPU4 stanowi: 7.1% 0.1% użytkowników systemu 0.0% nice 3,0 iowait% 88.0% idle
    CPU5 states: 7.1% user 29.0% system 0.0% nice 0.0% iowait 62.1% idle CPU5 stanowi: 7.1% 29.0% użytkowników systemu 0.0% nice 0,0 iowait% 62.1% idle
    CPU6 states: 25.1% user 1.0% system 0.0% nice 0.0% iowait 72.1% idle CPU6 stanowi: 25,1% 1,0% użytkowników systemu 0.0% nice 0,0 iowait% 72.1% idle
    CPU7 states: 16.0% user 0.1% system 0.0% nice 0.0% iowait 83.0% idle CPU7 stanowi: 16,0% 0,1% użytkowników systemu 0.0% nice 0,0 iowait% 83.0% idle

    For example this would be shown right at the top for a multi-core system. Na przykład będzie to widoczne na pierwszym miejscu dla wielu system podstawowy.

  4. Bob Bob

    You can use the grep command to monitor the CPU load average: Możesz użyć polecenia grep do monitorowania średnie obciążenie procesora:

    top -b | grep -2 “load average” top-b | grep -2 "load average"

  5. brainextender brainextender

    I'ma little curious how to get the load of a single core from the /proc file system? Jestem trochę ciekaw, jak uzyskać obciążenie pojedynczy rdzeń z system plików / proc?


Leave a Comment Zostaw komentarz




Leave your Zostaw swój friendly przyjazny comment here. komentarz.

If you have a computer help question, Jeśli masz pytanie pomocy komputera, click here to leave it on the forums Kliknij tutaj, aby pozostawić ją na forum instead. zamiast.

Note: Your comment may not show up immediately on the site. Uwaga: Twój komentarz nie pojawi się od razu na stronie.

Our Friends Nasi Przyjaciele
Getting Started Pierwsze kroki


About How-To Geek O How-To Geek
What Is That Process? Co to jest proces?
svchost.exe svchost.exe
jusched.exe jusched.exe
dwm.exe dwm.exe
ctfmon.exe Gadu-Gadu
wmpnetwk.exe wmpnetwk.exe
wmpnscfg.exe wmpnscfg.exe
rundll32.exe rundll32.exe
wfcrun32.exe wfcrun32.exe
Ipoint.exe Ipoint.exe
Itype.exe Itype.exe
Wfica32.exe Wfica32.exe
Mobsync.exe Mobsync.exe
conhost.exe conhost.exe
Dpupdchk.exe Dpupdchk.exe Adobe_Updater.exe Adobe_Updater.exe

Copyright © 2006-2009 HowToGeek.com. Copyright © 2006-2009 HowToGeek.com. All Rights Reserved. All Rights Reserved.