Answers.Body: <p>You are experiencing <a href="https://issues.civicrm.org/jira/browse/CRM-16035" rel="nofollow noreferrer">CRM-16035 - Dashlet refresh can crash server</a>.</p>
  
  <p>The default dashboard config is pretty close to maxing out the default Debian config for either Apache or PHP-FPM.</p>
  
  <p>Depending on your server setup (question says just Apache which typically suggests via mod_php) you probably need to <a href="https://stackoverflow.com/questions/3389496/how-do-you-increase-the-max-number-of-concurrent-connections-in-apache">increase either the number of  connections Apache permits</a>. </p>
  
  <p>You could also remove some dashboard widgets for the affected contact - if the dashboard is currently inaccessible so not editable for you, you could do this by directly editing entries in <code>civicrm_dashboard_contact</code> in the DB.</p>
  
  <p>If you are using Apache + php-fpm or fcgi, you might need to increase the max_children setting in your php-fpm config instead. For non-Apache users, other StackExchange will explain how to increase server limits for your php/webserver configuration.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-18T16:31:31.407Z
Answers.Text: Thanx, Xavier and Chris. I'll do this and let you know but why did this happen all of a sudden on all instances when nothing had changed? I did try to no avail disabling all the dashlets in table civicrm_dashboard. When I am able to get access to the dashlet config page after apache restart only the default Activities dashlet is listed but not active on the dashboard. Still then i get the same issue.
Answers.UserDisplayName: BruceW
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-18T22:16:35.283Z
Answers.Text: It's hard to say without insight into your situation; perhaps the server is busier, or perhaps you have some recursion in the dashboard configuration. Observing your webserver logs while triggering the issue may help you to understand why your site is particularly affected.
Answers.UserDisplayName: Chris Burgess
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-18T09:47:14.937Z
Answers.LastActivityDate: 2015-06-18T22:18:04.133Z
Answers.LastEditDate: 2017-05-23T12:38:59.763Z
Answers.UserDisplayName: Chris Burgess
Answers.Body: <p>How many dashlets do you have?</p>
  
  <p>The way they are implemented unfortunately triggers 2 http requests (one to get the dashlet, the other behind to generate the content of that dashlet if it's not cached)</p>
  
  <p>So if you have "many", you might end up with more queries that what your server can handle in parallel and slow things, or trigger some protection against denials of services or...</p>
  
  <p>Try increasing the number of php processes that run and see if it fixes things. if it does, you can then remove some dashlets?</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-18T17:35:22.430Z
Answers.Text: I've done the DB part and it did clear up the issue on one site but not the other. Next is max_connections.
Answers.UserDisplayName: BruceW
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-06-18T06:38:43.950Z
Answers.LastActivityDate: 2015-06-18T06:38:43.950Z
Answers.UserDisplayName: Xavier
Body: <p>This is in planning for upgrade to J!3. I have found no workable solutions here or elsewhere on the web.<br></p>
  
  <p>CiviCRM 4.6.4<br>
  Joomla 2.5.28<br>
  MySQL 5.5.38-1~dotdeb.0<br>
  Apache 2.2.16<br>
  PHP 5.3.29-1~dotdeb.0<br>
  Debian Squeeze 6<br>
  Linux 2.6.32-5-amd64<br></p>
  
  <p>On all virtual hosts before I updated CiviCRM (4.4.x and 3.5.x) the Dashboard shows up but the Ajax "Loading..." widget just keeps spinning and freezes the whole GUI. If I click on another CiviCRM link and restart Apache, it will go to that page and I can navigate around but going back to the Dashboard locks it up again. I then updated both instances to 4.6.4 to the same result. I've disabled all other third party extensions to no avail.</p>
  
  <p>I get no unusual errors in Firebug. Under Net, just a bunch of GET 304 reports for a lot of CiviCRM jQuery and other Javascript libraries.</p>
  
  <p>Turning on Debugging with backtrace produces no output. Clean page. </p>
  
  <p>Any help would be greatly appreciated. Thanks in advance.</p>
  
Tags: <ajax><dashboard><4.6.4><javascript><dashlet>
Title: Dashboard hangs; forces apache restart
ThreadText: # Dashboard hangs; forces apache restart
  
  (Asked by: username_0 on 2015-06-18)
  
  This is in planning for upgrade to J!3. I have found no workable solutions here or elsewhere on the web.
  
  CiviCRM 4.6.4  
  Joomla 2.5.28  
  MySQL 5.5.38-1~dotdeb.0  
  Apache 2.2.16  
  PHP 5.3.29-1~dotdeb.0  
  Debian Squeeze 6  
  Linux 2.6.32-5-amd64
  
  On all virtual hosts before I updated CiviCRM (4.4.x and 3.5.x) the Dashboard shows up but the Ajax "Loading..." widget just keeps spinning and freezes the whole GUI. If I click on another CiviCRM link and restart Apache, it will go to that page and I can navigate around but going back to the Dashboard locks it up again. I then updated both instances to 4.6.4 to the same result. I've disabled all other third party extensions to no avail.
  
  I get no unusual errors in Firebug. Under Net, just a bunch of GET 304 reports for a lot of CiviCRM jQuery and other Javascript libraries.
  
  Turning on Debugging with backtrace produces no output. Clean page.
  
  Any help would be greatly appreciated. Thanks in advance.
  
  **Tags:** ajax, dashboard, 4.6.4, javascript, dashlet
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_1 on 2015-06-18. Score: 2
  
  You are experiencing [CRM-16035 - Dashlet refresh can crash server](https://issues.civicrm.org/jira/browse/CRM-16035).
  
  The default dashboard config is pretty close to maxing out the default Debian config for either Apache or PHP-FPM.
  
  Depending on your server setup (question says just Apache which typically suggests via mod\_php) you probably need to [increase either the number of connections Apache permits](https://stackoverflow.com/questions/3389496/how-do-you-increase-the-max-number-of-concurrent-connections-in-apache).
  
  You could also remove some dashboard widgets for the affected contact - if the dashboard is currently inaccessible so not editable for you, you could do this by directly editing entries in `civicrm_dashboard_contact` in the DB.
  
  If you are using Apache + php-fpm or fcgi, you might need to increase the max\_children setting in your php-fpm config instead. For non-Apache users, other StackExchange will explain how to increase server limits for your php/webserver configuration.
  
  > **Comments:**
  > **username_0**: Thanx, username_2 and Chris. I'll do this and let you know but why did this happen all of a sudden on all instances when nothing had changed? I did try to no avail disabling all the dashlets in table civicrm_dashboard. When I am able to get access to the dashlet config page after apache restart only the default Activities dashlet is listed but not active on the dashboard. Still then i get the same issue.  
  > **username_1**: It's hard to say without insight into your situation; perhaps the server is busier, or perhaps you have some recursion in the dashboard configuration. Observing your webserver logs while triggering the issue may help you to understand why your site is particularly affected.  
  
  ---
  
  ### Answer by username_2 on 2015-06-18. Score: 1
  
  How many dashlets do you have?
  
  The way they are implemented unfortunately triggers 2 http requests (one to get the dashlet, the other behind to generate the content of that dashlet if it's not cached)
  
  So if you have "many", you might end up with more queries that what your server can handle in parallel and slow things, or trigger some protection against denials of services or...
  
  Try increasing the number of php processes that run and see if it fixes things. if it does, you can then remove some dashlets?
  
  > **Comments:**
  > **username_0**: I've done the DB part and it did clear up the issue on one site but not the other. Next is max_connections.  
  
  ---
  
  