cron

Cron job for list of urls(closed)

Leave it I got What I want...and let you know what I was searching for it..coz the site is launching on 19 th of this month...actually I cant explain the details now... ...

Help with basic shell script. /bin/sh: source: not found

My cron : 45 10 * * * source /home/ThinkCode/Test/hello.sh hello.sh : #!/bin/bash echo "helloworld" The error it emails me : /bin/sh: source: not found What am I doing wrong? It is configuration/environment specific, so Googling didn't help much! Thanks.. ...

How to run a Python script in the background even after I logout SSH?

I have Python script bgservice.py and I want it to run all the time, because it is part of the web service I build. How can I make it run continuously even after I logout SSH? ...

cron file_get_contents() error

I have a php file which uses file_get_contents() It works fine in the browser, but fails with the following error when run as a cron job: Warning: file_get_contents(): URL file-access is disabled in the server configuration in /path/to/the/phpfile.php on line 22 This is what I'm using: /usr/bin/php5 -q /path/to/the/php...

cron output options when using curl

when running a cron job like this: curl http://example.com/cronjob.php The output email contains this: % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 0 52 0 52 0 0 81 0 --:--:-- --:--:-- --:--:-- 81...

How to pass multiple parameters to cron job with curl?

I'm running two cron jobs: This one executes without a problem: curl -sS http://example.com/cronjob.php?days=1 But this doesn't run at all: curl -sS http://example.com/cronjob.php?days=1&month=1 Is this because of the ampersand (&)? If yes, how to pass multiple parameters? Using argv is not an option. ...

Twitter Oauth login in a cron agent executing PHP file evenry 2 minutes

Hello, I'm using Twitter Basic authentification in a CRON agent to get et savelist of tweets in SQL db of 5 of my twitter account. Because we have to use Oauth after June 30th I'm searching to know how can I use oauth without connecting me manually. In fact I don't have user interface in my PHP file executed every 2 minutes. Thanks in ...

Cron job execute backup.bash

Dear all, I wish to let cron executes delete_snapshot.bash, but when I try to create cron as below: */1 * * * * /var/www/mango_gis/delete_snapshot.bash >/dev/null It didn't execute my script at all, because when I didn't see it delete the snapshot in the amazon cloud, and my script is already tested with bash, it work fine. Here is my ...

What is corresponding Cron expression to fire in every X seconds, where X > 60?

I want my jobs to execute in every X seconds, there's one to one matching between job and X. Also during runtime there can be registered new jobs with their own intervals. I've tried to write cron expression for such scenarios, but in documentation there's written that value of seconds can't be more than 59. So cron expression like this...

Run a command as cron would but from the command line.

I have a script that I'm trying to run from cron. When I run it from bash, it work just fine. However when I let cron do it's thing, I get a: myscript.sh: line 122: syntax error: unexpected end of file What I want is a way to run a command as if it was a cron job, but do it in my shell. As a side note: does anyone know what would ...

quartz cron expression help (daily trigger)

Hi, i want to run a cron trigger every 5th day starting from the 16th of every month. so it should execute on every: 16th, 21st, 26th, 31st, 5th, 10th, 15th, 20th and so on i tried "0 0 1 16/5 * ?" but this gets execute on 16th, 21st, 26th, 31st, 16th, 21st.... It skips anything between 1st and 15th. Please help. thanks ...

Do you know any library or code in PHP to check if a date satisfies a given cron expression?

Hi, I was wondering if some of you know about a library in php so that I can pass a date and a cron expression and it tells me wether the date satisfies the cron expression or not. The java Quartz library is able to do that (and more like getting the next valid date for a given cron expression) but I was wondering if this is possible usi...

Copying MYSQL backup to another server

I'm new to SSH. How to copy a .gz file from one server to another using SSH? I'm using cron to backup mysql databases and want to also automate the process of copying the .gz files a different web host. Any information on the limit of file size that can be copied would also be great. The backup file size range from 100 MB to few GB. ...

Drupal hook_cron execution order

Does anyone know off hand what order Drupal executes it's _cron hooks? It is important for a certain custom module I am developing and can't seem to find any documentation on it on the web. Maybe I'm searching for the wrong thing! Any help? Jeff ...

Job scheduler UI widget?

Does anyone know of a good Job scheduler UI widget? The ideal component would be a Javascript widget (hopefully JQuery) that allows a user to select a frequency which is converted to a cron expression. Anything good out there? ...

Ruby on Rails - Rake task not working through Cron

When I execute a rake task manually, it works fine but when I put the same command in Cron nothing happens: cd /path/to/my/rails/app && rake daily_import The Cron log indicates that the command was issues: CMD (cd /path/to/my/rails/app && rake daily_import) The rake task logs error and success messages, but nothing is recorded to the...

Rails Dreamhost Cron Job

I'm trying to get some cron jobs going through Dreamost using their panel. I'm also using rake to execute these jobs My rake files are located in app/lib/tasks/example.rake But I don't know what code to give the panel to execute them ...

running a php script via cron, how can I log any output?

Morning all, I have a php script which I have been testing, and seems to run fine when I call it from the command line. I now want to automate it via cron, how can I get the outputs I have put into the file as checkpoints into a log file? eg I have some simple echo commands in the script and I'd like the output to appear inside an exi...

Why would my rake tasks running via cron get invoked twice?

I have a rails app with the whenever gem installed to setup cron jobs which invoke various rake tasks. For reasons unbeknownst to me, each rake task gets invoked twice at precisely the same time. So my db backup task backs up the db twice at 4:00am. Inspecting crontab reveals correct syntax for all of the cron jobs, so I don't think th...

Having Trouble Allowing Only One Instance of a PHP Script at a Time, Using Cron

I can't seem to figure this one out. I have a validator-type script that validates certain files on my server (checks if exists, its contents, etc). I want it to run continuously with only one instance of it, not more. The current solution I have doesn't seem to work, I'm guessing due to timeouts (possibly other reasons too). For each f...