LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-10-2003, 08:38 PM   #1
linear
LQ Newbie
 
Registered: Oct 2001
Location: Somewhere on top of a red mountain looking down
Distribution: CMENOEor
Posts: 26

Rep: Reputation: 15
Crontab Question


Ok I run a local gameserver that is associated with a my remote webserver wich I regulary update the stats manually.
Here is my question I would like to use crontab to run my /stats/stats.pl every 23 hour (11pm).. im not sure what the command should look like i think it would look like this

* 23 * * * * nice /stats/stats.pl >/dev/null 2>&1

if im right please let me know.. optionally I would like to beta test running the update every 12 hours would it look something like this?

* 0,12 * * * * nice /stats/stats.pl >/dev/null 2>&1

If my above hypothosis is correct how would I make that a permanent setting on the crontab, where I will not have to re enter one these commands at every boot?

Im running slackware 8.0

Regards Linear/ZeN

-----------------------------------------------------------------------
www.zenscow.com
 
Old 01-10-2003, 11:51 PM   #2
leed_25
Member
 
Registered: Jul 2002
Location: san francisco
Distribution: freebsd
Posts: 102

Rep: Reputation: 17
crontab -e
 
Old 01-11-2003, 01:22 AM   #3
moses
Senior Member
 
Registered: Sep 2002
Location: Arizona, US, Earth
Distribution: Slackware, (Non-Linux: Solaris 7,8,9; OSX; BeOS)
Posts: 1,152

Rep: Reputation: 48
man crontab
man crond

in /var/spool/cron/crontabs, you'll find user specific crontab files.
in /etc/cron.[hourly|daily|weekly|monthly] you'll find system crontab
files.
It looks like you've got an extra "*" in there. . .
Quote:
Code:
       # MIN HOUR DAY MONTH DAYOFWEEK   COMMAND
       # at 6:10 a.m. every day
       10 6 * * * date

Last edited by moses; 01-11-2003 at 01:26 AM.
 
Old 01-11-2003, 02:33 AM   #4
linear
LQ Newbie
 
Registered: Oct 2001
Location: Somewhere on top of a red mountain looking down
Distribution: CMENOEor
Posts: 26

Original Poster
Rep: Reputation: 15
Heh thats what I thought about the extra "*" wasnt sure so if I do the above mentioned minus one "*" the crontab will do this automaticly like an alarm clock right?

btw hey fellow slacker..
 
Old 01-11-2003, 03:42 AM   #5
moses
Senior Member
 
Registered: Sep 2002
Location: Arizona, US, Earth
Distribution: Slackware, (Non-Linux: Solaris 7,8,9; OSX; BeOS)
Posts: 1,152

Rep: Reputation: 48
Yeah, it should work. Make sure you read the man page and
check out their examples. . .
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
crontab question kaplan71 Linux - General 4 07-18-2005 05:04 PM
Crontab question stefaandk Linux - Newbie 1 06-21-2005 08:31 AM
crontab question linuxtesting2 Linux - General 5 09-21-2004 05:54 PM
crontab question DriveMeCrazy Linux - Newbie 1 05-23-2004 01:25 PM
Crontab Question? f117bomb Linux - General 5 02-09-2002 08:28 PM


All times are GMT -5. The time now is 04:51 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration