Error: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level.

 
 
 
Error: It is an Error to Use a Section Registered as Allowdefinition='machinetoapplication' Beyond Application Level.

Issue

When you browse to a URL on your site, you get a message similar to the following:
Server Error in '/' Application.
Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level.  This error can be caused by a virtual directory not being configured as an application in IIS.
 
Source File: C:\Inetpub\vhosts\test.org\httpdocs\subdirectoryname\web.config    Line: 61


Causes
  • There is an extra web.config in the child directory.
  • You are trying to run DotNetNuke from a subdirectory that is not set up as an application in IIS.
Resolutions
Remove the Extra Web.config
  1. Follow How to access your web.config, to get to your file structure.
  2. This is the location of the main web.config so when you get to click on HTTPDocs your next step is click the child portal folder name.
  3. The file we need looks like this C:\Inetpub\vhosts\test.org\httpdocs\child_portals_name\web.config 
  4. Rename the secondary web.config file to Old_Web.config or web.config.not_used or something similar. 
  5. You may alternately delete the web.config in the child_portals_name folder NOT the root directory.

Set Up DotNetNuke's Subdirectory in IIS
 
Plesk 12
  1. Log into your Control Panel.
  2. Click on the System tab.
  3. In the Subscriptions section select your domain.
  4. Select the Websites & Domains tab.
  5. Expand the Show More link then click Virtual Directories.
  6. Click the Create Virtual Directory folder.
  7. Name the new directory the same as the existing directory you are attempting to run DotNetNuke from.
  8. Uncheck Create physical directory with the same name as the virtual directory.
  9. Click the folder and browse to the existing folder you want to set up as an application.
  10. Click OK, and then OK again on the main page to create the application.
  11. Test to verify it is working.
Plesk 11
  1. Log into your Control Panel.
  2. Click on the System tab.
  3. In the Subscriptions section select your domain.
  4. Select the Websites & Domains tab.
  5. Expand the Hide Advanced Options link then click Virtual Directories.
  6. Click the Create Virtual Directory folder.
  7. Name the new directory the same as the existing directory you are attempting to run DotNetNuke from.
  8. Uncheck Create physical directory with the same name as the virtual directory.
  9. Click the folder and browse to the existing folder you want to set up as an application.
  10. Click OK, and then OK again on the main page to create the application.
  11. Test to verify it is working.
 Plesk 9
  1. Log into your Control Panel.
  2. Select your domain.
  3. Under the Hosting section click on Web Directories.
  4. Click Add new Virtual Directory 
  5. Name the new directory the same as the existing directory you are attempting to run DotNetNuke from.
  6. Uncheck Create physical directory with the same name as the virtual directory.
  7. Click the folder and browse to the existing folder you want to set up as an application.
  8. Click OK, and then OK again on the main page to create the application.
  9. Test to verify it is working.
 

Add Feedback