Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...High database resource usage issuesHigh database resource usage issues
Previous
 
Next
New Post
2/18/2007 8:41 PM
 
Hi Everyone,

I recently built and launched a Dotnetnuke-based website for a high profile Automobile brand in Australia.

We have launched the site and have been receiving complaints from the hosting company advising of relatively high resource usage on the database.

I am not a DBA, so the message below is not very useful to me. Now I realise I may have to contact a DBA to do the suggested work, but if anyone here can advise me on the best action, it would be greatly appreciated.

Kind Regards,

James Beattie
Snr Web Developer

EMAIL FROM WEB HOSTS:

Hi

The data which is analysed is only captured twice a week as collecting the data on more frequent intervals is reserved for more specific Profiling requests where specific data is collected on a higher frequency to allow further investigation. The reporting we base our investigation on is designed to identify databases above our thresholds and that allows us to investigate further and provide some information to yourself. Then if required further profiling can be performed to further identify possible tuning which can be performed to optimize the database further.

I have looked back over the reported data which we have for your database xxxxx over the last month and I have provided the information from 2 days where the data was captured and your database reported usage above our thresholds.  The following tables outline the top queries captured on the dates listed.


 

10/01/2007 - xxxxxx

Query (example)   Batches
/Min
CPU(ms)
/Run
Duration
(ms)/Run
Reads
/Run
exec sp_reset_connection
 
344
0
5
0
exec dbo.GetHostSettings
 
236
0
80
3
exec dbo.GetTabsByParentId @ParentId=7
 
34
3
3293
68
exec dbo.GetModulePermissionsByModuleID @ModuleID=438,@PermissionID=-1
 
16
1
947
12
exec dbo.GetHtmlText @ModuleId=932
 
4
0
84
7
exec dbo.GetSearchItems @PortalId=NULL,@TabId=NULL,@ModuleId=747
 
3
8
8616
3265
exec dbo.GetTabPermissionsByPortal @PortalID=0
 
2
11
12848
1914
exec dbo.GetPortal @PortalId=0
 
2
2
2775
33
exec dbo.GetTabs @PortalId=0
 
1
415
421683
2039
exec dbo.GetSchedule @Server='WIC022U'
 
1
27
26880
1189
exec dbo.GetScheduleNextTask @Server='WIC022U'
 
1
27
25256
1126
exec dbo.GetSearchModules @PortalID=0
 
1
344
1502938
18335

 

17/01/2007 - xxxxx

 
Query (example)   Batches
/Min
CPU(ms)
/Run
Duration
(ms)/Run
Reads
/Run
 
exec sp_reset_connection
 
54
0
5
0
exec dbo.GetTabsByParentId @ParentId=7
 
15
3
3236
68
exec dbo.GetModulePermissionsByModuleID @ModuleID=375,@PermissionID=-1
 
11
1
1109
12
exec dbo.GetHtmlText @ModuleId=727
 
4
0
88
7
exec dbo.GetSearchItems @PortalId=NULL,@TabId=NULL,@ModuleId=747
 
3
10
9634
3265
exec dbo.GetTabPermissionsByPortal @PortalID=0
 
2
15
14190
2266
 
 
1
1
1467
51
exec dbo.GetTab @TabId=84
 
1
2
2313
13
exec dbo.GetTabs @PortalId=0
 
1
402
402005
2039
exec dbo.GetSearchModules @PortalID=0
 
1
390
420216
18335
exec dbo.GetSchedule @Server='WIC022U'
 
1
23
22680
1040
exec dbo.GetScheduleNextTask @Server='WIC022U'
 
1
20
21855
984

 From this information  you can see that there are 2 main Stored Procedures which are resulting in high amounts of CPU, which I have highlighted in bold. I have noticed that when these Stored Procs are not listed in the report your CPU usage is only listed at a warning level, which would indicate that these stored procs may not be used on a daily basis however they do appear in the reports on the days we have captured the data.

After looking into the queries which are run by the Stored Procs 'dbo.GetTabs' and 'dbo.GetSearchModules' I have found that although there are some indexes configured for the Tables used by those Stored Procs there are also a number of fields which are referenced in clauses such as JOINS, WHERE, ORDER BY, and that is resulting in Table Scans and other expensive steps in the Execution Plan. The following is a few of the tables that I have found which require further indexing and may be used to assist with your own investigation / optimization:

Table: dbo.tabs
current indexes:
IX_Tabs_1 on 'PortalID'
IX_Tabs_2 on 'ParentId'
From what I have found I would suggest also indexing 'TabOrder', 'TabName', 'URL', 'IconFile', 'TabId'

Table: dbo.TabModules
current indexes:
IX_TabModules on 'TabID', 'ModuleID'
From what I have found I would suggest also indexing 'TabModuleId', 'ModuleOrder', 'IconFile' 

Ideally the indexing of your database should be performed by someone who is familar with the application as it requires knowledge of what statements are used across the application to ensure that the indexes being created allow for all of those statements.

Please let us know when you have improved the optimization of your database so that we can monitor the affect it has from our data which we capture. 

If you have any further queries, feel free to respond to this job.

 
New Post
2/18/2007 9:45 PM
 
This is interesting.  What version of DNN are you running?

Best Regards,

Robert J Collins | Co-Founder & President

Netlogic Corporation

 
New Post
2/18/2007 11:06 PM
 

You might want to talk with John Mitchell from http://www.snapsis.com

 John's knowledge on compression (and caching) is outstanding and his PageBlaster module has been well received by many users.

In my opinion, and based on what I've heard from many people, even though the DNN 4.4.1 build is fast, on larger sites you need to consult with experienced people who know how to make the application run faster in a commercial environment. I think you'll find the AFL site will be running DNN in the next 48 hours, and it was running very poorly until they got in touch with John and the peformance changes were very impressive to say the least. I can't share them with you but I am hoping that it will be publicised since it's hard to believe how good the improvements were by using his compression technology.

I'm interested to know what major car manufacturer in Australia would be using DNN.

Nina Meiers
My Site  -  My Blogs  - Goodies - DNNSkins - Nina's Free Skins 

//edited - Omitted the other important part of the equation - caching //


Nina Meiers My Little Website
If it's on DNN, I fix, build, deploy, support,skin, host, design, consult, implement, integrate and done since 2003.
Who am I? Just a city chic, having a crack at organic berry farming.. and creating awesome websites.
 
New Post
2/19/2007 5:23 PM
 
Thanks for the info.

We are currently using build 4.3.5

I am running the Pageblaster plugin already and while it has definitely improved performance, the site is still pretty dog slow.

I am not completely convinced that the hosting company we are using have dedicated enough resources to their .NET environment.

Apart from these performance/speed issues, I am really impressed with the flexibility and user-friendliness of this system as compared to many of the open-source PHP offerings.
 
New Post
3/2/2007 1:06 AM
 

I would like to know the numbers from these queries:

 

 select portalid from dbo.portals order by portalid

select portalid, count(*) from dbo.modules group by portalid order by portalid

select t.portalid, count(*) from dbo.tabmodules as tm
inner join dbo.tabs as t on tm.tabid = t.tabid
group by t.portalid order by t.portalid

select portalid, count(*) from dbo.files group by portalid order by portalid

select t.portalid, count(*) from dbo.tabmodules as tm
inner join dbo.tabs as t on tm.tabid = t.tabid
where upper(tm.iconfile) like 'FILEID=%'
group by t.portalid order by t.portalid

 

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Administration ...Administration ...High database resource usage issuesHigh database resource usage issues


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out