Closed (fixed)
Project:
Advanced User
Version:
6.x-2.3
Component:
Miscellaneous
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
26 May 2010 at 08:13 UTC
Updated:
25 Aug 2010 at 11:10 UTC
Jump to comment: Most recent
Comments
Comment #1
Anonymous (not verified) commentedDo you have a copy of production in a dev/test environment? I would like you to try the 6.x-3.x-dev version. Also, you'll need to install the devel module and enable the options to see the slow queries. It may come down to needing an index.
Comment #2
dontgotanick commentedHi,
i changed now to the dev version and installed the devel module and logged.
Path Memory (MB) ms (Total) Anonymous? # Queries Query ms
1 13.75 454 No 65 14
admin/reports 19.25 669 No 62 11
1 13.75 455 No 65 17
admin/settings/performance_logging 23.00 1589 No 87 29
admin/settings/performance_logging 12.50 710 No 26 10
The site endet up in an error page.
How can i create an index
regards dave
Comment #3
Anonymous (not verified) commentedHow did you copy your production? You may need to empty the cache via admin/settings/performance and you may need to empty the sessions table using a sql truncate query. Make sure you have the slow queries enabled on the devel module and you have the blocks enabled to show them.
Comment #4
dontgotanick commentedHi i cleaered the cache and everything.
for some reason its not logging the queries
and when i load the advanced page it takes ages an then just shows up a blank page ....
Comment #5
Anonymous (not verified) commentedWSOD is usually a sign of over running the memory limit.
Check the httpd log files and the php log files.
Check the watchdog table admin/reports/dblog or with phpmyadmin.
Comment #6
dontgotanick commentedOk
the problem is that i cant look in the 2 log files cause the provider does not seperate them by customer and logs everything of all users.
I asked them now to allocate more memory and how to create an index.
And how stable is the dev oder alpha 1 module cause i need the possibility to search for people without roles and active accounts.
regards dave
Comment #7
dontgotanick commentedHi got now the instruction how to increase the memory and the side loads now but it takes ages?
How can I create an Index can u tell me that?
regards
Comment #8
Anonymous (not verified) commentedOnce you have determined which query is giving you the slow response please post it here so I can help determine which column. The column will be one of the ones in the WHERE clause or perhaps an ORDER BY clause. To create an index adhoc is easiest with phpMyAdmin assuming you're using MySql for your database.
Comment #13
dontgotanick commentedHi they are telling me that there is nothing in that logs and its not slow with them?
thanks for your patience btw :)
I really dont know how i could contribute more information to you?
regards
Comment #14
Anonymous (not verified) commentedDitto. Without more information I can't help you. There must be a slow query somewhere. Maybe try the 3.0-alpha1 version? You'll like the filter interface better anyway.
Comment #15
dontgotanick commentedHi,
finally they told me what is the slow query.
| Id | User | Host | db | Command | Time | State | Info |
| 7991024 | confi14_admin | localhost | confi14_drupalvm | Query | 139 | Sending data | /* drupal_admin : pager_query */ SELECT COUNT(DISTINCT u.uid) FROM drupal_users u LEFT JOIN drupal_u |
regards
Comment #16
Anonymous (not verified) commentedI've been away on vacation and just getting back to you on this. The query you post isn't a full query. There is more beyond the LEFT JOIN than just drupal_u.
Comment #17
dontgotanick commentedHi they sended me now the query.
SELECT COUNT(DISTINCT u.uid) FROM drupal_users u LEFT JOIN drupal_users_roles ur ON u.uid = ur.uid
regards
Comment #18
Anonymous (not verified) commentedThat query has nothing to do with the Profile module, it doesn't touch the profile tables. Besides the uid column is the PRIMARY KEY for both the DRUPAL_USERS table and the DRUPAL_USERS_ROLES table. There is nothing you can do to speed that query.
Comment #19
dontgotanick commentedWeired cause its only slow when i activate profile fields ? Any idea why?
Comment #20
Anonymous (not verified) commentedNot without the query that is causing the problem. It will be a query with a table that has PROFILE in its name. My guess is that the query is causing a full table scan of one or multiple tables for each user being displayed on the page.
Comment #21
dontgotanick commentedHi thanks for your patience but they are not able to give me the proper query so we wont get whats causing that.
But thx anyway :)
Comment #22
jghyde commentedJoe Here, co-maintainer.
Simple test for this: Disable the advuser module and see if the slowness continues. Otherwise, without any further input, I suggest this topic be closed.
Re-open if there is more info to diagnose.
Joe Hyde
Earnie's Brand New Co-Maintainer
Comment #23
Anonymous (not verified) commentedWell, slow down a bit. This is still unresolved.
Comment #24
dontgotanick commentedHi, I'm back sorry for the time it took. But now I know the queries. which cause the problem.
If i run the query directly in phpmyadmin the first takes approximatly 4 minutes and the second 3. But if i start the advacned user module in drupal i get a White Screen of Death.
query1:
SELECT COUNT(DISTINCT u.uid) FROM drupal_users u LEFT JOIN drupal_users_roles ur ON u.uid = ur.uid LEFT JOIN drupal_profile_values profile_company ON profile_company.fid = 11 AND profile_company.uid = u.uid LEFT JOIN drupal_profile_values profile_vorname ON profile_vorname.fid = 1 AND profile_vorname.uid = u.uid LEFT JOIN drupal_profile_values profile_nachname ON profile_nachname.fid = 2 AND profile_nachname.uid = u.uid;
the result of this query is 3224 or sth like that
query2:
SELECT DISTINCT u.uid, u.name, u.mail, u.status, u.created, u.access FROM drupal_users u LEFT JOIN drupal_users_roles ur ON u.uid = ur.uid LEFT JOIN drupal_profile_values profile_company ON profile_company.fid = 11 AND profile_company.uid = u.uid LEFT JOIN drupal_profile_values profile_vorname ON profile_vorname.fid = 1 AND profile_vorname.uid = u.uid LEFT JOIN drupal_profile_values profile_nachname ON profile_nachname.fid = 2 AND profile_nachname.uid = u.uid ORDER BY u.created DESC LIMIT 0, 50;
i hope this information helps
regards dave
Comment #25
Anonymous (not verified) commentedThe count query is so that the pager knows how many pages that may be displayed. The second query gets the details for the page. Make sure your drupal_profile_values table has an index on columns fid and uid. Make sure your drupal_users and drupal_users_roles tables have an index on column uid. You may need to tune your SQL server for better performance; there are people on the support list that maybe able to help.
For help with your WSOD (white screen of death) go to drupal.org and enter wsod in the search criteria.
I don't have any further help for you. If someone has a better query then open a new issue as a bug report with a patch for review.
Comment #26
dontgotanick commentedindex erstellen:
CREATE INDEX IDX_profile_fields ON drupal_profile_fields (fid)
CREATE INDEX IDX_profile_values ON drupal_profile_values (uid,fid)
CREATE INDEX IDX_users ON drupal_users(uid)
CREATE INDEX IDX_users_roles ON drupal_users_roles(uid)
thanks for all of your help this totaly fixed the problem
regards dave