The decision to exclude services from the outdated services script’s check in cPanel is generally dangerous. However, there can be some situations that demand it.
In cPanel, the outdated services script plays a vital role in ensuring the security and stability of the server. It regularly scans for outdated software versions and alerts the administrator to update them promptly. However, there may be situations where certain services need to be excluded from this script’s check.
Excluding services from the outdated services script can be necessary for various reasons. One common scenario is when a particular service has been customized extensively and is running on a modified version that may not be compatible with the latest updates. In such cases, updating the service could potentially cause conflicts or disrupt the functionality of the customized components.
Another reason for excluding services from the script’s check could be that its developers no longer support or maintain the service. If a service has reached its end-of-life or is no longer actively updated, no updates may be available to apply. Including such services in the script’s check would only generate unnecessary alerts and notifications, leading to confusion and clutter in the monitoring system.
Here are the Steps:
- Log in to your server via SSH
- Create a directory under /etc/cpanel/local to exclude a service.
mkdir -p /etc/cpanel/local
- Next, create a file “ ignore_outdated_services “under /etc/cpanel/local/ and add services.
For example, you can use the below command to exclude lshttpd service from the outdated services script’s check.
echo -e "# Prevent cPanel from checking the lshttpd services\nlshttpd" >> /etc/cpanel/local/ignore_outdated_services
If the directory is already available, use a text editor, such as vim or nano, and open the “/etc/cpanel/local/ignore_outdated_services “ file and add services.
Services listed in the “/etc/cpanel/local/ignore_outdated_services” will be excluded. Run the outdated services script to check for outdated services. The services should now be ignored and not displayed on outdated services.
By carefully managing the exclusion of services from the outdated services script’s check, administrators can strike a balance between ensuring system security and stability while avoiding unnecessary updates or alerts for services that require special handling. It is essential, however, to regularly review the excluded services and reassess their status to ensure prompt implementation of necessary updates or alternative solutions.