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)

2
votes
2answers
20 views

Is it possible to determine if a job is being started as an at job (kicked off via atd/cron)?

Is there a way to identify a script is being run as an at job instead of interactively from the shell by a user? Some of our scripts have a guard to check if they're running in screen by checking ...
1
vote
2answers
954 views

Capturing output from a remotely executed command via SSH fails in CRON

This question is in a direct relation to this one: ssh fails to execute remote command when run from cron bash script - works from CLI I'm not able to comment on the accepted answer as I don't have ...
1
vote
2answers
499 views

Cron getting timeout when attempting to access url (wget).

I'm sure this is simple and I've been digging but no answer is quite as specific as I need it to be. The goal is easy, have Cron hit a url on my server every 5 minutes. All of that is set up and ...
1
vote
2answers
127 views

Cron job sends out the same data every time despite changes in the database

This question is related to Gentoo Linux. I have cron job that runs every morning at 10AM. The cron job calls a bash script which in turn calls a groovy script that queries the database for a column ...
1
vote
2answers
137 views

libc segfault when running cron

I am trying to submit the job using drqueue's sendjob tool. When doing this from the terminal it works just fine. However, when doing this from cron, I get segmentation fault at libc (2.11.3-4). I ...
1
vote
2answers
499 views

'/var/spool/cron' is not a directory, bailing out. when trying to work with crontab via PHP's shell_exec

I am creating a web application. Part of the functionality is depending on that the user can start/stop a cronjob that imports emails. It doesn't work. Just to make sure I'm on the right track, as ...
1
vote
2answers
175 views

Check if cron ran and have fallback

I have written a realtime bus tracking program that runs a cron every minute to check the service of the bus. In order to remove some server resources I am going to be creating an instance on PHPfog ...
1
vote
2answers
325 views

Dealing with cron jobs and MySQL/CPU contention on a single dedicated server architecture

We have a single small EC2 instance where we run a front-end server (php5-fpm/nginx) but also a lot of fetching cron php scripts inserting a lot of data (2k+rows every ~15min) which seems to ...
1
vote
2answers
305 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 ...
0
votes
2answers
52 views

Crontab: Authentication token expired; new one is required

I have a crontab job running daily as a non-root user job. Unfortunately it did stop working with the following message (in /var/log/syslog): CRON[29256]: Authentication token is no longer valid; new ...
0
votes
1answer
84 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 ...
0
votes
1answer
26 views

Starting a detached screen has no effect

I want to start a shell script in detached mode on ubuntu bootup (via cronjob @reboot) but it doesn't even work when I try it directly. Syntax: screen -d -m -S myscreenname /path/to/my/script.sh ...
0
votes
1answer
144 views

How to make sure script is always running?

I have 4 scripts in crontab that start on server boot. After 12 hours or so, some throw an exception and stop running. At that point, I want my server to just start the script again, so each script is ...
0
votes
1answer
186 views

ssmtp won't send cron email

I can't figure out why cron on my AWS EC2 (Ubuntu 14.04.1 LTS (GNU/Linux 3.13.0-32-generic x86_64)) can't seem to send email out via sSmtp to AWS SES. This works: echo "test" | ssmtp my@myemail.com ...
0
votes
1answer
63 views

Binding timestamp value to a variable in crontab

I'm basically trying to declare a variable with a date() value in crontab as I will constantly be using the same date structure over and over, here is what my crontab looks like so far. php = ...
0
votes
1answer
139 views

logwatch on Centos 6.4

My logwatch is configured correctly and is working correctly when I issue manually /usr/sbin/logwatch I added it to root's crontab and it is listed correctly when I make crontab -l which gives: 0 ...
0
votes
1answer
452 views

Why is cron running twice?

I wanted to execute my PHP mailing-script automatically with cron. I always get the mail twice though. The script runs fine when started manually. I put this in the crontab for testing: 54 13 * * * ...
0
votes
1answer
711 views

Compress and remove logs from jboss on linux with cron

