Skip to main content
7 votes
Accepted

How Smart Groups Work

Smart groups are kind of complicated. If you've got a small install, using the defaults will generally just work, i.e. there will be temporary caching that gets refreshed when necessary. To answer ...
Alan Dixon's user avatar
  • 7,126
6 votes
Accepted

Cron not running since updating to 5.39.0

I would upvote @Demerit if his comment was an answer, but instead I posted some additional info at the link they gave. To satisfy Stack Exchange guidelines, I'll post it below: In Administer menu » ...
Jon G - Megaphone Tech's user avatar
4 votes

Cron breaks after upgrading PHP

As PHP develops, some code that used to work in older versions fails in newer versions. The CiviCRM code gets updated to accommodate those changes - but obviously if you don't upgrade you don't get ...
Aidan's user avatar
  • 13.7k
4 votes

Cron job has started producing output

Not sure why it's suddenly started producing output when it didn't previously, but you could use: #!/bin/sh a=`drush -r /home/crwheelmen/www/www --quiet civicrm-api job.execute` if echo $a | grep -qv ...
Aidan's user avatar
  • 13.7k
4 votes
Accepted

What is the easiest way to set up cron for CiviCRM on a Drupal 7 installation?

Welcome to SE! Setting up cron can be confusing since there are many variations and it touches several aspects: OS users & permissions, CMS users & permissions, other tools, cron - and the ...
Aidan's user avatar
  • 13.7k
4 votes
Accepted

Why am I getting a warning about hook_civicrm when Civi's cron runs?

I'm assuming you have the civicrm_entity module installed. There's an open pull request for this at https://github.com/eileenmcnaughton/civicrm_entity/pull/238 If you're able to test out that patch ...
Demerit's user avatar
  • 24.7k
3 votes

Cron error after upgrading to 4.7.14 - Function "is_admin()" is missing, even though WordPress is the user framework

The error message comes from here and indicates that cron.php is not bootstrapping the WordPress CMS, so WordPress functions aren't available. WordPress is_admin() is defined in wp-includes/load.php. ...
Chris Burgess's user avatar
3 votes

To prevent cron emails do I need to redirect output to /dev/null?

What I've done to fix this is create a bash script that executes the civicrm api command, captures the output to a variable, tests for the string [is_error] => 0, if there's no match, then it echos ...
onefiftyfour's user avatar
3 votes

Why are all bulk mailings delayed by 5 hours?

I would look at the scheduled_date on the mailings in your database: SELECT name,scheduled_date FROM civicrm_mailing; If the scheduled_date is off, then it might be that MySQL has a time mismatch - ...
Jon G - Megaphone Tech's user avatar
3 votes
Accepted

Long running Scheduled Job

If you run the schedulded job as a cron job and don't use the http-method for the setup you will not face a php runtime timeout. We did have no issues with schedulded jobs running multiple hours.
Thomas Schüttler's user avatar
3 votes

DB Error: connect failed when trying to call Job.execute using cli.php?

First, you can view the error with greater detail if you enable "Debug and Backtrace", or view the CiviCRM log. The troubleshooting documentation will tell you how to do both. Second, I would assume ...
Jon G - Megaphone Tech's user avatar
3 votes

process_mailing processing addresses when called in UI but not CRON

Had the same problem, on Ubuntu change the system time zone with "sudo dpkg-reconfigure tzdata". Restart the mysql service with "sudo service mysql restart". Can confirm that this gets the cron ...
Stephen Sloan's user avatar
3 votes

CiviMail cron job unable to find: civicrm.config.php, built with: roundearth/drupal-civicrm-project

