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)

0
votes
0answers
14 views

How does changes in /etc/pam.d/common-session-noninteractive affect fail2ban and possibly other programs/services?

I am playing with Fail2Ban on Ubuntu 10.04. I noticed the following: default /etc/pam.d/common-session-noninteractive: fail2ban-client set ssh banip 1.2.3.4 -> the IP gets banned by an invisible ...
-1
votes
1answer
15 views

Cron and FTP daemons crashing randomly in RHEL

Not sure where to start in troubleshooting this. I'm not finding anything indicating an issue in ProFTP logs or in /var/log/messages. So I do apologize for not having more information to give. ...
0
votes
2answers
37 views

crontab in different sessions

I started a crontab job in a server remotely (in a screen session) from a local machine. Days later, I terminated the screen session and restarted my local machine. The cron job in the server is still ...
1
vote
1answer
67 views

Cron expression that runs every 5 minutes from 1:30 am - 6:00 am [duplicate]

I'm looking to run a job at these very specific times. Can this even be done in one expression?
0
votes
2answers
48 views

Cron job to execute PHP command fails with “Could not open input file: php”

I have a dozen or so cron jobs running on my Ubuntu 12.04 server, and I use the Webmin interface to administer them. They all execute PHP scripts. Most I created a while back, and they all work fine. ...
0
votes
0answers
26 views

Why doesn't this cron behave the same way when run from CLI? [duplicate]

I have this cron for user root (obtained with crontab -l): 20 10,14 * * 1-5 /usr/sbin/puppetd --onetime --no-daemonize --logdest syslog > /dev/null 2>&1 When it is run, it is supposed to ...
-1
votes
2answers
32 views

mysqldump in cron not working [duplicate]

I am trying to do a mysqldump on the cron for every 5 minutes but it seems that it is not working. I try to execute the mysqldump and it works fine. mysqldump mysqldump -uroot -ppassword ...
-2
votes
0answers
31 views

Cron job is occupying my server [closed]

I wrote two PHP scripts. First one is adding users to one another system calling its API functions. Another script is connecting to FTP, downloads the file, and analyze it. Tuesday I scheduled two ...
0
votes
1answer
21 views

Mail from my server that Webmin install is complete, but I didn't initiate it

I just got the following mail from my server. I didn't install/update webmin manually, it's there as it has always been since I've set it up over a year ago. Is this just a normal regular automatic ...
0
votes
1answer
33 views

Secure way to have a user that can move and change files in a FTP folder structure?

We have an FTP where customers can drop their files. We want to run a script that sweeps the files out of the folders every 15 minutes. The current permission and folder structure looks like this: ...
1
vote
2answers
41 views

Which user should cron jobs run as?

Ubuntu server with users root www-data mywebsite1 mywebsite2 There are multiple websites hosted on this server, each with their own user. Each website has their own cron jobs mostly ...
1
vote
2answers
20 views

Read-only cronjobs for users

Here's a weird issue. I want to make crontab for a user that is read-only for that particular user and can only be managed via root. Sounds easy? Here's the catch: $ ls -alh /var/spool/cron/my_user ...
0
votes
1answer
11 views

Ubuntu Server scheduleing a cron job not working

I am trying to schedule a cronjob on my ubuntu server through SSL. I ran the command: sudo crontab -e Then once it created a new file for my user, I put : * * * * * php /etc/php5/apache2/php.ini ...
1
vote
1answer
33 views

schedule a job to run only “once” after 50 seconds

I have a process which is designed to do a specific task in case of events. Requirement is to run a specific command 50 seconds after an event occurs. Cannot modify the code to put sleep there as it ...
1
vote
2answers
45 views

how to execute bash script with crontab in centos? [duplicate]

My bash file is not executed by cronjob created as root. The cronjob setup looks as it follows 0 0 * * * mysql_backup.sh does need to be decalared with the bash command 0 0 * * * bash ...
0
votes
2answers
30 views

centos cron logs are not executed

I have been trying to setup a cronjob on centos but doesn't seems to work. I have been deleting the crons logfile to see all newly created logs and I have been restarting crond but /var/log/conf ...
9
votes
1answer
174 views

How do I make cron run every other Sunday on the OTHER Sunday?

I have a cron job that runs at 0 0 * * 0/2 -- i.e. every other Sunday. It just ran now, for instance. However, I want it to run on the other Sundays -- next Sunday, rather than this one. Another ...
0
votes
1answer
32 views

No way to make a specific cronjob work [duplicate]

