简体   繁体   English

如何同步安装MSI?

[英]How do I install an MSI synchronously?

To do an unattended installation of any MSI package, one can simply use the following command: 要无人参与安装任何MSI包,只需使用以下命令:

msiexec /qn /i package.msi

However, this triggers an asynchronous installation: if you happen to chain 2 dependent installations, you will have to wait somehow for the 1st installation to complete. 但是,这会触发异步安装:如果您碰巧链接2个依赖安装,则必须等待第一次安装才能完成。

Is there a way to do this from the command line ? 有没有办法从命令行执行此操作?

I've had luck with this: 我对此很幸运:

start /wait msiexec /i MyInstaller.msi ...

Found in this blog post from 2005. Hope you found it way back in '08. 在2005年的博客文章中找到。希望你在08年找到它。

We'd run into this a number of times with various products and I'd ended up using a small outer program that launches each msi and waits until it finishes to start the next one. 我们已经使用各种产品多次遇到这种情况,我最终使用了一个小的外部程序来启动每个msi并等待它完成以启动下一个msi。 You can probably do this in something as lightweight as a vbscript, but at the time we wanted a bit more gui so we had a larger outer program. 你可以用像vbscript那样轻量级的东西来做这件事,但当时我们想要更多gui所以我们有一个更大的外部程序。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM