
Maart 10, 2015 07:07 by
Ben
In DotNetNuke installing and uninstalling modules is quite considerably automated so normally there is no need to to this manually. But at times this needs to be done manually, by way of example when uninstalling failed because of an SQL error.
Also, DotNetNuke is lacking a mechanism to invoke module methods for cleaning up on uninstall. This means all files and configuration the module produced won't be touch. So I will also highlight under other steps involved in uninstalling a module.

Just before Uninstalling a Module
Either you happen to be uninstalling automatically employing DNN functions or manually, make certain to verify every single item beneath to avoid issues which you would run into later:
- Remove Skin Objects
If the module lets you use it as a Skin Object, undergo all ascx files in DNN skin folders (/Portals/[portal id]/Skins) and take away the @Register directive at the best and all occurrences from the that tag inside that file
- Check web.config references
Some modules/components also do changes to web.config to register their own handlers. One such instance are URL Rewrite elements - they need to register both an URL Provider plus a URL Rewriter. Make an effort to search the element you're uninstalling by its name or parts of its name.
- Check dependencies
Some modules on the market depend on other modules/components that need to currently be installed on that portal. Removing the dependency prior to the module could leave the internet site offline and you'd have to go in on FTP and SQL Server to manually fix the error.
- Verify Files
Even though this may possibly not create problems it's greater which you know what elements leave on disk following uninstall so you are able to determine what to complete with that (delete, backup, and so on). It's typical for modules to write their information within the portal folder (by default Portals/[portal id]/) folder. This can consist of settings, temporary files, documents produces by the module and so on. As an example, Search Boost leaves the Lucene Index at "/Portals/_default/Lucene[ID String]". This has small worth to keep it since it may be recreated at any time by Search Increase. Nevertheless, a gallery module could store its photos and thumbnails and you may possibly wish to preserve that.
- Backup
This ought to be 1st in your list, much better to be certain than sorry. Ahead of undertaking key configuration changes (at least to production atmosphere) ensure to backup the database and files on disk.
Manually Cleaning the Database
All modules deploy with SQL uninstall scripts. They are located in [Website Folder]/DesktopModules/[ModuleName]/Uninstall.SqlDataProvider. Usually the SQL consists of two unique tokens that generally get replaced by DNN:
- {databaseOwner} - you can replace this with empty text, this will work in 99% of the cases
- {objectQualifier} - you were asked for this during DotNetNuke installation wizard. If you don't remember it, look into the database at the table names and see if they all have the same prefix. If they do, that's the objectQualifer. Make sure to copy the underscore as well if it exists (for example the objectQualifier "dnn_" not "dnn")
As soon as you created the replace run the SQL in SQL Management Studio or in Host>SQL (and ensure to verify Run as Script).
Right after this, there could still be some leftovers, but sadly they are not so straightforward to locate particularly once you don't know what to appear for. But typically modules add their very own prefix to all database objects they generate. For instance, all My Tokens tables and stored procedures possess the prefix "avtMyTokens_". After you spot this, it is possible to run an SQL query like below to find out all database objects matching that pattern:
select * from sysobjects where name like '%avtMyTokens%'
Note the xtype column will tell the type of the object (U - user table, P - stored procedure, F - foreign key and so on).
Best DotNetNuke Hosting Recommendation
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.