Managing Slow Queries and Scripts Using cPFence Owl™

Do you miss the CloudLinux and CageFS features you had in cPanel after switching to the Enhance control panel? No worries—cPFence Owl™ has you covered. With its advanced monitoring and resource management tools, Owl™ automatically handles slow queries, poorly written scripts, and resource-hungry processes, helping you maintain optimal server performance without the need for manual intervention.

This guide will show you how to configure this feature.

Step 1: Review the High Load Notification

When you receive a high load notification from the cPFence Owl™ module, check the attached details in the notification email. These will help you identify any user or process that is causing excessive load on your server.

Step 2: Add Abusive Users to the Blacklist

If you identify any user abusing server resources, you can automatically terminate their hung processes or long-running MySQL queries by adding their username to the blacklist. To do this, edit the following file:

/opt/cpfence/config.conf

In the file, add the user's username to the blacklist in the following format:

BLACKLISTED_USERS="Username1_|Username2_|Username3_"
MAX_EXECUTION_DURATION="30"

This will ensure that any process or MySQL query from the blacklisted user that exceeds the maximum execution time (e.g., 30 seconds) will be automatically terminated, freeing up server resources.

 

Is It Recommended to Apply This Feature for All Users?

No, because some "good" scripts sometimes require more time to complete certain tasks and will barely cause any issues to server load. On the other hand, poorly written scripts, plugins, and themes can cause serious problems. It’s recommended to only apply this feature to users who are abusing server resources to avoid unnecessary disruptions.

Can This Feature Cause Issues for Sites and Configurations?

No, it will only stop long, slow queries, helping you manage server resources more efficiently. Users will not even notice it happening. However, it’s always a good practice to communicate with your client and discuss ways they can improve their scripts, plugins, and themes to avoid such issues in the future.

 


Need Further Assistance?

If you encounter any issues or need additional help, feel free to reach out to our support team via your client portal.

  • 0 Пользователи нашли это полезным
Помог ли вам данный ответ?

Связанные статьи

How to Enable / Disable cPFence Owl™ ?

cPFence Owl™ is a smart 24/7 monitoring system that provides advanced security features,...

What is cPFence Owl™ / DDos Protection ?

cPFence Owl Monitoring Features cPFence Owl™ offers comprehensive monitoring features to keep...