# These is a sample crontab entry to call the maintenance script from cron. #------------------------------------------------------------------------------ # Run the weekly maintenance script to clean up old users, labels, workspaces # and changelists. This requires the maintenance.cfg file to have a configuration # section for the given instance. 0 20 * * 4 /p4/common/bin/run_if_master.sh ${INSTANCE} /p4/sdp/Maintenance/maintenance ${INSTANCE} 0 19 * * 4 /p4/common/bin/run_if_edge.sh ${INSTANCE} /p4/sdp/Maintenance/edge_maintenance ${INSTANCE} # Workaround for p4d bugs related to orphaned locks, already fixed. # Run 'p4 unlock -x' on master and edge servers each hour to clear orphaned remove exclusive locks # that shouldn't be there. */60 * * * * [ -e /p4/common/bin ] && /p4/common/bin/run_if_master.sh ${INSTANCE} p4 unlock -x > /dev/null 2>&1 */60 * * * * [ -e /p4/common/bin ] && /p4/common/bin/run_if_edge.sh ${INSTANCE} p4 unlock -x > /dev/null 2>&1