2 calls to unlink in checkresults
Jon Angliss
jon at netdork.net
Thu May 14 05:46:17 CEST 2009
On Wed, 13 May 2009 17:47:06 -0400, Mathieu Gagné <mgagne at iweb.com>
wrote:
>Hi,
>
>I did a strace on the Nagios daemon and found out there's 2 calls to
>unlink for each check result file in checkresults.
I believe they're only temporary files to contact results from a
specific check.
>For example:
>
>stat64("/usr/local/nagios/var/spool/checkresults/cXKYnMY",
>{st_mode=S_IFREG|0600, st_size=475, ...}) = 0
>stat64("/usr/local/nagios/var/spool/checkresults/cXKYnMY.ok",
>{st_mode=S_IFREG|0600, st_size=0, ...}) = 0
>time(NULL) = 1242249182
>open("/usr/local/nagios/var/spool/checkresults/cXKYnMY", O_RDONLY) = 7
>fstat64(7, {st_mode=S_IFREG|0600, st_size=475, ...}) = 0
>mmap2(NULL, 475, PROT_READ, MAP_PRIVATE, 7, 0) = 0xb7ee8000
>munmap(0xb7ee8000, 475) = 0
>close(7) = 0
>unlink("/usr/local/nagios/var/spool/checkresults/cXKYnMY") = 0
>unlink("/usr/local/nagios/var/spool/checkresults/cXKYnMY.ok") = 0
>
>[......]
>
>unlink("/usr/local/nagios/var/spool/checkresults/cXKYnMY") = -1 ENOENT
>(No such file or directory)
>unlink("/usr/local/nagios/var/spool/checkresults/cXKYnMY.ok") = -1
>ENOENT (No such file or directory)
>
>
>Any idea about the source of this problem? (if it's one)
Are you seeing a problem? It's supposed to unlink them I believe. See
base/utils.c delete_check_result_file, I believe that's probably where
you're seeing the two unlink calls come from.
--
Jonathan Angliss
<jon at netdork.net>
------------------------------------------------------------------------------
The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your
production scanning environment may not be a perfect world - but thanks to
Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700
Series Scanner you'll get full speed at 300 dpi even with all image
processing features enabled. http://p.sf.net/sfu/kodak-com
More information about the Developers
mailing list