mmm_control show gives incorrect suggestion when run as non-root

Bug #416586 reported by Walter Heck on 2009-08-20
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mysql-mmm
Undecided
Unassigned

Bug Description

When I run "mmm_control show" as a non-root user, i get the following error:

[openquery@mmm2-monitor ~]$ mmm_control show
2009/08/20 18:27:08 No config file mmm_mon.conf in /etc, /etc/mmm, /etc/mysql-mmm
2009/08/20 18:27:08 Could not find config file
Could not find config file at /usr/lib/perl5/vendor_perl/5.8.8/MMM/Common/Config.pm line 123

The problem here is not that there is no config file, but that the non-root user has no access rights to it:
[openquery@mmm2-monitor ~]$ ls -lha /etc/mysql-mmm
total 32K
drwxr-xr-x 2 root root 4.0K Aug 8 09:24 .
drwxr-xr-x 77 root root 4.0K Aug 20 16:36 ..
-rw-r----- 1 root root 716 Aug 8 09:29 mmm_common.conf
-rw-r----- 1 root root 327 Aug 8 10:09 mmm_mon.conf

This means that either the error message should be expanded, or, ideally mmm_control should check that it is running as root and complain when it isn't. Another thing is that it needs to check for access rights to the conf files and give the correct error.

Pascal Hofmann (pascalhofmann) wrote :

Changed log message for now. There were requests to make mmm runnable as non-root user.

Changed in mysql-mmm:
status: New → Fix Committed
Changed in mysql-mmm:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers