This is a discussion on cron.daily question within the Slackware Linux Support forums, part of the Unix Operating Systems category; --> Ralph Alvy wrote: > Joost Kremers wrote: > > >>Ralph Alvy <ralvy@warpmail.net> writes: >> >> >>>I have, by default, ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Ralph Alvy wrote: > Joost Kremers wrote: > > >>Ralph Alvy <ralvy@warpmail.net> writes: >> >> >>>I have, by default, an slocate script in cron.daily, however I see no >>>evidence that that script ever runs. Is there something I need to do to >>>make Slack run that script daily, other than have it in that directory >>>and make sure it's executable? >> >>take a look at root's crontab (do 'crontab -l' as root). then you'll see >>what happens when you put a script in cron.daily. >> > > Thanks to all. After reading up on crontab with man, I did > > crontab -l > > as root and found how to form the file I needed. I then did > > crontab -l > > as user and, as expected, found no listings at all. So I did > > crontab -e > > as user and created a similar file, but made sure the values I used caused > operations during midday. My computer is off when I retire for the night. I > got a nice explanation of the meanings of the different values in that file > here: http://tinyurl.com/5hysr Since most of the jobs in the cron.daily directory are run on night hours and my box too is off I put in rc.local as last command: batch <<DONE /usr/bin/run-parts /etc/cron.daily DONE This forces the execution of all daily activities that cron schedules during the night. Ciao Giovanni -- A computer is like an air conditioner, it stops working when you open Windows. Registered Linux user #337974 <http://counter.li.org/> |
| |||
| -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 _.-In alt.os.linux.slackware, Wim wrote the following -._ > Keith Keller wrote: >> Oops. I forgot that I can only run updatedb as root. Will the root crontab >> run even when not logged in as root? Perhaps a silly question. > > Not a silly question and yes, root's crontab will always run (even when > not logged in as root). Lets make that clearer. Every users crontab will run even when that user is not logged in. crontab is there to run apps that 1) need to be run at regular intervuls. 2) need to be run when the user is not logged in. In an ideal world you should never be logged in as root so if cron jobs didn't run if you weren't logged in then roots jobs would never be run. - -- .-')) asciipr0n.com/fp ('-. | It's a damn poor mind that ' ..- .:" ) ( ":. -.. ' | can only think of one way to ((,,_;'.;' UIN=66618055 ';. ';_,,)) | spell a word. ((_.YIM=Faux_Pseudo :._)) | - Andrew Jackson -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQFBulaeSJec2PH9pbURAkh2AJsEgmu5k90cCpZGwgmUTX VOfYmmvACdGLDp mwCg0DBnJrO1IK8CodqGyhU= =KaBN -----END PGP SIGNATURE----- |
| |||
| Faux_Pseudo wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > _.-In alt.os.linux.slackware, Wim wrote the following -._ >> Keith Keller wrote: >>> Oops. I forgot that I can only run updatedb as root. Will the root >>> crontab run even when not logged in as root? Perhaps a silly question. >> >> Not a silly question and yes, root's crontab will always run (even when >> not logged in as root). > > Lets make that clearer. Every users crontab will run even when that > user is not logged in. > > crontab is there to run apps that 1) need to be run at regular > intervuls. 2) need to be run when the user is not logged in. > > In an ideal world you should never be logged in as root so if cron > jobs didn't run if you weren't logged in then roots jobs would never > be run. Yep. Very clear. Thanks. |