You should run CV commands from the root of the website (especially on Drupal 8/9 - where support isn't as well tested for "pathing" - i.e finding the correct files to bootstrap CiviCRM). If your ...
HomoTechsual's user avatar
  • 1,138
3 votes

BackdropCMS & cron

Ok, The CLI version works out of the box: /usr/local/bin/php /home/#dir#/public_html/modules/civicrm/bin/cli.php -s #domain# -u #cronuser# -p #cronpwd# -e Job -a execute The HTTP version needs a ...
Catorghans's user avatar
  • 3,544
3 votes

Upgrade to 5.47.2 now cron does nothing - how to fix?

The cause was a folder permissions problem. The folders at the 2 bottom levels of www.mysite.com/sites/all/modules/civicrm/bin/cron.php had got changed from 755 to 777. When I tried to execute the ...
Andy Clark's user avatar
  • 4,965
3 votes

Cronjob for CiviCRM with drush 10: The "-u" option does not exist

I don't know if there still is a way to use drush but I got the cronjob working with cv: composer require civicrm/cv And then the crontab is: * * * * * /var/www/path_to_civi_project/vendor/civicrm/cv/...
Tobias Krause's user avatar
3 votes

Why does Drupal 9 complain when my CiviCRM cron runs?

I have one Drupal 9 site with this problem, and several more that don't. I don't know the root cause of the issue, but I know that adding --level=cms-full to the cv command fixes the issue.
Jon G - Megaphone Tech's user avatar
2 votes
Accepted

Can I turn off Drupal cron while the CiviCRM upgrade script is running?

My standard for Drupal cron is to only run it every 8 hours. Unless you use modules that expect a more frequent update (e.g. to pull in RSS feeds in a timely manner) you should be fine turning it off ...
Jon G - Megaphone Tech's user avatar
2 votes

Has anyone run into scheduled jobs drifting on Centos7?

This extension might solve this issue: Cron Plus
luciano_s's user avatar
  • 566
2 votes

"Cron not running" (but it is), trying to use wp-cli in crontab, with WordPress

whereis wp showed wp: /usr/bin/wp, so I tried that in crontab and the problem appears to be solved! System Status no longer says cron is not running and the "Last Run" column on Scheduled Jobs ...
user1147171's user avatar
2 votes

Cron failing on Update Membership Statuses and Send Renewal Reminders

I solved the issue with the help of xurizaemon on the Mattermost chat channel. The script was failing because it was trying to delete a membership that looked like it was already deleted. Hints ...
joewickert's user avatar
2 votes

Error: Cron Not Running

I may have solved this with the following steps. create a drush alias for the site configure crontab using the drush alias Drush alias (~/.drush/example.aliases.drushrc.php) <?php $aliases['...
Brylie Christopher Oxley's user avatar
2 votes
Accepted

URL for cron Jobs gives me a 404 error

Two answers: First, yes, changing the permission should be safe to do. Note, however, that you'll have to repeat this process every time you upgrade. Second - this isn't a normal restriction, so I'...
Jon G - Megaphone Tech's user avatar
2 votes

How Smart Groups Work

This is not a specific answer to your questions but an option for larger smart groups to improve performance is to use the CiviRules extension to manage group memberships. So when a certain activity ...
KilakwaBT's user avatar
  • 2,391
2 votes
Accepted

Safe to run cron jobs using wget and user with full admin rights?

It's better to limit the cron user to the minimum permissions - but I'm not 100% sure what those permissions are. E.g. if you don't give access to CiviEvent, can you use smart groups based on ...
Jon G - Megaphone Tech's user avatar
2 votes

Schedule Jobs Page on Multisite

This is actually the correct interface. I believe you're trying to compare the "List Scheduled Jobs" interface with the "Edit a single Scheduled Job" interface. If you press "Edit" next to any ...
Jon G - Megaphone Tech's user avatar
2 votes
Accepted

Cron job for Multisite in WordPress

I manage one WordPress multisite instance, so I looked how cron is configured. We use wp-cli with the CiviCRM extension to trigger cron. Cron jobs look like: 11,26,41,56 * * * * /full/path/to/wp-...
Jon G - Megaphone Tech's user avatar
2 votes

Crons are running but system status page says otherwise

You do not need to have a separate cronjob for each job: on the admin interface, set the frequency for each job you want to (nightly is good for most of them, but the one that process the mailing and ...
Xavier's user avatar
  • 10.2k
2 votes

I am trying to set up easycron

The username and password are for a WordPress user. I would recommend setting up a user specifically for this purpose and don't use it for anything else. You will need to give the user the correct ...
William Mortada's user avatar
2 votes
Accepted

Problem with wp-cli and setting up cron in CiviCRM

After much research and getting expert ideas... (I'm sure this is known to many people here, but I'm posting here to hopefully help others who don't know this.) TLDR; in Cron jobs, you should fully ...
Norman Cates's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible