Web Hosting Talk







View Full Version : Cron Jobs


TheDuck
06-08-2005, 05:58 PM
Not sure which forum to post this in.

I am trying to setup Cron Jobs to save the daily raw access log file from cPanel to a folder on the server.

The problem is that I am not a programmer and no very little about Linux command line. I am learning fast though. The problem I am having is getting the file because of the location on the server, I think that it’s also because the log file is created when I click on the link in cPanel.

Can anyone give me a sample command line that I can use? Please!

Here is the url with a bit of editing
http://255.255.255.255:1080/getaccesslog/accesslog_username_6_8_2005.gz

Thanks for the help
Richie Schut (Cron Noob)

WO-Jacob
06-08-2005, 06:57 PM
wget --http-user=username --http-passwd=password http://<ip>:<port>/<path to file>

Edit: Glad to see you coming along on this :)

TheDuck
06-08-2005, 07:49 PM
I get the error message below

/bin/sh: line 1: /usr/bin/wget: Permission denied

I am guessing that means that I cant use wget? Is that right?

Thanks
Richie Schut

WO-Jacob
06-08-2005, 07:50 PM
Yeah... that's what that would mean. i guess the next step would be to use libCURL in PHP... though i'm not sure how you'd go about a file download with it.

TheDuck
06-08-2005, 08:06 PM
I am going to try setting up cron jobs on one of my local computers and use wget on that machine instead of on the server. Thanks for your help.

Richie Schut

Googled
06-08-2005, 11:56 PM
Hi,

there's better way to achieve this using a little of php.

http://www.josheli.com/vox/

plenty of scripts to achieve nice tricks with cpanel such as backups, awstats outside of cpanel.

Worth a try :)