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

learn more… | top users | synonyms

0
votes
1answer
25 views

Cron won't run my root script

I am on Ubuntu 14.04 (using Digital Ocean) trying run a script as root. It's a script to check if a server is running and restart if it has crashed. The issue isn't the script, but crontab won't run ...
0
votes
0answers
9 views

Delete messages in Gmail “All”, “Incoming” or “Sent” folder

I use one Gmail account only for mail relaying from my home server to different accounts, to multiple users. The problem is that there are some thousands of emails on this account in the "Sent" and ...
0
votes
0answers
29 views

Not able to open crontab -l

I am running crontab -l to view the crons on a RHEL server(v5.10) and getting the below error: crontab: error while loading shared libraries: libaudit.so.1: cannot open shared object file: No such ...
0
votes
0answers
16 views

How do I launch a gui app from a script called in cron in Linux?

I understand that cron doesn't like launching apps that have a gui. I am trying to google around this, and I found that it is possible, but I need to tell cron which display to launch it in. Well, I ...
0
votes
1answer
16 views

Where is the default directory of saved files using wget in crontab?

I want to download some files using wget command in crontab. I use a text file to make a list of my desired urls. wget's -O parameter works well for setting a destination folder for single files, but ...
0
votes
1answer
47 views

cronjob not uploading to FTP

i have a php script that should take a file from one web server and upload it on another, when i run the script through a browser it works fine. when i use this cronjob it doesn't upload. 51 14 * * * ...
0
votes
0answers
10 views

Emails from root while working with Horton Sandbox

I recently installed the VM for Horton Sandbox (CentOS 64) and I consistently get the notification: You have new mail in /var/spool/mail/root and when I go there I see notices of the form: 22 ...
0
votes
0answers
37 views

Correct crontab settings on Cpanel/WHM Cron on CentOS 6.5

I have recently migrated from collocation to Amazon EC2 and setup new WHM installs with CentOS 6.5 I then used the Transfer tool to move all websites to the new server, however I am trying to transfer ...
0
votes
1answer
15 views

install crontab every 10 minutes

I'm following the tutorial here on how to install a crontab every 10 minutes, but I'm running into an issue. My Cron is */10 * * * * /app/qa/dashboard/ec2/autoscaling-onesearch/manage check But ...
1
vote
2answers
53 views

Restarting process in CentOS if server restarts

I have a VPS with some Java applications (made with "Play Framework") running on ports 9000, 9001, 9002 and 9003. VPS Provider (iPage) happens to reboot servers unexpectedly from time to time, leaving ...
0
votes
1answer
33 views

Cronjob etiquette?

I am a student at a relatively small university. I wrote a script that sends me an email when a math newsletter comes out, so I can get a head-start on the problem of the week. I plan to run it as a ...
0
votes
2answers
26 views

Write PID To File On Bash Execution

I'm executing a bash script via cron. I want to write the process id (PID) of the script to a /tmp/ file for reference, in case I need to kill it later on (this script can take 6 - 10 hours to ...
0
votes
1answer
36 views

Strange timing behaviour

I need to run a CRON each 5 minutes for a specific user example.com, the script executed is a php file. File : /var/spool/cron/crontabs/example.com /5 * * * * /usr/bin/php -f ...
-1
votes
1answer
55 views

Double pipe “||” not working in cron jobs

fellow SUers, I am trying to run a watchdog cron job to make sure a process is running (DreamHost keeps killing processes). I was inspired by this SU question. However, the double pipe || seems not ...
0
votes
1answer
31 views

Can't create incron job

I am trying to create incron job, but no success. When I type: incrontab -l I got: no table for vujke and when I type: incrontab -e I got: editor finished with error: No such file or ...
0
votes
1answer
20 views

Cron jobs on IBM i 7.1

I just found out today that on an IBM i system I am able to use SSH to get to a Unix-like terminal (AIX/PASE) and would like to use this to schedule automated tasks using crontab. Does anyone know if ...
0
votes
1answer
49 views

How to get crontab to run when backup requires a password

