NSClient++ Help (#1) - Problem with checkfile2 checking for old files with 0.3.8 [SOLVED] (#505) - Message List

Problem with checkfile2 checking for old files with 0.3.8 [SOLVED]

Hi,

I have made a clean test case for the problem I have with the latest nighly. If it is fixed in the next stable I am perfectly happy to wait. I can live with the truncate problem I have in the existing stable. Let me know if you need any more information or if I should create a trac. (or just wait for next version)

The problem is that I dont get the same (correct) result everytime I run the same command on the same target. It seem to work one time after restart and then something goes highwire.

1

Tested on win2003sp2 NSClient++ 0.3.8.11 2010-01-26 By pasting command in the local win command prompt.

2

Test file

dir c:\test /T:C
13-02-2010  11:25                 0 test.txt
dir c:\test /T:W
13-02-2010  11:25                 0 test.txt

3

Start the test prompt and paste: checkfile2 path=c:\test filter+written=gt:1m MaxCrit=1

4 Debug log

2010-02-13 11:49:08: debug:NSClient++.cpp:1073: Injecting: checkfile2: path=c:\test, filter+written=gt:1m, MaxCrit=1
2010-02-13 11:49:08: debug:NSClient++.cpp:1109: Injected Result: CRITICAL 'test.txt, found files: 1 > critical'
2010-02-13 11:49:08: debug:NSClient++.cpp:1110: Injected Performance Result: '''''found files'=1;0;1; ''''
2010-02-13 11:49:13: debug:NSClient++.cpp:1073: Injecting: checkfile2: path=c:\test, filter+written=gt:1m, MaxCrit=1
2010-02-13 11:49:13: debug:NSClient++.cpp:1109: Injected Result: OK 'CheckFile ok'
2010-02-13 11:49:13: debug:NSClient++.cpp:1110: Injected Performance Result: '''''found files'=0;0;1; ''''
2010-02-13 11:49:15: debug:NSClient++.cpp:1073: Injecting: checkfile2: path=c:\test, filter+written=gt:1m, MaxCrit=1
2010-02-13 11:49:15: debug:NSClient++.cpp:1109: Injected Result: OK 'CheckFile ok'
2010-02-13 11:49:15: debug:NSClient++.cpp:1110: Injected Performance Result: ''found files'=0;0;1; '
2010-02-13 11:49:16: debug:NSClient++.cpp:1073: Injecting: checkfile2: path=c:\test, filter+written=gt:1m, MaxCrit=1
2010-02-13 11:49:16: debug:NSClient++.cpp:1109: Injected Result: OK 'CheckFile ok'

5 then after a while it sometimes comes back

2010-02-13 11:51:46: debug:NSClient++.cpp:1073: Injecting: checkfile2: path=c:\test, filter+written=gt:1m, MaxCrit=1
2010-02-13 11:51:46: debug:NSClient++.cpp:1109: Injected Result: CRITICAL 'test.txt, found files: 1 > critical'
2010-02-13 11:51:46: debug:NSClient++.cpp:1110: Injected Performance Result: ''found files'=1;0;1; '
  • Message #1625

    I am thinking this is solved in the latest nightly?

    Michael Medin

    • Message #1627

      Yes, I have just made a very quick test but it looks ok now. It must have been the "now" problem.

      thanks!

      • Message #1628

        Yes, I did some refactoring and lost the init for the variable so all time related checks where broken :)

        Michael Medin

Subscriptions