3

Is there such a utility or capability an MSI? Perhaps msiexec?

rpm -ql provides the list of all the files installed by a given package. I'd like to get the same info from a Windows system.

jscott
  • 24,484
  • 8
  • 79
  • 100
joebalt
  • 211
  • 2
  • 11
  • Why do you really need the list of files installed by an MSI package? What do you want to achieve? – Alexey Ivanov May 18 '12 at 06:35
  • I want to understand all files completely that the MSI package deposited onto my system when it was initially installed. – joebalt May 22 '12 at 00:34
  • To examine the files MSI contains, perform administrative install. If you want to know, what files are installed and where they're installed, then you have to enumerate the components of the package, check whether a component is installed, and enumerate the files and the registry keys/values in a component. I'm not sure there are tools which do what you want. – Alexey Ivanov May 22 '12 at 07:02
  • MSI package is an open book that's why IT departments love them. It allows examining its content easily, and additionally it allows for customization to meet company needs. – Alexey Ivanov May 22 '12 at 07:06
  • @Alexey, I agree that MSI is a book, but is is not an open book. ;) I find myself frequently looking for utilities, or writing my own to better explore and/or work with its contents. With rpm, one simply has to run "rpm ...." to discover everything about a package. I am going to write some basic MSI query tools very soon as a result of the discussions here. – joebalt May 23 '12 at 13:51
  • It's an open book as opposed to custom-made setup tools where you can't *easily* study what installation does. (I know, I know the word “easily” sounds weird in context of MSI, yet custom-made installation tools provide no means at all to study what's installed.) I agree it's much easier to study rpm contents. – Alexey Ivanov May 23 '12 at 18:58

4 Answers4

2

The Windows SDK contains a graphical utility called Orca for viewing and editing .msi databases. At a minimum, select Windows Native Code Development => Tools in the SDK installer, then install Orca from %ProgramFiles%\Microsoft SDKs\Windows\vX.Y\Bin\Orca.msi. When viewing a database in Orca, the File table contains a row for each file that will be installed.

Windows Installer XML (WiX) contains a tool called Dark that will decompile an .msi database to an XML file:

dark.exe Installer.msi

This will create an Installer.wxs file in the current directory. The <File /> elements correspond to rows in the File table.

1

msiexec can do that in admin mode.

msiexec /a something.msi TARGETDIR="c:\windows\temp" /qb

you may need some other switches, though.

johnshen64
  • 5,865
  • 24
  • 17
  • msiexec.exe /a - msiexec help says that installs the product on a network share. That's not what I am looking to do. – joebalt May 11 '12 at 21:40
  • yes, the tool is for installing, but you can extract the files without installing with the right switches. i found the right switches through google :-) but if you want to be really safe, do it in a disposable vm. do it on a very small and harmless msi that even if installed it will not hurt you. there are some other msi extraction tools on the net but i cannot recommend any because i have not used them and anything unknown could cause problems presumably. this is the official MS tool. – johnshen64 May 11 '12 at 21:41
  • I apologize for the lack of detail in my question. I just want a list of the files and their location on disk (full paths) *after* the msi package has been installed. I need to query the system on which the msi was installed for this list. – joebalt May 12 '12 at 16:20
  • Sorry, I do not know if that file list in the original msi database is always kept properly and in a fixed place, other than by examining the original msi file. The uninstaller script, if there is one, should have that but I don't know how to extract that. – johnshen64 May 13 '12 at 13:13
  • MSI does not provide such kind of functionality. It is possible to change the location of files during installation (by passing properties on the command line for example) so the paths can be different on each machine. – Alexey Ivanov May 18 '12 at 06:34
1

lessmsi

This is a utility with a GUI & CLI that can be used to view and extract the contents of an MSI file.

I just tried it out, works great.

jftuga
  • 5,731
  • 4
  • 42
  • 51
0

No, Windows Installer can't do this. There are no options which will tell you which files are installed from a certain package.

As suggested by John, you can look at all the files this package contains. Admin image would have folder structure similar to installed one with default options.


If you really want to get the list of all the files installed by a package, I think you can do it:

  1. Enumerate all the components in the package,
  2. Check with the system if the component is installed,
  3. Enumerate the files in components.

I have never heard of tool that can do this.

Alexey Ivanov
  • 246
  • 1
  • 4