How to uninstall a RPM correctly (answering a query).

martin MHC

Well-Known Member
Sep 14, 2016
338
75
78
UK
cPanel Access Level
Root Administrator
I have an RPM that needs to be removed; but the process that I have read about how to remove it did not seem to work:

Version: Copanel and WHM version 66.0.14
Server access command line via Putty.

RPM to remove: Webalizer stats.

Emails appear regularly stating:
The system detected problems with the following cPanel-provided files that the RPM controls:

RPM Status Additional Information
cpanel-webalizer-2.23_05-2.cp1136 Unnecessary

If you did not make these changes intentionally, execute the following command as the root user to correct them:

/usr/local/cpanel/scripts/check_cpanel_rpms --fix

So; I run the command above in Putty.

SIDE NOTE : If I move to the directory and run the command check_cpanel_rpms this is unrecognised; I have to be in the root and run the whole directory structure of the command above. Seems silly not being able to run the comand from the same directory.

But the command response says the same thing, stating it's found cpanel-webalizer as a broken RPM.
 

martin MHC

Well-Known Member
Sep 14, 2016
338
75
78
UK
cPanel Access Level
Root Administrator
HERE IS THE ANSWER:

HOWEVER: Please note that the fix command DOES remove the detailed RPM, even after stating that the RPM is an issue, it then proceeds to remove it.

I missed this vital nugget of text reading the Command line output, and proceeded to try and uninstall the RPM via Yum.

If you do need to use Yum, the correct method is to do:

:: yum remove <RPM name>

such as yum remove cpanel-webalizer-2.23_05-2.cp1136
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463

martin MHC

Well-Known Member
Sep 14, 2016
338
75
78
UK
cPanel Access Level
Root Administrator
Hello Michael,
I had disabled Webalizer but then was getting persistent emails from the system tellingme it wasn't working so felt it best to uninstall it.

Cheers
Martin
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello,

It's possible something on your server was modifying the default Webalizer installation as provided by cPanel (through a post upcp hook or in /scripts/postupcp).

Thank you.