I am running a script to backup my postgres database on Debian. I am basically running exactly this: https://wiki.postgresql.org/wiki/Automated_Backup_on_Linux Now I have everything working fine when ...
0
votes
0answers
33 views

Maintain screen session when executing shell script on boot

Solved: I solved this problem by introducing a delay before executing the script: @reboot sleep 60; /root/start_server.sh On Ubuntu 14.04, I have a crontab entry set to run on reboot: @reboot ...
0
votes
2answers
33 views

Synchronized script execution across multiple servers

I'm looking to run an automated task (a shell script) on multiple Ubuntu servers at the same time with as much timing accuracy as possible. Ideally, I'd like the time discrepancy between the start of ...
1
vote
1answer
34 views

cron jobs set for different times, but execute at the same time

I have a file which I loaded into crontab with the following jobs, and crontab -l reports the following: # runs daily at 2:00 am and 2:05 am 30 12 * * * /usr/bin/wget -q -O temp.txt ...
0
votes
1answer
54 views

Daily crontab with hg, git and svn

Hello I have made a script that updates some repos from git merc and svn, then updates a git repo. The script works manually but doesn't work in crontab, here is the script: #!/bin/bash cd ...
0
votes
2answers
34 views

Why is this cronjob not working?

I have a ruby script in ~/custom_scripts/get_all_products.rb. I want it to run every night at 04:00. Here's what the cronjob in crontab -e looks like: MAILTO="<email>" 0 4 * * * ruby ...
0
votes
1answer
40 views

“echo” prints the options in crontab

I'm running Rasbian 3.12.26+ on a Pi model B. Here is what my cron entry looks like: * * * * * sleep 11; { echo -en "\e[1;4;33m"; date; echo -en "\e[0m"; curl -k "http://sampleurl.com/update.php"; ...
0
votes
1answer
14 views

How to execute a Linux Cron Job from day x to y on crontab?

I found that I can use an hour range by using a slash, for instance, 4-20 to run from 4AM until 8PM. But what about day range? Can I use something like: * * 5-20 * * CMD
0
votes
2answers
46 views

Is there any reason this cronjob would fail in cron, but not on the command line?

I have written a little one liner that will email me when a list of files changes - I used sha512 to generate a list of hashes and then periodically check that those hashes still match. */5 * * ...
1
vote
2answers
47 views

How to find out the reason why a scheduled task hang?

I have scheduled quite a number of tasks in my Windows 7, doing a variety of cron jobs on my machines. I am perfectly sure that these tasks, when run on their own, won't hang. But the problem is ...
0
votes
0answers
43 views

How to run browser in background in Ubuntu

I am using Ubuntu 14.04, and PHP. I have 2 files: test.html - content java to test network update.php - the test file will post result to update database. I need to run and execute an URL address ...
0
votes
1answer
20 views

btrfs won't run from cron

I'm trying to set up a cron job to create a btrfs subvolume snapshot of my root partition. The command works perfectly if I run it from the command line, but nothing happens at the scheduled cron ...
0
votes
1answer
303 views

DD-WRT Additional Cron Jobs aren't running

I have installed DD-WRT (v24-sp2 (06/23/14) std - build 24461) on a TP-Link TL-WR841ND v9 and I'm trying to add a CRON job to update my Unlocator IP configuration as described here: How to set up a ...
0
votes
2answers
86 views

crontab is not working

I am using Linux Fedora. I want to create a crontab with SCP command, but it's not working. [shiv@db2 ~]$ crontab -l #this is server to server copy... */2 * * * * date >> ~/$ scp ...
0
votes
0answers
16 views

crond regularly maxes out CPU

I'm running Arch Linux ARM and I've having a few issues with crond. I have a conky that displays the top 5 processes (in terms of CPU usage) and every few minutes, crond will appear at the top of the ...
4
votes
4answers
421 views

How to use “date” to print tomorrow's day of the week

On CentOS 6 Linux I use date +%a in several cronjobs and scripts to generate logfile names like myprog-Tue.txt and this works well for me since many years. But now for one program I need to delete ...
3
votes
4answers
67 views

Is there a way to tell cron to trigger a particular cron job right now?

