1

When I run my cron job, wget -O - -q -t 1 domain.org/wp-content/plugins/civicrm/civicrm/bin/cron.php?name=XXX&pass=XXX&key=XXXXX

When I use this link in my browser it works just fine no issue, so the key is valid. I get the same error when running GET domain.org/wp-content/plugins/civicrm/civicrm/bin/cron.php?name=XXX&pass=XXX&key=XXXXX

I can't seem to use single quotes or it stops running altogether. A FQDN and I get a JSON error in the cron setup.

1

Without quotes around the URL, your shell may interpret the '&' character as a request to run a command in the background:

$ wget -O - -q -t 1 none.such/wp-content/plugins/civicrm/civicrm/bin/cron.php?name=XXX&pass=XXX&key=XXXXX
[1] 9887
[2] 9888
$ jobs
[1]-  Exit 4                  wget -O - -q -t 1 none.such/wp-content/plugins/civicrm/civicrm/bin/cron.php?name=XXX
[2]+  Done                    pass=XXX
$

Here it uses the URL up to but not including the first '&', thus missing the pass and key parameters. Enclosing the URL in quotes should resolve this:

$ wget -O - -q -t 1 'none.such/wp-content/plugins/civicrm/civicrm/bin/cron.php?name=XXX&pass=XXX&key=XXXXX'
$

You say this didn't work for you, could you provide details of what command you tried and what the result was?

  • When I used quotes like this GET 'domain.org/wp-content/plugins/civicrm/civicrm/bin/cron.php?name=XXX&pass=XXX&key=XXXXX' Nothing happens. Job does not run. I do not get an email. I let it sit through 3 cycles last night and it never ran once. – Tiffany Carra Aug 28 '15 at 14:09
  • Tiffany - can you please clarify whether you're running this command directly on a command line when you test? Or are you using your webhost's control panel? If the latter, then there may be a security setting on the webhost's control panel. If you're testing directly on the command line, please show the output of the command when you use the single quotes? – Jon G - Megaphone Tech Aug 28 '15 at 15:12
  • I am running it on CPanel – Tiffany Carra Aug 28 '15 at 16:49
0

This was a permissions issue with my webhost like davejenx suggested. Quick fix via support chat.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.