Cron is used to execute scheduled commands. It acts as a task scheduler on Linux and UNIX systems which will execute commands at specified times set by the user. Cron has a great deal of customization and is often used on server environments where common tasks are run on a regular basis.

learn more… | top users | synonyms (2)

1
vote
1answer
52 views

How to Defrag XFS

I have a /home partition in a separate disk with XFS, how do I de-fragment it ? (on-line or off-line) I haven't tried anything yet and the / partition has BTRFS. Also how to schedule it would be nice....
0
votes
2answers
108 views

run php file from cron and start browser through exec on ubuntu [duplicate]

I am trying to start FireFox from php script using exec("firefox"). This works fine if i run php file from the terminal but does not work when run by the cron. User for cron & terminal is root. ...
0
votes
1answer
36 views

Why the auto reboot not working?

Why the system is not rebooting? i have this following in the crontab under root username. uptime: 08:43:06 up 10 days, 13:28, 2 users, load average: 0,17, 0,08, 0,06 but it should be rebooting ...
1
vote
0answers
30 views

Why might this “reboot on ping fail” script not be working?

I have an unresolved problem with my vps falling off the network. There's no reply and the webhost have no idea, so I thought this bash script should work #!/bin/sh ping -c5 8.8.8.8 if [ $? -eq 0 ]; ...
1
vote
0answers
97 views

Not able to execute a url from python script running via Cron

I have a script web.py which I am trying to run on the aws EC2 Instance using cron. It basically has these line of codes: import webbrowser webbrowser.open('http://xxxxxxxxxxxxxxxxxxxxxxxxxxxx') If ...
0
votes
0answers
51 views

How to start a Python script in LXTerminal using crontab at boot-up

I have a script called myscript.py (in /home/pi) that I want to run in the terminal every time the Pi boot up. I want to activate this by using 'crontab'. However after searching and trying stuff ...
1
vote
1answer
124 views

Rebooting computer using cronjob doesn't work

I have a kiosk application running on Ubuntu Server 14.04. In my kiosk app there is a link to reboot the system which just defaults to some PHP page that run: exec('sudo reboot'); If the user ...
0
votes
3answers
168 views

Magento PHP cron job fail to open required php files

We are trying to set up cron job for Magento site. We tried this Job, but it didn't work for us: */5 * * * * php -f /var/www/html/sitename/cron.php To debug we tried this Job: */5 * * * * /usr/...
1
vote
2answers
52 views

CronJob to copy a directory on a remote server

I Need to create a Cronb that will run daily on my server and will ftp into a remote server with a username and password. It will copy a directory on that server and copy it onto a directory on my ...
1
vote
0answers
21 views

Ubuntu Upgrade not finishing

I am upgrading ubuntu 14.10 to 16 LTS using a DVD and well it has been at the saving installed packages phase for more than 2 hours.What should I do? Here is a screenshot
0
votes
2answers
162 views

How to set up cron to call php script - bash: */5: No such file or directory for setting cron job

we are trying to set up cron for magento site running in ubuntu server we are trying following command : */5 * * * * php -f /var/www/html/sitename/cron.php but we are getting error as below : -...
1
vote
1answer
50 views

Get a list of all scripts and their paths which are run as cron job

I am looking for some scripts or a terminal command to list all the active scripts (preferably with their paths), which run on a periodic basis by cron, cron.daily and/or anacron. I am not looking for ...
9
votes
2answers
385 views

Make a new archive once per minute using “crontab”

I am trying to make a crontab that makes a new .tar file each minute every business day by using the following code: */1 * * * 1,2,3,4,5 tar -cf /home/user/Archiv/$(date +"%Y%m%d%H%M").tar /home/user/...
0
votes
1answer
27 views

My bash script doesn't work when triggered by crontab, but works when i trigger it manually?

this is the cron entry */1 * * * * ./home/usr/automation/check_rejected_files.sh > /home/usr/automation/cronout it produce the file but nothing else happen, i added a date log in the beginning ...
1
vote
0answers
31 views

how do I get the atd daemon log at commands?

On HPUX all at jobs are logged in a cron.log file. Alas I cannot find similar on Ubuntu. I see cron is logged to syslog and I can change rsyslog to log to a cron.log. But my attempts to log at.* ...
1
vote
0answers
45 views

Can't start a job with Cron on Ubuntu startup

