CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Joomla! Installations (Moderator: Deepak Srivastava) »
  • cron.php fails silently
Pages: [1] 2

Author Topic: cron.php fails silently  (Read 3880 times)

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
cron.php fails silently
September 10, 2013, 06:23:19 am
I've scheduled the cron job via cpanel. Went through all the usual stuff including creating a new admin user who didn't have a hash in their password ...

So now the wget call seems to work, but nothing happens. Mail does not get sent, mail jobs are still waiting. If I execute the URL in the browser, it gets logged as 200 OK but nothing happens.

How do I debug this?


Joomla 2.5
PHP Version 5.3.22
CiviCRM 4.3.4

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: cron.php fails silently
September 10, 2013, 06:31:59 am
did you look at the civi logs to see if anything informative is there?
/media/civicrm/ConfigAndLog
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 10, 2013, 07:44:41 am
Quote from: lcdweb on September 10, 2013, 06:31:59 am
did you look at the civi logs to see if anything informative is there?
/media/civicrm/ConfigAndLog

Not seeing anything pertinent there, unfortunately.

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 10, 2013, 08:26:02 am
OK, here's something.

I tried this from the manual:

Quote
If you are worried CiviMail won't send email at all, you can send queued messages as well with these commands.  If nothing is sent, check your Outgoing Mail Settings.
Drupal: http://<site>/index.php?q=civicrm/mailing/queue&reset=1&name=username&pass=password&key=site-key
 
Joomla: http://<site>/administrator/index.php?option=com_civicrm&task=civicrm/mailing/queue&reset=1&name=username&pass=password&key=site-key


This worked, BUT ... it didn't work automatically, it landed me on the Joomla login page. If I then logged in with the same username and password that were in the URL, it worked. All I had to do was manually log in


So ... could this be the problem with the cron task? Somehow automatic logins are not working?

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: cron.php fails silently
September 10, 2013, 08:56:32 am

the below quote from the manual seems incorrect. Can you give us a link to the manual page where u saw this info

thanx

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 10, 2013, 12:59:59 pm
Quote from: Donald Lobo on September 10, 2013, 08:56:32 am

the below quote from the manual seems incorrect. Can you give us a link to the manual page where u saw this info

thanx

lobo

I saw that here:

http://wiki.civicrm.org/confluence/display/CRMDOC/CiviMail+Installation


BTW, any ideas I how I could troubleshoot the problem? :)

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: cron.php fails silently
September 10, 2013, 01:13:35 pm

i fixed the wiki to more accurately reflect things (as i know them)

check your permissions on the media/ folder and ensure that the command line user can also write to that directory. that might be tripping things up. just  a shot in the dark

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 12, 2013, 07:47:10 am
Quote from: Donald Lobo on September 10, 2013, 01:13:35 pm
i fixed the wiki to more accurately reflect things (as i know them)

Thanks!


Quote from: Donald Lobo on September 10, 2013, 01:13:35 pm
check your permissions on the media/ folder and ensure that the command line user can also write to that directory. that might be tripping things up. just  a shot in the dark

So that I can get some more informative logging? Or for some other reason?

The media and media/civicrm folders were already 0777. The media/civicrm/ConfigAndLog folder was 0755; I've changed it now to 0777 (this is on a development server, BTW).

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 12, 2013, 08:15:44 am
Hmm; when I try to run the cron command in the browser and I am not logged into Joomla (I hadn't thought of that previously), I get a Joomla login page. I'm guessing this is not what is supposed to happen.  ???

http://{site}/administrator/index.php?option=com_civicrm&task=civicrm/mailing/queue&reset=1&name=cronadmin&pass={pass}&key={key}
« Last Edit: September 12, 2013, 09:19:14 am by holmesg »

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 12, 2013, 08:22:18 am
And when I manually complete the login, using the username and password from the cron URL, the mailing gets sent.

So, the problem is with the automated login via URL.

How do I make this work?
« Last Edit: September 12, 2013, 08:45:53 am by holmesg »

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: cron.php fails silently
September 12, 2013, 09:00:51 am

FYI, the above url: civicrm/mailing/queue is NOT cron.php and does not recognize the username/pass parameter

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 12, 2013, 09:18:47 am
Quote from: Donald Lobo on September 12, 2013, 09:00:51 am

FYI, the above url: civicrm/mailing/queue is NOT cron.php and does not recognize the username/pass parameter

lobo

Bleah; I got confused and used the test URL ("If you are worried CiviMail won't send email at all, etc.")


However, the actual cron job URL that I am using is:

http://{site}/administrator/components/com_civicrm/civicrm/bin/cron.php?name=cronadmin&pass={password}&key={key}


Trying that manually does not give me the login page, it just gives me a blank page.  And the mail jobs do not send.
« Last Edit: September 12, 2013, 10:43:40 am by holmesg »

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 12, 2013, 10:50:38 am
What should the permissions on cron.php itself be?

holmesg

  • I post occasionally
  • **
  • Posts: 61
  • Karma: 0
  • CiviCRM version: CiviCRM 4.3.4
  • CMS version: Joomla! 2.5.8
  • MySQL version: 5.1.70
  • PHP version: PHP Version 5.3.22
Re: cron.php fails silently
September 12, 2013, 11:43:10 am
OK, slow and painful debugging ...

It's dying somewhere during this call:

Code: [Select]
return $config->userSystem->authenticate($name, $password, $loadCMSBootstrap, $realPath);
from /public_html/administrator/components/com_civicrm/civicrm/CRM/Utils/System.php


I tried to dig deeper ... that's pretty much as far as my brain gets in that nest of objects ...

Help?

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: cron.php fails silently
September 12, 2013, 11:50:22 am

that function is in:

CRM/Utils/System/Joomla.php

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

Pages: [1] 2
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Joomla! Installations (Moderator: Deepak Srivastava) »
  • cron.php fails silently

This forum was archived on 2017-11-26.