cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
spooooky
Level 2

Creating virtual directory under Default Web Site in IIS7

Hello

An installshield 2008 project of mine that creates a virtual directory/applicaton under "Default Web Site" used to work correctly in IIS 6. But when running against IIS 7 (Windows server 2008), the virtual directory is not created. I created a small sample app for testing the same. Attaching a few screen shots from the installshield designer. Pls let me know what else I need to do, to get the Virtual dir craeted in IIS 7

After creating the web site named "Default Web Site", i did not edit information in any tabs for the web site. For virtual directory, i have modified information in the first two tabs (screen shots attached).

My intention here is to create a virtual directory under the default web site in IIS.

If i run the following command from command prompt in the windows server 2008 machine, the app and vdir is created fine.

AppCmd ADD APP /site.name:"Default Web Site" /path:/Spooky /physicalPath:"D:\Program Files\SpookyTest"

Looking forward to your comments, suggestions

PS: Please review the attached screenshots..
Labels (1)
0 Kudos
(3) Replies
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

Please try applying the updated IIS custom action DLL from KB article Q200236.

After applying the updated DLL, rebuild and test your project. If the behavior does not change, please log the install with the following command line and attach the verbose log:
setup.exe /v"/l*v C:\iistest.log"
0 Kudos
spooooky
Level 2

After applying the patch, the virtual directory is created as expected... That was a relief.... Thanks for the info...

I have one design question.. My intention is to create an application/virtual directory under the default site. For this, I created a web site with hardcoded name "Defaut Web Site", because in IIS the name of the default site is this (by default).

But if the server where the program is being installed, is running the default site under a different name, then the installation will create another site with the name "Default Web Site" and wont be able to start it also, because the port conflicts...

Is this the right way of doing this? Even with AppCmd command line tool, we need to pass in a site name...

Using the IIS6 admin script (adsutil.vbs), we could have done something like CREATE_VDIR W3SVC/1/Root/MyAppName, which is not bound to a site name, but the Root keyword identifies the default web site...

Is there something similar to the 'Root' keyword in the above command, that we could use in the Installshield IIS View, to identify the default web site. Or even in the AppCmd command...

Looking forward to your reply
0 Kudos
joshstechnij
Level 10 Flexeran
Level 10 Flexeran

The website name is relevant usually when the site will be installed. To be able to get a website installed with the InstallShield IIS support, the port and/or site number for the website in the project need to be changed from the default setting to some value that won't exist on a target machine.

Unless the port or site number is different on a target machine (or these settings are changed in your project), your virtual directory should always be installed to the default website.
0 Kudos