I am trying to get a simple Python script running on startup with Cron on Ubuntu 16.04. What I did is opened cron with: sudo crontab -e and added the last line as shown in the screenshot: I even ...
0
votes
0answers
33 views

How to stop x11vnc from shutting down when I log out?

At boot I have sudo x11vnc -xkb -noxrecord -forever -noxfixes -noxdamage -display :0 -auth /var/run/lightdm/root/:0 -usepw run via init.d It works and shows me the login prompt when I use a VNC ...
3
votes
1answer
31 views

cron email from address

a linux machine executes a cron job for a script every night that does a backup, this should then send an email to us with the basic results. However since moving to a spam filtering platform its ...
0
votes
0answers
10 views

Can either Postfix or Cron Daemon mix up simultneous cron jobs' stderr reports?

I have a use case on a Trusty Desktop LTS box, where two (non-root) cron jobs trigger simultaneously: # cron entry #1 # `rsync' Mozilla FF's profile from RAM-DISK to SSD every 4 hrs. # (FF's profile ...
0
votes
1answer
32 views

Script to send Email if Log grows past 90M

I have the Below Script to check the size of my Log file. Should it grow to beyond 84M to should be renamed with the current date and a a new one is automatically generated by my APP. However it ...
2
votes
2answers
28 views

How do I block myself from logging in over the weekend?

I'm wondering if anyone has ever written a cron script that blocks ones remote access (specifically a linux email server that I access via alpine on my local linux machine over an ssh connection) over ...
0
votes
1answer
23 views

How can execute a cron at machine sturtup?

I am trying to make a cron for my machine. It there a possibility I to make it for every starting up of my pc? Some way like this : # File : /tmp/crontab.LgVuXf/crontab uptime ... command
0
votes
0answers
32 views

Ccrontab script returns empty output

I'm writing a simple bash script for analysing disk health status with smartctl and when i run it in a terminal or by script all works fine: for i in {0..5}; do echo "***** /dev/sda$i *****"; ...
1
vote
2answers
399 views

confusion about cron and anacron (setting up backup schedule for rsnapshot)

I am trying to set up a not too complicated backup schedule with rsnapshot on a laptop running Ubuntu 16.04 LTS. The plan is to retain two daily backups and 24 hourly backups. I think this is the ...
0
votes
1answer
32 views

How to modify the default 'sender' and 'subject' in cronjob failure email?

I setup a cronjob that sends me email on failure. The problem is it's coming from Cron Daemon and the subject is Cron <ubuntu@ip-10-100-21-10> /home/ubuntu/neo/bin/backup-test.sh >> /home/...
0
votes
0answers
34 views

Cron script runs but dpkg command fails

I have a cron script that updates a package with dpkg. This is an oversimplified version of a much larger script. But this is the part that is not working. I copy the update cron script to /etc/...
1
vote
2answers
48 views

How to shutdown system if not charging

I am using Ubuntu 14.04 LTS. My battery is not working, i.e. it provides backup for around 5 minutes. Now when I download stuff, it sometimes takes around 5 - 6 hours. And I can't just hang around the ...
0
votes
0answers
16 views

Why am I seeing much more cron jobs in webmin than in `crontab -e`?

I am just starting to learn cron jobs. Basically I am going to use webmin to manage my cron jobs, I am also reading some basic information about cron jobs. So far I've learned that /etc/crontab ...
0
votes
1answer
12 views

Why I am seeing different content in crontab -e and nano /etc/crontab

I just start learning to use cron job. I've learned that cron jobs' setting and information are stored at /etc/crontab and I come across this command crontab -e, when I execute it, I was prompted to ...
0
votes
2answers
25 views

run two ongoing processes on startup with one that needs initialization time

I'd like to record start recording utility consumption right at startup but I can't find the right combo of operators, pipes, and sleep commands to enter into crontab -e . I think my smartest attempt ...
-1
votes
1answer
51 views

start screen programm with crontab @reboot

I try to start a start.sh at reboot with crontab. But nothing happens afer a reboot, and the log is without an error. Does someone know what i've done wrong? For testing i gave the start.sh and Mod....
0
votes
2answers
39 views

How to start Crontab before login?

Basically I have a script (.sh) that syncs a local folder with an FTP one (using cron to run this). This script needs to be ACTIVE AT ALL TIMES (business use :D) and the only thing I cant control is ...
0
votes
1answer
75 views

Location of start-up configuration files - Firefox launching at startup, Ubuntu MATE 16.04

