Questions tagged [cron]

1

votes
2

answer
277

Views

Crontab isn't running Laravel scheduled jobs

I've set up crontab on my AWS-EC2 instance to hit the Laravel scheduling endpoint every minute via the root account using sudo crontab-e: * * * * * php ~/htdocs/artisan schedule:run >> /dev/null 2>&1 However, despite to the cron logs showing it is indeed running every minute: Jan 26 12:02:01 ip-172-...
nomaki
1

votes
3

answer
62

Views

how to work with @scheduled annotation in spring

I have to read time of a file(video) created and if the time of file is greater than 3 days i have to delete the files. For this i have used @scheduled annotation in spring. But when i run the application, that deletion code is not working. I have configured xmlns:task='http://www.springframework.or...
rohan
1

votes
2

answer
426

Views

Symfony command runned by cron, but no effect. Runs fine on command line

I'm currently making a mail client with Symfony 2.7. I've made a command to collect new mails with IMAP and create entities from them. This command runs fine in command line, it collects and displays new mails. Here is the command : protected function configure() { parent::configure(); $this ->setN...
Blackwaxx
1

votes
2

answer
2.1k

Views

How to trigger a Lambda function at specific time in AWS?

I am aware of the CloudWatch recurring events that can be used to run Lambda recurringly.. but is there a way that I can trigger it on a certain time and not repeat?
Faizuddin Mohammed
1

votes
2

answer
288

Views

Run a python script on schedule on Google App Engine

I'm looking for a good samaritan that can provide with a very basic skeleton to run a python script using Google App Engine. I have read the documentation, check on related SO questions but I'm lost with the WebApp format. All I want to do is run one python script which accepts arguments or several...
Racu
1

votes
2

answer
81

Views

2019: Dynamic cron jobs Google App Engine

I am developing a reporting service (i.e. Database reports via email) for a project on Google App Engine, naturally using the Google Cloud Platform. I am using Python and Django but I feel that may be unimportant to my question specifically. I want to be able to allow users of my application schedul...
ViaTech
0

votes
1

answer
15

Views

AWS EC2 Ubuntu16.04 crontab not working at specified time

As titled, i have read through a lot different online resources, but still not be able to make crontab work at specified time, it only works when the the job is specified for every minute. p.s I have changed the timezone to Asia/Hong_Kong via dpkg-reconfigure tzdata, Also $TZ=Asia/Hong_Kong I have t...
Edison Lo
1

votes
1

answer
231

Views

execute python script from cron don't send mail

I've script in python that takes photos from raspberry camera and send mail with this photos. From command line everything works OK, script start do the jobs and finishes without errors. I setup cron to execute script every 1 hour. Every hour I get mail but without attachments. Where or how can I...
kolo
1

votes
1

answer
546

Views

Google assistant to run python script

I have installed the google assistant SDK on a raspberry pi 3 and have so far managed to get Spotify working, and managed to get IFTTT to run for lights. What I really want to know is whether it is possible to have google assistant run and interact with python scripts on the pi. By which I mean I ha...
Will Marks
1

votes
0

answer
69

Views

After changes in pam crontab stop working

I have made changes in : cat /etc/pam.d/common-session-noninteractive sudo vi /etc/pam.d/cron sudo vi /etc/security/limits.conf after rebooting system crontab stop working when I check syslog it shows below error: PAM (cron) illegal module type: ession cron[4936]: Permission denied
Sandesh Dumbre
1

votes
0

answer
147

Views

How to avoid zombie process from crond ( crond -l 9 )

My system based on Linux ( 3.12.14 ), I could see Zombie process [ sh ] creates for very frequently. I have found that (crond -l 9) which was parent process of zombie. I confirmed that, always crond -l 9 was parent process. As per crontab (crontab -l), lot of scripts are running based on configura...
mselvara1982
1

votes
0

answer
50

Views

Running python script periodically with crontab. Error

I'm using crontab to run this python script every minute: def cronSendEmail(): print('Hello') return True In the log file: /var/log/syslog Jan 3 23:37:01 brahmh CRON[4627]: (me) CMD (/home/venv/bin/python /home/proj/manage.py crontab run b74d4d1f47748498b81b5bcf863684c3 >> /home/proj/file.log # dja...
Vaish MK
1

votes
0

answer
368

Views

Magento Zend_Mail_Protocol_Exception: Unable to connect via TLS

On Magento version 1.9.1 I am using a custom module where I need to send the mail by cron.. I am also using Aschroder SMTP Extension. The testing for mail sending works fine within Magento Aschroder extension. Server setting: mail.mydomain.com port:587 security:TLS authentication:plain the related m...
Joshi
1

votes
1

answer
52

Views

Bash Script Unstable Result

I have bash script and I put in the crontab. It runs every 10 minutes. When I run it manually, it gives perfect results. It creates '.tmp' files and these '.tmp' files are not empty, but Crontab results are not as I expected. it only creates '.tmp' files. Contents of '.tmp' files are empty. In this...
Umut TEKİN
1

votes
1

answer
44

Views

Getting issue in adding cron expression to crontab from java and CLI

I am running the command below with is passing two argument to my script file(This below command is being constructed from java): sh /home/accure/Desktop/scripts/cronhandler.sh '/home/accure/Desktop/scripts/pipeline.sh 028d8ccb-4c46-4e02-a9b0-3c97a383daaf' '* * * * */5' Where '/home/accure/Desktop/s...
Deepak Pathak
1

votes
1

answer
281

Views

django-crontab does not execute scheduled jobs

I am having a very similar virtualenv setup than in the question: Django crontab not executing test function. in my_app.cron.py def test(): print('HELLO') in settings.py INSTALLED_APPS = ( ... 'django_crontab', ) CRONTAB_COMMAND_SUFFIX = '2>&1' CRONJOBS = [ ('*/1 * * * *', 'my_app.cron.test','>> /cr...
Pierre
1

votes
1

answer
593

Views

Load Cron syntax from database in spring boot application

This is my Scheduled task class @Component public class ScheduledTask { private static final Logger LOGGER = LoggerFactory.getLogger(ScheduledTask.class); private static final SimpleDateFormat dateFormat = new SimpleDateFormat('HH:mm:ss'); @Scheduled(cron = '${scheduling.job.cron}') public void rep...
Dharita Chokshi
1

votes
0

answer
36

Views

Cannot parse crontab with tabs as field delimiters with Python's crontab package

I am parsing an /etc/crontab (from a Debian 7.10 host) with Python's crontab package. I slightly misparses lines where the user field is surrounded by tabs (CTRL+I, not spaces). Yet crontab(5) states: The fields may be separated by spaces or tabs. Have I encountered a bug in Python's crontab packag...
rookie099
1

votes
0

answer
147

Views

Schedule Python Script to Run Using Task Scheduler w/Windows7 — Error (0x2)

I have been pulling my hair out on this problem for the past few days. I have a Python script that manually runs without any issues. My Python code essentially writes a pandas data frame to a MSSQL server. I am trying to setup Task Scheduler to automatically run my Python script at a certain time...
PineNuts0
1

votes
0

answer
67

Views

cron job not running in night in iisnode

We have a MEAN stack application. It is deployed on iisnode. We have written a cron job using npm cron module.cron is not running until we hit the URL. We think iisnode become idle. Is there a way to resolve this?
aks
1

votes
1

answer
92

Views

Schedule Job on jenkins over night

I've read the help in Jenkins itself and also How to schedule jobs in Jenkins?. In Jenkins you can build a job periodically by defining a cron like syntax with the addition of H(for 'hash'). So defining H H(0-7) * * * means build once between 0:00 AM and 7:00 AM. But how can I define 1 job between 2...
derHugo
1

votes
1

answer
115

Views

Codeigniter CLI does not log

I have the following function which updates the status of my vacancies (based on dates) and logs the amount of vacancies that got a change, it looks like this: //Function used to check the statusses of every vacancy and update it accordingly function checkVacanciesStatusses() { // this function can...
Dennis
1

votes
0

answer
361

Views

Crontab: Is it possible to activate `pyenv` as soon as reboot?

Environment : Linux Ubuntu 16.04, pyenv, 'pyenv-virtualenv` What I want to automate is: reboot activate my virtual_environment as soon as reboot run a command (in this case, honcho start ~~. honcho can be installed via pip) after that What I tried: In crontab list (crontab -e) Add @reboot sh /home/...
user3595632
1

votes
1

answer
125

Views

How to add function to cron using Go reflect?

I am trying to schedule few jobs dynamically by reading configuration from file like below import ( 'github.com/robfig/cron' 'fmt' ) masterJobDetails :=// this is array of job from file c := cron.New() for k, v := range masterJobDetails { fmt.Println(k, v.JobName) c.AddFunc(v.CronExpression, v.JobN...
Gan
1

votes
0

answer
61

Views

Synchronize separate processes with using redis

I have four separate instances of a server running and I want only one of them to run a query every 5 seconds. The problem I am having is that they seem to be able to check the redis key that i have set for the last time the query was run so quickly that multiple instances run my query at the same t...
stihl
1

votes
0

answer
103

Views

Triggering Cron job on AWS manually through sending a message from SQS

I setup cron job on Elasticbeanstalk using cron.yaml file and sqs run my tasks periodically. Is there a way to trigger a cron job manually through sqs platform so that for not-frequently running tasks I can easily test the results without waiting for the schedule itself? I tried to send a message to...
cubbuk
1

votes
1

answer
1.8k

Views

Errors “QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-mizu'” when running phantomjs from contab

When I run phantomJS with crontab, the following errors occur. How can I run it successfully? I am using Ubuntu 17.10. [error] QStandardPaths: XDG_RUNTIME_DIR not set, defaulting to '/tmp/runtime-mizu' QXcbConnection: Could not connect to display PhantomJS has crashed. Please read the bug reporting...
shin
1

votes
1

answer
251

Views

How to tell a crontab to expire on particular date?

It is straightforward to execute a task for every 6 hours using the following cron pattern : * */6 * * * Is it possible to stop the above cron job on particular date, say, 2018-02-10?
Prem
1

votes
1

answer
341

Views

Kubernetes CronJob Failure to start a job “Timeout” and “Job already exists”

I am trying to run a cronjob in kubernetes, but keep to having these two errors: type: 'Warning' reason: 'FailedCreate' Error creating job: jobs.batch 'dev-cron-1516702680' already exists and type: 'Warning' reason: 'FailedCreate' Error creating job: Timeout: request did not complete within allowe...
Reynaldi Wijaya
1

votes
1

answer
103

Views

How to fetch updated JSON data continuously using python

While working with json in python, I've written this small script to fetch the current price of BTC. This works fine when I run the script in Ubuntu terminal. What I want is to update the variable current_price for every minute so that I can use this variable to display a desktop notification for cu...
Srideep Nayak
1

votes
0

answer
606

Views

Node Js Express . how to schedule task

How can I schedule a job or task to be executed at a certain point in time? I have crons for tasks that execute recurrently, but let's say I create a calendar event and I want my server to send a notification whenever it is the time of the event. Also, will this be deleted whenever the server is res...
htafoya
1

votes
0

answer
197

Views

How to joomla cron manually

Using Joonla 3.7 I used to get a warning about the cron job not running because my provider does not allow me to run cron jobs. I could run the cronjob manually by clicking on the warning message and all was fine to me. After updating Joomla to 3.8.3 I cannot find the link to run the cron manually....
Rob Ouwerkerk
1

votes
0

answer
20

Views

Cron Job Issue on Once a Day

I have two Cron Jobs running on CentOS. One Every 5 Mins Its working fine */5 * * * * curl 'http://10.133.43.243/cron/aaa.php' > /dev/null 2>&1 Another One Once a day 0 0 * * * curl 'http://10.133.43.243/cron/bbb.php' > /dev/null 2>&1 This Cron Not Working fine. But When I call this URL Directly...
nagaking
1

votes
1

answer
130

Views

Fetching near-realtime data from external API

I'm looking for a sustainable solution to fetch data every x seconds (let's say 20) and store it in a relational database using PHP. After doing some research I found a few options: 1) Cronjobs (with shell scripts) See https://askubuntu.com/questions/800/how-to-run-scripts-every-5-seconds for more i...
JasonK
1

votes
0

answer
859

Views

Cron expression for every 48 hours

I'm trying to run a cron job for every 48 hours. But the given expression is not valid apparently saying more than 23 hours is invalid. (here) 0 0/48 1/1 * ? * Can someone help me with the expression?
CCoder
1

votes
1

answer
267

Views

Quartz.Net with XmlPlugin, use Misfire with overwrite-existing-data

I'm using Quartz.Net (v 3.0.1) for the first time, with the XML Plugin to schedule the jobs and triggers from a XML file. I need in particular two features: To use the misfire policy, for example FireOnceNow for a certain job scheduled with a cron trigger that had a misfire To load at run time oth...
luke88
1

votes
0

answer
20

Views

Sklearn import issue with cron

I have a python script that use sklearn package. It runs fine when I launch it from terminal But when I try to run this script in a cron job, it faills ! It seems that import faills from sklearn.neural_network import MLPRegressor from sklearn.externals import joblib How can I solve this issue ?
Cezembre
1

votes
1

answer
241

Views

Rails whenever not able to execute service methods

I have a NotificationService which has methods like this: def trial teacher notification = Notification.create(recipient: teacher, tag: 'trial', text: 'text', title: 'title') notification.deliver end I want to have a Whenever runner job to execute this method ... bin/rails runner 'NotificationServi...
Zlautumn
1

votes
0

answer
32

Views

PHP cURL gives error at crontab, but through ssh it works perfect

I've made a php script, that i want to excecute on my ubuntu 16.04 machine. I am working with php 7 and i use crontab. When i run the command which php this is the output: /usr/bin/php Now my script is uploading a picture on a website. I use PHP curl for that. This is my cURL setup $ch = curl_init()...
user82887
1

votes
1

answer
204

Views

webmin cron not running per minute

I'm using Webmin on my AWS EC2 Instance I have created few cron tasks to run every minute. setup for one cron job is like in script mode /var/spool/cron/crontabs/root # DO NOT EDIT THIS FILE - edit the master and reinstall. # (/tmp/crontab.abHzd4/crontab installed on Wed Feb 7 06:53:10 2018) # (Cro...
Anuj TBE

View additional questions