Answers.Body: <p>I'm not sure about this but it sounds like a permissions problem and you may need to update the permissions in root/wp-content/plugins/civicrm/civicrm/bin/cli.php to be executable. Hope this solves your problem.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-12-14T18:47:25.920Z
Answers.Text: Thanks for the suggestion, peterb. I had forgotten to fix those permissions when I reinstalled, but even with it set to 755 I still get
  
  ERROR: Invalid username and/or password
  
  when using the WP username; when using the same user's full email address, I still get
  
  Failed to login as [useremail]
Answers.UserDisplayName: Joe White
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-12-15T12:08:33.947Z
Answers.Text: Would it be worth trying to move public_html after sub.domain.com in your cron command?
Answers.UserDisplayName: peterb
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-12-16T00:18:31.183Z
Answers.Text: Thanks again, peterb, but `/home/me/public_html/sub.domain.com/wp-content/plugins/civicrm/civicrm/bin/cli.php` is the actual path.
Answers.UserDisplayName: Joe White
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-12-14T12:40:42.077Z
Answers.LastActivityDate: 2016-12-14T12:40:42.077Z
Answers.UserDisplayName: peterb
Body: <p>New installation of 4.7.14 into a WordPress 4.7 site located in a subdomain (e.g. sub.domain.com) hosted at A2. Everything good except for the "Cron Not Running". Created a new WP user with admin privileges, but still get "ERROR: Invalid username and/or password". Happens when trying to run from the command line as well.</p>
  
  <p>php /home/me/public_html/sub.domain.com/wp-content/plugins/civicrm/civicrm/bin/cli.php -s sub.domain.com -u WP-user -p WP-password -e Job -a execute</p>
  
  <p>What am I missing?</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-12-16T03:07:42.023Z
Comments.Text: Progress! Using full path of `/usr/bin/php` got the error `cli.php can only be run from command line.` Using the hack at [link](http://civicrm.stackexchange.com/questions/4723/how-do-i-import-contacts-through-the-command-line/4724#4724) I now get a bunch of html and then `<!-- W3 Total Cache: Minify debug info:
  Engine:             disk
  Theme:              2fa4e
  Template:           index
  -->
  /continued in next comment
Comments.UserDisplayName: Joe White
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2016-12-16T03:12:50.337Z
Comments.Text: (final output)
  <!-- W3 Total Cache: Page cache debug info:
  Engine:             disk: enhanced
  Cache key:          gs.joewhite.com/_index.html
  Caching:            enabled
  Creation Time:      0.005s
  Header info:
  X-Powered-By:        PHP/5.5.38
  Last-Modified:       Thu, 01 Jan 1970 00:00:00 GMT
  Expires:             Fri, 16 Dec 2016 04:08:18 GMT
  Pragma:              public
  Cache-Control:       max-age=3600, public
  Etag:                64a26f9af5e9eb7cc1fa0a8df39c39cc
  -->
  Cron now running every 15 minutes, but still getting no cron runs have been recorded.
Comments.UserDisplayName: Joe White
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-06-12T16:35:22.993Z
Comments.Text: Are you using the WP user nickname or email address?  I set one of these up recently on WP and could only get it to work correctly with the email address of the cronuser, not the nickname/username.
Comments.UserDisplayName: Lesley Carter - BackOffice
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-08-05T16:10:37.037Z
Comments.Text: I finally just wiped and reinstalled from scratch. Worked with the WP username:
  
  /path/to/php /home/me/public_html/sub.domain.com/wp-content/plugins/civicrm/civicrm/bin/cli.php  -u username -p password -s sub.domain.com -e Job -a execute
Comments.UserDisplayName: Joe White
Tags: <wordpress><cron><cli>
Title: cron setup failing in new Wordpress installaion
ThreadText: # cron setup failing in new Wordpress installaion
  
  (Asked by: username_0 on 2016-12-14)
  
  New installation of 4.7.14 into a WordPress 4.7 site located in a subdomain (e.g. sub.domain.com) hosted at A2. Everything good except for the "Cron Not Running". Created a new WP user with admin privileges, but still get "ERROR: Invalid username and/or password". Happens when trying to run from the command line as well.
  
  php /home/me/public\_html/sub.domain.com/wp-content/plugins/civicrm/civicrm/bin/cli.php -s sub.domain.com -u WP-user -p WP-password -e Job -a execute
  
  What am I missing?
  
  **Tags:** wordpress, cron, cli
  
  > **Comments:**
  > **username_0**: Progress! Using full path of `/usr/bin/php` got the error `cli.php can only be run from command line.` Using the hack at [link](http://civicrm.stackexchange.com/questions/4723/how-do-i-import-contacts-through-the-command-line/4724#4724) I now get a bunch of html and then `<!-- W3 Total Cache: Minify debug info: Engine:             disk Theme:              2fa4e Template:           index --> /continued in next comment  
  > **username_0**: (final output) <!-- W3 Total Cache: Page cache debug info: Engine:             disk: enhanced Cache key:          gs.username_0.com/_index.html Caching:            enabled Creation Time:      0.005s Header info: X-Powered-By:        PHP/5.5.38 Last-Modified:       Thu, 01 Jan 1970 00:00:00 GMT Expires:             Fri, 16 Dec 2016 04:08:18 GMT Pragma:              public Cache-Control:       max-age=3600, public Etag:                64a26f9af5e9eb7cc1fa0a8df39c39cc --> Cron now running every 15 minutes, but still getting no cron runs have been recorded.  
  > **username_1**: Are you using the WP user nickname or email address?  I set one of these up recently on WP and could only get it to work correctly with the email address of the cronuser, not the nickname/username.  
  > **username_0**: I finally just wiped and reinstalled from scratch. Worked with the WP username:  /path/to/php /home/me/public_html/sub.domain.com/wp-content/plugins/civicrm/civicrm/bin/cli.php  -u username -p password -s sub.domain.com -e Job -a execute  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_2 on 2016-12-14. Score: 1
  
  I'm not sure about this but it sounds like a permissions problem and you may need to update the permissions in root/wp-content/plugins/civicrm/civicrm/bin/cli.php to be executable. Hope this solves your problem.
  
  > **Comments:**
  > **username_0**: Thanks for the suggestion, username_2. I had forgotten to fix those permissions when I reinstalled, but even with it set to 755 I still get  ERROR: Invalid username and/or password  when using the WP username; when using the same user's full email address, I still get  Failed to login as [useremail]  
  > **username_2**: Would it be worth trying to move public_html after sub.domain.com in your cron command?  
  > **username_0**: Thanks again, username_2, but `/home/me/public_html/sub.domain.com/wp-content/plugins/civicrm/civicrm/bin/cli.php` is the actual path.  
  
  ---
  
  