7 # Mark Huang <mlhuang@cs.princeton.edu>
8 # Copyright (C) 2006 The Trustees of Princeton University
10 # $Id: crond,v 1.5 2006/06/23 20:29:22 mlhuang Exp $
13 # Source function library and configuration
14 . /etc/plc.d/functions
15 . /etc/planetlab/plc_config
20 # Export so that we do not have to specify -p to psql invocations
21 export PGPORT=$PLC_DB_PORT
25 MESSAGE=$"Starting crond"
28 if [ "$PLC_MAIL_ENABLED" = "1" ] ; then
29 MAILTO=$PLC_MAIL_SUPPORT_ADDRESS
33 cat >/etc/cron.d/plc.cron <<EOF
35 PATH=/sbin:/bin:/usr/sbin:/usr/bin
39 # minute hour day-of-month month day-of-week user command
40 */5 * * * * root gen-slices-xml-05.py
41 */15 * * * * root gen-sites-xml.py
42 */15 * * * * root gen-static-content.py
43 */15 * * * * root dns-config
44 5 5 * * * root vacuumdb -U postgres --all --analyze --quiet
47 # Run them once at startup
56 vacuumdb -U postgres --all --analyze --quiet
66 MESSAGE=$"Stopping crond"