windows Installer - 当版本安装策略不同时卸载以前的版本(每用户,每台机器) [英] windows Installer - uninstalling previous version when the versions differ in installation policy (per-user, per-machine)

查看:28
本文介绍了windows Installer - 当版本安装策略不同时卸载以前的版本(每用户,每台机器)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们有一个 visio 插件(比如版本 1),它由具有管理员权限的用户安装(Just me"选项),并且 msi 安装程序是使用 Visual Studio 的设置和部署创建的.后来因为组织政策到位撤销所有用户的管理员权限被撤销.因此,新版本(版本 2)需要由 IT 管理员按每台机器(每个人的选项)安装,以便该插件可供该机器上的所有用户使用,并卸载已安装的旧版本(版本 1)被撤销权限的用户.

We have a visio plugin (say, version 1) which was installed by the User with Admin rights as per-user (‘Just me’ otpion) and the msi installer was created using setup and deployment of visual studio. Later because of organization policy in place to revoke admin privileges for all users were revoked. So the new version (version 2) needs to be installed by a IT admin as per-machine (everyone option) in order for the plugin to be available for all users on that machine and also to uninstall the old version (version 1) installed by the User whose permissions were revoked.

我们正在尝试自动卸载以避免人工干预.该实用程序通过查看该计算机上的注册表项并使用 msiexec 强制卸载来检测应用程序的所有已安装实例.但 msiexec 无法卸载其他用户安装的版本,退出代码为 1605 - 此操作仅对当前安装的产品有效

We are trying to automate the uninstallation to avoid manual intervention. The utility works by detecting all installed instances of the application by looking at registry keys on that machine and forcing uninstall with msiexec. But msiexec fails to uninstall the version that was installed by other user with exitcode as 1605 - This action is only valid for the products that are currently installed

如果用户(安装了版本 1 插件)被授予卸载应用程序的管理员权限,他可以手动卸载它,证明应用程序没有被篡改并且处于可以毫无问题地卸载的状态.

If the User (who installed the version 1 plugin) is given admin rights to uninstall the application, he is able to manually uninstall it that proves that the application not tampered and is in a state that can be uninstalled without any issues.

有关如何以编程方式卸载已由其他用户使用仅我一个"选项安装的计算机上安装的应用程序的任何指示都会有所帮助

Any pointers about how to programmatically uninstall application installed on a machine that has been installed by the other user with ‘Just me’ option would really help

推荐答案

这不仅仅是 Visual Studio 的问题.Windows Installer 不允许在升级过程中更改安装上下文(用户/机器).在安装新的每台机器安装之前,您必须以执行安装的用户配置文件身份登录并删除它们.

It's not just a Visual Studio problem. Windows Installer doesn't allow the installation context (user/machine) to change durin an upgrade. You have to perform logon as the user profile(s) that did the installation(s) and remove them before installing the new per-machine install.

这篇关于windows Installer - 当版本安装策略不同时卸载以前的版本(每用户,每台机器)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