I installed nginxcp on my server and they recommend to add the following cron: 0 */1 * * * /usr/sbin/tmpwatch -am 1 /tmp/nginx_client I already added it to var/spool/cron and restarted crond ...
0
votes
3answers
67 views

Auto-delete files after they've been on the server for 14 days

We have a Linux FTP server that clients and project managers upload files onto to exchange files. Unfortunately, nobody ever goes in and deletes anything when they're done with it. I'm looking for ...
0
votes
1answer
40 views

Review of a crontab script to add timestamps to minutely runs; any suggestions?

I've got a crontab job set to run minutely as such: * * * * * /home/username/public_html/domain.tld/production/scripts/cron_runner.sh My goal is to add some timestamps to output from cron so I can ...
0
votes
2answers
30 views

using ssh to automatically retrieve info from remote box

Greets all. I need a 'basics-202' question answered; it's been a while. From a cronjob, how do I automatically ssh to a remote box to retrieve information that normally requires root equivalence to ...
1
vote
0answers
43 views

What could cause a PHP script run as a cron job to end up in D state?

My server is running Ubuntu 12.04 LTS (precise) and I'm having a weird issue. The server is hosting a large website which is used for data collection. The website is in PHP and uses Zend Framework. ...
0
votes
1answer
66 views

Restarting PHP based service via cron [closed]

I have a service that was written in PHP that needs to be restarted every morning. I added the following cronjob to do this: 0 8 * * * /usr/bin/php /etc/init.d/service.php restart This will happily ...
0
votes
2answers
61 views

Crontab not sending e-mail with output [duplicate]

I'm having a strange problem here with crontab. I have set up the crontab correctly to run the cron job as follows: [user@user ~]$ crontab -e SHELL=/bin/bash PATH=/sbin:/bin:/usr/sbin:/usr/bin ...
-1
votes
2answers
53 views

Cron to do a backup and automatically send it to dropbox [closed]

Is there a way to send backups to Dropbox (tar & send)? I bought a plan there and was thinking to save some money dropping Amazon S3 (that I'm using for backups). I'll have to manually delete old ...
0
votes
0answers
38 views

Contab running multiple times every minute CentOS

I have two crontabs setup on my server. One that runs every minute and one that runs every 5 minutes. */5 * * * * ~/aws-scripts-mon/mon-put-instance-data.pl --mem-util --disk-space-util --disk-path=/ ...
-1
votes
1answer
38 views

Cron Find & Replace via ssh - send a result via mail [closed]

I'm having a small issue, i'm running and cron task every 5 minutes which is looking text chain and replacing it with nothing.. In order to optmize something i would like to add a new function to my ...
0
votes
1answer
26 views

cron daemon forking multiple processes and running jobs multiple times

I'm running a bunch of cron jobs (set up using sudo crontab -e) on Ubuntu, and recently (though I don't know when to be sure) I'm suddenly seeing the same jobs appear to be run multiple times in the ...
0
votes
1answer
94 views

Why this command does not work from cron.daily file?

I have a file in cron.daily: root@nagios.example.com:/# cat /etc/cron.daily/nagios-logs /usr/bin/nice -n 19 /bin/gzip --fast /var/log/nagios3/archives/* root@nagios.example.com:/# ls -l ...
3
votes
2answers
91 views

Why this script in cron.daily won't run?

I wrote this small Python script to make daily backups of a directory containing some files (the backups should rotate after one week). This is it: $ cat /etc/cron.daily/file-store-backup.py ...
0
votes
1answer
23 views

Checking that PostGres and Apache are running on Ubuntu?

I am trying to learn the best practices for checking that Apache and Postgres are running on my server. If either of them have stopped, I want to auto-restart these services. I'm using Ubuntu 12.04 ...
0
votes
0answers
24 views

Files beginning with log being deleted [duplicate]

Im have a huge, and bizarre problem, this has occured twice no this month, on the 1st and the 13th. I run a small shared server for my clients, maybe 30 active domains, most run on the same real ...
15
votes
2answers
442 views

Is there a utility like cron, that schedules a job for later (but only once)?

I'm trying to design a program that sends a text when a certain (non-periodic) event occurs. Right now, I'd like a script that finds when this event occurs, and then schedules a (cron-like) job that ...
1
vote
1answer
45 views

Getting cron logs to add to file, not override it

First, I'm sorry if this is the wrong stackexchange for this, but it seemed like the right one. This is my crontab right now: MAILTO=****@gmail.com 10,30,50 * * * * ~/webapps/****/apache2/bin/start ...
1
vote
2answers
63 views

Why does cron not mail me the job output?

Here's my crontab: MAILTO=michael 02 11 * * * bash /home/michael/projectname/nightly_tests.sh * * * * * python /home/michael/projectname/throwaway/hello.py My username is specified correctly: ...
0
votes
0answers
23 views

webmin 'Scheduled Cron Jobs' menu tab not working

I am using webmin for centos server. I did setup my last cron job by using 'Scheduled Cron Jobs' for every minute. In next time when I was trying to set another cron job then 'Scheduled Cron Jobs' tab ...
0
votes
2answers
33 views

Debian webserver - Crontab error (not running php script)

I've a webserver with several sites and I'm trying to run a script by crontab but it gives me a error (126 and 127) My script is in: /var/www/site1/script.php When I run the command: php ...
0
votes
2answers
27 views

Does cron maintain an in-memory directory cache?

We run a large distributed Linux computing environment where a user's home directory may be moved between different back-end filestores due to their affiliation and general distribution between ...
0
votes
0answers
32 views

mysqldump not working/running via cron job

I have a crontask which runs at 1am every morning and dumps all databases. 0 1 * * * /var/backups/dumpit.sh 2>&1>> /var/backups/dumpit.log The dumpit.sh source: #!/bin/bash ...
-1
votes
2answers
53 views

Centos 5 - Configuring a crontab PHP job [duplicate]

I'm running a CentOS 5 server, and trying to schedule a job which runs a php file every day at the same time, I've added a new file to the directory /etc/cron.d/ called get_files The get_files ...
0
votes
2answers
75 views

Crontab on Ubuntu Server 12.04 doesn't run as it should (PHP script)

I have a PHP script which downloads and manipulate an image from some server and then saves it locally. Because image is update every 5 minutes I want to download and save that image every 5 minutes ...
1
vote
2answers
110 views

Running Node.js at boot

I'm trying to run a node.js script at boot using crontab. Here's the command /usr/local/bin/forever -c /usr/local/bin/node start /var/www/html/lights.js >/var/log/lights 2>&1 & At ...
2
votes
2answers
91 views

Cron job executed multiple times daylight saving time [duplicate]

We run a CentOS release 6.2 (Final) 2.6.32-220.13.1.el6.x86_64 with a stock cronie.x86_64 1.4.4-7.el6. On Mar 31 we moved to summer time: 03:00 become 04:00. In crontab we have: 0 4 * * * ...
2
votes
2answers
112 views

Using 'which' command in cron job

I have a cron job that runs once a day on a Linux server and in the script it executes there is a test: # Validate ffmpeg is installed if [ $(which ffmpeg | grep -c "ffmpeg") -eq 0 ]; then echo ...
1
vote
2answers
40 views

Exporting paths and configs in ubuntu

I am trying to add some exports using the following method: # SETUP CONFIGS sudo bash -c "cat >> /etc/bash.bashrc" <<'EOF' export AWS_CONFIG_FILE=/etc/test/aws.txt export ...
0
votes
2answers
34 views

crontab -u admin -l doesn't list cronjobs that are defined in directadmin backup crons as admin user

I have defined 1 cron job to take a backup of all of my users in Directadmin. Some users needed more than just one monthly backup. So I logged in again as admin user and went to Admin Backup/Transfer ...
1
vote
0answers
193 views

Do I really need the PHP maxlifetime hourly cron job? [closed]

On my Debian Wheezy, every half-hour a cron job runs: find /var/lib/php5/ -depth -mindepth 1 -maxdepth 1 -type f -ignore_readdir_race -cmin +$(/usr/lib/php5/maxlifetime) ! -execdir fuser -s {} ...
1
vote
4answers
87 views

Randomizing minute for crontab entries between servers

I have a common puppet recipe for a set of our servers. One of the puppet-managed files is /etc/crontab that contains the original cron.daily, cron.weekly and cron.monthly entries. The problem of the ...
-1
votes
1answer
44 views

@reboot cron directive doesn't work on Solaris? What do I use instead?

I just tried to use contab -e on a Solaris server to add this line: @reboot /root/reboot.sh The script starts up the web application. But the trouble is that this syntax is rejected. # crontab -e ...
1
vote
2answers
70 views

Run php script every 3 seconds

how can I set a cron job or a php script details to run a php script every 3 seconds between 11:30 PM and 12:30 AM (23:30 - 0:30)? Thank you very much for your help

1 2 3 4 5 21