[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 483: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4688: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4690: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4691: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
[phpBB Debug] PHP Warning: in file [ROOT]/includes/functions.php on line 4692: Cannot modify header information - headers already sent by (output started at [ROOT]/includes/functions.php:3823)
Cheshire Cat Computing • View topic - MRTG , Segmentation Fault , After re-installing perl .

Cheshire Cat Computing

Software support and information
It is currently Mon Nov 10, 2025 6:18 pm

All times are UTC + 12 hours [ DST ]




Post new topic Reply to topic  [ 6 posts ] 
Author Message
PostPosted: Sat Feb 07, 2009 9:12 am 
Offline
Gold user

Joined: Fri Mar 07, 2008 8:51 am
Posts: 125
Location: Fairbanks , AK
Does anyone have any ideas for me to check on that maybe causing this ?

rrdtool [info|fetch] work fine on the example .cfg's .rrd file .
routers2.cgi reports itself in good health on the offending *.cfg as well .

From below my best guess is that hte segfault is happening in the line with 'RRDs::updatev' .
And of course I am way over my head with trying to trace that down .

Even even after upgrading to mrtg-2.16.2 , we still get a segfault .

Tia , JimL

# Editted a copy of mrtg to help find the area after the last debug logged , See below , ...

--- /usr/local/mrtg-2/bin/mrtg-workingon 2009-02-06 10:05:23.000000000 -0900
+++ /usr/local/mrtg-2/bin/mrtg 2009-02-06 09:58:37.000000000 -0900
@@ -845,22 +845,18 @@
warn "$NOW: ERROR: Cannot tune logfile: $e\n" if $e;
}
# update the rrd
$inlast = 'U' unless defined $inlast and $inlast =~ /\S/ and $inlast ne '##UNDEF##';
$outlast = 'U' unless defined $outlast and $outlast =~ /\S/ and $outlast ne '##UNDEF##';
-#
debug('log', "RRDs::update($dotrrd, '$time:$inlast:$outlast')");
my $start = gettimeofday();
my $rrddata;
if ( $RRDs::VERSION >= 1.2 ){
-#
$rrddata=RRDs::updatev($dotrrd, "$time:$inlast:$outlast");
} else {
-#
RRDs::update($dotrrd, "$time:$inlast:$outlast");
}
-#
debug('prof',sprintf("RRDs::update $dotrrd - %.3fs",gettimeofday()-$start));
my $e = RRDs::error();
warn "$NOW: ERROR: Cannot update $dotrrd with '$time:$inlast:$outlast' $e\n" if ($e);

