Hi,

I am installing an msi by silent installation ie using /qn installation. It fails because UAC is denied. This msi is installed as a part of continuous integration(CC.Net). Is there a way in which I can actually run the msiexec using elevated permissions? /a does not help either.


Thanks,
Reddy
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Not sure what your trying to accomplish or what your MSI is doing or how it looks
If you are using the same MSI each date, only updating it with new files, you'd probably be able to use the same MST for the updated MSI.
Answered 02/06/2012 by: andemats
Second Degree Black Belt

Please log in to comment
0
Is there a way to load the newly generated msi into Orca, and change a property value through a batch file or something like that. Windows Installer exposes a bunch of methods and properties so you can use any scripting language that can access Windows COM objects. The object name is 'WindowsInstaller.Installer' and it is documented on MSDN.
Answered 02/06/2012 by: VBScab
Red Belt

Please log in to comment
0
The msi gets generated everyday and I am wanting to install the new msi everyday. There is a property whose value is 0 by default and I change it to 1 in the mst. So I want to generate a new mst corresponding to the new msi everyday. Or is it fine if I just use the old mst with the new msi?
Answered 02/06/2012 by: ReddyLoyalty
Yellow Belt

Please log in to comment
0
It would be much, much simpler to make the property a public property and then specify its value on the command line.
Answered 02/06/2012 by: VBScab
Red Belt

Please log in to comment
0
Thank you for the reply. I am very very new to all this mst stuff.

1. How can I make a property public?
2. How do I know if a property is public or not?
3. How to set value through commandline.

Please bear with me as I am very very new to all this.
Answered 02/06/2012 by: ReddyLoyalty
Yellow Belt

Please log in to comment
0
A public property is all UPPERCASE.
Look in the property table of your MSI to find it.

MsiExec.exe \\Server\Share\MsiName.msi ALLUSERS=1 /qb!

In the above, "ALLUSERS" is a public property

Edit: I'll leave it to Ian to post the inevitable. [:D]
Answered 02/06/2012 by: andemats
Second Degree Black Belt

Please log in to comment
0
thank you very much
Answered 02/06/2012 by: ReddyLoyalty
Yellow Belt

Please log in to comment
0
A vbscript to create a transform based on two MSIs would look like

'// MsiPath; path to the original MSI
'// MsiTransPath; path to the updated MSI
'// MstPath; path to the transform
Call CreateTransform(MsiPath, MsiTransPath, MstPath)

Function CreateTransform(ByVal MsiPath, ByVal MsiTransPath, ByRef MstPath)
Const msiOpenDatabaseModeReadOnly = 0
Const msiOpenDatabaseModeDirect = 2
Const msiTransformErrorNone = 0
Const msiTransformValidationNone = 0

Dim Installer : Set Installer = CreateObject("WindowsInstaller.Installer")
Dim Database : Set Database = Installer.OpenDatabase(MsiPath, msiOpenDatabaseModeReadOnly)
Dim TransDatabase : Set TransDatabase = Installer.OpenDatabase(MsiTransPath, msiOpenDatabaseModeDirect)

TransDatabase.GenerateTransform Database, MstPath
TransDatabase.CreateTransformSummaryInfo Database, MstPath, msiTransformErrorNone, msiTransformValidationNone
TransDatabase.Commit
End Function
Answered 02/07/2012 by: AngelD
Red Belt

Please log in to comment
0
I might be off the mark here, but if your base MSI remains roughly structurally the same, and the only change in the MST would be to set a property from 0 to 1, you can just re-use the same MST on your MSI every time.
That being said, the idea of using a public property would make your life alot easier in this case.

PJ
Answered 02/07/2012 by: pjgeutjens
Red Belt

Please log in to comment
0
Have in mind that public properties does not get "stuck" so it will not be available through a repair, so that is something you'll need to handle (write/read to registry).
Answered 02/08/2012 by: AngelD
Red Belt

Please log in to comment
0
I am successful in running using /qb but when I use /qn, the installation fails. This is because when I use /qn option, I do not answer the UAC, so it fails. Is there a way that I can actually run the msi as an administrator woth elevated permissions. I used /a but that does not help either.
Answered 02/13/2012 by: ReddyLoyalty
Yellow Belt

Please log in to comment
0
/a is to create an administrative install point so it won't help you.

I don't know anything about CC.net so I'm sorry if this doesn't help you. If it is a deployment tool like SMS, LANDesk, SCCm, etc, then it likely has a setting to run as an administrator account or System. Be sure you have that set properly.

MSI's can't use Run as Admin (from the right click menu), but in general it will prompt for UAC. So instead you have 2 choices (well, more but here is probably the easiest 2). When you create your msi package, create it inside or with a setup.exe or put your msiexec.exe command inside a cmd or bat file.
Answered 02/13/2012 by: jmaclaurin
Third Degree Blue Belt

Please log in to comment
Answer this question or Comment on this question for clarity