IIS 7.5 and IIS 8.0 European Hosting

BLOG about IIS 7.5 Hosting, IIS 8.0 Hosting and Its Technology - Dedicated to European Windows Hosting Customer

European IIS 8.5 Hosting – HostForLIFE.eu :: Fix HTTP Error 500.19 – Internal Server Error

clock March 24, 2020 06:46 by author Peter

If you are reading this post you may face Http Error 500.19 error in your IIS 8.5. And in this article I’ll going to show you what I am doing to resolve this problem. I had simple webapi built by Visual Studio 2013, it work good when I run it from Visual Studio 13 but when I copy the project in IIS it give me this error.

Error Message

HTTP Error 500.19 - Internal Server Error The requested page cannot be accessed because the related configuration data for the page is invalid.

Detailed Error Information:

Module IIS Web Core
Notification BeginRequest
Handler Not yet determined
Error Code 0x80070021
Config Error This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"), or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false".
Config File \?\C:\inetpub\wwwroot\APITeslin\web.config

Config Source:

<system.webServer> 
  <handlers> 
    <remove name="ExtensionlessUrlHandler-Integrated-4.0" />

How to Solve HTTP Error 500.19 In IIS 8.5

  1. Got to Server manager
  2. Click Add roles and Features
  3. In the roles section choose web server
    1. Under security sub-section choose everything (I excluded digest,  IP restrictions and URL authorization as we don't use them)
    2. Under Application Development choose .NET Extensibility 4.5, ASP>NET 4.5, both ISAPI entries
  4. In the features section choose: NET 3.5, .NET 4.5, ASP.NET 4.5
  5. In the web server section choose: Web Server (all), Management Tools (IIS Management Console and Management Service), Windows Authentication - if you are using any of it.

Those is step by step how to solve HTTP Error 500.19 - Internal Server Error IIS.



European IIS 8 Hosting - HostForLIFE.eu :: Dynamic Compression Issue in IIS 8.5

clock December 6, 2019 11:49 by author Peter

Windows Server 2012 R2 comes with IIS 8.5, and in this release an issue has been found in relation to the Dynamic Compression module.  The module sets the “Vary” header which is used to specify caching properties that the browser uses to determine whether the response should be cached or not. 

In IIS 8.0 and earlier, the Dynamic Compression module was overwriting the Vary header with the value “Accept-Encoding”, and as it happens this is the correct value to ensure that dynamic content is correctly cached – but – according to IIS it should be appending this value to the existing value and not overwriting it.

As it happens, this was supposed to be fixed in IIS 8.5 but the fix appears to be broken.  In IIS 8.5 (which ships with Windows Server 2012 R2) the Vary header is being set to “*” and the “Accept-Encoding” from the Dynamic Compression module is not appended.  The result of this is that no dynamic content is being cached by the browser.

Workaround

Thankfully there is an easy workaround in IIS 8.5 for this:

1. Select an IIS site, and go to Configuration Editor

2. Select system.web/caching/outputCache section, then set the omitVaryStar property to true

Setting this value results in the Vary header being returned with a value of “Accept-Encoding” and the browser then caches the dynamic content.



European IIS Hosting - HostForLIFE.eu :: How to Create Multiple 301 Redirects

clock December 15, 2016 08:33 by author Scott

Some of our clients sometimes ask about how to create URL Rewrite on their site. Previously, we have written about how to redirect HTTP to HTTPS in IIS. In this tutorial, we will advise how to create multiple redirection with a URL Rewrite Map.

URL Rewrite Module with IIS 7/IIS 8

Now there’s an easier solution, and one that offers better performance.  Starting with IIS 7 one can implement different kinds of url rewriting and redirecting with ease by using the URL Rewrite Module. The various rules can be configured using the IIS 7 Manager GUI or by directly editing the web.config. To open the URL Rewrite Module simply double click the URL Rewrite icon on your site properties as shown below.

From there you will be able to maintain your existing rules or add new ones as seen in this picture.

This is a pretty easy way to create server-side rules for rewriting and redirecting, but what happens when you have 30 or 40 legacy URLs that need to be redirected to new pages? Do you have to enter each one manually? Of course not. The solution to that is to use a URL Rewrite Map.

URL Rewrite Map

By using a URL Rewrite Map it has never been easier to create and maintain multiple 301 redirects for different pages on your web site.  The rewrite rules are stored in the <system.webServer> section of your web.config so you can quickly make changes as needed.

Here is all the code you need to accomplish this:

<system.webServer>
<rewrite>
<rewriteMaps>
<rewriteMap name=”Redirects”>
<add key=”/test.aspx” value=”/test2.aspx” />
<add key=”/aboutus.aspx” value=”/about” />
</rewriteMap>
</rewriteMaps>
<rules>
<rule name=”Redirect rule1 for Redirects”>
<match url=”.*” />
<conditions>
<add input=”{Redirects:{REQUEST_URI}}” pattern=”(.+)” />
</conditions>
<action type=”Redirect” url=”{C:1}” appendQueryString=”false” />
</rule>
</rules>
</rewrite>
</system.webServer>

In the example above I’m performing a 301 redirect on the test.aspx file to test2.aspx file. There’s also a 301 redirect for the aboutus.aspx file to folder called /about, however, in this case it’s important to note that the /about folder will also need a default page or else a 404 error will result.

As you add more URLs to your Rewrite Map you’ll notice that your web.config can become a bit cluttered. The solution to this will be to store the redirect rules in an external file. Let’s call this file myrewritemaps.config. This file will now contain this code block:

<rewriteMaps>
<rewriteMap name=”Redirects”>
<add key=”/test.aspx” value=”/test2.aspx” />
<add key=”/aboutus.aspx” value=”/about” />
</rewriteMap>
</rewriteMaps>

In your web.config you add the following line of code under the <rewrite> section referencing the external config file:

<rewriteMaps configSource=”myrewritemaps.config” />

Your web.config will now look nice and clean like this:

<system.webServer>
<rewrite>
<rewriteMaps configSource=”myrewritemaps.config” />
<rules>
<rule name=”Redirect rule1 for Redirects”>
<match url=”.*” />
<conditions>
<add input=”{Redirects:{REQUEST_URI}}” pattern=”(.+)” />
</conditions>
<action type=”Redirect” url=”{C:1}” appendQueryString=”false” />
</rule>
</rules>
</rewrite>
</system.webServer>

There is no real limit on how many URLs can be configured for redirecting with the URL Rewrite Map.  You should perform regular search engine analysis to see when the new URLs have been picked up. Once the old URL is no longer indexed and traffic has dropped off you could remove it from your map.



IIS 8 Hosting - HostForLIFE.eu :: How to Install SSL Certificate in IIS 8?

clock April 6, 2016 18:31 by author Anthony

In this tutorial, I will show you how to install SSL certificate in IIS 8.0. To communicate securely over the web requires the use of encryption on the messages passed back and forth.  Encryption on the web is accomplised through the use of Transport Layer Security (TLS). Http traffic layered over SSL/TLS is called Https.  It would be all too easy to venture down the rabbit hole and explain in great detail how TLS establishes a secure connection, but the crypto minutia is likely a bit out of scope for the purposes of this discussion.  However, a basic understanding of the mechanisms used by TLS to secure the communication channel will make understanding the use of SSL certificates much easier.

TLS uses public key cryptography, which requires the distribution of a public key.  This public key is transmitted as part of an SSL certificate, along with other identifying information meant to establish trust that a server is who it is supposed to be (and not a malicious eavesdroper).  While it is possible to create self-signed certificates, browsers do not trust these certificates and will give users dire warning when they are encountered (this would be like me printing my own drivers license and saying "See, I am who I say I am... really!").  For a certificate to be trusted, it must be issued by a trusted Certificate Authority (CA).  When a secure connection is made using a trusted certificate, most browsers will display an indicator that the connection is secure.  In Chrome, clicking the green lock icon will reveal information regarding the details of the connection:

And this is what a self-signed certificate will get you:

So to fully take advantage of Https you need to have a certificate from a trusted CA (Symantec [GeoTrust, VeriSign], Comodo, GlobalSign, etc).  Getting a certificate involves first creating a Certificate Signing Request (CSR).  IIS has the capability of creating a CSR, and their are other tools available, including the linux command line using OpenSSL.  This is what it looks like in IIS:

You'll transmit the CSR in one form or another to the CA you are getting your certificate from, and after they've performed whatever level of due diligence they'll send you your SSL certificate.  Once you have the certificate, you'll need to install it on the server hosting your site.  For .NET based web applications, that likely means IIS or Azure.

  • Installing SSL Certificate in IIS 8.0

In IIS Manager, under Server Certificates, there is an option for "Complete Certificate Request".  Here you'll browse to the *.cer file that contains your certificate, add a friendly name to make management easier it doesn't change anything in the certificate and add the certificate to the Personal certificate store.  This installs the certificate to the server.  To use it in your site, you have to bind it.  Navigate to the site settings in IIS, go to bindings, and add a binding for https using port 443 and the created certificate.

  • Using Https in the application

Using the URL Rewrite rule described in the Azure SSL instruction involved adding this rule to the web.config file:

<system.webServer>
  <rewrite>
    <rules>
      <rule name="Force HTTPS" enabled="false">
        <match url="(.*)" ignoreCase="false"/>
      <conditions>
        <add input="{HTTPS}" pattern="off"/>
      </conditions>
        <action type="Redirect" url="https://{HTTP_HOST}/{R:1}"
                appendQueryString="true" redirectType="Permanent"/>
      </rule>
    </rules>
  </rewrite>
  </system.webServer>

In MVC, using the [RequireHttps] attribute gives fine grained control over what portions of the site will need to use https:

[RequireHttps]
public ActionResult About()
{
    ViewBag.Message = "Your application description page.";
 
    return View();
}

HostForLIFE.eu IIS 8 Hosting

HostForLIFE.eu revolutionized hosting with Plesk Control Panel, a Web-based interface that provides customers with 24x7 access to their server and site configuration tools. Plesk completes requests in seconds. It is included free with each hosting account. Renowned for its comprehensive functionality - beyond other hosting control panels - and ease of use, Plesk Control Panel is available only to HostForLIFE's customers. They offer a highly redundant, carrier-class architecture, designed around the needs of shared hosting customers.



IIS 8.5 Hosting - HostForLIFE.eu :: How to Install Web Server in Windows 8?

clock April 1, 2016 20:42 by author Anthony

Today I will discuss about how to install IIS on Windows 8. IIS or Internet Information Services or Internet Information Server is an HTTP web server that is used in Windows server operating system, from Windows NT 4.0 Server, Windows 2000 Server or Windows Server 2003. This service is an integrated service in Windows 2000 Server, Windows Server 2003 or as an add-on in Windows NT 4.0. This service serves as a support TCP / IP protocol that runs in the application layer (application layer). IIS also be the foundation of the Internet and Intranet Microsoft platform, which includes Microsoft Site Server, Microsoft Commercial Internet System and Microsoft BackOffice products more. Web Server can be run on Windows 8 and Windows Server 2012 and earlier versions of Windows.

The relationship between the Web Server and Internet Browser is a combination or existing computer networks around the world. Once physically connected, Protocol TCP / IP (networking protocol) that allows all computers can communicate with each other reply. By the time the browser requests a web page of data to the server the instruction data requests by the browser in containers in which a TCP transport protocol and sent to the reply address in this case is the next protocol is Hyper Text Transfer Protocol (HTTP). HTTP is the protocol in use on the World Wide Web (WWW) between computers that are connected in the network in the world. To recognize this protocol clearly is very easy once where every time you type http: // ... you have to use it, and bring you into the world of internet. Data that in passing from the browser to the Web server called the HTTP request which asks the web page and then the web server for data existing HTML and packed in TCP protocol and sent back to the browser. Data sent from the server to the browser called the HTTP response. If the data requested by a browser that can not be found by the Web server will meninbulkan error that often you see on the web page that is Error: 404 Page Not Found. It gives a taste of a process that is tridimensional, meaning that Internet users can read from one document to another simply by clicking a few sections of pages of documents (web) it. The process that starts from the demand webclient (browser), web server is received, processed, and process the results returned by a web server to a web client again carried out in a transparent manner. Each person can easily find out what happened to each process. In broad outline only web server to process all the input it received from its clients web.

How to Install Web Server (IIS) in Windows 8?

  • Press the Windows key + W (Windows key and the letter w on a keyboard), then type features, and then click Turn Windows features on or off.

Step By Step Install Web Server (IIS) di Windows 8 1

  • Then click on the Internet Information Service (see picture below), and then click OK.
  • Step By Step Install Web Server (IIS) di Windows 8 2

    After the installation process Internet Information Services will run, wait for it to finish.

  • After the installation of Internet Information Service is complete, press the Windows key and then type IIS in the search box, and then click Internet Information Services (IIS) Manager, as shown below.
  • Step By Step Install Web Server (IIS) di Windows 8 3

  • In Internet Information Services (IIS) Manager, click the arrow on the name of your computer> sites> then click Default Web Site, as shown below (4a). Then click the Basic Settings in the action pane to the right (4b).
  • Step By Step Install Web Server (IIS) di Windows 8 4

  • Here we will try to override the default physical path where the data of our website later. In this example I will create a folder called "mywebsite" on drive C :, then his path to C:\mywebsite, as in the image below. I click the "..." as in the picture, and navigate his path to the C:\mywebsite, and then click OK.
  • Step By Step Install Web Server (IIS) di Windows 8 5

    To perform the test helloworld create a file called index.htm in the folder C:\mywebsite. Then type localhost in your browser.

    hello word


HostForLIFE.eu IIS 8.5 Hosting
HostForLIFE.eu revolutionized hosting with Plesk Control Panel, a Web-based interface that provides customers with 24x7 access to their server and site configuration tools. Plesk completes requests in seconds. It is included free with each hosting account. Renowned for its comprehensive functionality - beyond other hosting control panels - and ease of use, Plesk Control Panel is available only to HostForLIFE's customers. They offer a highly redundant, carrier-class architecture, designed around the needs of shared hosting customers.



IIS 8.5 Hosting - HostForLIFE.eu :: How to Fix: “HTTP Error 401.3 – Unauthorized” Error in IIS ?

clock October 8, 2014 08:05 by author Peter

Today, I am going to show you how to fix How to Fix: “HTTP Error 401.3 – Unauthorized” Error in IIS. While working on my site, I got a small issue with IIS. I had set up a new virtual directory for the site but when the site was viewed in the browser the IIS error was displayed:
Server Error in Application “DEFAULT WEB SITE”
HTTP Error 401.3 – Unauthorized
You do not have permission to view this directory or page because of the access control list (ACL) configuration or encryption settings for this resource on the Web server.

As you can see on the picture below:

Judging from the error the permissions on the folder was incorrect. And a quick peek at the properties confirmed this. Admittedly, I don’t have much experience with  IIS 7+ (IIS 6 & 6.5 that’s a different story). So when I tried to add the correct user account to the I couldn’t identify the correct user account. Honestly, I was actually looking for IUSR_MachineName . As it turns out IUSR_MachineName was removed in IIS 7 and replaced with IUSR. So adding the IUSR user account to the folder and everything worked. Yes, it was a simple fix but it can be an annoying one if you don’t know what to look for.



European IIS 8.5 Hosting – HostForLIFE.eu :: How to Configure Dynamic Website Activation in IIS 8.5

clock August 15, 2014 07:43 by author Onit

In this article we will showed you how to configure Dynamic Website Activation.

One of the best feature in the latest IIS 8.5 is the “Dynamic Website Activation”. What so cool about this feature? When the IIS servicing large number of configured sites (100 or greater, by default) this feature let the IIS Service not activate any of the sites when the service started.

 

What is The Function?

When IIS servicing a large number of configure sites (default: 100 or greater), IIS will not activate any of the sites (all of them at once).

Why Using This Feature?

This Feature only available in the latest IIS 8.5 before this version IIS will automatically activates all configures websites at once. This will bring some trouble in the resources, and memory if it’s service the large number of sites.

How This Feature works?

If IIS 8.5 service in a large number of configured sites (default: 100 or greater), This service will not activate all of the sites at once, instead of activate them all at once IIS will activate each sites one by one (only when it receives the first request of the sites) and by using this technique could reduce the amount of system resources require by IIS.

How to Configure This Feature?

As I mention before, if there are less than 100 sites configured then IIS will activate all sites at starts up, but if there are 100 or more. Then it will activate each site as it is accessed the first time.

Step by Step

  1. Open IIS Manager
  2. Double Click Configuration Editor

  3. Select System.applicationHost/webLimits

  4. Set the value of dynamicRegistration Threshold to the new Treshold Value ( the default is : 100)
  5. Restart IIS


European IIS 8.5 Hosting – HostForLIFE.eu :: How to Redirect HTTP to HTTPS in IIS

clock August 6, 2014 08:25 by author Onit

Prerequisite

If you are using SSL on your IIS 8.5 (from 7.5 or greater) server for some time now; to get here you had to do a few things:

  1. You scrubbed your site content to ensure all URLs are using their relative form, e.g. “src=’//images\image.png” or explicitly reference the use of HTTPS.
  2. You have tested for certificate and SSL related problems like mixed content, appropriately tagging cookies as secure.
  3. You have ensured that you follow the best practices guidance for SSL server configuration and verified you get an A on  SSLLabs.

there are a few things left for you to do, the most obvious being redirecting all traffic to the SSL version of your site! You should probably monitor your CPU usage during your peak so to ensure you have some headroom. This isn’t likely to be a problem as most web-servers are not CPU bound but it’s always good to check.

 

Once you know you are OK then it’s just a matter of deciding which approach to use, you have two choices:

  1. Dynamically rewriting via code in your ASPX pages
  2. Using the IIS URL Rewrite  module

If you are familiar with the IIS configuration you’re probably asking yourself what about the “Require secure channel (SSL)” option in the IIS MMC? Unfortunately this doesn’t do redirecting it only requires the use of SSL on a given site/folder/file.

So how do you decide which approach to use? The answer to that question is dependent on both your environment and personal preference, but this time we will show how to do using the method two

IIS URL Rewrite Module

since in this article we will showed you to use the second choice, using the IIS URL Rewrite module, you can check the steps below

This approach has a number of benefits, for one having this module allows you to leverage remapping for other purposes also for example maintaining old links that have SEO value. From a security standpoint it’s also a good approach as it keeps this decision one of policy that is enforced in a central place.

To use the URL rewrite approach you will need to do the following:

  1. Install the URL Rewrite module (x86, x64).
  2. Add a rule to rewrite all HTTP URLs to HTTPS.
    1. Open your “web.config” with your favorite editor.
    2. Find the “configuration\system.webserver\rewrite\rules” section.
    3. Add the following text block:
      <rule name=”Redirect to HTTPS” stopProcessing=”true”>
      <match url=”(.*)” />
      <conditions>
      <add input=”{HTTPS}” pattern=”^OFF$” />
      </conditions>
      <action type=”Redirect” url=”https://{HTTP_HOST}/{R:1}” redirectType=”Permanent” />
      </rule>
  3. Restart IIS

Now you can go to your website over HTTP and you will see you are redirected to the HTTPS instance of the site.



About HostForLIFE.eu

HostForLIFE.eu is European Windows Hosting Provider which focuses on Windows Platform only. We deliver on-demand hosting solutions including Shared hosting, Reseller Hosting, Cloud Hosting, Dedicated Servers, and IT as a Service for companies of all sizes.

We have offered the latest Windows 2016 Hosting, ASP.NET Core 2.2.1 Hosting, ASP.NET MVC 6 Hosting and SQL 2017 Hosting.


Tag cloud

Sign in