Nagios_Grapher and RRD input

Hi All
I Installed Nagios_Grapher to display graphs for my service performance data.
And it seems to work just fine…however i have a problem.

I want to monitor my DNS servers response time.
The check_dns plugin returns with the following format in the ngraph.log file:

DNS OK: 0,024 seconds response time DNSSERVERHOSTNAMEREMOVED returns 10.0.2.13 time=0,024347s;;;0,000000

And i use the following ngraph definition to store it:

define ngraph{
service_name DNS
graph_perf_regex time=([0-9,]+)
graph_value DNS
graph_units Seconds
graph_legend Lookup Response time
page DNS
rrd_plottype AREA
rrd_color 0066c0
}

Now my problem is the following:
The response made by the DNS filter uses a comma (,) to display its time…instead of a dot (.) as is more common for floating points…
This results in the rrdtool complaining that it cannot convert the floating point.
An example:
2005-11-16 19:22:49 RRD: [hostname][IMAP]:conversion of ‘0,026833’ to float not complete: tail ‘,026833’

Howerver…this is not happening always (though most of the time).

Anyone got an idea as to how this is, or how to replace the , with a . (i tried all sorts of regexp using s// and tr// but either im too stupid or it won’t work the way collect2.pl parses the log)

./check_dns -H google.com
DNS OK: 0.006 seconds response time google.com returns 64.233.187.99,72.14.207.99|time=0.005580s;;;0.000000

My check_dns plugin even has perf data output. I suppose it’s possible that the problem is with your plugin and not the dns, Try the google.com. Does that give you a comma also? If so, then it would be the plugin, if not, then you are right, it’s the dns you are using.

Seems like it might be a problem with the host region/language settings.
Danish conventions for floating points is a comma, so it would make sense…guess i just have to change the region setting then…bad hack :confused:

Changing locale from en_DK to en_US did the trick.