Forum Moderators: phranque

Message Too Old, No Replies

phpadsnew maintenance question

how to run maintenance

         

benevolent001

12:03 pm on May 7, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi
I am using phpadsnew to serve ads to my website.The problem is that it stops serving ads after two days again i log in to system and says the maintenance script has not run since 24 hours so you should run it

after seeing the message i added a cron job in cpanel
as to run every day and added following line to run

[domain.com...]

the email report which i got says the following

/bin/sh: line 1: [domian.com...] No such file or directory

What i am doing wrong how to set maintenance to run regularly ,am loosing lot of revenue due to non showing of ads by the server.

please help
Thanks

benevolent001

3:51 am on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



anyone please

NeedScripts

5:19 am on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Well I am glad you using CPanel, as I also use the same and do know how to setup maintenance for PhpAdsNew via Cpanel ;)

Here is the cron job setup line (change user with username of the domain)

0 * * * * php /home/user/public_html/phpadsnew-path/maintenance/maintenance.php

this should work.

Vishal

benevolent001

7:20 am on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thank You Vishal your heart is really vishal :)

One clarification

In cpanel there are

Minute
Hour
Day
Month
Weekday
Command

I assume i have to write

Minute0
Hour*
Day*
Month*
Weekday*
Command php /home/user/public_html/phpadsnew-path/maintenance/maintenance.php

and is there space between php / or its php/home

NeedScripts

9:20 am on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Minute0
Hour*
Day*
Month*
Weekday*

Yes

and is there space between php / or its php/home

Single Space between php & /home/, so suppose if the username is benevolent001 and the subdirectory is myads, then you should use below line for Cron Manager.

php /home/benevolent001/public_html/myads/maintenance/maintenance.php

:)

Vishal

benevolent001

1:14 pm on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Thank you sir,it was really troubling me too much.
I will catch you in case i find any new problem
thanks once again

benevolent001

3:15 pm on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



okay now i am getting email report like this

Content-type: text/html
X-Powered-By: PHP/4.3.10
Pragma: no-cache
Cache-Control: private, max-age=0, no-cache
Date: Sun, 08 May 2005 15:00:00 GMT

Does this means its working fine

earlier it was saying no file there

NeedScripts

4:53 pm on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You will be getting 1 email every minute if it is working fine, so you might want to setup email filter to delete all those messages (error message has different content then success, so setup filter for success email) ... else you will have a full mailbox in no time..

Vishal

benevolent001

5:16 pm on May 8, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Yes
I am getting these mails every hour but now deleted that email address from cron jobs to prevent notifications to reach me

internetlab

8:26 pm on Jun 10, 2005 (gmt 0)

10+ Year Member



I have the exact same problem as the original post except I use Ensim. Is there an easy way to setup a cron job in Ensim? My server company tech support has set up the cron job multiple times for me but every couple of days when I log into PhpAdsNew the script tells me that the cron job has not run in the last 24 hours. The cron job needs to run every hour.

I tried connecting to my server through SSH (I have limited knowledge in this area) and running the cron job command as outline in the directions but I am a little confused about the directions.

The directions outlined in the documentation are listed below:

Step 1
Export cron schedule:

crontab -l > cron.txt

Step2:
0 * * * * curl -s -o /devnull [virtual.servername.com...]

Step 3:
Import file back into cron daemon

crontab cron.txt

My questions are as follow:
Step1 - When you type the command (crontab -l > cron.txt) into SSH what directory does it export the file to?

Step 2
Is this command correct? My hosting company told me what to fill in for server name and preceed it with virtual. The server is Linux, Apache.

Step 3
Which directory do you place the cron file in for import?

Thanks