My problem is simple. Firefox is launching by itself at startup. I can't disable this and if I try to purge it then it tries to also uninstall MATE desktop WTF ??!! The question is which are the ...
3
votes
1answer
55 views

What is needed to automatically run Cron tasks created with Gnome Schedule?

I used Gnome Schedule to create the following test task. The task runs fine manually but is not being run every hour automatically as defined. What is required for this task to run automatically?
0
votes
0answers
22 views

Cron Job Error email

I'm new and I have a Precise server which had a trojan which I cleaned however There was a cron job created by the trojan and since i removed the jobfile from location every three minutes I get this ...
-1
votes
1answer
19 views

how to find a folder based on creation time

I would like to write a small script that: finds the creation date/time of a folder on a server that creates a backup folder every two days with the date as 2016 04 22 as folder name remove the ...
0
votes
2answers
64 views

How to do a monthly system backup

I want to create an automatic monthly backup on Ubuntu 14.04 LTS - Server Ed., with the following command: $ tar -cvpz --exclude=/bckupftp --exclude=/ser --exclude=/proc --exclude=/lost+found --...
1
vote
1answer
28 views

How can I use the in-built function alert in Gnome Schedule?

I want to access the alert function in Gnome Schedule. I can run alert from my default Bash command-line but receive the following error in Gnome Schedule: /tmp/tmpxi4X16: line 1: alert: command not ...
0
votes
0answers
39 views

atq command problem

I am trying to enable www-data to use the at commmand. First I deleted www-data in /etc/at.deny file and tried to execute the following command #sudo -u www-data atq I got this error You do not ...
1
vote
1answer
42 views

I have 5 hosts which i need to ping if any one down i should be alerted through an email it is possible..?

I have 5 hosts which i need to ping if any one down i should be alerted through an email it is possible..? and it will be checked with every 20 minutes. can anyone help me.. Thanks in advance... i ...
0
votes
1answer
106 views

I need a script file for checking (ping) 3 ip address are working or not

I need to create a script for checking (ping) 3 ip address are working or not. using the crone tab and i do want to know how is it working. I was used a script using a test file, but i need to get the ...
0
votes
1answer
60 views

auto start a reverse ssh tunnel on system startup

I am have a remote machine behind a firewall that I wish to connect to through SSH. As far as I understand this can be achieved by using a reverse ssh tunnel. So the command I am using is ssh -N -...
1
vote
1answer
33 views

How to schedule app to lauch including it's GUI

I have a calc spreadsheet that I'm trying to automate. When open, it collects data, calculates, saves itself and exits. So I created a script to call this. soffice --calc --norestore Updater.ods ...
0
votes
0answers
49 views

PHP Errors in mail

I've been getting these error messages sent to me a lot lately, pretty sure it's causing me a problem. From root@kallarserver Fri Apr 15 13:39:01 2016 Return-path: <root@kallarserver> Envelope-...
0
votes
2answers
44 views

crontab doesn't seem to work and makes different schedule in cron.d!

sudo crontab -e lets me edit the crontab, and I put in this: # Hourly backup 0 * * * * rsnapshot hourly # Daily backup 0 2 * * * rsnapshot daily # Weekly backup 0 4 * * 6 rsnapshot weekly And it ...
1
vote
1answer
90 views

Can't run Sikulix 1.1.0 on Ubuntu 15.10 with crontab

I try to run a Sikulix script but nothing happens. crontab: SHELL=/bin/sh PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/home/absolute MAILTO="" # m h dom mon dow user ...
0
votes
1answer
32 views

Cron job. Runs at minutes interval but otherwise when set at another time

During the test of my script. The cronjob should run a script through the browser every 2 minutes. So I had the following cron: */2 * * * * wget -O http://192.10.10.1/mypage/myscript.php The cron ...
0
votes
3answers
30 views

Cronjobs not showing up using crontab -u <user> -l

I added some jobs directly to the /etc/crontab file. They are running fine. However, I cannot see them if I use the ‍‍‍‍‍‍‍‍crontab‍‍ command crontab -u <user> -l Do I have to reindex ...
2
votes
1answer
52 views

How do I set up a cron job on Snappy?

If I run sudo crontab -e I can edit the crontab, but it's read-only so nothing gets saved.
0
votes
0answers
48 views

Autostart .jar file with screen

How can I autostart a .jar file in screen at boot? I already have some other programs that start at boot, but the .jar file doesn't work for me.