Search Results

Search found 297 results on 12 pages for 'crontab'.

Page 4/12 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • [mac] Running an Automator task at night

    - by Roberto Aloi
    I've just created an Automator workflow and I'm using crontab to execute it at night. The problem is that, after a while, the machine is going to sleep and a password is required (this is the intended behaviour). Unfortunately, Automator seems to be unable to perform the task when the password is required. It works like a charm if the "password required" dialog is not displayed (before the sleep). Any suggestion on how to solve this?

    Read the article

  • running python script with cron

    - by paulo
    hey guys, im trying to run a python script after every 5 minutes using cron, inside the script is a django import import django when running the crontab i get mailed the following error ImportError: No module named django this is what the crontab file looks like: [email protected] */5 * * * * /usr/bin/python /Users/paulo/Desktop/ashtanga/ping/sender.py do anyone of you know whats causing this ? btw i do have django insalled version 1.2, python 2.6, and MacOX 10.6

    Read the article

  • How many cron jobs are too many?

    - by guitar-
    I have a couple of cron jobs for basic maintenance which aren't very resource-intensive. I also have custom task scheduling (which is just calling a .php file and passing information via GET, ie: cronjob.php?param1=param ...). These can add up pretty quickly. These just call system commands and run external programs (Nmap is one of them). They usually don't take long either. Anyway, can anyone tell me, roughly what point is too many? I know it's hard to say since it depends on what job is being run and how often, but at what point does the crontab program start "struggling"? Anyone have any idea? Thanks.

    Read the article

  • Automatizing the backup of my databases and files with cron

    - by Patrick
    hi, I want to automatize the backup of my databases and files with cron. Should I add the following lines to crontab ? mysqldump -u root -pPASSWORD database_name | gzip > /home/backup/database_`date +\%m-\%d-\%Y`.sql.gz svn commit -m "Committing the working copy containing the database dump" 1) First of all, is this a good approach ? 2) It is not clear how to specify the repository and the working copy with svn" 3) How can I run svn only when the mysqldump is done and not before ? Avoiding conflicts Any other tip ? thanks

    Read the article

  • Automate the backup of my databases and files with cron

    - by Patrick
    hi, I want to automate the backup of my databases and files with cron. Should I add the following lines to crontab ? mysqldump -u root -pPASSWORD database_name | gzip > /home/backup/database_`date +\%m-\%d-\%Y`.sql.gz svn commit -m "Committing the working copy containing the database dump" First of all, is this a good approach? It is not clear how to specify the repository and the working copy with svn? How can I run svn only when the mysqldump is done and not before ? Avoiding conflicts

    Read the article

  • cron job executing every minute but should be setup to execute every 4 hours.

    - by Frank V
    Note: I've viewed cron: can’t lock /var/run/crond.pid, otherpid may be 3759 but I believe my question is different (but with the same resulting problem.) I'm very new to cron. I setup a script to run a python script every minute to test that everything was working. I did use crontab to accomplish this. It worked great, so I wanted to switch it to run every 4 hour. I changed my * * * * * {...} to * */4 * * * {...} but the job is continues to run every minute. It's been like this for the last hour or so. When I attempt to run cron restart (thinking that would solve the problem), I receive the following error message: cron: can't lock /var/run/crond.pid, otherpid may be 2311: Resource temporarily unavailable Is my cron syntax wrong? And why might I not be able to restart cron?

    Read the article

  • This weird behaviour from cronjob

    - by The DOCTOR from TARDIS
    I have set the crontab like this: */5 0 * * * /www/permitChat.sh and the /www/permitChat.sh is this: # We are setting the name of file # in the variable along with complete path. sFilePath=`date +\/www\/ChatLogs\/%Y\/%m/%d_%m_%Y.txt` # First we set its permissions to # readable by all users, and then # modify them to be writable by only root. chmod a=r $sFilePath chmod u+w $sFilePath ls -lh $sFilePath The trouble I am facing is, the cron gets executed after 12:00 PM everyday, instead of executing at 12:00 AM to 01:00 AM, every 5 minutes. What could be wrong? All my system variables appear to be synced.

    Read the article

  • How to schedule a biweekly cronjob?

    - by Roman
    crontab(5) defines the following fields: field allowed values ----- -------------- minute 0-59 hour 0-23 day of month 1-31 month 1-12 (or names, see below) day of week 0-7 (0 or 7 is Sun, or use names) and explains: Step values can be used in conjunction with ranges. Following a range with ``/<number>'' specifies skips of the number's value through the range. For example, ``0-23/2'' can be used in the hours field to specify command execution every other hour (the alternative in the V7 standard is ``0,2,4,6,8,10,12,14,16,18,20,22''). So, no biweekly Jobs, as far as my understanding goes. I'm quite sure there are workarounds, what are yours? Or did I miss something?

    Read the article

  • Cronjob not Running

    - by Pete Herbert Penito
    I have a bash script that looks like this: #!/bin/sh PID=`ps faux | grep libt | awk 'NR==2{print $2}'` STATUS=`ps faux | grep libt | awk 'NR==2{print $1}'` if [ "$STATUS" = "ec2-user" ]; then echo "libt already killed" else sudo kill $PID echo "libt was killed" fi sleep 5 cd /home/ec2-user/libt sudo ./libt I have saved this file as restart.sh and when I run it like ./restart.sh, it does what its supposed to (kills the libt process and restarts it). However, now I am trying to automate the process by using cron. So I made a cron job that I want to run every 6 hours that looks like this 0 */6 * * * /home/ec2-user/restart.sh When I run "crontab -l" I can see this print so I know it's been added properly. I should mention that the service does not have the ability to be restarted, (like "service ... restart") the process ID needs to be found, killed and then the start script needs to be ran. I have found that this cronjob is not working, I'll log onto the box and I can tell by looking at the logs that no restart has occurred. What am I doing wrong? What can I do to troubleshoot? Any advice would help, this is my first cron job :) Thanks!

    Read the article

  • sudo with -u via ssh -t in a crontab

    - by DJK_devel
    I'm trying to create a cron job that uses ssh to login to a remote server and run a script as a different user. I try: * * * * * source $HOME/.keychain/$HOST-sh && sudo -u $USER $PATH/$SCRIPT but this doesn't work because there is no -t option specified for ssh. The cron job needs to source the keychain file in order to work without a password, but I'm not sure where to include the -t option for ssh in this instance.

    Read the article

  • An agenda in Korn Shell: New / Edit / Delete / View appointment

    - by Abaco
    As stated in the title, I have to write a simple script which should perform some typical agenda's functions. The script must use crontab. The functions are: Creating a new appointment Edit an existent appointment Delete an appointment List the appointment I really don't have a clue how to do this, can you help me with some hint? Maybe a bit of sweet code? Thank you very much, Abaco EDIT: To be more specific on my question Point 1: how can I edit a crontab thorugh ksh? How can I insert a new line? Can you link me some documentation or a bit of code about this?

    Read the article

  • User Crontab + Python + Random wallpapers = Not working?

    - by Andrew Bolster
    I have a python script that correctly sets the desktop wallpaper via gconf to a random picture in a given folder. I then have the following entry in my crontab * * * * * python /home/bolster/bin/change-background.py And syslog correctly reports execution Apr 26 14:11:01 bolster-desktop CRON[9751]: (bolster) CMD (python /home/bolster/bin/change-background.py) Apr 26 14:12:01 bolster-desktop CRON[9836]: (bolster) CMD (python /home/bolster/bin/change-background.py) Apr 26 14:13:01 bolster-desktop CRON[9860]: (bolster) CMD (python /home/bolster/bin/change-background.py) Apr 26 14:14:01 bolster-desktop CRON[9905]: (bolster) CMD (python /home/bolster/bin/change-background.py) Apr 26 14:15:01 bolster-desktop CRON[9948]: (bolster) CMD (python /home/bolster/bin/change-background.py) Apr 26 14:16:01 bolster-desktop CRON[9983]: (bolster) CMD (python /home/bolster/bin/change-background.py) But no desktopy changey, Any ideas?

    Read the article

  • Help with running crontab from root

    - by user242065
    Im using OSX and having trouble getting a cron job to run. I type the following: $ sudo -i $ crontab -e I then enter: * * * * * root ifconfig en0 down > /dev/null 0 19 * * * root ifconfig en0 down > /dev/null 0 7 * * * root ifconfig en0 up > /dev/null and no success, the first line is for testing. I want it to shut off my internet. The next two lines I plan to leave in, once I get this working. If I type this in to the terminal the internet goes off ifconfig en0 down Why is my cron job not shutting down the internet? FYI: This is a follow up question from http://stackoverflow.com/questions/3027362/how-can-i-write-a-cron-job-that-will-block-my-internet-from-7pm-to-7am-so-i-can most of the comments there are people making fun of me. And a few attempts to solve the problem with out cron jobs.

    Read the article

  • How to run crontab-e?

    - by user1723760
    I am currently reading this documentation here where I want to use CRON. Now it says in the first section that I need to enter in a command: crontab -e. Do I only need to enter this in a simple text editor file and just upload the file into the server? I am using helios.hud.ac.uk so would this be the correct command: * * 25 10 * helios.hud.ac.uk/u00000000/Mobile/inactivatesession.php This will execute this php script below (inactivatesession.php): <?php include('connect.php'); $createDate = mktime(0,0,0,10,25,date("Y")); $selectedDate = date('d-m-Y', ($createDate)); $sql = "UPDATE Session SET Active = ? WHERE DATE_FORMAT(SessionDate,'%Y-%m-%d' ) <= ?"; $update = $mysqli->prepare($sql); $update->bind_param("is", 0, $selectedDate); $update->execute(); ?> The url for this php script is: helios.hud.ac.uk/u00000000/Mobile/inactivatesession.php I havn't used CRON before so just need little help on it. Thanks

    Read the article

  • Undesired Output of Crontab Job Using CURL

    - by Russell C.
    I have written a perl script that runs as a daily crontab job that uploads files to Amazon S3 via CURL. I want the output of the cron job emailed to me which works fine but I don't want that email to include messages related to the CURL upload (only those message my script is outputting). Here are the CURL related messages I'm seeing in the daily email right now: % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 230M 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0 0 230M 0 0 0 544k 0 1519k 0:02:35 --:--:-- 0:02:35 1807k 0 230M 0 0 0 1744k 0 1286k 0:03:03 0:00:01 0:03:02 1342k 1 230M 0 0 1 2880k 0 1219k 0:03:13 0:00:02 0:03:11 1250k 1 230M 0 0 1 4016k 0 1198k 0:03:17 0:00:03 0:03:14 1218k 2 230M 0 0 2 5168k 0 1186k 0:03:19 0:00:04 0:03:15 1202k 2 230M 0 0 2 6336k 0 1181k 0:03:19 0:00:05 0:03:14 1157k 3 230M 0 0 3 7488k 0 1177k 0:03:20 0:00:06 0:03:14 1147k 3 230M 0 0 3 8592k 0 1167k 0:03:22 0:00:07 0:03:15 1142k 4 230M 0 0 4 9744k 0 1166k 0:03:22 0:00:08 0:03:14 1145k 4 230M 0 0 4 10.6M 0 1163k 0:03:23 0:00:09 0:03:14 1142k 5 230M 0 0 5 11.7M 0 1161k 0:03:23 0:00:10 0:03:13 1140k 5 230M 0 0 5 12.8M 0 1158k 0:03:23 0:00:11 0:03:12 1133k 6 230M 0 0 6 13.9M 0 1155k 0:03:24 0:00:12 0:03:12 1138k 6 230M 0 0 6 15.0M 0 1155k 0:03:24 0:00:13 0:03:11 1138k 7 230M 0 0 7 16.1M 0 1152k 0:03:25 0:00:14 0:03:11 1131k 7 230M 0 0 7 17.2M 0 1152k 0:03:25 0:00:15 0:03:10 1132k 7 230M 0 0 7 18.4M 0 1152k 0:03:24 0:00:16 0:03:08 1140k I am using a simple Perl system() call to invoke CURL. Does anyone know what command line argument I can supply CURL to turn off the reporting of the upload progress? Thanks in advance for your help!

    Read the article

  • django custom command and cron

    - by Hellnar
    Hello I want my customly made django command to be executed every minute, however it seems like python /path/to/project/myapp/manage.py mycommand doesn't seem to work while at the directory python manage.py mycommand works perfectly. How can I achieve this ? I use /etc/crontab with: ****** root python /path/to/project/myapp/manage.py mycommand

    Read the article

  • sqlldr job not running through Autosys

    - by Frank
    I have a shell script that if run manually or via Cron executes fine and loads a delimited file using sqlldr to the database successfully. However via Autosys the script executes, sqlldr says it was successful, however the data is never actually loaded into the database. Has anyone ever experienced this before with the sqlldr/Autosys combination, and if so, knows of a workaround/fix?

    Read the article

  • Cron - run task every 90 min.

    - by Cory J
    Trying to adjust a cron job to run every 90 min. It was previously running every 20 min, which was a simple cron job: */20 * * * * whatever To change it to every 90, it seems like I need to split it into 2 jobs, I've done this: 0 0,3,6,9 * * * whatever 30 1,4,7,10 * * * whatever Is this right? The job doesn't seem to kick off.

    Read the article

  • Running cronjob in the odd-numbered days

    - by Spacedust
    I'm currently running my MySQL backup script on every day of the week: 0 1 * * 1 sh /root/mysql_monday.sh 0 1 * * 2 sh /root/mysql_tuesday.sh 0 1 * * 3 sh /root/mysql_wednesday.sh 0 1 * * 4 sh /root/mysql_thursday.sh 0 1 * * 5 sh /root/mysql_friday.sh 0 1 * * 6 sh /root/mysql_saturday.sh 0 1 * * 0 sh /root/mysql_sunday.sh Now I would like to keep backups for one week more so two weeks in total just to be more secure. For example: I though I can create one backup file on monday in the even days and then again in the odd-numbered days. For even days I can just use: 0 1 */2 * 1 sh /root/mysql_monday_even.sh 0 1 */2 * 2 sh /root/mysql_tuesday_even.sh 0 1 */2 * 3 sh /root/mysql_wednesday_even.sh 0 1 */2 * 4 sh /root/mysql_thursday_even.sh 0 1 */2 * 5 sh /root/mysql_friday_even.sh 0 1 */2 * 6 sh /root/mysql_saturday_even.sh 0 1 */2 * 0 sh /root/mysql_sunday_even.sh But what about the odd-numbered days ?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >