尝试取消Windows服务的服务时服务已存在错误 [英] Service already exists error when trying to depoly windows service

查看:86
本文介绍了尝试取消Windows服务的服务时服务已存在错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要使用安装程序和部署来部署Windows服务的新版本(已经安装了以前的版本),但是我试图这样做,但我收到一个错误,提示该服务已经存在,我正在按照以下方式进行该过程:-
1.将removepreviousversion属性更改为true.
2.更改了版本号(因此产品代码会自动更改)
3.添加自定义操作(安装,提交,回滚,卸载)

后来我尝试在没有自定义操作的情况下进行更新,但已成功使用新版本进行更新.但是我需要进行自定义操作,因为在没有自定义操作的情况下进行全新安装的情况下,我无法安装Windows服务.

解决方案

大家好

终于我至少现在就找到了解决方案.我只是在安装和卸载中分别设置了两个条件NOT PREVIOUSVERSIONINSTALLED和NOT UPGRADINGPRODUCTCODE.它对我来说工作正常,没有任何错误.

I need to deploy a new version of windows service (a previous version already installed) using setup and deployment,but i am trying to do like that i got an error that service already exists,i am doing that procedure in following manner:-
1.changed the removepreviousversion property into true.
2.changed the version number(so product code automatically changed)
3.Add the Custom actions (install,commit,rollback,uninstall)

later i tried to update without custom actions its updated successfully with newer version.but i need to do with custom actions because in case of fresh installation with out custom action i cant install windows services. have any update on this?

解决方案

Hi all

Finally i got the solution for this at least for now.i just put two conditions in install and uninstall NOT PREVIOUSVERSIONINSTALLED and NOT UPGRADINGPRODUCTCODE respectively.its working fine for me without any error.


这篇关于尝试取消Windows服务的服务时服务已存在错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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