/build/static/layout/Breadcrumb_cap_w.png

Vendor-supplied MSI, how to edit private properties to ease distribution?

Hi all.
Long time lurker and first time poster here.
I've used many of the tips and tricks espoused here for a couple of years now, and am (slightly) dangerous with kixtart and other general scripting tools like ASE.

I have a vendor supplied MSI that needs installing to a few hundred PCs in our group.
The product MSI requires user entry of only ONE field, consisting of MachineName\InstanceName for a database connection (SQL Express 2005 - not that I think that's relevant here).
The MachineName will be unique to each machine and I planned to simply use the env variable %COMPUTERNAME% for that part.
The InstanceName will be identical across all machines the MSI is run, so I was just going to define that statically.

I was hoping to find a nice easy way of specifying these properties at commandline like:

msiexec.exe /I "vendor.msi" /QB ALLUSERS=All DBSERVER=%COMPUTERNAME%\InstanceName

However, that does not work.
I've opened the MSI with Windows Installer Command Line Builder from Wise, and found that there doesn't seem to be a public property associated with the field I want to specify.
I then opened the MSI with Orca and had a snoop around in there - that's how I found the "DBSERVER" string I listed above. It is in the CustomAction table:

CustomTextC_SetProperty_EDIT2 307 DBSERVER (local)

So then I looked in the Property table and found:

EDITC2 1

Am I on the right track here? Can I use this property at the commandline like:
msiexec.exe /I "vendor.msi" /QB ALLUSERS=All EDITC2=%COMPUTERNAME%\InstanceName

I tried that, but it didn't work, I guess as the "EDITC2" is not in the list of Public properties when I looked with the Win Installer Command Line Builder.

I have spent a few hours searching in this forum and googling for how to set private properties, but haven't found info on how to do it, only repeated info that you can't do it from the commandline...
So, any advice on where to go from here will be gratefully received. :)
I am a complete noob when it comes to Orca - I have never tried to "modify" an MSI before.
But as I said previously, I'm reasonably confident with general silent installs and switches.
Please note that the network environment is NOT an active directory, and is in fact not even a domain as such, so any tools/methods suggested will need to be fully portable.
The final MSI/script/whatever will need to be installed on a completely standalone workstation in some cases.
I'm sure someone out there knows just what to do, so TIA!
tU

0 Comments   [ + ] Show comments

Answers (5)

Posted by: anonymous_9363 16 years ago
Red Belt
0
Only public properties (easily identified, as they're the ones in all upper-case) can be passed on the command line. For anything else, you need to use a transform. Alter the property values in the transform (you may as well use it for ALLUSERS, DBSERVER, etc) and specify that transform name on the command line:

msiexec.exe /I "path_to_and_name_of_vendor.msi" /QB TRANSFORMS="path_to_and_name_of_MST"

Note that TRANSFORMS is a special public property and is plural: this is because you can concatenate multiple transforms, each separated by a semi-colon:

msiexec.exe /I "path_to_and_name_of_vendor.msi" /QB TRANSFORMS="path_to_and_name_of_first_MST;path_to_and_name_of_next_MST"
Posted by: oreillyr 16 years ago
Fifth Degree Brown Belt
0
Hi VBScab
When installing multiple transforms, you leave ou the path to the mst, so it would just be msiexec.exe /I "path_to_and_name_of_vendor.msi" /qb TRANSFORMS=2057.mst;adobe.mst ( for example).
Posted by: anonymous_9363 16 years ago
Red Belt
0
ORIGINAL: oreillyr

Hi VBScab
When installing multiple transforms, you leave ou the path to the mst, so it would just be msiexec.exe /I "path_to_and_name_of_vendor.msi" /qb TRANSFORMS=2057.mst;adobe.mst ( for example).
Really? That's not what MSDN says http://msdn2.microsoft.com/en-us/library/aa372085(VS.85).aspx, nor does it tally with my experience...YMMV, of course.
Posted by: aogilmor 16 years ago
9th Degree Black Belt
0
ORIGINAL: theUtmost

Hi all.
Long time lurker and first time poster here.
I've used many of the tips and tricks espoused here for a couple of years now, and am (slightly) dangerous with kixtart and other general scripting tools like ASE.

I have a vendor supplied MSI that needs installing to a few hundred PCs in our group.
The product MSI requires user entry of only ONE field, consisting of MachineName\InstanceName for a database connection (SQL Express 2005 - not that I think that's relevant here).
The MachineName will be unique to each machine and I planned to simply use the env variable %COMPUTERNAME% for that part.
The InstanceName will be identical across all machines the MSI is run, so I was just going to define that statically.

I was hoping to find a nice easy way of specifying these properties at commandline like:

msiexec.exe /I "vendor.msi" /QB ALLUSERS=All DBSERVER=%COMPUTERNAME%\InstanceName

However, that does not work.
I've opened the MSI with Windows Installer Command Line Builder from Wise, and found that there doesn't seem to be a public property associated with the field I want to specify.
I then opened the MSI with Orca and had a snoop around in there - that's how I found the "DBSERVER" string I listed above. It is in the CustomAction table:

CustomTextC_SetProperty_EDIT2 307 DBSERVER (local)

So then I looked in the Property table and found:

EDITC2 1

Am I on the right track here? Can I use this property at the commandline like:
msiexec.exe /I "vendor.msi" /QB ALLUSERS=All EDITC2=%COMPUTERNAME%\InstanceName

I tried that, but it didn't work, I guess as the "EDITC2" is not in the list of Public properties when I looked with the Win Installer Command Line Builder.

I have spent a few hours searching in this forum and googling for how to set private properties, but haven't found info on how to do it, only repeated info that you can't do it from the commandline...
So, any advice on where to go from here will be gratefully received. :)
I am a complete noob when it comes to Orca - I have never tried to "modify" an MSI before.
But as I said previously, I'm reasonably confident with general silent installs and switches.
Please note that the network environment is NOT an active directory, and is in fact not even a domain as such, so any tools/methods suggested will need to be fully portable.
The final MSI/script/whatever will need to be installed on a completely standalone workstation in some cases.
I'm sure someone out there knows just what to do, so TIA!
tU


Hi, and welcome! Hopefully we'll see you around more.
307 = 256 + 51, which means
TypeFirstSequence 256 Execute once if present in both sequence tables. Skips action in execute sequence if UI sequence has run. No effect in UI sequence. Not affected by install service registration.
Custom Action Type 51 This custom action sets a property from a formatted text string.
So barring some other action that affects the value of DBSERVER, it should pick up the value of DBSERVER that you set in the Property table or on the command line. Generate a verbose log, which will list all the properties at the time of the installation:

msiexec.exe /I "vendor.msi" /QB ALLUSERS=1 DBSERVER=%COMPUTERNAME%\InstanceName /l*v <path to log file>

Also, I just noticed that you used ALLUSERS=All in your initial post. I don't think this is valid. It should be 1 for a per machine installation.

See what you come up with and let us know
Posted by: theUtmost 16 years ago
Yellow Belt
0
Wow - thanks for the replies folks.
I must confess I wasn't expecting such a speedy response. Maybe I should have asked the occassional question round these parts earlier ;)
I'm away on a work trip so won't be anywhere near my dev box for over a week to try anything else.
I'll be sure to report back on how I get on.

@aogilmor I had wondered about that ALLUSERS=All and whether it should be something like 1 or TRUE.
As I said, I'm really not too sure of my way around inside the various tables in an MSI, so any guidance gratefully received!
BTW, what is the easiest way of telling for sure whether a given software package HAS been installed for all users or just the current user?
Cheers,
tU
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