Hello,
I have been working on a small project with Silverstripe recently, when my entire computer suddenly started to freeze. What I figured out was that this happens whenever I would open the home page. I also found out that in an instance about a hundred MySQL queries were launched. At this stage my computer typically became unusable, but I was able to catch the following line from MySQL administrator:
SELECT `SiteTree_Live`.*, `BlogEntry_Live`.*, `BlogHolder_Live`.*, `Forum_Live`.*, `ForumHolder_Live`.*, `ImageGalleryPage_Live`.*, `ErrorPage_Live`.*, `RedirectorPage_Live`.*, `VirtualPage_Live`.*, `SiteTree_Live`.ID, if(`SiteTree_Live`.ClassName,`SiteTree_Live`.ClassName,'SiteTree') AS RecordClassName FROM `SiteTree_Live` LEFT JOIN `BlogEntry_Live` ON `BlogEntry_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `BlogHolder_Live` ON `BlogHolder_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `Forum_Live` ON `Forum_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `ForumHolder_Live` ON `ForumHolder_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `ImageGalleryPage_Live` ON `ImageGalleryPage_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `ErrorPage_Live` ON `ErrorPage_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `RedirectorPage_Live` ON `RedirectorPage_Live`.ID = `SiteTree_Live`.ID LEFT JOIN `VirtualPage_Live` ON `VirtualPage_Live`.ID = `SiteTree_Live`.ID WHERE (`ParentID` = 18 ) AND (`SiteTree_Live`.ClassName IN ('Page','BlogEntry','BlogHolder','Forum','Fo
My Apache access log shows a long list like this, which matches a large number of spawned httpd processes, confirming my suspicions of it being a redirect problem (I only accessed the site once):
127.0.0.1 - - [26/Sep/2009:15:18:22 +0100] "GET / HTTP/1.1" 200 6509
127.0.0.1 - - [26/Sep/2009:15:18:21 +0100] "GET / HTTP/1.1" 200 7196
127.0.0.1 - - [26/Sep/2009:15:18:22 +0100] "GET / HTTP/1.1" 200 6509
127.0.0.1 - - [26/Sep/2009:15:18:23 +0100] "GET / HTTP/1.1" 200 6509
127.0.0.1 - - [26/Sep/2009:15:18:23 +0100] "GET / HTTP/1.1" 200 6509
127.0.0.1 - - [26/Sep/2009:15:18:26 +0100] "GET / HTTP/1.1" 500 8041
127.0.0.1 - - [26/Sep/2009:15:18:26 +0100] "GET / HTTP/1.1" 500 8041
127.0.0.1 - - [26/Sep/2009:15:18:28 +0100] "GET / HTTP/1.1" 500 8041
127.0.0.1 - - [26/Sep/2009:15:18:25 +0100] "GET / HTTP/1.1" 500 8041
127.0.0.1 - - [26/Sep/2009:15:18:26 +0100] "GET / HTTP/1.1" 500 8041
...
I'm a bit afraid to do anything with Silverstripe now, but I will try to access the admin to look up details. I haven't been changing anything in my .htaccess file, but a notable thing I did was changing the page type of the Home page a BlogHolder and renaming its navigation label to "News". (Before I have been unsuccessful with removing the Home page and just having a News page since the Home page always returned from the dead at arbitrary times).
Help would be very much appreciated. Once again, I'll be happy to look up further details that might be helpful here - I can't really do anything else until this is fixed.