The cron job for updatedb didn't run because the system was powered off at the time. I'd like to tell cron to run that job now, as if now were the schedule time. Is there a way to do that? For this ...
0
votes
0answers
14 views

cron unavailable, how should I run old jobs?

My hosting company requires cron jobs to be entered one-at-a-time thought thier web interface rather than the command line. I've got about 70 jobs to transfer over from another host. Is it ...
1
vote
2answers
120 views

cron table mailx caused empty content

I'm using centos 7.0/6.5. The content of /etc/cron.hourly/mail.cron #!/bin/sh log=/var/log/mail.cron.log echo "`hostname` `date`" >> $log 2>&1 mailx -s "test mail" me@example.com < ...
0
votes
0answers
31 views

Disappearing Crontab, Odd Files

I have a number of Debian-based systems running on an ARM-based SBC connected to a network and they've been running for years. All of a sudden, when I log onto several devices, the cron file is ...
0
votes
0answers
13 views

How can I queue a script to run the next time a system is up and connected to the internet?

I'm using mailsend (on a Mac) to send mail from the command line. I'd like to set this up such that I can execute a send command, but if my system is disconnected from the internet, that command is ...
2
votes
0answers
24 views

Performance loss when having too many files in /etc/cron.d?

Is there an amount of files in /etc/cron.d that would lead to worse performance? There are currently about 50 jobs in. In the future there can be up to 200 files in. Am I correct to expect the cron ...
0
votes
0answers
63 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 ...
0
votes
1answer
68 views

mysql backup verification

Im not a dabase admin or advanced database user or advanced linux user.. but I would like to know how to verify mysql dumps because I am backing up my own sites manually. Normally when backing up lot ...
0
votes
1answer
175 views

Ubuntu Cron ec2-create-snapshot

I have a new ec2 Ubuntu instance running. I have properly set up the ec2-api tools. I want to create a daily backup using the ec2-create-snapshot command. Just to test it, I have my script, which is ...
1
vote
0answers
34 views

How can I run a cron job from PM to AM? [duplicate]

I want to execute a script once an hour from 20:00 to 08:00. Would the following work? 0 20-8 * * * location_of_script_to_run I'm currently using the following: 0 20,21,22,23,0,1,2,3,4,5,6,7,8 * * ...
0
votes
0answers
59 views

How to run an script using cron in Windows 7 using cygwin?

I have installed all the dependencies in cron. My scripts are working properly, and also I have tested cron which I think works properly as well. However, I would like to set up a task to run a script ...
0
votes
0answers
33 views

How to parallelize crontab executions to increase user base for web app based on mongodb and mysql?

I have a symfony based web application that runs on mongodb and mysql backend. The principle of the application is that for each user there is a python script that runs 4-12 times a day on cronjobs ...
0
votes
0answers
121 views

cron job monitoring script

greeting of the day!!! please help me a situation, i am trying to develop a script which provides me details which my cron job is commented or stopped which job is running or scheduled. like we ...
0
votes
0answers
11 views

Trying to find dbus session, doesent work

Trying to use notify-send with cron, it needs dbus, what im i doing wrong? var= $(set | grep '^DBUS_SESSION_BUS_ADDRESS=') export DBUS_SESSION_BUS_ADDRESS=$var #!/bin/sh { ...
0
votes
0answers
53 views

Make a script identify DBUS session address and use it

I'm using cron with notify-send to display some notifications, but it requires DBUS session to run Here is the script: export DBUS_SESSION_BUS_ADDRESS=[session] #!/bin/sh { DISPLAY=:0 ...
0
votes
2answers
80 views

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

I would like to do this: When the application VLC is open and I press the space bar, it pauses the video and an itunes starts to play. Then spacebar again would resume the workout video and pause my ...
0
votes
1answer
29 views

Set cron's maximum run counter

How do I setup cron to run only for a specific number of times? Let's say I want to setup cron so that it runs hourly, but when the scheduler has already run five times, I want to stop cron. How do I ...
0
votes
1answer
115 views

WGET/cron downloading webcamera file

our new town doctor put a web camera to his waiting room for people to see how much crowded it is. As my mom and grandparents go to this doctor, I wanted to download the files periodically and if they ...