DotNetNuke Hosting with ASPHostPortal.com

BLOG about DotNetNuke CMS, latest technology and Special DotNetNuke Hosting Package with ASPHostPortal.com

DotNetNuke Hosting - ASPHostPortal.com :: Easy DotNetNuke Performance Improvements

clock Februarie 13, 2015 06:39 by author Ben

I have been seeing a big number of concerns not too long ago with regards to DotNetNuke functionality and items that will be done to help improve the overall performance in the internet site. Usually these questions surround the SiteLog and EventLog tables so I thought I'd post a number of simple queries which you can run to assist hold your database lean that will preserve your DotNetNuke website running at peak efficiency.

Website Log

I'll start off using the Internet site Log table, the website log functionality isn't a single that I truly utilize in my site, nonetheless for all those of you who use it in yours you are going to need to hold an eye on it, I have noticed that right after the log has grown to more than about 4-5 thousand records that you could begin to notice some efficiency decreases. Furthermore if you're like myself and have turned off the internet site log I found out that it will not necessarily clean itself up in case you turned it off, therefore in my case I had 1000 lingering records, which just unnecessarily improved the size of my database.

To check the amount of records within your Site Log use the following query

SELECT Count(*)
FROM SiteLog

To find the oldest record in the site log use the following

SELECT MIN([DateTime])
FROM SiteLog

Soon after you've viewed this details you can establish your necessary course of action. In my case since the internet site log is disabled on all portals I simply deleted all records in the table employing a basic delete statement. Within your case you could only want to purge certain records but that determination is outdoors the scope of this short article.

Event Log

The Occasion log shops portal certain event details like logins, invalid login attempts and actual errors. If you have a pretty active portal this table can grow very big really quickly. For my sites with their visitors of about 100-120 guests per day I have noticed an EventLog of over 2000 records within a two.five month period. Now unless you happen to be auditing logins or undertaking particular tracking you are able to normally rid yourself of those records without much impact. You'll be able to purge these portal by portal via the "Event Viewer" inside DotNetNuke, or it is possible to view and modify records by way of the database. Beneath I'll give you two valuable queries.

To determine the number of records, as well as the quantity of records per portal. Note, inside the benefits in the per portal query, you are going to discover a lot of entries listed having a NULL portal id, that is for DNN installation wide things, like scheduler and application events.

--Overall total
SELECT COUNT(*)
FROM EventLog

--Total by portal (null is not portal specific)
SELECT LogPortalId, COUNT(*)
FROM EventLog
GROUP BY logPortalId

To identify the oldest records you can use one of the following queries, again an overall minimum and a per portal minimum will be found

SELECT MIN(LogCreateDate)
FROM EventLog

SELECT LogPortalId, MIN(LogCreateDate)
FROM EventLog
GROUP BY logPortalId

Once again for deleting these records the decision truly depends upon your portals use on the Occasion Log and any require for user login auditing. In my case I once again don't require this details and at present I've resolved all of my routine errors that had been taking place, for that reason I removed all records in my listing across all sites. I try to complete this at the very least as soon as as month to ensure that the table size has been decreased.

Viewing DB Size

If you would like to view the size of one's database files you are able to make use of the query below to view the size of every single file for the present database.

SELECT *
from SYSFILES

Making use of these ideas you'll be able to start to acquire a better understanding of the database size and you can assist handle it and preserve your DotNetNuke website running at peak efficiency!

Best DotNetNuke Hosting Recommendation

ASPHostPortal.com
ASPHostPortal.com provides its customers with Plesk Panel, one of the most popular and stable control panels for Windows hosting, as free. You could also see the latest .NET framework, a crazy amount of functionality as well as Large disk space, bandwidth, MSSQL databases and more. All those give people the convenience to build up a powerful site in Windows server. ASPHostPortal.com offers DotNetNuke hosting starts from $5/month only. We also guarantees 30 days money back and guarantee 99.9% uptime. If you need a reliable affordable DotNetNuke Hosting, we should be your best choice.




DotNetNuke Hosting with ASPHostPortal :: How To Uninstall DNN Module Programmatically

clock Februarie 11, 2015 17:38 by author Mark

Uninstall DNN Module programmatically

To uninstall the DNN module is actually quite complex via code. There are couple of table modules related and depends on each other. Fortunately, the DNN framework has a built in delete method for these modules. There are 3 tables in the database that are related to the module definitions. They are: DesktopModules, ModuleDefinitions and PortalDesktopModules. The DesktopModules and ModuleDefinitions tables are global tables that are linked to all portals. While PortalDesktopModules table contains a relationship between each portals and what modules can be used by each individual portal.
Lets say you want to remove a list of modules containing a name started with MyModule_.

/* Firstly, you need to include these namespaces on the top of the code */
/* This namespace for Dictionary collection */
using System.Collections;
/* These namespaces for module collection */
using DotNetNuke.Entities.Modules;
using DotNetNuke.Entities.Modules.Definitions;

The next part is to grab a list of module definitions collection and compare if the name contains MyModule_

/* Declare ModuleDefinitionController object */
ModuleDefinitionController objModuleDefinitionController = new ModuleDefinitionController();
/* Declare DesktopModuleController object */
DesktopModuleController objDesktopModuleController = new DesktopModuleController();
/* Get dictionary module collection */
Dictionary<int, ModuleDefinitionInfo>  moduleList = ModuleDefinitionController.GetModuleDefinitions();
/* Perform a looping in the module list */
foreach (int i in moduleList.Keys) {
    /* We only delete the module friendly name contains MyModule_ */
    if (moduleList[i].FriendlyName.IndexOf("MyModule_") >= 0) {
        /* Delete the module from table module definitions */
        objModuleDefinitionController.DeleteModuleDefinition(moduleList[i].ModuleDefID);
        /* Delete the module from table desktop modules */
        objDesktopModuleController.DeleteDesktopModule(moduleList[i].DesktopModuleID);
        /* Delete the module from portal desktop modules */
        DesktopModuleController.RemoveDesktopModuleFromPortal(PortalId, moduleList[i].DesktopModuleID, true);
    }
}

Best Recommended DotNetNuke Hosting

ASPHostPortal.com

ASPHostPortal.com is the leading provider of Windows hosting and affordable DotNetNuke Hosting. DotNetNuke Hosting from ASPHostPortal.com provides a safe, reliable and performance-driven foundation for your DotNetNuke website. DotNetNuke is the perfect Content Management System for managing and developing your website with one of ASPHostPortal’s Hosting plans. ASPHostPortal has ability to support the latest Microsoft and ASP.NET technology, such as: WebMatrix, WebDeploy, Visual Studio 2015, .NET 5/ASP.NET 4.5.2, ASP.NET MVC 6.0/5.2, Silverlight 6 and Visual Studio Lightswitch, ASPHostPortal guarantees the highest quality product, top security, and unshakeable reliability, carefully chose high-quality servers, networking, and infrastructure equipment to ensure the utmost reliability.



DotNetNuke Hosting With ASPHostPortal :: How to Automate the Packaging of your DNN Module

clock Februarie 9, 2015 15:53 by author Mark

Today we will learn How to Automate the Packaging of your DNN Module, let me to show you step by step :

 

  • Delete all source code and start over from scratch with my templates installed.
  • Open your project in Visual Studio
  • Install the MSBuildTasks project from Nuget:

   PM> Install-Package MSBuildTasks

  • Create a BuildScripts folder in your project
  • Add two files (source for each here)
  • ModulePackage.targets
  • MSBuild.Community.Tasks.Targets
  • Right click on the project in Visual Studio Solution Explorer and choose “Unload Project”
  • Save changes if prompted
  • Right click on the unloaded project and choose the Edit option
  • At the bottom of the file, before the </Project> section add

        <PropertyGroup>
          <Extension>zip</Extension>
          <DNNFileName>CHANGEME.dnn</DNNFileName>
          <PackageName>CHANGEME</PackageName>
          <MSBuildCommunityTasksPath>$(SolutionDir)\Build</MSBuildCommunityTasksPath>
        </PropertyGroup>
        <Import Project="BuildScripts\ModulePackage.Targets" />
        <Target Name="AfterBuild" DependsOnTargets="PackageModule">
        </Target>
        <Import Project="$(SolutionDir)\.nuget\nuget.targets" />

  • Change the “CHANGEME” text to match the name of your .DNN file and the name of the ZIP file that you want the package created as.
  • Save the Project changes.
  • Right click on the project in Solution Explorer and choose Reload Project.
  • Switch into Release mode in Visual Studio and do a Build of your project.

This should create two files, ModuleName_Version#_Install.zip and ModuleName_Version#_Source.zip.
What I typically do then is install the module to a test DNN install to make sure that everything is working correctly. You’ll want to make sure that the ZIP files created contain all the right files, and they get installed correctly, so a test installation is the best way to go through that process.
If something fails, try to track it down, then do another Build in Release mode, rinse and repeat the installation process in your test install until you get everything working properly.

Now going forward, after you do a release, you go into your AssemblyInfo file, change your version number there, and into your .DNN File and change your Version number there. Next time you build in Release mode the module will create a new VERSION number ZIP file, leaving your last version builds there as well.

Best Recommended DotNetNuke Hosting

ASPHostPortal.com

ASPHostPortal.com is the leading provider of Windows hosting and affordable DotNetNuke Hosting. DotNetNuke Hosting from ASPHostPortal.com provides a safe, reliable and performance-driven foundation for your DotNetNuke website. DotNetNuke is the perfect Content Management System for managing and developing your website with one of ASPHostPortal’s Hosting plans. ASPHostPortal has ability to support the latest Microsoft and ASP.NET technology, such as: WebMatrix, WebDeploy, Visual Studio 2015, .NET 5/ASP.NET 4.5.2, ASP.NET MVC 6.0/5.2, Silverlight 6 and Visual Studio Lightswitch, ASPHostPortal guarantees the highest quality product, top security, and unshakeable reliability, carefully chose high-quality servers, networking, and infrastructure equipment to ensure the utmost reliability.



About ASPHostPortal.com

We’re a company that works differently to most. Value is what we output and help our customers achieve, not how much money we put in the bank. It’s not because we are altruistic. It’s based on an even simpler principle. "Do good things, and good things will come to you".

Success for us is something that is continually experienced, not something that is reached. For us it is all about the experience – more than the journey. Life is a continual experience. We see the Internet as being an incredible amplifier to the experience of life for all of us. It can help humanity come together to explode in knowledge exploration and discussion. It is continual enlightenment of new ideas, experiences, and passions

Author Link


 photo ahp banner aspnet-01_zps87l92lcl.png

Corporate Address (Location)

ASPHostPortal
170 W 56th Street, Suite 121
New York, NY 10019
United States

Tag cloud

Sign in