This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- Feature prerequisites during silent install
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
‎Apr 08, 2009
09:54 AM
Feature prerequisites during silent install
I'm having trouble getting my feature prerequisites to install when running a silent install from the command line. I'm not sure what I'm missing.
I have a Basic MSI setup project, that installs 3 features one with a prerequisite (sql server 2005). It always installs all 3 features, and the user is not given the option to select the features to install in the UI mode.
The error in the install log:
Action start 10:11:19: ISInstallPrerequisites.
InstallShield 10:11:19: No features with associated prerequisites are being installed or advertised. Skipping prerequisites.
What do I need to do to make it recognize that I am installing a feature with a prerequisite?
Thanks,
Caroline
I have a Basic MSI setup project, that installs 3 features one with a prerequisite (sql server 2005). It always installs all 3 features, and the user is not given the option to select the features to install in the UI mode.
The error in the install log:
Action start 10:11:19: ISInstallPrerequisites.
InstallShield 10:11:19: No features with associated prerequisites are being installed or advertised. Skipping prerequisites.
What do I need to do to make it recognize that I am installing a feature with a prerequisite?
Thanks,
Caroline
(11) Replies
‎Apr 08, 2009
10:42 AM
How are you launching your installation? This should be handled automatically from a setup.exe /v"/qn" style silent install, and should be impossible from an msiexec /qn style silent install. (The former has special handling for feature prerequisites; both it and the latter skip the UI sequence which is the normal entry point, but the latter has no way to do special handling.)
‎Apr 08, 2009
01:08 PM
Ah, that helps. Thanks a lot.
I found that it was failing one of the conditions.
I accidentally put one of my actions, which sets a registry key that the prerequisite checks, in the wrong sequence, so it wasn't getting run.
I found that it was failing one of the conditions.
I accidentally put one of my actions, which sets a registry key that the prerequisite checks, in the wrong sequence, so it wasn't getting run.
‎Apr 08, 2009
02:02 PM
During silent mode, do the Feature prerequisites get checked before other custom code can run?
I have an action that checks a variable and sets a regkey that is used as a condition for the prerequisite. And it seems that the conditions are checked before this action runs. It is set to run before CostFinalize with Immediate Execution.
I have an action that checks a variable and sets a regkey that is used as a condition for the prerequisite. And it seems that the conditions are checked before this action runs. It is set to run before CostFinalize with Immediate Execution.
‎Apr 08, 2009
04:59 PM
Yes. Feature prerequisites have to occur outside the InstallExecute sequence in order to support prerequisites that include Windows Installer setups. For full-UI installs, we launch them shortly before ExecuteAction. For silent setups, there is only the InstallExecute sequence, so we launch them from setup.exe before running the MSI.
For your case, if you can represent the check directly in the prerequisite conditions, I'd suggest that you do so. Alternately, you may want to explore creating an InstallScript installation or other custom exe as a bootstrap around your current setup.exe, and pull the registry key generation out to there. I'd avoid the latter if possible.
For your case, if you can represent the check directly in the prerequisite conditions, I'd suggest that you do so. Alternately, you may want to explore creating an InstallScript installation or other custom exe as a bootstrap around your current setup.exe, and pull the registry key generation out to there. I'd avoid the latter if possible.
‎Apr 09, 2009
10:22 AM
Is there any way that I can get my properties set before the prerequisites run? The properties that I pass in on the command line. They don't seem to set the values until after the prerequisites run as well.
(Specifically, I pass in the SA password that I want to install sql server with, which is passed to the prerequisite installer through it's command line, but the value doesn't seem to be getting through).
(Specifically, I pass in the SA password that I want to install sql server with, which is passed to the prerequisite installer through it's command line, but the value doesn't seem to be getting through).
‎Apr 09, 2009
01:55 PM
This should work fine. Did you make sure to specify a silent command line for the prerequisite that uses the property? I tested with a notepad prerequisite, passing PROP1="MiKe" in the command line, and using [PROP1] in the prerequisite's command line, and "MiKe" was passed.
‎Apr 09, 2009
02:04 PM
we specify the silent command line for the prereq as
/qn ADDLOCAL=ALL INSTANCENAME=MYINSTANCE SECURITYMODE=SQL SAPWD=[SQL_SA_PASSWORD]
But when it installs it appears to not substitute in this value. Later when we try to connect to sql server with the password that was specified it does not work. In fact, if I try to log in with "[SQL_SA_PASSWORD]" as the password, it connects. If I go through the UI install (it also uses the same prereq command line), connecting works correctly (the specified password, not the property name).
I tried also setting that value using the System Search functionality, in case that would help, but it didn't seem to.
(I ended up creating a batch file that would create the registry key that I needed for the condition check on the prereq, and also temporarily stored the password value in the registry, so I could pull it out with the system search.)
The following is the command line that I'm using to call setup.exe, maybe I'm doing something wrong with it?
setup.exe /v"/qb INSTALLSQLSERVER=1 SQL_SA_PASSWORD=A!ra2235A!ra INSTALLDIR=\"C:\\Program Files\\MyCompany\\MyProduct\\\" /L*v C:\install.log" /debuglog
/qn ADDLOCAL=ALL INSTANCENAME=MYINSTANCE SECURITYMODE=SQL SAPWD=[SQL_SA_PASSWORD]
But when it installs it appears to not substitute in this value. Later when we try to connect to sql server with the password that was specified it does not work. In fact, if I try to log in with "[SQL_SA_PASSWORD]" as the password, it connects. If I go through the UI install (it also uses the same prereq command line), connecting works correctly (the specified password, not the property name).
I tried also setting that value using the System Search functionality, in case that would help, but it didn't seem to.
(I ended up creating a batch file that would create the registry key that I needed for the condition check on the prereq, and also temporarily stored the password value in the registry, so I could pull it out with the system search.)
The following is the command line that I'm using to call setup.exe, maybe I'm doing something wrong with it?
setup.exe /v"/qb INSTALLSQLSERVER=1 SQL_SA_PASSWORD=A!ra2235A!ra INSTALLDIR=\"C:\\Program Files\\MyCompany\\MyProduct\\\" /L*v C:\install.log" /debuglog
‎Apr 20, 2009
03:56 PM
I think I figured out what was happening. It seems to only pass the parameter in correctly if I use the /s /v"qn" options instead of /v"qb" option. If I use the full silent install method then it works ok.
Thanks.
Thanks.