I am trying to monitor the number of files in a directory, I am able to use the following command at the shell to get the results.
find /var/qmail/queue/mess/ -type f -print | wc -l
I would like to use PRTG to monitor this but when I put it into a script it comes back with the error message below, although it does show the correct number in there but does not work correctly. I read through the API document and that it needs to be formatted correctly but due to my lack of skills in the development line of work I am looking for some help.
Response not wellformed: "2 " (code: PE132)
Would anyone be able to help me out with a script I could use to monitor the output?