I need to compress and remove log files after some time from serwer. I have never write scripts before. So far i have script logs.sh: #!/bin/bash LOGS=/usr/local/jboss/server/default/log/ ...
0
votes
1answer
609 views

Cron won't use msmtp to send emails in case of failed cronjob

I'm trying to configure a machine so that it will send me an email if one of the cronjobs output something in case of an error. I'm using Debian Wheezy. Cron is working normally (without the email ...
0
votes
1answer
238 views

Unable to get cron to append output from wget

I have a cronjob setup and running, but the logfile keeps getting overwritten every time it runs. I would like for the wget output to be appended each time the cron runs. Why is this and how do I fix ...
0
votes
1answer
46 views

Include executed cron command when outputting to log

Is there a way I can include the command that was executed in the output when I'm logging to a file? For example: * * * * * date && /path/to/php /path/to/script.php >> cron.log ...
0
votes
1answer
99 views

Can't stop LAMP graceful restart

I just got my first LAMP up and running, everything works fine except that my server is restarting itself every sunday. When I read the logs I see "Graceful restart requested, doing restart" Should ...
0
votes
1answer
231 views

cron job not running the script that start vncserver

Hi I wrote a script to start my vncserver when I call it manually via command line. It works as follows: the script is in usr/bin I gave it the right authorization (chmod u+x startvnc) but wen I ...
0
votes
1answer
344 views

How to stop long-running cron process from being killed

I have a long-running cron process, running a Python script, that seems to get randomly killed. In dmesg I see: [230568.077358] init: cron main process (890) killed by TERM signal [237517.974422] ...
0
votes
1answer
180 views

Logrotate rotating daily but should be rotating weekly

For some reason logrotate is rotating logs daily instead of weekly, even though all the config files for logrotate seem to be set to weekly. Any ideas? /etc/cron.daily/logrotate #!/bin/sh test -x ...
0
votes
1answer
86 views

Changing IP of the machine at regular intervals

I have a pool of public IP addresses. There are some services in my box which binds to these. What i'm trying to achieve is to automate the IP change process. Best way to do this is to write a script ...
0
votes
1answer
205 views

Running cronjobs with proxy

I have a requirement where I have to run several cron jobs with specific IP in an EC2 instance. That specific IP is used by another EC2 instance. I have access to that EC2 instance. Is there any ...
0
votes
1answer
62 views

Centos: List all cron jobs in a week ordered by date

I'm trying to get all cron jobs in the current week (or from monday to sunday) ordered by schedule time. I'm trying with some elaboration on the output of the command crontab -l I appreciate ...
0
votes
1answer
319 views

SFTP download the files and then i wanted rename the server files how to do this?

I have to setup with the banking interface where I need to connect to the remote bank and then download the files in the bank server in-box to my local server for further processing so i do following ...
0
votes
1answer
708 views

let CRON send emails through SMTP ( debian squeeze )

i would like to send emails whenever a cronjob has completed, i read that this is possible with exim4. in /etc/alias i added the line myuser: mygmail@gmail.com in /etc/exim4/update-exim4.conf.conf ...
0
votes
1answer
387 views

Linux CentOs 2.6.18 Setting locale for cronjobs

I have the problem, that I am trying to automate some Informix database job via the crontab. The job runs fine when done via the command line or processed via the at queue, but not via the crontab. ...
0
votes
1answer
306 views

Cron task failing on specific job

On my server I am getting the following error when running one of my cron tasks: CRON[9913]: (CRON) error (grandchild #9915 failed with exit status 127) The server is running ...
0
votes
1answer
124 views

Virtual server (VM) running Ubuntu re-configures itself?

I'm helping to administer a VM running Ubuntu with Media Temple. The hostname was changed, and sendmail was removed and replaced with exim4. To change the hostname 'sudo hostname newhostname' was ...
0
votes
1answer
255 views

solaris + run script every night one time from the crontab

I build in my Solaris machine new script Script name: send_brd_msg.sh ( this script located under /var directory I want to activate this script every 12:00 at night by the crontab Please advice ...
0
votes
1answer
682 views

Cron, chroot, jails, and permissions

I'm trying to grasp how to run crons under chrooted users. I'm on Ubuntu, and using ISPConfig where I can. I created a cronjob in ISPConfig which resulted in a file /etc/cron.d/ispc_chrooted_web1 ...
0
votes
1answer
237 views

Can we list all possible reason for a cron job crashed or killed?

We have some cron jobs which cannot be dead otherise the consequence would be davastating. So we need to have an eye on the process and know exactly what cause the death of a job. So I would like to ...
0
votes
1answer
263 views

Any chance a crontab entry is deleted automatically after the entry is commented?

Maybe I'm mistaken, but it seems that every-time I commented out a crontab entry, it will deleted automatically. eg. ssh server crontab -e commented out an entry using "#", save and quit Next day ...
0
votes
1answer
137 views

Simple cronjob issue (I think!)

I am a Unix/Linux n00b. I have a VPS running CentOS with WHM/cPanel. I comissioned the installation of ASSP Deluxe, which is a third-party anti-spam solution. Everything works great. One of the ...
0
votes
1answer
293 views

Curl doesn't work in crontab

I'm new to set up server settings and to the whole unix thing so maybe this is simple. I'm trying to start crontab with curl in but it doesn't work. I want it go to file and send email every 30 ...
0
votes
1answer
144 views

Services Similar to Cronless?

Are there any other well known cron alternative services to manage large amounts of automated tasks, such as curl'ng a url at a certain frequency? The only one I have found is cronless.com
0
votes
1answer
149 views

Using a link to a crontab file located elsewhere than /etc/crontab (Debian)

I have an EC2 instance in AWS. As you know, if my instance crashes I lose all data located in the local EC2 hard drive. Of course I have an EBS for my data, but /etc is located in the ...
0
votes
1answer
299 views

Run crontab to click a website link every hour

I would like to click on a test like this (the "start testing" button) every hour so I can get a hourly result (results are saved on the server side). Basically what happens is that I connect with a ...
0
votes
1answer
95 views

how large size support `crontab.txt` on linux serve?

I have a long long list of task list in crontab.txt, my crontab.txt over 5MB, will it cause fault in linux serve? (has lunux dad a limit size requiry?) And is it good to write a task list like ...
0
votes
1answer
81 views

How to dump a stream for a defined amount of time on a schedule basis

I have a video stream from a video4linux device /dev/dsp/adapter0/dvr0 I want to programmatically dump this stream for a predefined amount of time. I think to schedule the jobs I might use cron and ...
0
votes
1answer
394 views

using outside smtp to deliver cron generated emails

I want to deliver cron generated emails to my id, abc@example.com instead of being saved on /var/spool/clientqueue I've done the following: echo "set smtp=smtp.example.com" > /root/.mailrc echo "set ...
-1
votes
1answer
61 views

How can I flush and/or rotate cronevents?

Can anyone tell me how I can flush / clean / zeroize or better still rotate the contents of cronevents? I need to solve this, because I am attempting to 'productionize' my fileserver instance-pair ...
-1
votes
1answer
462 views

sending email from cron in html format not text

i am trying to send email every 1 hour from cron job which is executing a php script that fetches data from database and shows in a table format. i have CentOs 6.1 where i created my cron job.firstly ...
-1
votes
1answer
156 views

Allow nginx www to run Centos at command

I have a job which created by PHP script running as www (nginx) 31 2014-06-09 19:08 a www After the time passed, the job is executed but nothing happens. But if i run it as a root, 32 ...
-1
votes
1answer
432 views

VPS debian 64 bits put cron to reboot at 7:00 every day

I have a VPS with debian 64bit. And I would like to set a daily reboot at 7:00 with $ ps aux root 1844 0.0 0.1 18832 964 ? Ss 07:23 0:00 /usr/sbin/cron so the cron it's ...
-2
votes
1answer
101 views

Possible to run commands in a screen through cron jobs?

I currently have an application running in a screen. I would like to run some commands in the screen through a cron job but would like to know if this is possible. Using CentOS