I finally decided to get cron.php running for one of my multisite domains. (It's the only one live.) But, dang if I can't get the command to execute cron.php. Been at it for two full days; seems like it's gotta be something simple and I'm just not seeing it. Hope someone can spare a second to help.
Here's the crontab (in cygwin on a Windows 2003 server -- not an ISP -- I have temporary admin privileges)
30 13 * * * /bin/wget.exe -O - -9 -t 1 http://domain.edu/cron.php
--- command entered in command line window (cygwin)
--- -O is a capital O not a zero.
--- to get path to wget, I used this command: $ whereis wget and it ret'nd:
wget: /bin/wget.exe /usr/bin/wget.exe /usr/share/man/man1/wget.1.gz
--- cygwin path: C:\cygwin
--- OS -- Windows Server 2003
--- Drupal path in Windows: C:\Apache2.2\htdocs\drupal
--- Drupal path in Windows to domain: C:\Apache2.2\htdocs\drupal\sites\water
--- That's a one(1) before the url. (correct -- or l as in el?)
This is the first time I have used cygwin and issued a cron command.
Thanks for any help or ideas....
Comments
Postscript: Still not
Postscript: Still not running but I changed my command. The -9 is now -q and I changed the path to wget so it reads: /usr/bin/wget
Anybody have any ideas?
Does cygwin actually have a
Does cygwin actually have a running cron daemon?
Perhaps see if there's a way it can be done using the Windows equivalent. (I can't remember what it's called.) Also consider using Drush instead of the wget approach - it's far more sane.
The Boise Drupal Guy!
You asked if cygwin has a
You asked if cygwin has a running cron daemon. Hmmm...running..huh? I didn't know I had to turn it on. I'll investigate that. Been looking for some type of cron diagnose script.
I've got enough hours into this that I'd like to try and finish using this approach but I've set a time cap.
Why do you say the wget approach isn't sane? ( I thought I was the one losing my mind but heck, I'll blame it on wget happily!)
windows equivalent
I believe the Windows equivalent of cron is called at.
As for wget, it uses the same settings for php as the web server and ties up a process while it's running. By using brush it uses the cli.
Not understanding this:
Not understanding this: "believe the Windows equivalent of cron is called at."
wget --> interesting. didn't know that. I only will have it running for this domain 1X per day and manual takes just a second, so would you agree that the process congestion isn't a sig issue.
Depends..
Windows has a cron-like setup called "at." (sorry, was typing on a phone earlier.. easy to do air quotes, hard to do real ones).
For wget vs. drush, well, it depends on your setup.
One of the advantages of using drush is that you can set up a separate php.ini for CLI. In this manner, you can set it to have higher memory limits, disable max_execution_time, etc... All things that make cron run happily.
However, if you don't need that, wget works fine. :)
"at" ---> fascinating. news
"at" ---> fascinating. news to me. will google it.
I'll check out drush given the conversational momentum here on that module but for right now, i have this terrier-like need to chew on this and figure it out. I'm not good at walking away when something is too hard. It's a personal problem! :-)
it's gotta be something simple....headaches like this usually are. grrrr.
"at" may be the command-line
"at" may be the command-line tool, but there's also the Task Scheduler, which was what I was referring to earlier and couldn't recall the name. It has a graphical interface which you may be more comfortable working with.
The Boise Drupal Guy!
Hi folks --- I've progressed
Hi folks ---
I've progressed on this crontab running cron.php problem after some time away. Wondering if someone here thinks that I have a server inbound or outbound block in the firewall or elsewhere (httpd??) Or is this a module problem. Not sure. If I can pinpoint, then it's easy to tell the IT guy at university here what to do/change on this server. Otherwise, I am on my own.
----------Updates report is not updated
----------Feeds are not updated
This is all happening on a Windows 2003 server; apache 2.2; Drupal 6x.
Here's what I see from running in debug mode within the command line interface (replaced real domain with "domainname"):
$ wget -O- -t1 -d http://domainname/cron.php
DEBUG output created by Wget 1.11.4 on cygwin.
--2010-06-17 14:46:05-- http://domainname/cron.php
Resolving domainname... 129.101.xxx.xx
Caching domainname => 129.101.xxx.xx
Connecting to domainname|129.101.xxx.xx|:80... connected.
Created socket 3.
Releasing 0x00ac94a8 (new refcount 1).
---request begin---
GET /cron.php HTTP/1.0
User-Agent: Wget/1.11.4
Accept: /
Host: domain-name
Connection: Keep-Alive
---request end---
HTTP request sent, awaiting response...
---response begin---
HTTP/1.1 200 OK
Date: Thu, 17 Jun 2010 21:46:05 GMT
Server: Apache/2.2.15 (Win32)
Set-Cookie: SESS9ba5500cc8672b58ffb5d574c3076d59=a2a5e6f1d477264484b1e450a0e1be1
a; expires=Sun, 11-Jul-2010 01:19:25 GMT; path=/; domain=.domainname
Expires: Sun, 19 Nov 1978 05:00:00 GMT
Last-Modified: Thu, 17 Jun 2010 21:46:05 GMT
Cache-Control: store, no-cache, must-revalidate
Cache-Control: post-check=0, pre-check=0
Content-Length: 0
Keep-Alive: timeout=5, max=100
Connection: Keep-Alive
Content-Type: text/html; charset=utf-8
---response end---
200 OK
Registered socket 3 for persistent reuse.
cdm: 1 2
Stored cookie domain -1 (ANY) / <permanent> <insecure> [expiry 2010-07
-10 18:19:25] SESS9ba5500cc8672b58ffb5d574c3076d59 a2a5e6f1d477264484b1e450a0e1b
e1a
Length: 0 [text/html]