Plugins like Munin for cPanel comes handy for monitoring server resources.

However, customers may get errors due to improper installation or because of insufficient user permission on the server.

One of such error is HTTP error 401 cgi/addon_munin.cgi
WHM is configured to disallow execution of unregistered applications when logged in as root or a reseller with the “all” ACL.

At Bobcares, we often get requests from our customers to install Munin for cPanel as part of our Server Management Services.

Today, let’s get into the details on how our Support Engineers fix the related errors.

 

How we install Munin plugin for WHM

Munin is a Server Monitor plugin that used to monitor server resources such as Apache, Disk Usage, Exim, MySQL, Network, Processes. Also, it provides detailed reports on it.

Here, let’s see how our Support Engineers install Munin for cPanel.

1. Initially, we login to WHM.

2. We go to Home >> cPanel >> Manage Plugins.

3. Then, we click on Install “Munin for cPanel” button to install the Munin plugin.

 

4. Once the installation is completed, we will get a Process Complete message at the bottom of the screen.

That’s it. Now we have successfully installed the Munin plugin in WHM.

 

How we fixed the errors while installing Munin for cPanel

At Bobcares, where we have more than a decade of expertise in managing servers, we see many customers face problems while installing Munin for cPanel server.

Now, let’s see the major reasons for installation errors and how our Support Engineers fix this error.

 

1. Installation problems

Recently, one of our customers had a problem while installing the Munin plugin on the cPanel server. He could not install the Munin plugin and received an error like,

HTTP error 401 cgi/addon_munin.cgi
WHM is configured to disallow execution of unregistered applications when logged in as root or a reseller with the "all" ACL.

Usually, unregistered plugins throw up the above error. As a result, users may find problems when attempting to install Munin.

To fix this error we need to register the plugin first. So, our Support Engineers follow these steps.i

1. Firstly, we login to the server with SSH as a root user.

2. Then, we create the following folder if it doesn’t exist. Also, we set up the correct permission for the folder.

mkdir /var/cpanel/apps
chmod 755 /var/cpanel/apps

3. After that, we create a configuration file for the Munin plugin.

vi /var/cpanel/apps/addon_munin.conf

We add the following data too.

# name name=addon_munin
# Service that will serve this app service=whostmgr
# Physical path: /usr/local/cpanel/3rdparty/Foo.php
# Literal URL path: $server:$port/$cpsession/3rdparty/Foo.php url=/cgi/addon_munin.cgi
# System user to run process as user=root
# Required acls acls=any
# Display name as show in the service ui displayname=addon_munin

4. At last, we register the plugin with WHM by running the following command.

/usr/local/cpanel/bin/register_appconfig addon_munin.conf

To display all the currently registered plugins, we run the following command and verify that the Munin plugin is installed properly or not.

/usr/local/cpanel/bin/show_appconfig

This is how we fixed the error.

 

2. Insufficient permission

Similarly, another customer had a problem with the working of Munin.  He installed a new cPanel server on Cloudlinux. Since that time, the Munin plugin did not have full access to the system and showed variations in the Munin graphs values.

For example, the processes graph showed 10-32 active processes instead of 170 processes.

On checking, our Support Engineers found that Cloudlinux was restricting Munin from accessing the server to collect the information.

The virtualized filesystem was set up to prevent users from looking at the other users /proc/ processes. Since the user ‘munin‘ was a regular user, we checked and found that it could not see /proc/ for the root user.

To fix the problem, we had to add the gid of the munin user as the fs.proc_super_gid in /etc/sysctl.conf.  Further, we ran the command sysctl -p, the munin process was able to see all processes and threads on the system.

Finally, we restarted munin and the graphs started working again.

 

[Need assistance to fix plugin errors? We’ll help you.]

 

Conclusion

In short, Munin for cPanel is a very useful plugin for monitoring server resources. Sometimes, it may not work as we expect due to improper installation or because of insufficient user permission on the server. Today, we saw how our Support Engineers assisted our customers to solve this error.



Source link

Author

Write A Comment