if ( $RRDs::VERSION < 1.2 ){


Yes when it segfaults it doesn't do any cleanup .
# rm /var/www/htdocs/router2cgi/cfg/*_l_*

# /usr/local/mrtg-2/bin/mrtg --debug="base,snpo,snpo2,coca,repo,fork,time,log,eval,prof" /var/www/htdocs/router2cgi/cfg/to-rtr01.cfg >> ~/mrtg-the-last-area-before-segfault.log 2>&1

--time: prog start Fri Feb 6 10:07:31 2009
--base: Creating Lockfiles /var/www/htdocs/router2cgi/cfg/to-rtr01.cfg_l,/var/www/htdocs/router2cgi/cfg/to-rtr01.cfg_l_7765
--base: Reading Config File: /var/www/htdocs/router2cgi/cfg/to-rtr01.cfg
--base: Reading Interface Config cache
--base: Checking Config File
--base: Loading RRD support
--base: Loading default Locale
--base: Starting main Loop
--time: loop start Fri Feb 6 10:07:31 2009
--base: Populate Target object by polling SNMP and external Datasources
--time: snmp read start Fri Feb 6 10:07:31 2009
--snpo: run snmpget from ifInOctets&ifOutOctets:6f4@I#NB$@to-rtr01
--snpo: simple If: .1
--snpo: simple If: .1
--snpo: SNMPGet from 6f4@I#NB$@to-rtr01: -- ifInOctets.1,ifOutOctets.1
--snpo: SNMPfound -- '517463880', '3391376386'
--snpo: run snmpget from ifInOctets&ifOutOctets:6f4@I#NB$@to-rtr01
--snpo: simple If: .2
--snpo: simple If: .2
--snpo: SNMPGet from 6f4@I#NB$@to-rtr01: -- ifInOctets.2,ifOutOctets.2
--snpo: SNMPfound -- '3137038639', '254183055'
--snpo: run snmpget from .1.3.6.1.2.1.2.2.1.14&.1.3.6.1.2.1.2.2.1.20:6f4@I#NB$@to-rtr01
--snpo: simple If: .1
--snpo: simple If: .1
--snpo: SNMPGet from 6f4@I#NB$@to-rtr01: -- .1.3.6.1.2.1.2.2.1.14.1,.1.3.6.1.2.1.2.2.1.20.1
--snpo: SNMPfound -- '16954', 'undef'
--snpo: run snmpget from .1.3.6.1.2.1.2.2.1.14&.1.3.6.1.2.1.2.2.1.20:6f4@I#NB$@to-rtr01
--snpo: simple If: .2
--snpo: simple If: .2
--snpo: SNMPGet from 6f4@I#NB$@to-rtr01: -- .1.3.6.1.2.1.2.2.1.14.2,.1.3.6.1.2.1.2.2.1.20.2
--snpo: SNMPfound -- 'undef', 'undef'
--time: target loop start Fri Feb 6 10:07:31 2009
--base: Act on Router/Target to-rtr01_1
--base: Get Current values: in:517463880, out:3391376386, up:undef, name:undef, time:1233947251
--base: Create Graphics
--base: start RRDtool section
--base: maxi:48000, maxo:48000
--log: RRDs::tune(/var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd -a ds0:48000 -a ds1:48000 -d ds0:COUNTER -d ds1:COUNTER)
--prof: RRDs::tune /var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd - 0.000s
--log: RRDs::update(/var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd, '1233947251:517463880:3391376386')
Segmentation fault

# tail -1 /var/log/messages
Feb 6 10:07:31 dsb-mntr01 kernel: mrtg[7765]: segfault at 00000001 eip b7e3922b esp bfbfeb40 error 4


Not that this is the culprit , but ...
routers2-v2.20-Beta4

Even mrtg-2.16.2 causes a segfault .

# head /usr/local/mrtg-2/bin/mrtg
#! /usr/local/bin/perl -w
# -*- mode: cperl -*-

###################################################################
# MRTG 2.16.1 Multi Router Traffic Grapher
###################################################################
# Created by Tobias Oetiker <tobi@oetiker.ch>
# and Dave Rand <dlr@bungi.com>

# rrdtool --version
RRDtool 1.3.6 Copyright 1997-2008 by Tobias Oetiker <tobi@oetiker.ch>
Compiled Feb 6 2009 09:28:18

# perl --version

This is perl, v5.10.0 built for i686-linux

Copyright 1987-2007, Larry Wall


Top
 Profile Send private message  
 
PostPosted: Sat Feb 07, 2009 12:02 pm 
Offline
Gold user

Joined: Fri Mar 07, 2008 8:51 am
Posts: 125
Location: Fairbanks , AK
Hello all , Well an strace isn't shedding any good light on the difficulty(ies) .
Seems fcntl64 (a kernel item) mzay be the culprit . I haven't updated the kernel . Tho I probably should (eventually) . Tho it could be the next call to 'something' that is actually failing , But I am not able to acquire that readily .
Again any hints on where to look please pipe up .
Tia , JimL


# strace -f /usr/local/mrtg-2/bin/mrtg --debug="base,snpo,snpo2,coca,repo,fork,time,log,eval,prof" /var/www/htdocs/router2cgi/cfg/to-rtr01.cfg 2>&1 | tee ~/strace-mrtg-the-last-area-before-segfault.log


# tail -20 ~/strace-mrtg-the-last-area-before-segfault.log
write(2, "--prof: RRDs::tune /var/www/htdo"..., 86--prof: RRDs::tune /var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd - 0.002s
) = 86
write(2, "--log: RRDs::update(/var/www/htd"..., 114--log: RRDs::update(/var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd, '1233956397:553429700:3414135629')
) = 114
gettimeofday({1233956398, 821161}, NULL) = 0
open("/var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd", O_RDWR) = 5
utime("/var/www/htdocs/router2cgi/graphs/to-rtr01/to-rtr01_1.rrd", NULL) = 0
fstat64(5, {st_mode=S_IFREG|0674, st_size=94584, ...}) = 0
fadvise64(5, 0, 0, POSIX_FADV_RANDOM) = 0
mmap2(NULL, 94584, PROT_READ|PROT_WRITE, MAP_SHARED, 5, 0) = 0xb7cc0000
madvise(0xb7cc0000, 94584, 0x1 /* MADV_??? */) = 0
madvise(0xb7cc0000, 112, MADV_SEQUENTIAL|0x1) = 0
madvise(0xb7cc0000, 240, MADV_SEQUENTIAL|0x1) = 0
madvise(0xb7cc0000, 864, MADV_SEQUENTIAL|0x1) = 0
madvise(0xb7cc0000, 8, MADV_SEQUENTIAL|0x1) = 0
gettimeofday({1233956398, 823497}, NULL) = 0
fcntl64(5, F_SETLK, {type=F_WRLCK, whence=SEEK_SET, start=0, len=0}) = 0
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
Process 6293 detached


Top
 Profile Send private message  
 
PostPosted: Sat Feb 07, 2009 12:46 pm 
Offline
Gold user

Joined: Fri Mar 07, 2008 8:51 am
Posts: 125
Location: Fairbanks , AK
Well it is 'RRDS::updatev' I commented out this 'if' area leaving only 'RRDS::update' .
No error but , 'RRDs::update' does NOT update the file .
Now I have to figure out why .
Again , Any insite into where & how to cure this is appreciated .
tnx , JimL


Top
 Profile Send private message  
 
PostPosted: Mon Feb 09, 2009 10:33 am 
Offline
Site Admin

Joined: Tue Jul 29, 2003 11:42 am
Posts: 3039
Location: Auckland, New Zealand
Might be worth passing this on to the mrtg-dev and rrdtool-dev mailing lists? Its getting a bit deep into the RRD library internals for me.

_________________
Steve Shipway
UNIX Systems, ITSS, University of Auckland, NZ
Woe unto them that rise up early in the morning... -- Isaiah 5:11


Top
 Profile Send private message  
 
PostPosted: Thu Feb 12, 2009 11:39 am 
Offline
Gold user

Joined: Fri Mar 07, 2008 8:51 am
Posts: 125
Location: Fairbanks , AK
Hello Steve ,
Fyi (only) I have to stand corrected the plain RRDs::update works fine . I'll try to get this thread to the lists you mentioned .
Thank you . JimL


Top
 Profile Send private message  
 
PostPosted: Fri Feb 13, 2009 5:12 pm 
Offline
Gold user

Joined: Fri Mar 07, 2008 8:51 am
Posts: 125
Location: Fairbanks , AK
Hello Steve , Url & this threads contents sent to rrd-developers & mrtg-developers , today .
Twyl , JimL


Top
 Profile Send private message  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC + 12 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 14 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group