rrosnowski
Joined: 22 Sep 2004 Posts: 15
|
Posted: Wed Oct 20, 2004 10:00 am Post subject: script problem |
|
|
Hey Cacti Rocks... i am trying to get weatherbug working as an excercise for getting custome scripts to work. I am having a problem getting it to work. Initially i could run the program no problem from the command, but when i ran cmd.php, i got some errors.
| Code: | #!/usr/bin/php -q
10/20/2004 10:16:46 AM - CMDPHP: Poller[0] PHP Script Server Started Properly
: bad interpreter: No such file or directoryweatherbug.pl: /usr/bin/perl
10/20/2004 10:16:46 AM - CMDPHP: Poller[0] Host[0] WARNING: Result from CMD not valid. Partial Result:
10/20/2004 10:16:46 AM - CMDPHP: Poller[0] Host[0] CMD: /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl, output: U
|
i edited weatherbug.pl and added -w at the top and got it to worked kinda!
| Code: |
#!/usr/bin/php -q
10/20/2004 11:00:08 AM - CMDPHP: Poller[0] PHP Script Server Started Properly
Malformed UTF-8 character (unexpected continuation byte 0xb0, with no preceding start byte) in substitution (s///) at /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl line 5.
Malformed UTF-8 character (unexpected continuation byte 0xb0, with no preceding start byte) in substitution (s///) at /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl line 5.
Malformed UTF-8 character (unexpected continuation byte 0xb0, with no preceding start byte) in substitution (s///) at /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl line 5.
Malformed UTF-8 character (unexpected continuation byte 0xb0, with no preceding start byte) in substitution (s///) at /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl line 5.
Malformed UTF-8 character (unexpected continuation byte 0xb0, with no preceding start byte) in substitution (s///) at /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl line 5.
Malformed UTF-8 character (unexpected continuation byte 0xb0, with no preceding start byte) in substitution (s///) at /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl line 5.
10/20/2004 11:00:09 AM - CMDPHP: Poller[0] Host[0] CMD: /usr/local/apache2/htdocs/cacti/scripts/weatherbug.pl, output: current_temp:46 wind_speed:4 barometer:3010 humidity:100 high_temp:46 low_temp:45 dew_point_temp:46 wind_chill_temp:44
10/20/2004 11:00:10 AM - CMDPHP: Poller[0] Host[7] SNMP: Host responded to SNMP
10/20/2004 11:00:10 AM - CMDPHP: Poller[0] Host[7] RECACHE: Processing 1 items in the auto |
Anyone know what is going wrong? |
|