This is a discussion on [mrtg] MRTG Script error within the MRTG forums, part of the Networking and Network Related category; I am facing a littile problem in creating MRTG Graph for Disk I/O perfromance. I created script to collect ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
I am facing a littile problem in creating MRTG Graph for Disk I/O perfromance. I created script to collect read/write data by thie following script. ################################ #disk.sh #!/bin/bash Kbr=`iostat -x |grep sda | awk '{print $7}' |sed "s/[.]//"` Kbw=`iostat -x |grep sda | awk '{print $6}' |sed "s/[.]//"` echo $Kbr echo $Kbw ################################ If I run disk.sh, it shows me following result which is ok 429 26 My disk.cfg is as follows... ################################ Target[disk]: `/usr/local/mrtg-2/bin/disk.sh` Title[disk]: Disk HDA I/O Utilization Report #Unscaled[disk]: dwym MaxBytes[disk]: 10240000 PageTop[disk]: Disk I/O Utilization Report kmg[disk]: KB,MB,GB LegendI[disk]: Disk I/O KBread/sec LegendO[disk]: Disk I/O KBwrite/sec Legend1[disk]: Disk I/O KBread/sec Legend2[disk]: Disk I/O KBwrite/sec YLegend[disk]: Megabytes ShortLegend[disk]: & Options[disk]: growright,gauge,nopercent ################################# But when i set it in MRTG , it shows me follwing error and donot updatedisk Graph. ################## 2008-04-21 17:04:02 -- Started mrtg with config '/usr/local/mrtg-2/bin/mrtg.cfg' 2008-04-21 17:04:38 -- 2008-04-21 17:04:02: WARNING: Problem with External get '/usr/local/mrtg-2/bin/disk.sh': Expected a Number for 'in' but got '' 2008-04-21 17:04:38 -- 2008-04-21 17:04:02: WARNING: Problem with External get '/usr/local/mrtg-2/bin/disk.sh': Expected a Number for 'out' but got '' 2008-04-21 17:04:38 -- 2008-04-21 17:04:38: ERROR: Target[disk][_IN_] ' $target->[47]{$mode} ' did not eval into defined data 2008-04-21 17:04:38 -- 2008-04-21 17:04:38: ERROR: Target[disk][_OUT_] ' $target->[47]{$mode} ' did not eval into defined data ############################# What could be the error ??? Regards, __________________________________________________ _______________ Invite your mail contacts to join your friends list with Windows Live Spaces. It's easy! http://spaces.live.com/spacesapi.asp...aspx&mkt=en-us _______________________________________________ mrtg mailing list mrtg@lists.oetiker.ch https://lists.oetiker.ch/cgi-bin/listinfo/mrtg |
![]() |
| Thread Tools | |
| Display Modes | |
|
|