Questions tagged [cron]

Cron is a time-based job scheduler found in most Unix-like computer operating systems, like macOS. Cron is driven by a crontab (cron table) file, a configuration file that specifies commands to run periodically on a given schedule. This tag should be use when dealing with any cron issues.

147 questions
5
votes
1 answer

Will a crontab job wake OS X up from sleep?

Since OS X has its own task scheduler, launchd, it appears that crontab is a relic. Hence I'm wondering: Will a cron job (crontab) wake OS X up from sleep? In case it matters, I'm on Yosemite 10.10.5. Why I'm not switching to launchd? Laziness: >…
Calaf
  • 4,359
2
votes
1 answer

What timezone is cron in?

If I run crontab -e and add a cronjob 4 5 * * * "echo hi", the job will run at 5:04 of what timezone? Let's say the laptop displays time in PST in the top menu bar and sudo systemsetup -gettimezone is Time Zone: America/Los_Angeles. I tried running…
Almenon
  • 253
2
votes
1 answer

Can't open crontab

I tried running crontab on my Mac for the first time and got the following: $ crontab -e crontab: no crontab for User - using an empty one crontab: subl -w: No such file or directory crontab: "subl -w" exited with status 1 I've never used crontab…
1
vote
1 answer

Where should I put cron jobs?

I have some shell code that I'd like to execute daily using cron. Currently, I have the entire code written as a one-liner, and the 6 variations (each designed to run at different times) are all written in the crontab. While this works, it's quite…
tjcaul
  • 266
1
vote
1 answer

Stop cron daemon "symmetrical.xm" error messages in Terminal mail

After upgrading to High Sierra (I think) I've started receiving the following message almost every time I start up Terminal: You have new mail in /var/mail/MyUsername I had some problems upgrading to High Sierra so I strongly suspect this started…
sabriele
  • 115
1
vote
2 answers

"Temporary" folder

I often download images, take screenhots, and save files that I am only going to use for a little until it can be discarded. I want to create a folder which deletes the contents inside it every few days ad midnight to conserve space on my mac. My…
0
votes
1 answer

why won't my cron command work?

I have manually added a command to my crontab file (Monterey 12.6.9). Pretty simple; the crontab entry is something like: 0 10 * * * mv /Users/me/Desktop/test /Users/me/Desktop/test2 Which means, at 10am every day, do this rename. But it simply…
user637
  • 11
0
votes
1 answer

Using tar on crontab causes it to use multiple processes which consume all cpu

The following line is the only line in crontab: * 13 * * * sh /Users/gentaliaru/Dropbox/work/scripts/backup.sh >/tmp/stdout.log 2>/tmp/stderr.log And the script contents are rm -rf /Volumes/X5/backup/git.tar.tz tar -cvzf /Volumes/X5/tmp/git.tar.tz…
Infira
  • 1
0
votes
1 answer

Cron job cannot find ffprobe/avprobeor ffmpeg/avconv even though its installed

I have a cronjob setup to run "/Users/admin/Scripts/youtubedl.sh" Script: cd "/Users/admin/Music/youtubedl-music" /usr/local/bin/youtube-dl -o "%(title)s.%(ext)s" --download-archive .mydownloads -i -f bestaudio --extract-audio --audio-format mp3…
Tim Apple
  • 109
  • 1
  • 8
0
votes
1 answer

Crontab didn't work as intended

I set crontab but nothing happened, crontab -l 03 04-22 * * * python /me/radio_alarm.py What's the reason, the command works as intended in Linux.
Wizard
  • 2,589