Forum

Monitor

fetch_webserver cron job hangs in 'top'
21 November 2012, 20:45
I've got my Hiawatha sites running under the /home folder of the user 'webadmin' who belongs to the group www-data.
-webadmin's crontab is programmed to fetch_webserver_logs on the 7th minute of every hour...
-the log files are all located at: /var/log/hiawatha, which belongs to www-data, and has drwxrwxr-x permissions
-hiawatha is programmed to write "extended" log files to "sitename-access.log" and "sitename-error.log"

For some reason when I pulled up "top," the fetch_webserver_logs is still running 25 minutes later, and the load average is 1.5+

Where do I start troubleshooting this one?

Ron

Hiawatha version: v8.6
Operating System: Ubuntu 12.04 LTS
Hugo Leisink
21 November 2012, 22:18
Run it manually. Add print statements at random places in the code to see if it reaches that place. My guess is that is hangs on downloading the logfiles.
Ron Jones
21 November 2012, 23:59
1. how would I add a print statement in the (fetch_webserver_logs?) code?

2. I reinstalled monitor, and recreated the database. During the next few moments, I noticed that monitor's db entries (requests, events, etc) have very different timestamps than the clock in my server.

For example: right now the date time stamp is 2012-11-21 16:57. But the last 'requests' time says 2012-11-19 00:47:37.

Perhaps that is a contributing factor. How would I adjust it to pick up the time from the server?
Hugo Leisink
22 November 2012, 19:15
1. Open the script in an editor and add a print statement. This requires knowledge about PHP.

2. Try the ntpdate tool. This sets the corrent time on your server. Make sure the timezone is set correctly (tzselect and /etc/timezone).
This topic has been closed.