23 Feb 2012

Firewall rule for IIS 7.5 on Server 2008 R2

I've been attempting to install and configure FTP on IIS 7.5 today and had an issue which I believed to be related to the Windows Firewall on the server, while the FTP service appears to be in the list of allowed applications which can pass through the Windows Firewall, a remote FTP connection would still not work.

I found an interesting article advising to add svchost to the allowed applications, which then led me to this article

To get "insecure" FTP working, I ran the following from an elevated command prompt on the server and sure enough it work :o)
netsh advfirewall firewall add rule name="FTP (non-SSL)" action=allow protocol=TCP dir=in localport=21

IIS 7/7.5 Best Practices and Inetpub Relocation

When building Server 2003 web servers, I used the unattended install method to relocate IIS 6 to a drive other than the C: drive, with Server 2008, this isn't possible but the inetpub can be relocated post install.

A list of IIS 7/7.5 best practices compiled by Vivek Kumbhar can be found here and a move script for the relocation of the IIS inetpub can be found at Thomas Deml's blog.

N.B. The syntax for the moveiis7root.bat script is
moveiis7root.bat driveletter