Cron is a time-based job scheduler in Unix-like computer operating systems. Cron enables users to schedule jobs (commands or shell scripts) to run periodically at certain times or dates.

learn more… | top users | synonyms (2)

-3
votes
1answer
189 views

Cron jobs fail to run on raspberry pi (STAT FAILED shows in syslog) [closed]

I have a Raspberry Pi server in a remote location (it's a weather station). I have set up a few python scripts that I would like to run via cron. Sometimes, everything works fine. Other times, none ...
0
votes
1answer
36 views

CURL isn't running from Crontab

Here is the output. Not sure if cron isn't running or other issue. If I issue curl --silent http://..../scanner.php from terminal, I'm getting desired output. Actually scanner.php do some check and ...
0
votes
2answers
807 views

Can't run AWS CLI from CRON (credentials)

Trying to run a simple AWS CLI backup script. It loops through lines in an include file, backs those paths up to S3, and dumps output to a log file. When I run this command directly, it runs without ...
3
votes
1answer
145 views

How can I find what's starting crond?

I need to stop crond at the command line. (I'm writing a script which needs to stop it, do some work, and then start it again. I'd rather not remove and replace the crontab file because it's more ...
0
votes
1answer
47 views

Automysqlbackup - dumped files have wrong permissions

This question has been askewd here. But it was not answered. I just got a 3rd server and on all 3 servers I use Automysqlbackup script to create MySQL backups. I do it with cronjob: 52 04 * * * ...
1
vote
2answers
47 views

Hourly Clamscan cron script failes at reading file list

I've this piece of code located in /etc/cron.hourly/hourlyclamscan. #!/usr/bin/bash # Create Hourly Cron Job With Clamscan # Directories to scan SCAN_DIR=/home/transmission/Downloads # Temporary ...
8
votes
6answers
17k views

How to disable everything in crontab -l?

I just want to pause everything. Don't execute anything listed on crontab -l.
0
votes
1answer
293 views

Is it better to use the systemd service unit's Restart & RestartSec, or use a systemd timer unit?

I have a couple of in-house automated scripts running at periodic intervals. One is every five minutes, the other is every minute. They don't really need to be ran on-the-dot; e.g. I don't care if ...
4
votes
4answers
2k views

How to schedule a biweekly cronjob?

crontab(5) defines the following fields: field allowed values ----- -------------- minute 0-59 hour 0-23 day of month 1-31 ...
0
votes
2answers
102 views

crontab's invalid time checking is inconsistent

One of our DBAs created the following crontab entry to run a backup every 3 hours starting 6:30 AM to midnight every day: 30 6-24/3 * * * (path to backup script) Cron took the entry but did not run ...
0
votes
2answers
194 views

What mailer does cron use to send mail?

I am trying to debug an issue with cron not sending mail on a Centos 6 box that I did not configure. How can I determine which mailer cron is using to send mail? The crontab man page has this to say, ...
2
votes
3answers
1k views

For tripwire, how would I have the report e-mailed only when a violation is found

My ideal solution for tripwire reports would be: Daily e-mails would only generate if a violation was found Every Sunday, a report would be e-mailed regardless of whether a violation was found I'm ...
0
votes
1answer
690 views

vi.recover/update command appears every minute in cron log. (POSSIBLE VIRUS)

UPDATE (7th Dec 2010) & WARNING: I copied the files discussed below (from the /var/tmp/vi.recover directory) to my Windows PC and sacnned with ESET NOD 32. It identifed two of the file (sshd: and ...
0
votes
1answer
272 views

Is there a way to restart automatically the HHVM service if I get a '502 Bad Gateway Error'?

I've reported the error on stackoverflow - from time to time my Nginx/PageSpeed+HHVM+MariaDB+WordPress blog stops working. There is some problem with the HHVM service that I don't locate, and I'm ...
-1
votes
2answers
149 views

Cronjob run every two weeks, on Saturday, starting on this saturday [duplicate]

Today is Friday, October 3, 2014 3:58 AM I want to schedule a cronjob like that to run it at the following dates: Saturday, October 4, 2014 8:00 AM Saturday, October 18, 2014 8:00 AM Saturday, ...
0
votes
0answers
53 views

pppd call to restart VPN ineffectual from a CRON

This works when I run it directly but never from a cron it is the 'pppd call OM01' which seems to be ineffectual when run from a cron. #!/bin/bash # vpnTest.sh test if you ping via the VPN # if ping ...
13
votes
3answers
5k views

Override MAILTO for a single crontab entry

We have a role account at work that has a pretty big crontab. Its MAILTO is pointed at a shared address, so that a number of us get notified if something fails. I'd like to add an entry to this ...
0
votes
0answers
45 views

cron vs anacron on server machine (AWS instance)

During review of environment which I took over I've discovered that Amazon Linux uses anacron by default which means that cron.weekly jobs are executed somewhere between 3a.m. and 10p.m. Moreover - ...
0
votes
1answer
46 views

Daily postgresql cron error log file

I am getting these emails daily: /etc/cron.daily/logrotate: error: error accessing /var/log/postgresql: No such file or directory error: postgresql-common:1 glob failed for /var/log/postgresql/.log ...
0
votes
1answer
139 views

Sending cron output as a text file attachment

I sysadmin a multiplayer game at CentOS 6.5 Linux server for a customer. The customer has requested me to send the daily chat logs (to identify and ban agressive players) - as a text file ...
0
votes
1answer
58 views

Cronjob for a bash script pauses for 2 minutes randomly

I have been running a bash script on CEntOS 5.5 machine that checks replication on a remote mysql server. The script creates a temporary lock file and is scheduled to run in Crontab every minute. But ...
22
votes
6answers
2k views

Outgrowing cron: what's the next scheduler?

We've been using cron for about as long as I can remember to handle all of our job scheduling needs. Everything from storage clones/snapshots to reports against databases to daily system reports to ...
-1
votes
1answer
16 views

some services switched off automatically

with my company we have a VPS. We have some issues with it. this morning the pure-ftpd was stopped. I had to start also postfix and the cron jobs were off for 3 hours. My config : Debian GNU/Linux 7 ...
0
votes
3answers
2k views

Non-root user is not allowed to use crontab due to PAM restrictions [closed]

I have the issue that I am not able to use cron with my normal user ( other than root ) [coins@COINS-TEST ~]$ crontab -l Authentication service cannot retrieve authentication info You (coins) are ...
2
votes
1answer
106 views

Should I use cron.hourly or crontab?

It seems that all the suggestions for using/scheduling awstats is via crontab, as such: 0 * * * * /usr/local/awstats/wwwroot/cgi-bin/awstats.pl -config=mysite -update >/dev/null (running awstats ...
49
votes
3answers
39k views

Why is my crontab not working, and how can I troubleshoot it?

This is a Canonical Question about using cron & crontab. The answer for 'Why is my crontab not working, and how can I troubleshoot it?' can be seen below. This addresses the cron system with ...
0
votes
1answer
46 views

zip in cron doesn't work, but zip from command is working [duplicate]

I need to back up a directory with zip -r /savehere/backup_`date +%y%m%d%H%M%S` /save/this -q It works fine. But not from crontab: * * * * zip -r /savehere/backup_`date +%y%m%d%H%M%S` /save/this ...
0
votes
2answers
135 views

crontab fails, cannot find aws executable

I am trying to run a backup script on my ec2 amazon server (ubuntu 14.04), to automatically create a snapshot of amazon ebs volumes. Therefore I am using the aws-missing-tools script: ...
0
votes
1answer
41 views

simple crontab every 5min not working [duplicate]

I am trying to setup a crontab to execute a command from a specific user. Here is my code in "crontab -e". Why is this not working ? */5 * * * * user /home/user/whoami>swag.txt I am running ...
-5
votes
3answers
55 views

Crontab is not working [closed]

I am trying to add a new script to crontab using putty. I am following these steps: open putty enter my username / password enter command crontab -e to create new crontab copying this command to ...
2
votes
1answer
211 views

Have a Vagrant VM destroy itself or power off on completion of a long-running task

I've been using Vagrant with Ansible to perform certain ETL tasks. This has provided some flexibility and transparency: jobs can be easily be moved around and the YAML playbook provides some level of ...
-2
votes
2answers
201 views

Cron not launching python script

Python script is not being run, all other functions are running and stand alone script runs but combined... nada. Initially it was */30 * * * * screen python ~/db_preset.py (Yes there was new line ...
-1
votes
1answer
19 views

issues with cron file in cron.d

running amazon ami (similar to centos.) this is what I found on cron file under /var/log : Sep 4 15:32:01 mike crond[2289]: (root) BAD FILE MODE (/etc/cron.d/mytasks) and this is my file mytasks ...
-2
votes
3answers
90 views

crontab job is setting date wrongly [duplicate]

I need to set date and time in my server in order to make them synced always. I cannot use ntp inside my channel due to proxy issues. I've found this workaround. It works fine when I run it in command ...
1
vote
2answers
299 views

SQL Server DBA moving to Greenplum / Postgres on Linux ( Centos ) looking for friendly MS Sql Agent like scheduler instead of CRON

To be honest, I and others are spoiled by Microsoft's SQL Agent. We'd really like to keep properties of SQL Agent : the features, the usable GUI. I searched serverfault for an evaluation of ...
1
vote
1answer
1k views

how to properly run a scrapy crawl from cron

How would I run a command like scrapy crawl empt.com in a cron job where I need to be in a specific folder to run the command for example: /downloads/my_crawler/empt/empt/ then the command scrapy ...
0
votes
2answers
92 views

cron ignores changes to /etc/crontab

I'm seeing strange cron behavior which I'm not sure how to debug and fix. It ignores changes to /etc/crontab until restarted, e.g. I edit /etc/crontab adding * * * * * root echo 'weee' > ...
1
vote
1answer
43 views

crontab truncates file path

I try to run the following command: crontab -u root /root/iss/current/node/bin/installers/nl_brandless_selector_full_hd/nl_brandless_selector_full_hd_cron_file But I got an error like this: ...
2
votes
3answers
466 views

Server incremental backup to AWS Glacier

I'm looking to backup various directories and files from a Linux server to AWS Glacier. I'm trying to work out the details on how to do manage this. Incremental Backups I want to upload files ...
-4
votes
3answers
112 views

cronjob or similar to open a local php file including query [closed]

How do I open the following file with cronjob correctly every 5 minutes: /var/www/mysite/folder/foo.php?query=1 I tried myself but i just did not get it working... i tried with /usr/share/php5 , ...
0
votes
2answers
5k views
0
votes
1answer
457 views

cron.daily not running at the time it should?

My /etc/cron.daily scripts seem to be executing far later from what I understand they should. I am in Ubuntu and anacron is installed. If I do a sudo cat /var/log/syslog | grep cron I get something ...
1
vote
2answers
295 views

Kill all currently running cron jobs

For some reason my cron job scripts aren't exiting cleanly and they're backing up my server. There are currently a couple hundred processes running for one of my users. I can use the following command ...
0
votes
2answers
974 views

shell script within crontab

I can run the following shell script from command prompt as expected: /bin/sh -xv /home/shantanu/backup_transfer.sh But when I set it in a cron, it does not execute correctly. There are 2 ...
-2
votes
1answer
341 views

Crontab not working to send email [closed]

I have CentOs 6.5 running on a VPS Host. I installed crontab and email using the below commands yum install vixie-cron service start crond chkconfig crond --levels 235 on yum install sendmail ...
5
votes
1answer
4k views

Users cannot use crontab after password security upgrade

I have a box being upgraded from CentOS 5 to CentOS 6. On the original server, all users have MD5 passwords. The upgraded server is now using SHA-512 passwords. Users who have changed their password ...
0
votes
0answers
38 views

Cron sends error email every 24 hours

I receive the following email from cron every 24 hours. Header: Cron <example@box500> ~/public_html/admin/backup-from-cron.php 2>&1 > /dev/null Body: /bin/sh: ...
0
votes
0answers
25 views

Crond stopped sending e-mails for no apparent reason [duplicate]

I have a cron job that I want to run just once a day (executes a rake task), but while I'm testing it I have it set to run every 5 minutes. It was running perfectly fine this morning and sending me ...
4
votes
7answers
18k views

script to automatically test if a web site is available

I'm a lone web developer with my own Centos VPS hosting a few small web sites for my clients. Today I discovered my httpd service had stopped (for no apparent reason - but that's another thread). I ...
0
votes
1answer
62 views

Spam emails from Suse server: test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp

Have a virtual server with old Suse. About a month ago cron started spamming me with emails like this: Subject: test -x /etc/init.d/sendmail && /usr/share/sendmail/sendmail cron-msp ...