Monitoring resource CPU, Memory dan Network menggunakan aplikasi dstat

Install dulu aplikasinya… Bisa menggunakan yum atau rpm.
Kalau pake yum tinggal jalanin perintah ini di console atau terminal

yum install dstat

Beberapa option penggunaan dstat :

[ahmadi@localhost ~]$ dstat –help
Usage: dstat [-afv] [options..] [delay [count]]
Versatile tool for generating system resource statisticsDstat options:
-c, –cpu enable cpu stats
-C 0,3,total include cpu0, cpu3 and total
-d, –disk enable disk stats
-D total,hda include hda and total
-g, –page enable page stats
-i, –int enable interrupt stats
-I 5,eth2 include int5 and interrupt used by eth2
-l, –load enable load stats
-m, –mem enable memory stats
-n, –net enable network stats
-N eth1,total include eth1 and total
-p, –proc enable process stats
-r, –io enable io stats (I/O requests completed)
-s, –swap enable swap stats
-S swap1,total include swap1 and total
-t, –time enable time/date output
-T, –epoch enable time counter (seconds since epoch)
-y, –sys enable system stats–aio enable aio stats
–fs enable fs stats
–ipc enable ipc stats
–lock enable lock stats
–raw enable raw stats
–socket enable socket stats
–tcp enable tcp stats
–udp enable udp stats
–unix enable unix stats
–vm enable vm stats-M stat1,stat2 enable external plugins
–mods stat1,stat2

–list list all internal and external plugins

-a, –all equals -cdngy (default)
-f, –full expand -C, -D, -I, -N and -S discovery lists
-v, –vmstat equals -pmgdsc -D total

–integer show integer values
–nocolor disable colors (implies –noupdate)
–noheaders disable repetitive headers
–noupdate disable intermediate updates
–output file write CSV output to file

delay is the delay in seconds between each update
count is the number of updates to display before exiting
The default delay is 1 and count is unspecified (unlimited)

Contoh penggunaan jika ingin di export ke file csv biar nanti bisa dijadiin grafik melalui excel… ( wah kok melalui excel, gak menggunakan open office calc? karena saya belum bisa buat grafik menggunakan calc sampe sekarang ^_^ )

[ahmadi@localhost ~]$ dstat -tam –output contohdstat.csv 50

penjelasannya
-tam -> t=time, a=all ( default, memory belum termasuk ), m=memory
–output contohdstat.csv -> di export ke file yang bernama contohdstat.csv
50 -> delay count atau setiap 50 detik sekali baru update… Satuannya detik.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s