Cron run exceeded the time limit and was aborted.
I have a function that runs a few updates and displays a list of what it did. In order to get caught up from a long period of neglect, I decided to add it into the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit and was aborted" yet it completes in far less than 30 seconds. Any ideas how my code could be inadvertantly triggering this? Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In order to get caught up from a long period of neglect, I decided to add it into the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit and was aborted" yet it completes in far less than 30 seconds. Any ideas how my code could be inadvertantly triggering this?
Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message. -- Earnie -- http://progw.com -- http://www.for-my-kids.com
If I comment that line out, the problem goes away, so yes, I am reasonably convinced it is my function. I can clearly see it returning in far less than even 30 seconds, so there is no way it's taking 240. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Earnie Boyd <earnie@users.sourceforge.net> To: development@drupal.org Sent: Wed, September 8, 2010 12:08:25 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In
order to get caught up from a long period of neglect, I decided to add it into
the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit
and was aborted" yet it completes in far less than 30 seconds. Any ideas how my
code could be inadvertantly triggering this? Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message. -- Earnie -- http://progw.com -- http://www.for-my-kids.com
Actually I do watchdog("my function', myfunction(10)) so the output goes to dblog when it works. I never use exit() in Drupal. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Ted <ted-drupalists@webfirst.com> To: development@drupal.org Sent: Wed, September 8, 2010 12:24:14 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. Have you tried suppressing the output of your function? Also, make sure you're not calling drupal_goto--or anything else that calls exit(). Ted On 9/8/2010 12:17 PM, nan wich wrote: If I comment that line out, the problem goes away, so yes, I am reasonably convinced it is my function.
I can clearly see it returning in far less than even 30 seconds, so there is no way it's taking 240. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King,
Jr.
________________________________ From: Earnie Boyd <earnie@users.sourceforge.net>
To: development@drupal.org Sent: Wed, September 8, 2010 12:08:25 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted.
nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In
order to get caught up from a long period of neglect, I decided to add it into
the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit
and was aborted" yet it completes in far less than 30 seconds. Any ideas how my
code could be inadvertantly triggering this? Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message.
-- Earnie -- http://progw.com -- http://www.for-my-kids.com
hey cron takes time in cheching updates of ur drupal version and its modules. If u deactivate the update module then it will not take time. On Wed, Sep 8, 2010 at 9:38 PM, Earnie Boyd <earnie@users.sourceforge.net>wrote:
nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In order to get caught up from a long period of neglect, I decided to add it into the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit and was aborted" yet it completes in far less than 30 seconds. Any ideas how my code could be inadvertantly triggering this?
Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message.
-- Earnie -- http://progw.com -- http://www.for-my-kids.com
-- Thanks & Regards, Dhananjay Gandhi
Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Dhananjay Gandhi <dhananjay.gandhi@gmail.com> To: development@drupal.org Sent: Wed, September 8, 2010 12:21:34 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. hey cron takes time in cheching updates of ur drupal version and its modules. If u deactivate the update module then it will not take time. On Wed, Sep 8, 2010 at 9:38 PM, Earnie Boyd <earnie@users.sourceforge.net> wrote: nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In order to get caught up from a long period of neglect, I decided to add it into the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit and was aborted" yet it completes in far less than 30 seconds. Any ideas how my code could be inadvertantly triggering this?
Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message.
-- Earnie -- http://progw.com -- http://www.for-my-kids.com
-- Thanks & Regards, Dhananjay Gandhi
Perhaps your hook has an exit() in it (or aborts for some other reason?) and therefore cron does not have a chance to clear the semaphore? Elysia cron will probably make the problem go away, by working around it. On Wed, Sep 8, 2010 at 12:26 PM, nan wich <nan_wich@bellsouth.net> wrote:
Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site.
*Nancy*
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------ *From:* Dhananjay Gandhi <dhananjay.gandhi@gmail.com> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:21:34 PM *Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
hey
cron takes time in cheching updates of ur drupal version and its modules. If u deactivate the update module then it will not take time.
On Wed, Sep 8, 2010 at 9:38 PM, Earnie Boyd <earnie@users.sourceforge.net>wrote:
nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In order to get caught up from a long period of neglect, I decided to add it into the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit and was aborted" yet it completes in far less than 30 seconds. Any ideas how my code could be inadvertantly triggering this?
Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message.
-- Earnie -- http://progw.com -- http://www.for-my-kids.com
-- Thanks & Regards, Dhananjay Gandhi
-- Khalid M. Baheyeldin 2bits.com, Inc. http://2bits.com Drupal optimization, development, customization and consulting. Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra Simplicity is the ultimate sophistication. -- Leonardo da Vinci
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron(). As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears. Are you using drush? If so you can trace the root of the problem with relative ease. find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron" Then just try drush dis -y <module> and drush cron Repeat as necessary. --- appa
No I am not using drush. I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: António P. P. Almeida <appa@perusio.net> To: development@drupal.org Sent: Wed, September 8, 2010 12:38:40 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron(). As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears. Are you using drush? If so you can trace the root of the problem with relative ease. find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron" Then just try drush dis -y <module> and drush cron Repeat as necessary. --- appa
What about running it from /cron.php? Does it work, or does what devel does? Could it be that your php timeout is too low? Check *max_execution_time* in php.ini or friends. On Wed, Sep 8, 2010 at 12:46 PM, nan wich <nan_wich@bellsouth.net> wrote:
No I am not using drush.
I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel.
*Nancy*
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------ *From:* António P. P. Almeida <appa@perusio.net> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:38:40 PM
*Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
-- Khalid M. Baheyeldin 2bits.com, Inc. http://2bits.com Drupal optimization, development, customization and consulting. Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra Simplicity is the ultimate sophistication. -- Leonardo da Vinci
When the normal cron time comes, it's fine. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Khalid Baheyeldin <kb@2bits.com> To: development@drupal.org Sent: Wed, September 8, 2010 12:54:28 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. What about running it from /cron.php? Does it work, or does what devel does? Could it be that your php timeout is too low? Check max_execution_time in php.ini or friends. On Wed, Sep 8, 2010 at 12:46 PM, nan wich <nan_wich@bellsouth.net> wrote: No I am not using drush.
I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King,
Jr.
________________________________ From: António P. P. Almeida <appa@perusio.net>
To: development@drupal.org Sent: Wed, September 8, 2010 12:38:40 PM
Subject: Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
-- Khalid M. Baheyeldin 2bits.com, Inc. http://2bits.com Drupal optimization, development, customization and consulting. Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra Simplicity is the ultimate sophistication. -- Leonardo da Vinci
The link in devel is just a link to the same URL as clicking it in the status report (/admin/reports/status/run-cron). Here's a good hacky trick I have used before to diagnose cron problems. Go into module.inc and edit the module_invoke_all function so it looks like this: foreach (module_implements($hook) as $module) { $function = $module .'_'. $hook; if ($hook=='cron'){ echo "$module <br />"; } That will give you an idea of exactly which cron implementation it's hanging up at, then you can just revert the changes in module.inc when you are done troubleshooting. Jamie Holly http://www.intoxination.net http://www.hollyit.net On 9/8/2010 12:46 PM, nan wich wrote:
No I am not using drush. I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel.
/*Nancy*/
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------------------------------------------------ *From:* António P. P. Almeida <appa@perusio.net> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:38:40 PM *Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net <mailto:nan_wich@bellsouth.net> wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
A better approach for timing cron stuff here http://drupal.org/node/131536#comment-1117255 There is a variable to turn this on or off on demand. On Wed, Sep 8, 2010 at 12:55 PM, Jamie Holly <hovercrafter@earthlink.net>wrote:
The link in devel is just a link to the same URL as clicking it in the status report (/admin/reports/status/run-cron).
Here's a good hacky trick I have used before to diagnose cron problems. Go into module.inc and edit the module_invoke_all function so it looks like this:
foreach (module_implements($hook) as $module) { $function = $module .'_'. $hook; if ($hook=='cron'){ echo "$module <br />"; }
That will give you an idea of exactly which cron implementation it's hanging up at, then you can just revert the changes in module.inc when you are done troubleshooting.
Jamie Hollyhttp://www.intoxination.net http://www.hollyit.net
On 9/8/2010 12:46 PM, nan wich wrote:
No I am not using drush.
I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel.
*Nancy*
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------ *From:* António P. P. Almeida <appa@perusio.net> <appa@perusio.net> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:38:40 PM *Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
-- Khalid M. Baheyeldin 2bits.com, Inc. http://2bits.com Drupal optimization, development, customization and consulting. Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra Simplicity is the ultimate sophistication. -- Leonardo da Vinci
In this case, I can count to 5 and it's back, so it is clearly not taking long enough to time out. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Khalid Baheyeldin <kb@2bits.com> To: development@drupal.org Sent: Wed, September 8, 2010 1:17:28 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. A better approach for timing cron stuff here http://drupal.org/node/131536#comment-1117255 There is a variable to turn this on or off on demand. On Wed, Sep 8, 2010 at 12:55 PM, Jamie Holly <hovercrafter@earthlink.net> wrote: The link in devel is just a link to the same URL as clicking it in the status report (/admin/reports/status/run-cron).
Here's a good hacky trick I have used before to diagnose cron problems. Go into module.inc and edit the module_invoke_all function so it looks like this:
foreach (module_implements($hook) as $module) { $function = $module .'_'. $hook; if ($hook=='cron'){ echo "$module <br />"; }
That will give you an idea of exactly which cron implementation it's hanging up at, then you can just revert the changes in module.inc when you are done troubleshooting.
Jamie Holly http://www.intoxination.net http://www.hollyit.net
On 9/8/2010 12:46 PM, nan wich wrote: No I am not using drush.
I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King,
Jr.
________________________________ From: António P. P. Almeida <appa@perusio.net>
To: development@drupal.org Sent: Wed, September 8, 2010 12:38:40 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
-- Khalid M. Baheyeldin 2bits.com, Inc. http://2bits.com Drupal optimization, development, customization and consulting. Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra Simplicity is the ultimate sophistication. -- Leonardo da Vinci
Ah, there is a slight difference: a destination is appended. It runs fine without the destination, but as soon as I put that on there, it bombs. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Jamie Holly <hovercrafter@earthlink.net> To: development@drupal.org Sent: Wed, September 8, 2010 12:55:20 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. The link in devel is just a link to the same URL as clicking it in the status report (/admin/reports/status/run-cron). Here's a good hacky trick I have used before to diagnose cron problems. Go into module.inc and edit the module_invoke_all function so it looks like this: foreach (module_implements($hook) as $module) { $function = $module .'_'. $hook; if ($hook=='cron'){ echo "$module <br />"; } That will give you an idea of exactly which cron implementation it's hanging up at, then you can just revert the changes in module.inc when you are done troubleshooting. Jamie Holly http://www.intoxination.net http://www.hollyit.net On 9/8/2010 12:46 PM, nan wich wrote: No I am not using drush.
I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King,
Jr.
________________________________ From: António P. P. Almeida <appa@perusio.net>
To: development@drupal.org Sent: Wed, September 8, 2010 12:38:40 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
From memory, having a destination makes the page do a drupal_goto(), which does an exit() and therefore the semphore is not cleared?
On Wed, Sep 8, 2010 at 2:35 PM, nan wich <nan_wich@bellsouth.net> wrote:
Ah, there is a slight difference: a destination is appended. It runs fine without the destination, but as soon as I put that on there, it bombs.
*Nancy*
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------ *From:* Jamie Holly <hovercrafter@earthlink.net> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:55:20 PM
*Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
The link in devel is just a link to the same URL as clicking it in the status report (/admin/reports/status/run-cron).
Here's a good hacky trick I have used before to diagnose cron problems. Go into module.inc and edit the module_invoke_all function so it looks like this:
foreach (module_implements($hook) as $module) { $function = $module .'_'. $hook; if ($hook=='cron'){ echo "$module <br />"; }
That will give you an idea of exactly which cron implementation it's hanging up at, then you can just revert the changes in module.inc when you are done troubleshooting.
Jamie Hollyhttp://www.intoxination.net http://www.hollyit.net
On 9/8/2010 12:46 PM, nan wich wrote:
No I am not using drush.
I have discovered that this only happens when I invoke cron from the Devel menu in the admin_menu bar. If I go to admin/reports/status and click the link there, it runs fine, as it also does when the normal cron run happens. So I opened an issue with Devel.
*Nancy*
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------ *From:* António P. P. Almeida <appa@perusio.net> <appa@perusio.net> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:38:40 PM *Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
On 8 Set 2010 17h26 WEST, nan_wich@bellsouth.net wrote:
[1 <text/plain; iso-8859-1 (quoted-printable)>] Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
I'll second Earnie's suggestion for trying Elysia Cron, you can set the cron running time for each implementation of hook_cron().
As a more hands on approach: grep the hook_cron() implementations of the installed modules and try disabling one by one until the problem disappears.
Are you using drush? If so you can trace the root of the problem with relative ease.
find sites/all/modules/ -type f -regex ".*\.\(module\|inc\)" -print | xargs grep "function.*_cron"
Then just try
drush dis -y <module>
and
drush cron
Repeat as necessary.
--- appa
-- Khalid M. Baheyeldin 2bits.com, Inc. http://2bits.com Drupal optimization, development, customization and consulting. Simplicity is prerequisite for reliability. -- Edsger W.Dijkstra Simplicity is the ultimate sophistication. -- Leonardo da Vinci
Any chance it's doing something off-site that it's timing out on? That would take a lot of time. -Don- On 9/8/2010 12:26 PM, nan wich wrote:
Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site.
/*Nancy*/
Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
------------------------------------------------------------------------ *From:* Dhananjay Gandhi <dhananjay.gandhi@gmail.com> *To:* development@drupal.org *Sent:* Wed, September 8, 2010 12:21:34 PM *Subject:* Re: [development] Cron run exceeded the time limit and was aborted.
hey
cron takes time in cheching updates of ur drupal version and its modules. If u deactivate the update module then it will not take time.
On Wed, Sep 8, 2010 at 9:38 PM, Earnie Boyd <earnie@users.sourceforge.net <mailto:earnie@users.sourceforge.net>> wrote:
nan wich wrote: > I have a function that runs a few updates and displays a list of what it did. In > order to get caught up from a long period of neglect, I decided to add it into > the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit > and was aborted" yet it completes in far less than 30 seconds. Any ideas how my > code could be inadvertantly triggering this? > > Nancy > Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message.
-- Earnie -- http://progw.com -- http://www.for-my-kids.com
-- Thanks & Regards, Dhananjay Gandhi
Yes, it is getting data from another server within our organization, but that server is loafing and wouldn't be timing out this frequently. Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Don <donald@fane.com> To: development@drupal.org Sent: Wed, September 8, 2010 12:44:38 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted. Any chance it's doing something off-site that it's timing out on? That would take a lot of time. -Don- On 9/8/2010 12:26 PM, nan wich wrote: Nope, it's not Update. I can run cron every minute and this happens. And I don't think I even have Update enabled on that site.
Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
________________________________ From: Dhananjay Gandhi <dhananjay.gandhi@gmail.com>
To: development@drupal.org Sent: Wed, September 8, 2010 12:21:34 PM Subject: Re: [development] Cron run exceeded the time limit and was aborted.
hey
cron takes time in cheching updates of ur drupal version and its modules. If u deactivate the update module then it will not take time.
On Wed, Sep 8, 2010 at 9:38 PM, Earnie Boyd <earnie@users.sourceforge.net> wrote:
nan wich wrote:
I have a function that runs a few updates and displays a list of what it did. In order to get caught up from a long period of neglect, I decided to add it into the hook_cron. Every time I invoke cron, I get "Cron run exceeded the time limit and was aborted" yet it completes in far less than 30 seconds. Any ideas how my code could be inadvertantly triggering this?
Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr.
Are you sure it is your code? Try using Elysia Cron to schedule the hook_cron of different modules. The cron API gives 240 seconds for all hook_cron to execute, if all the modules exceed the 240 seconds then you'll see the exceeded time limit message.
-- Earnie -- http://progw.com -- http://www.for-my-kids.com
-- Thanks & Regards, Dhananjay Gandhi
participants (8)
-
António P. P. Almeida -
Dhananjay Gandhi -
Don -
Earnie Boyd -
Jamie Holly -
Khalid Baheyeldin -
nan wich -
Ted