You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am running a CentOS 8.3.2011 system on which I am attempting to install the PagerDuty Agent. However, problems were encountered both during the installation and the removal process. During installation, the postinst script appears to fail at line 68 with the following message:
chmod: cannot access '/usr/lib/python3/site-packages/pdagent/root_certs': No such file or directory
warning: %post(pdagent-1.7.3-1.noarch) scriptlet failed, exit status 1
As a result of this failure, the startup script for the service fails to deploy, and the service is not started. The cause of this problem is the version detection logic in lines 58-65. As found in makepkg.sh:106-110, the directories bundled into the RPM are as follows:
/usr/lib/python2.7/site-packages
/usr/lib/python3.6/site-packages
/usr/lib/python3.7/site-packages
In contrast, the postinst script selects between the following directories:
/usr/lib/python3/site-packages/pdagent
/usr/lib/python2.7/site-packages/pdagent
/usr/lib/python2.6/site-packages/pdagent
Of the above directories, only hosts using python2.7 will successfully install.
During removal, the prerm script appears to fail at line 43 with the following message:
File "<string>", line 1
import platform; print platform.python_version()
^
SyntaxError: invalid syntax
error: %preun(pdagent-1.7.3-1.noarch) scriptlet failed, exit status 1
Because the preflight checks fail, it is not possible to gracefully uninstall the RPM using yum. The purpose behind this logic (specifically line 59) appears to be the removal of the compiled python libraries, performed at postinst:71. A fix for this would be to use the version detection logic from postinst:58-65 in place of the version present in prerm:43-48, once the version in postinst is corrected. However, this doesn't take into consider the possibility of the default version of python being switched post installation. As such, the 'correct' fix would be to remove all .pyc files from all three installation directories.
The text was updated successfully, but these errors were encountered:
I am running a CentOS 8.3.2011 system on which I am attempting to install the PagerDuty Agent. However, problems were encountered both during the installation and the removal process. During installation, the postinst script appears to fail at line 68 with the following message:
As a result of this failure, the startup script for the service fails to deploy, and the service is not started. The cause of this problem is the version detection logic in lines 58-65. As found in makepkg.sh:106-110, the directories bundled into the RPM are as follows:
In contrast, the postinst script selects between the following directories:
Of the above directories, only hosts using python2.7 will successfully install.
During removal, the prerm script appears to fail at line 43 with the following message:
Because the preflight checks fail, it is not possible to gracefully uninstall the RPM using yum. The purpose behind this logic (specifically line 59) appears to be the removal of the compiled python libraries, performed at postinst:71. A fix for this would be to use the version detection logic from postinst:58-65 in place of the version present in prerm:43-48, once the version in postinst is corrected. However, this doesn't take into consider the possibility of the default version of python being switched post installation. As such, the 'correct' fix would be to remove all .pyc files from all three installation directories.
The text was updated successfully, but these errors were encountered: