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 »
  • Pre-installation Questions (Moderator: Dave Greenberg) »
  • PHP timeout value recommendation?
Pages: [1]

Author Topic: PHP timeout value recommendation?  (Read 2441 times)

AndrewSmith

  • I’m new here
  • *
  • Posts: 24
  • Karma: 0
  • CiviCRM version: 4.2.4
  • CMS version: Joomla 2.5
  • MySQL version: 5.5.27-cll
  • PHP version: 5.3.17
PHP timeout value recommendation?
October 26, 2012, 07:41:48 am
Just wondering if anyone knows if there is a recommendation or not for the timeout value for PHP scripts?  (Additionally, what the timeout value is.)

Andrew

Erik Hommel

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1773
  • Karma: 59
    • EE-atWork
  • CiviCRM version: all sorts
  • CMS version: Drupal
  • MySQL version: Ubuntu's latest LTS version
  • PHP version: Ubuntu's latest LTS version
Re: PHP timeout value recommendation?
October 27, 2012, 10:12:37 am
Does this help? http://php.net/manual/en/function.set-time-limit.php
Consultant/project manager at EEatWork and CiviCooP (http://www.civicoop.org/)

AndrewSmith

  • I’m new here
  • *
  • Posts: 24
  • Karma: 0
  • CiviCRM version: 4.2.4
  • CMS version: Joomla 2.5
  • MySQL version: 5.5.27-cll
  • PHP version: 5.3.17
Re: PHP timeout value recommendation?
October 27, 2012, 12:28:10 pm
That's the PHP function I was referring to.  I thought I had read somewhere that for CiviCRM it's a good idea to set it to 200 seconds in stead of the default 30 seconds.

The higher value would definitively give CiviCRM the headroom it needed to do its processing, even in the more resource intensive operations.

Andrew

Michael McAndrew

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1274
  • Karma: 55
    • Third Sector Design
  • CiviCRM version: various
  • CMS version: Nearly always Drupal
  • MySQL version: 5.5
  • PHP version: 5.3
Re: PHP timeout value recommendation?
October 29, 2012, 02:22:03 am
AFAIK, in most cases, setting it low is a safety valve.

It is like you are saying, if this process (e.g. loading a contact page) takes longer that 30 seconds, we should abort and free up the resources.  Not sure that there is a specific recommendation for Civi, apart from the default, but someone might pipe up and correct me.

There are exceptions to this, such as importing, some intensive reports, but I think these should have their timeouts set at an individual level using that function that Erik mentioned and/or some other clever technique.  I think Tim did something along these lines with upgrade script batching.

Michael
Service providers: Grow your business, build your reputation and support CiviCRM. Become a partner today

AndrewSmith

  • I’m new here
  • *
  • Posts: 24
  • Karma: 0
  • CiviCRM version: 4.2.4
  • CMS version: Joomla 2.5
  • MySQL version: 5.5.27-cll
  • PHP version: 5.3.17
Re: PHP timeout value recommendation?
October 29, 2012, 03:22:31 am
Maybe I shouldn't be worrying too much about timeouts.  Just trying to do an exemplary job of setting up the server, that's all.

Andrew

Michael McAndrew

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1274
  • Karma: 55
    • Third Sector Design
  • CiviCRM version: various
  • CMS version: Nearly always Drupal
  • MySQL version: 5.5
  • PHP version: 5.3
Re: PHP timeout value recommendation?
October 29, 2012, 04:29:13 am
i agree with both those sentiments :)
Service providers: Grow your business, build your reputation and support CiviCRM. Become a partner today

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Pre-installation Questions (Moderator: Dave Greenberg) »
  • PHP timeout value recommendation?

This forum was archived on 2017-11-26.