Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IIS express 7.5 only loading one site even though 2 sites defined?

Tags:

iis-express

I have IIS express loaded and running from a command line entry. I am using the default applicationhost.config file (I know it's the correct file as I have changed the 1st site's port a couple of times etc).

The strange thing is, I have two sites defined, and it appears only the first one gets loaded? I am sure IIS express can load multiple sites right? as long as different ports?

Here is the <sites> definition bit from the applicationhost.config file:

<sites>
    <site name="BF Local SVN" id="1">
        <application path="/" applicationPool="Clr4IntegratedAppPool">
            <virtualDirectory path="/" physicalPath="C:\_CODE SOURCECONTROL\BizzfaceLocalSVN" />
        </application>
        <bindings>
            <binding protocol="http" bindingInformation="*:6464:localhost" />
        </bindings>
    </site>
    <site name="SquirrelITfreeformBS" id="2">
        <application path="/" applicationPool="Clr4IntegratedAppPool">
            <virtualDirectory path="/" physicalPath="C:\_CODE SOURCECONTROL\SquirrelITfreeformBS" />
        </application>
        <bindings>
            <binding protocol="http" bindingInformation="*:6465:localhost" />
        </bindings>
    </site>
    <siteDefaults>
        <logFile logFormat="W3C" directory="%IIS_USER_HOME%\Logs" />
        <traceFailedRequestsLogging directory="%IIS_USER_HOME%\TraceLogFiles" enabled="true" maxLogFileSizeKB="1024" />
    </siteDefaults>
    <applicationDefaults applicationPool="Clr4IntegratedAppPool" />
    <virtualDirectoryDefaults allowSubDirConfig="true" />
</sites>

As you can see, two sites defined, different site ID's and different ports?

Any ideas?

like image 613
Dav.id Avatar asked Aug 22 '11 03:08

Dav.id


1 Answers

When you run iisexpress.exe from command line (without any command line arguments), it starts the first site given in default applicationhost.config file (%userprofile%\documents\iisexpress\config\applicationhost.config).

To start multiple sites, use /apppool switch as shown below;

iisexpress.exe /apppool:Clr4IntegratedAppPool

Above command would start all the applications that are using 'Clr4IntegratedAppPool' app pool.

like image 74
vikomall Avatar answered Nov 17 '22 11:11

vikomall