打印机型号:
打印机一:HP LaserJet Pro M226 MFP (M225-M226)
打印机二:HP LaserJet Pro M128fw MFP (M127-M128)
以往使用打印机的时候一切正常,但是最近一批电脑一直无法安装惠普打印机驱动,有如下报错:
……
MSIExec command:/I “…HpTcpMon64.msi” /qn
REBOOT=ReallySuppress
Path:<empty>
Return code:1603
这一批电脑的操作系统为win 10,我自己电脑的操作系统也是win 10,但早些时候我已经在我的电脑上成功安装了惠普打印机驱动。
为什么同样是win 10操作系统,我的电脑可以正常安装驱动,而新的这一批电脑却不行呢?我卸载驱动重新安装,则驱动已经无法正常安装,报错与上面一致。
大致可以推测出,安装失败的问题应该是驱动程序与操作系统不兼容导致的。我的win 10曾经可以正常安装驱动,但是伴随着win 10的自动更新,便和新的这一批电脑一样无法安装驱动了。
结论:
较新版本的win 10无法安装惠普打印机驱动。
解决办法:
网络上搜索:安装惠普打印机驱动 1603报错
发现遇到这个问题的用户非常多,可见惠普这样的大公司也是不靠谱的。
虽然报错类似,但提到的处理方法却多种多样:
有的让重启电脑;
有的让重启电脑的某些服务: print spooler,Windows Image Acquisition (WIA);
有的让重新安装.Net Framework;
……
甚至很多提出解决方案的人还是惠普的技术支持,但是这些处理方法都不能解决我的问题。
基本解决办法:
安装惠普打印机的“基本驱动程序”
安装惠普打印机的基本驱动程序后,打印机可以执行基本的打印任务了,但是不能使用包括扫描在内其他一些功能,于是只能继续探索。
终极解决办法:
仔细查看惠普打印机驱动的安装报错,可以看到安装程序在执行HpTcpMon64.msi这个文件时出现了错误,于是直接在安装程序的目录中找到这个文件:
LJPro_MFP_M127-M128_full_solution_15309\Setup\Core\SIPM_64\HpTcpMon64.msi
双击运行该文件,一路执行下去,出现如下报错:
Error 1934. This setup requires Administrator privileges for configuring IIS Virtual Roots.
应该就是这个错误导致安装惠普打印机驱动程序时出现1603错误。
仔细看这个报错,似乎是用户权限问题,但我本身是管理员账户啊。继续根据这个报错信息查找资料可以发现,问题的根源在于windows系统的DisableUserInstalls设置。
DisableUserInstalls
https://docs.microsoft.com/zh-cn/windows/win32/msi/disableuserinstalls
This is a per-machine system policy that can be used when the administrator only wants per-machine applications installed.
If this policy is not set, the installer searches the registry for applications in the following order: managed applications registered as per-user, unmanaged applications registered as per-user, and finally applications registered as per-machine.
If this policy is set to 1, the installer ignores all applications registered as per-user and only searches for applications registered as per-machine. Calls to the Windows Installer application programming interface or system ignore per-user applications. An attempt to perform an installation in the per-user installation context causes the installer to display an error message and stops the installation. In this case, the Windows Installer also prevents per-user installations from a terminal server.
Registry Key
HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer
Data Type
REG_DWORD
查看注册表可知,较新版本的win 10系统中DisableUserInstalls的值为1,此时安装程序将忽略所有按用户注册的应用程序,只搜索按机器注册的应用程序。调用Windows安装程序应用程序编程接口或系统忽略每个用户的应用程序。尝试在每个用户的安装上下文中执行安装将导致安装程序显示错误消息并停止安装。在这种情况下,Windows安装程序还阻止从终端服务器按用户安装。
将DisableUserInstalls的值改为0,再次安装惠普打印机驱动程序,安装正常。