[rt-users] Speeding up RT3
Matthew Watson
matthew.watson at staff.netspace.net.au
Fri Oct 22 21:59:36 EDT 2004
> -----Original Message-----
> From: Jesse Vincent [mailto:jesse at bestpractical.com]
> Sent: Saturday, October 23, 2004 1:00 AM
> To: Matthew Watson
> Cc: rt-users at lists.fsck.com
> Subject: Re: [rt-users] Speeding up RT3
>
>
> On Oct 22, 2004, at 1:01 AM, Matthew Watson wrote:
>
> >
> >>
> >> Looking at this, my best guess is RT is spending most of its time
> >> waiting on the database.
> >>
> >> --
> >
> > As a follow on, how many queries should be run for index.html?
> >
> > I've setup logging of the queries that were being run, I'm find for
a
> > user with 25 queues, for the index.html I'm getting about 250
queries!
>
> Are there duplicate queries? What percentage of them are ACLs? do you
> do per-queue acls or glbal acls? Want to answer the rest of my
> debugging questions from the previous message?
>
>
Sorry yes, I wrote out these answers first, but then forgot to send it
:)
Almost all the queries appear to be on the acl, eg
SELECT * FROM ( SELECT limitquery.*,rownum limitrownum FROM ( SELECT
ACL.id from ACL, Groups, Principals, CachedGroupMembers WHERE
(ACL.RightName = 'SuperUser' OR ACL.RightName = 'ShowTicket') AND
Principals.Disabled = 0 AND CachedGroupMembers.Disabled = 0 AND
Principals.id = Groups.id AND Principals.id =
CachedGroupMembers.GroupId AND CachedGroupMembers.MemberId = '174' AND (
ACL.ObjectType = 'RT::System' OR (ACL.ObjectType = 'RT::Ticket' AND
ACL.ObjectId = '1062173') OR (ACL.ObjectType = 'RT::Queue' AND
ACL.ObjectId = '7')) AND ( ( ACL.PrincipalId = Principals.id AND
ACL.PrincipalType = 'Group' AND (Groups.Domain = 'SystemInternal' OR
Groups.Domain = 'UserDefined' OR Groups.Domain = 'ACLEquivalence' OR
Groups.Domain = 'Personal')) ) ) limitquery WHERE rownum <= 1 ) WHERE
limitrownum >= 1
Something I should mention is I've edited the quicksearch Element to
have 4 columns, "new","Open","stalled" and "all". Which will effect the
query numbers.
Acls are mostly per queue.
>From what I can see though, most of the time is spent doing things other
than waiting on the database,
An example from the index.html page (25 queues, non superuser)
Time to display: 5.843325
Time in Database: 1.678154
Number of Query: 231
> 1) are you exiting standalone httpd by calling a mason page with %exit
> as its only content?
Yep
> 2) what version of RT are you running?
>
> Is it 3.2.2? Can you test out 3.2-HEAD from subversion?
Yeh its 3.2.2,
Where is 3.2-HEAD (not very used to subversion)
-bash-2.05b$ svn co svn://svn.bestpractical.com/rt/branches/3.2-HEAD
svn: URL 'svn://svn.bestpractical.com/rt/branches/3.2-HEAD' doesn't
exist
> 3) what OS are you running?
Linux 2.6.8.1 #20 SMP
> 4) What version of DBIx::SearchBuilder are you running?
1.11
> 5) are you doing any profiling of how long the backend database is
> spending on each page view?
>
> > Total Elapsed Time = 103.1376 Seconds
> > User+System Time = 8.597692 Seconds
>
> That's 8.6 seconds of CPU time over 2 minutes. What pages did you
view?
> how many times?
Front page about 3-4 times,
Few queues, few tickets.
I can come up with some specifics if its more helpful (eg, just load
index.html and then Exit )
Thanks.
Regards
Matt Watson
This email and any files transmitted with it are confidential and intended solely for the
use of the individual or entity to whom they are addressed. Please notify the sender
immediately by email if you have received this email by mistake and delete this email
from your system. Please note that any views or opinions presented in this email are solely
those of the author and do not necessarily represent those of the organisation.
Finally, the recipient should check this email and any attachments for the presence of
viruses. The organisation accepts no liability for any damage caused by any virus
transmitted by this email.
More information about the rt-users
mailing list