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 »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • Very slow with Civicrm enabled
Pages: [1]

Author Topic: Very slow with Civicrm enabled  (Read 5719 times)

jimurl

  • I post occasionally
  • **
  • Posts: 70
  • Karma: 0
  • CiviCRM version: 3.4.6
  • CMS version: drupal 6.22
  • MySQL version: 5+
  • PHP version: 5+
Very slow with Civicrm enabled
May 14, 2008, 09:58:53 pm
I just migrated my drupal site from my home server to a hosting service (ixwebhosting), including civicrm. I moved it, in part, because it was slow on my own (crappy old hardware) server. As part of moving it over, I got some errors at first, and it ran very slowly. I did finally get the errors worked out (they had to do with civicrms file upload path ...) I had thought that that was what was causing the slow  performance, but no. Even after getting those resolved, the pages still load very slowly, even slower than on my old crappy server.  Everything (that I have had the patience to check) works; its just running the scripts is very slow.

If I disable the civicrm module, it speeds up to normal, hence I suspect something in there is causing this.

How would I go about troubleshooting this? I don't really have access to anything besides webserver logs. I haven't contacted their support yet. (What does one say :"My website is really draggining your server down... sorry! Hee Hee!" )

Drupal 5.7
Civicrm 1.8 (updated from 1.7 during migration using the script in the sql folder)
MySQL 5.0.45
php 5.2.3

Thanks,

emilyf

  • Ask me questions
  • ****
  • Posts: 696
  • Karma: 54
  • CiviCRM version: 2.x - 4.x
  • CMS version: Drupal 5, 6, 7
Re: Very slow with Civicrm enabled
May 21, 2008, 01:49:33 pm
Hi,

You might have a look at this topic where there is some discussion about shared servers, etc (a bunch about dreamhost, but still potentially applicable to your host, too):
http://forum.civicrm.org/index.php/topic,2331.0.html

jimurl

  • I post occasionally
  • **
  • Posts: 70
  • Karma: 0
  • CiviCRM version: 3.4.6
  • CMS version: drupal 6.22
  • MySQL version: 5+
  • PHP version: 5+
Re: Very slow with Civicrm enabled
May 29, 2008, 04:22:35 pm
Thanks, Emily, that helps.

It actually got me to thinking: a big difference between the old ( slow home server) and IX webhost is that they use a dedicated mysql server.  In other words, the site (and php) is run on one server and mysql and its queries are on another. If there were a lot of communication between the two, perhaps that could slow the site down.

Perhaps someone with more experience or knowledge of this could verify or refute my hypothesis? I would try this, but don't have access to a commercial webhost with mysql on the same machine as the host.

Piotr Szotkowski

  • Moderator
  • I live on this forum
  • *****
  • Posts: 1497
  • Karma: 57
Re: Very slow with Civicrm enabled
May 29, 2008, 11:42:31 pm
Quote from: jimurl on May 29, 2008, 04:22:35 pm
In other words, the site (and php) is run on one server and mysql and its queries are on another. If there were a lot of communication between the two, perhaps that could slow the site down.

Most serious web hostings (and large-scale web applications) have separate web and database servers; network traffic between them is fast, while having a dedicated hardware to exclusive use for these two tasks speeds things up (in general). This should be especially true for shared hosting; the traffic (and processor load) on them is less steady than on single-app/single-website installations.

(Caveat: I’m not really an experienced server administrator, it’s just more a hobby of mine, so you’ll be much better talking to some professional before making any serious decisions.)
If you found the above helpful, please consider helping us in return – you can even steer CiviCRM’s future and help us extend CiviCRM in ways useful to you.

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Very slow with Civicrm enabled
May 30, 2008, 04:15:01 pm
Did you check your Resource URL (Admin CiviCRM >> Global Settings). If you "moved" your database - the new site may be sourcing css, javascript and other files from  your old server which could significantly slow down page loading. You can check this pretty easily by doing a view source and looking at the URLs for the civicrm jscript and css files.
Protect your investment in CiviCRM by  becoming a Member!

