Questions tagged [cron]

cron is a task scheduler based on clock time that runs on Linux-based machines.

898 questions
99
votes
8 answers

How can I view results of my cron jobs?

I see so many guides on how to run crontab, but what I need right now is to learn how to Find log files about cron jobs Configure what gets logged
Zombies
  • 3,792
  • 11
  • 46
  • 60
81
votes
4 answers

How to run a cron job as a specific user?

I would like to run a cron job as a specific user on my machine. How may I specify the user for a cron job to run as?. The cron jobs will be running on a server (running on Ubuntu 10.0.4). The 'users' are users that have been created specifically…
morpheous
  • 4,263
  • 12
  • 32
  • 30
80
votes
11 answers

How to stop a currently running cron job?

How can I stop a cron job which is currently running?
GURU KUMAR
80
votes
11 answers

How can I get a script to run every day on Mac OS X?

Cron? Launchd? iCal?? If so, how?
Paul D. Waite
  • 6,434
  • 11
  • 49
  • 72
79
votes
13 answers

How to make WSL run services at startup

After searching this site and various Q, it is clear that services and systemd is not available for WSL. I need to run a program in WSL every time I start my PC so I read this page on how to use crontab: How to run Ubuntu service on Windows (at…
seanbw
  • 933
  • 1
  • 8
  • 9
74
votes
7 answers

Run a command every week with Cron?

Simple question- what would a crontab entry look like for a command I want to run every week on Saturday at 8:05 AM?
igul222
  • 993
  • 1
  • 8
  • 8
71
votes
2 answers

Set a cron every certain hours between certain hours

How can I set a cron to run every 2 hours between 8 am and 5 pm for example? Is this possible?
luqita
  • 831
  • 1
  • 6
  • 6
57
votes
18 answers

Run a cron job on the first Monday of every month?

I'd like to run a job from cron at 8.30 on the first Monday of every month. The cron Wikipedia page says While normally the job is executed when the time/date specification fields all match the current time and date, there is one exception:…
Max Williams
  • 2,917
  • 6
  • 29
  • 38
57
votes
2 answers

Difference between /etc/crontab and "crontab -e"

What is the difference between the crontab located in /etc/crontab and the crontab that can be edited using crontab -e?
jrdioko
  • 12,445
  • 5
  • 27
  • 26
47
votes
1 answer

what is run-parts in /etc/crontab, and how do I use it

I have been digging through my Linux system. To try and understand how it all works In the /etc/crontab file. I see the following # run-parts 01 * * * * root run-parts /etc/cron.hourly 02 4 * * * root run-parts /etc/cron.daily 22 4 * * 0 root…
nelaaro
  • 13,149
  • 30
  • 84
  • 111
46
votes
4 answers

Log of cron actions on OS X

Does the cron which comes with OS X log its actions anywhere? I'm not looking for output of any particular cron job, but rather log of what cron is doing. On a couple linux machines I've checked, there's /var/log/cron which has contents like: Apr…
Doug Harris
  • 27,333
  • 17
  • 78
  • 105
40
votes
3 answers

What is the point of system-autodeath?

In a previous question I found a "system autodeath cron job" which would shut down my default network route daily. As I have never heard of such a thing before, I would like to know what it exactly it is and what purpose does it serve?
bobby
  • 543
  • 1
  • 4
  • 17
39
votes
9 answers

Error adding cronjobs in Mac OS X Lion

Until now, I have never attempted adding a crontask on my Mac. To my surprise, it threw an error.. [hayek@mac:/www/] 02:33:22 PM: crontab -e 1…
Hayek
  • 1,975
  • 3
  • 21
  • 26
36
votes
2 answers

Why doesn't my cron.d per minute job run?

I have thrown a bunch of darts trying to get a python script of mine to execute every minute. So I thought I'd simplify it to just do the "simplest thing that could could possibly work" once per minute (I'm running debian/testing). I created a…
Travis Griggs
  • 731
  • 1
  • 8
  • 14
35
votes
5 answers

How do I run a launchd command as root

I have the following launchctl command as a .plist file. It's loaded and set to run once a day but, it needs to run as root and I'm not sure how to verify this. Also, this cron job basically CDs into a directory and runs a command. I'm sure…
Emmanuel Mwangi
  • 453
  • 1
  • 4
  • 5
1
2 3
59 60