Re: [Nagios-devel] problem with cgiutils.c on solaris 10?

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
Guest

Re: [Nagios-devel] problem with cgiutils.c on solaris 10?

Post by Guest »

Brian Peterson wrote:
> I'm having a problem getting the avail.cgi and trend.cgi scripts working
> on Solaris 10. They both seem to seg fault while processing the archive
> logs in a memcpy function found in cgiutils.c. Has anyone else seen
> this or know how to get around this problem? The problem seems to exist
> in 2.0 as well as 2.3.
>
> Here's a quick dbx trace of the seg fault.
>
> #244 dbx avail.cgi
> For information about new features see `help changes'
> To remove this message, put `dbxenv suppress_startup_message 7.5' in
> your .dbxrcReading avail.cgi
> Reading ld.so.1
> Reading librt.so.1
> Reading libc.so.1
> Reading libaio.so.1
> Reading libmd5.so.1
> (dbx) run
> Running: avail.cgi
> (process id 8256)
> Cache-Control: no-store
> Pragma: no-cache
> Last-Modified: Tue, 09 May 2006 23:39:55 GMT
> Expires: Thu, 01 Jan 1970 00:00:00 GMT
> Content-type: text/html
>
[snip]
> signal SEGV (no mapping at the fault address) in _memcpy at 0xfeed43f2
> 0xfeed43f2: _memcpy+0x0032: movb 0x00000002(%esi),%cl
> Current function is mmap_fgets
> 1206 memcpy(buf,(char
> *)(temp_mmapfile->mmap_buf+temp_mmapfile->current_position),len);
> (dbx) where
> [1] _memcpy(0x8047780, 0x80661dd, 0x8774cc8, 0xfebd5fbe), at 0xfeed43f2
> =>[2] mmap_fgets(temp_mmapfile = 0x8147380), line 1206 in "cgiutils.c"
> [3] scan_log_file_for_archived_state_data(filename = 0x8047090
> "/opt/nagios/var/archives/nagios-05-08-2006-00.log"), line 2911 in
> "avail.c"
> [4] read_archived_state_data(), line 2878 in "avail.c"
> [5] main(argc = 1, argv = 0x80477c4), line 994 in "avail.c"
>
>
> Brian Peterson
> [email protected]
>

Is anyone else experiencing this problem? Perhaps the problem lies with
the pointer arithmetic, although I'm not sure.


Ethan Galstad,
Nagios Developer
---
Email: [email protected]
Website: http://www.nagios.org





This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]
Locked