jimurl

  • I post occasionally
  • **
  • Posts: 70
  • Karma: 0
  • CiviCRM version: 3.4.6
  • CMS version: drupal 6.22
  • MySQL version: 5+
  • PHP version: 5+
Re: Very slow with Civicrm enabled
June 02, 2008, 02:06:25 pm
I think this might be getting somewhere ....

I did as you recommended- viewed source on a page. The path to the civicrm js and css files appears to be correct (e.g. /sites/all/modules/civicrm/css/civicrm.css ) The js and css files it is looking for really are there. However, when I tried pasting this URL directly into a browser (in order to view the css directly,as the browser would need to do), the connection timed out. It timed out relatively quickly. The file permissions on civicrm are a bit funny- possibly looser than normal (I set them loose during the move to the hosted server, because of some problems with them being set by the ftp at 0 0 0). I also notice that these references are absolute; whereas for other (required) modules they are relative- could this make a difference? Perhaps contact me off list about this.


Another nbote: when I say I moved the site- just from one server to another;   DNS was also moved, so references should remain the same.  I realize that some of the references refer to the server path of directories, rather than an internet URL, but really, I think these are OK.

Dave Greenberg

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 5760
  • Karma: 226
    • My CiviCRM Blog
Re: Very slow with Civicrm enabled
June 02, 2008, 07:17:45 pm
You'll need to figure out what's causing that timeout when pasting the css file URL into your browser. That is almost certainly the crux of the problem. Your webserver logs might have clues.
Protect your investment in CiviCRM by  becoming a Member!

jimurl

  • I post occasionally
  • **
  • Posts: 70
  • Karma: 0
  • CiviCRM version: 3.4.6
  • CMS version: drupal 6.22
  • MySQL version: 5+
  • PHP version: 5+
Re: Very slow with Civicrm enabled
June 02, 2008, 09:39:58 pm
Wow, thank you guys so much. That was exactly it. 

Under Admin Civicrm --> Global settings -- Resource URLs, I was using an absolute path for Civicrm Resource URL, like: 
http://mysite.com/sites/all/modules/civicrm/

AS soon as I changed this to just "/sites/all/modules/civicrm/" the page loads became vastly faster- that was exactly the problem!

One note on the hints available on that page, it says:
    Absolute or relative URL of the location where the civicrm module or component has been installed.
 
    Drupal Example
    If your site's home url is http://www.example.com/ ... then your CiviCRM Resource URL would be:
       http://www.example.com/modules/civicrm/


But in this particular installation, on IXWebhosting, only the relative URL worked. 

Thanks so much for your help; I hope to one day understand enough to assist others in the same way.
« Last Edit: June 03, 2008, 09:46:00 am by jimurl »

vanalive

  • I post occasionally
  • **
  • Posts: 35
  • Karma: 1
Re: Very slow with Civicrm enabled
November 04, 2009, 02:59:34 pm
Just a note, relative links breaks civimail link tracking in 3.0

Piotr Szotkowski

  • Moderator
  • I live on this forum
  • *****
  • Posts: 1497
  • Karma: 57
Re: Very slow with Civicrm enabled
November 12, 2009, 05:06:20 am
Quote from: jimurl on June 02, 2008, 09:39:58 pm
Under Admin Civicrm --> Global settings -- Resource URLs, I was using an absolute path for Civicrm Resource URL, like: 
http://mysite.com/sites/all/modules/civicrm/

AS soon as I changed this to just "/sites/all/modules/civicrm/" the page loads became vastly faster- that was exactly the problem!

This means that the problem lies somewhere outside CiviCRM – my first thing to check would be whether the browser does not make separate, slow-for-some-reason DNS queries with the absolute path; if so, then the DNS server might be misconfigured (the domain name → IP resolution should be cached by your system for as long as the DNS server says – usually it’s 24 hours or so).
If you found the above helpful, please consider helping us in return – you can even steer CiviCRM’s future and help us extend CiviCRM in ways useful to you.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Drupal Installations (Moderator: Piotr Szotkowski) »
  • Very slow with Civicrm enabled

This forum was archived on 2017-11-26.