- Linux
- OpenBSD
- FreeBSD
- Solaris
- bash/shell
- » ab
- » arp
- » arping
- » awk
- » bzip2, bunzip2, bzip2re...
- » chcase
- » chkconfig
- » chmod
- » chown
- » comm
- » convert
- » cat
- » cp
- » cpio
- » cryptsetup
- » curl
- » date
- » diff
- » dig
- » dumpe2fs
- » e2fsck(fsck.{ext2,ext3})
- » eval
- » exportfs
- » file
- » find
- » ftp
- » fuser
- » getfacl
- » grep, egrep, fgrep
- » grub
- » gzip, gunzip
- » hdparm
- » head
- » host
- » ifconfig
- » ifenslave
- » import
- » ionice
- » ip
- » ipcs, ipcrm
- » kill
- » ldconfig
- » ld
- » ldd
- » less
- » locale
- » locate
- » losetup
- » ls
- » lsmod
- » lsof
- » man
- » mke2fs(mkfs.{ext2,ext3})
- » mkinitrd
- » mknod
- » mkswap
- » modinfo
- » modprobe
- » mount
- » mtr
- » mv
- » mysql
- » mysqladmin
- » mysqldump
- » netstat
- » netstat-nat
- » nice
- » nc
- » nm
- » nslookup
- » objdump
- » openssl
- » parted
- » patch
- » perl
- » pg_dump
- » pidof
- » ping
- » pkg-config
- » ps
- » psql
- » rar
- » readelf
- » renice
- » rm
- » rmmod
- » route
- » rpcinfo
- » rpm
- » rsync
- » screen
- » sed
- » sendmail
- » seq
- » setfacl
- » sfdisk
- » showmount
- » shred
- » smartctl
- » smbclient
- » smbget
- » smbpasswd
- » socat
- » sort
- » sox
- » split
- » ssh
- » ssh-keygen
- » stat
- » stdbuf
- » strace
- » svn, svnadmin
- » systool
- » tail
- » tar
- » tcpdump
- » top
- » tr
- » tracepath
- » traceroute
- » tune2fs
- » udevcontrol, udevadm
- » unclutter
- » uniq
- » unzip
- » uuencode, uudecode
- » vim
- » vncviewer
- » vnstat
- » wc
- » wget
- » wput
- » xargs
- » xhost
- » xprop
- » xrandr
- » xwd
- » xxd
- » yum
- » zip, zip{cloak,note,split}
- KDE
- GTK
CONTENT
- CHANGES
Szukaj
#top top¶
top - display Linux tasks
Powiązane:
iotop, lsof, pidof, ps, top,
SYNOPSIS
top -hv | -bcHisS -d delay -n iterations -p pid [, pid ...]
DESCRIPTION
OPTIONS
The command-line syntax for top consists of:
-hv | -bcHisSM -d delay -n iterations -p pid [,pid...]
The typically mandatory switches ('-') and even whitespace are completely optional.
-b : Batch mode operation
-c : Command line/Program name toggle
-d : Delay time interval as: -d ss.tt (seconds.tenths)
-h : Help
-H : Threads toggle
-i : Idle Processes toggle
-n : Number of iterations limit as: -n number
-u : Monitor by user as: -u somebody
-U : Monitor by user as: -U somebody
-p : Monitor PIDs as: -pN1 -pN2 ... or -pN1, N2 [,...]
-s : Secure mode operation
-S : Cumulative time mode toggle
-v : Version
-M : Detect memory units
-hv | -bcHisSM -d delay -n iterations -p pid [,pid...]
The typically mandatory switches ('-') and even whitespace are completely optional.
-b : Batch mode operation
Starts top in 'Batch mode', which could be useful for sending output from top to other programs or to a file. In this mode, top will not accept input and runs until the iterations limit you've set with the '-n' command-line option or until killed.
-c : Command line/Program name toggle
Starts top with the last remembered 'c' state reversed. Thus, if top was displaying command lines, now that field will show program names, and visa versa. See the 'c' interactive command for additional information.
-d : Delay time interval as: -d ss.tt (seconds.tenths)
Specifies the delay between screen updates, and overrides the corresponding value in one's personal configuration file or the startup default. Later this can be changed with the 'd' or 's' interactive commands.
Fractional seconds are honored, but a negative number is not allowed. In all cases, however, such changes are prohibited if top is running in 'Secure mode', except for root (unless the 's' command-line option was used). For additional information on 'Secure mode' see topic 5a. SYSTEM Configuration File.
Fractional seconds are honored, but a negative number is not allowed. In all cases, however, such changes are prohibited if top is running in 'Secure mode', except for root (unless the 's' command-line option was used). For additional information on 'Secure mode' see topic 5a. SYSTEM Configuration File.
-h : Help
Show library version and the usage prompt, then quit.
-H : Threads toggle
Starts top with the last remembered 'H' state reversed. When this toggle is On, all individual threads will be displayed. Otherwise, top displays a summation of all threads in a process.
-i : Idle Processes toggle
Starts top with the last remembered 'i' state reversed. When this toggle is Off, tasks that are idled or zombied will not be displayed.
-n : Number of iterations limit as: -n number
Specifies the maximum number of iterations, or frames, top should produce before ending.
-u : Monitor by user as: -u somebody
Monitor only processes with an effective UID or user name matching that given.
-U : Monitor by user as: -U somebody
Monitor only processes with a UID or user name matching that given. This matches real, effective, saved, and filesystem UIDs.
-p : Monitor PIDs as: -pN1 -pN2 ... or -pN1, N2 [,...]
Monitor only processes with specified process IDs. This option can be given up to 20 times, or you can provide a comma delimited list with up to 20 pids. Co-mingling both approaches is permitted.
This is a command-line option only. And should you wish to return to normal operation, it is not necessary to quit and and restart top -- just issue the '=' interactive command.
This is a command-line option only. And should you wish to return to normal operation, it is not necessary to quit and and restart top -- just issue the '=' interactive command.
-s : Secure mode operation
Starts top with secure mode forced, even for root. This mode is far better controlled through the system configuration file (see topic 5. FILES).
-S : Cumulative time mode toggle
Starts top with the last remembered 'S' state reversed. When 'Cumulative mode' is On, each process is listed with the cpu time that it and its dead children have used. See the 'S' interactive command for additional information regarding this mode.
-v : Version
Show library version and the usage prompt, then quit.
-M : Detect memory units
Show memory units (k/M/G) and display floating point values in the memory summary.
EXAMPLES
Interactive command:
t
- wyświetlanie obciążenia procesora (1
- dla wszystkich procesorów),m
- wyświetlanie ilości zużycia pamięci operacyjnej,s
- zmiana częstotliwości odświeżania,W
- zapis bieżących ustawień (do $HOME/.toprc),Non-interactive command:
Poniższe polecenie wyświetlaja w sposób ciągły informacje o uruchomionych procesach posortowane od procesu w korzystającego najintensywniej z procesora:
Aby przerwać należy nacisnąc CTRL+C
top
top -d 1 -n 3
top - 14:44:22 up 122 days, 19 min, 6 users, load average: 2.00, 2.94, 3.78 PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 8455 qemu 20 0 1364m 985m 348 S 6.9 8.3 967:58.59 qemu-kvm 5083 qemu 20 0 842m 513m 320 S 2.9 4.3 797:43.69 qemu-kvm 8545 qemu 20 0 842m 477m 320 S 2.9 4.0 1010:31 qemu-kvm 5660 qemu 20 0 582m 260m 400 S 2.0 2.2 324:45.16 qemu-kvm 3885 sp 20 0 19036 3952 424 S 1.0 0.0 50:43.98 top 5084 root 20 0 0 0 0 S 1.0 0.0 44:47.93 kvm-pit-wq 9687 qemu 20 0 594m 240m 324 S 1.0 2.0 326:23.18 qemu-kvm 28273 root 20 0 15200 1404 868 R 1.0 0.0 0:00.08 top 1 root 20 0 19244 480 292 S 0.0 0.0 8:05.58 init [...]
Zmodyfikowany ostatnio: 2015/12/03 14:44:53 (9 lat temu),
textsize: 6,05 kB,
htmlsize: 6,90 kB
Zapraszam do komentowania, zgłaszania sugestii, propozycji, własnych przykładów, ...
Dodaj komentarzKomentarze użytkowników