[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: 20050616: Scour.conf settings



Hi Peter,

Yes, place it in the cron table...

crontab -e is the command to edit the file.

You can do a:

man cron


for more info on how to use cron...

Cheers,

Jeff
---------------------------------------------------------------------
Jeff Weber                                    address@hidden        :
Unidata Program Center                        PH:303-497-8676        :
University Corp for Atmospheric Research      3300 Mitchell Ln       :
http://www.unidata.ucar.edu/staff/jweber      Boulder,Co 80307-3000  :
---------------------------------------------------------------------

On Fri, 17 Jun 2005, peter Msikela wrote:

>
> Jeff,
>
> The command crontab -l return the msg " no crontab for ldm", and below is
> the crontab file.The command ldmadmin scour seems to work fine.Do you
> know how to set scour so that it run automatically instead of run
> ldmadmin scour manually?.
>
> thanks,
>
> Peter
>
> [ldm@drizzle ldm-6.3.0]$ whereis crontab
> crontab: /usr/bin/crontab /etc/crontab /usr/share/man/man5/crontab.5.gz
> /usr/share/man/man1/crontab.1.gz
>
> [ldm@drizzle ldm-6.3.0]$ cd /etc/
>
> [ldm@drizzle etc]$ crontab -l
> no crontab for ldm
>
> [ldm@drizzle etc]$ vi crontab
>
> -------------------------------------------------------------------
>
> SHELL=/bin/bash
> PATH=/sbin:/bin:/usr/sbin:/usr/bin
> MAILTO=root
> HOME=/
>
> # run-parts
> 01 * * * * root run-parts /etc/cron.hourly
> 02 4 * * * root run-parts /etc/cron.daily
> 22 4 * * 0 root run-parts /etc/cron.weekly
> 42 4 1 * * root run-parts /etc/cron.monthly
> 0  0 * * * bin/ldmadmin newlog
>
> --------------------------------------------------------------------------------
>
>
>
>
>
>
>
>
>
> >From: Jeff Weber <address@hidden>
> >To: peter Msikela <address@hidden>
> >CC: ldm-support <address@hidden>
> >Subject: 20050616: Scour.conf settings
> >Date: Thu, 16 Jun 2005 14:20:13 -0600 (MDT)
> >
> >Hi Peter,
> >
> >When/how do you run scour.conf?
> >
> >Is it set in your crontab?
> >
> >What does crontab -l return...?
> >
> >Or run:
> >
> >ldmadmin scour
> >
> >as a line command....
> >
> >I suspect this ~may be the issue. Scour does not run automatically, it
> >needs to be placed in your cron table or run it via the line command.
> >
> >
> >Cheers,
> >
> >
> >Jeff
> >---------------------------------------------------------------------
> >Jeff Weber address@hidden :
> >Unidata Program Center PH:303-497-8676 :
> >University Corp for Atmospheric Research 3300 Mitchell Ln :
> >http://www.unidata.ucar.edu/staff/jweber Boulder,Co 80307-3000 :
> >---------------------------------------------------------------------
> >
> >On Thu, 16 Jun 2005, peter Msikela wrote:
> >
> > >
> > > Hi Jeff,
> > >
> > > Soory for late reply,we had power problems in our lab,so we had to
> > > shutdown all machines.But my question was why the old dataproducts
> files
> > > still exist even if you set one day as "the time to live" in
> scour.conf?
> > >
> > > For example,below is the scour.conf and the path to directory to
> > > delete,but as you can see there are some files which have been
> created
> > > couple of months ago and they are still exists.
> > >
> > >--------------------------------------------------------------------------------
>
> > > ---------------------------
> > >
> > > # Configuration file for "scour" utility, to delete all files older
> than
> > > a
> > > # specified number of days from specified directories and all their
> > > # subdirectories. Scour should be invoked periodically by cron(8).
> > > #
> > > # Each line consists of a directory, a retention time (in days), and
> > > # (optionally) a shell filename pattern for files to be deleted. If
> no
> > > # filename pattern is specified, "*" representing all files not
> beginning
> > > # with "." is assumed.
> > > #
> > > # A hash in column one indicates a comment line.
> > >
> > > # Directory Days-old Optional-filename-pattern
> > >
> > > #~ldm/data/dir1 2
> > > #~ldm/data/dir2 2 *.foo
> > > #~ldm/logs 1 *.stats
> > > /var/data/ldm 1 *
> > >
> > > [ldm@drizzle ldm]$ pwd
> > > /var/data/ldm
> > > [ldm@drizzle ldm]$ ls -l
> > > total 398580
> > > drwxrwxr-x 5 ldm ldm 4096 Mar 23 23:14 ldm
> > > -rw-rw-r-- 1 ldm ldm 407732224 Jun 16 11:43 ldm.pq
> > > drwxrwxr-x 2 ldm root 4096 Mar 24 16:06 logs
> > > [ldm@drizzle ldm]$ cd ldm
> > > [ldm@drizzle ldm]$ ls -l
> > > total 12
> > > drwxrwxr-x 2 ldm ldm 4096 Jun 14 10:19 nowcast
> > > drwxrwxr-x 3 ldm ldm 4096 Mar 23 23:11 surface
> > > drwxrwxr-x 3 ldm ldm 4096 Jun 13 20:28 WWA
> > > [ldm@drizzle ldm]$ cd nowcast
> > > [ldm@drizzle nowcast]$ ls -l
> > > total 520
> > > -rw-rw-r-- 1 ldm ldm 1067 Jun 12 21:31 ABQ
> > > -rw-rw-r-- 1 ldm ldm 689 Jun 6 07:52 ABR
> > > -rw-rw-r-- 1 ldm ldm 324 May 7 11:23 ADQ
> > > -rw-rw-r-- 1 ldm ldm 675 Jun 12 00:05 AFC
> > > -rw-rw-r-- 1 ldm ldm 760 Jun 14 01:40 AFG
> > >
> > > thanks,
> > >
> > > Peter
> > >
> > >
> > >
>
>