A recent upgrade from cPanel / WHM 11.54 resulted in the services getting broken and not able to access the services. Was able to find the following in the logs when attempt to restart cPanel was made :
Can’t locate Unix/PID/Tiny.pm in @INC (you may need to install the Unix::PID::Tiny module) (@INC contains: /usr/local/cpanel /usr/local/cpanel/3rdparty/perl/522/lib64/
The perl module Unix::PID::Tiny
is missing which is causing the issues here. The fix would be to rebuild the RPM db.
Follow the steps given below to take backup of current RPM db and rebuild the RPM db:
cd /var/lib mv rpm{,.old} mkdir -p rpm rpm --initdb cp rpm.old/Packages rpm rpm --rebuilddb
Kill the hanging RPM or upcp processes if any with the kill -9 $PID command
. To find if there are any PIDs, run the following :
ps aux|grep rpm ps aux|grep upcp
Once this is done, try for an upgrade :
/scripts/check_cpanel_rpms --fix /scripts/upcp --force