Hi Robert,

 

Thanks for the reply.  My issue isn't so much if I can get ConfigureIIS
custom action to work with IIS 7, but more that it doesn't cause the
error during the install, whether I use it or not.  The issue is I have
to support both Windows Server 2003, and Windows Server 2008 with my
install, and the presence of those IIS nodes in my wxs file causes the
scheduling of the ConfigureIIS custom action, even if when I detect the
IISMAJORVERSION="#7" I choose to disable those components.

 

Amy

 

From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 14, 2008 2:50 PM
To: Amy Rosewater; wix-users@lists.sourceforge.net
Subject: RE: [WiX-users] IIS 7.0 and Wix 3.0.4019 - PLS help!

 

Hello Amy,

 

There is no native support in WIX  for IIS7. So, unless you have the
module that allows the old api to work (I can't remember what it  is
called right now),  The Configure IIS stuff won't work. 

 

What was recommended to me (and what I have done) was to use XmlConfig
to modify the IIS7 configuration file.

 

The configuration file you are looking for is:
"%windir%\system32\inetsrv\config\applicationHost.config"

 

 

You should be able to find ample info on how to modify an Xml file with
XmlConfig.

 

From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Amy
Rosewater
Sent: Wednesday, May 14, 2008 4:40 PM
To: wix-users@lists.sourceforge.net
Subject: [WiX-users] IIS 7.0 and Wix 3.0.4019 - PLS help!

 

This is my second desperate posting for help.  Anyone with any ideas
feel free to send them my way.  I have an install that sets up Web
Application in either a virtual directory under the Default Web Site, or
as a separate website.  In order to find the default website, I use the
following wix:

            <iis:WebSite Id="DefaultWebSite" Description="Default Web
Site">

                  <iis:WebAddress Id="DefaultWebSiteAddress" IP="*"
Port="80" />

            </iis:WebSite>

I have this node at the same level as my property and directory nodes
such that it just finds the already existing Default Web Site, and does
not alter it on uninstall.   I also have a few Components for installing
against IIS (below is my Virtual Directory component).

                  <Component Id="CreateVirtualDirectory"
Guid="5f9a10ee-72b1-11dc-8314-0800200c9a66">

 
<Condition><![CDATA[(IISCONFIGURATIONTYPE="0")]]></Condition>

                        <iis:WebAppPool Id="WebAppPoolVirtualDirectory"
Name="iVantageAppPool" Identity="other" User="InstallUser" />

                        <iis:WebVirtualDir Id="WebVirtualDir"
Alias="[IISVIRTUALDIRECTORY]" Directory="MainWebDirectory"
WebSite="DefaultWebSite">

                              <iis:WebApplication
Id="MainWebApplicationVirtualDirectory" Name="iVantage50"
WebAppPool="WebAppPoolVirtualDirectory" />

                              <iis:WebDirProperties
Id="WebDirPropertiesVirtualDirectory" AnonymousAccess="yes"
AnonymousUser="InstallUser" Write="yes" DefaultDocuments="Default.aspx"
Execute="yes" Read="yes" Script="yes" AspDetailedError="yes" />

                        </iis:WebVirtualDir>

                  </Component>

 

When running this install on Windows Server 2003 with IIS 6.0, there are
no problems.  When running this install on Windows Server 2008 with IIS
7.0, I get the following (from my verbose log):

 

ConfigureIIs:  Skipping ScaInstallWebSvcExt() because
IIsWebServiceExtension table not present

ConfigureIIs:  Skipping ScaInstallMimeMap() - required table not present

ConfigureIIs:  Skipping ScaGetHttpHeaders() - required tables not
present.

ConfigureIIs:  Skipping ScaGetWebErrors() - required tables not present.

ConfigureIIs:  Error 0x80070005: Failed to find web root

ConfigureIIs:  Error 0x80070005: failed to read IIsWebSite table

Error 26002. Failed to read IIsWebSite table.   (-2147024891         )

 

I have installed all the possible features on my IIS Web Server in
Windows Server 2008, thinking that my issue might be related to server
configuration.

 

I have looked through the Wix source code in the hopes of being able to
figure out what is going on in the code when these errors occur.  I need
to know if something is incorrectly configured on my server, or if there
is something wrong with my wxs.  Please forgive me if this
interpretation is incorrect as I am not much of a c++ developer... L but
it looks like this is what is happening in the custom action.

 

(1)    ConfigureIIS action is evoked based on the presence of my various
IIS component nodes and the subsequent scheduling of that CustomAction.

(2)ConfigureIIS calls the ScaWebsRead method, the source of the second
error message:

hr = ScaWebsRead(piMetabase, &psmmList, &pswList, &pshhList, &psweList);

      MessageExitOnFailure(hr, msierrIISFailedReadWebSite, "failed to
read IIsWebSite table");

(3)    Now it appears that in this method, wix open views on the various
IIS tables in the install database.  We get a view on IISWebAddress,
IISWebApplication (if present) and IISWebSite.  Next we iterate the
records returned from IISWebSite.  In my case there are 3:

a.       Default Web Site - from my iis:WebSite node above

b.      Two Web Sites from Components in my install (one to create a
website with a port, and the other to create a website with an IP
address).

(4)    It appears to successfully read the data from this first record
(my Default Web Site), getting Address, IP, Port, Header and Secure
values without error.

(5)    We then get to this code - the source of the first error message:

  // TODO: fix this to look for the description as well (or is address
enough)?

        // find the web root

        dwLen = METADATA_MAX_NAME_LEN;

        hr = ScaWebFindBase(piMetabase, *ppswList,

                            psw->wzKey, 

                            psw->swaKey.wzIP, 

                            psw->swaKey.iPort, 

                            psw->swaKey.wzHeader, 

                            psw->swaKey.fSecure, 

                            psw->wzWebBase, &dwLen);

        if (S_OK == hr)

        {

            psw->fBaseExists = TRUE;

        }

        else if (S_FALSE == hr && FALSE == psw->fHasComponent) // if
we're not installing it, fail if it wasn't found

        {

            ExitOnFailure1(hr = HRESULT_FROM_WIN32(ERROR_NOT_FOUND),
"failed to find web site: '%S'", psw->wzKey);

        }

        else if (S_FALSE == hr)

        {

            dwLen = METADATA_MAX_NAME_LEN;

            hr = ScaWebFindFreeBase(piMetabase, *ppswList,
psw->wzWebBase, dwLen);

            psw->fBaseExists = FALSE;

        }

        ExitOnFailure(hr, "Failed to find web root");

(6)    Can anyone help me out here in understanding what it means when
there is a failure here?  Is anyone familiar with what is going on in
ScaWebFindBase?   From the code I can glean that it first attempts to
find the web in memory, and then it looks in the metabase?  This doesn't
help me intuit what is going on but I am hoping it might help someone
else out there...

 

Thanks in advance for your help.

 

A

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft 
Defy all challenges. Microsoft(R) Visual Studio 2008. 
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
WiX-users mailing list
WiX-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wix-users

Reply via email to