zabbix-agent-chocolatey
zabbix-agent-chocolatey copied to clipboard
Upgrade to 6.4.5 or 6.4.6 fails with cannot create a file when that file already exists
When i attempt to update zabbix-agent from older versions (confirmed 6.2.3 and 5.4.3) the upgrade fails with following error
Do you want to run the script?([Y]es/[A]ll - yes to all/[N]o/[P]rint): a
Extracting 64-bit C:\ProgramData\chocolatey\lib\zabbix-agent\tools\zabbix_agent-6.4.6-windows-amd64-openssl.zip to C:\Users\asomerset\AppData\Local\Temp\chocolatey\chocolatey\zabbix...
C:\Users\asomerset\AppData\Local\Temp\chocolatey\chocolatey\zabbix
Error installing Zabbix Agent
ERROR: Cannot create a file when that file already exists.
The upgrade of zabbix-agent was NOT successful.
Error while running 'C:\ProgramData\chocolatey\lib\zabbix-agent\tools\chocolateyInstall.ps1'.
See log for details.
Current workarounds that work - and do not seem to be entirely consistent:
- Stop Zabbix Agent Service and redo upgrade
- Stop Zabbix Agent Service, Delete the Bin files in Program Files/Zabbix Agent and redo upgrade
- In some even weirder edge cases when bin files can't be deleted (locked by event viewer process no less), stop, service, rename them and then run the upgrade