Agent Plugin - mk_mysql - no service discovery

Hello,

TL;DR: I am using checkmk 2.0.0p5. New services are not discovered for an alreday configured and monitored host.

  • The Plugin “mk_mysql” is installed on a mysql server (OS: Oracle Solaris)
  • The Plugin is executed when the agent is run locally on the system.
  • The output of mk_mysql ist not visible in the “connection test”-tab for the configured host
  • → Services are not discovered

Additional testing:

  • the plugin “netstat.solaris” is installed on the server
  • The Plugin is executed when the agent is run locally on the system.
  • The output of “netstat.solaris” is visible in the “connection test”-tab for the configured host
  • → Services are not discovered

I have no idea what to do.

Addition: a “Full service scan” finishes after 2.5 Seconds syaing "no new services discovered but:
when the agent is run locally it takes 4 seconds to complete.

Kind regards,

sefr

First make sure your software is up-to-date. That is 2.0.0p16 at the time of writing.

Have you double-checked that you are talking to the right host?

Hello,

1.) I understand the standardized approach but I ask myself if this is going to help.
In my experience this is just a waste of time.
In a desktop support scenario I would respond the same way.

Nevertheless: I will update my installation and the agent and the plugin.

2.) The ip adress that is used is correct. The server is talking to the right host.

Gruß,

sefr

Sounds like an issue with the path. Is the mysqladmin in a path where the mk_mysql plugin can find it when called remote? When logged in to the client machine, you may have different settings.

Simple test, find out where mysqladmin resides and then edit mk_mysql. Add, at the beginning (after the line: #!/bin/bash) something like this:

export PATH=$PATH:<location of mysqladmin>

Then see if it works.

Louis.

1 Like

Hello,

thanks for your reply, indeed that was the problem!
I feel so stupid, that is such a standard issue/problem, I should have looked for it.
Cannot believe I did not see that, spent hours trying to fix this.

I assumed because the Solaris agent works and MySQL is installed via paakcge manager that the PATH should be included in the environment when the agent is run but of course it did not.

Your help is very much appreciated. Thanks alot.

Solution: Make sure to use the full path für MySQL command in an plugin.

Question regarding netstat: Does the output of the plugin netstat.solaris appear under “TCP Connections” in the web interface?
I think so, is that correct?

Here I also updated the script so that the full path to netstat is used although that is a “standard path” (/usr/bin)

Kind regards,

sefr

Hi,

Don’t feel stupid about it. I just remembered because it recently took me several hours as well to figure it out.

As for your netstat question I don’t know; I don’t have Solaris, nor use the plugin. But it should work without updating the path; /usr/bin should be found. And you mention that you do have output in the connection test tab so looks like it’s executed. Maybe you need to create a rule for it? Sorry, really can’t help you there.

Louis.

Hi,

I guess the output was already there before and show up under “TCP Connections”. I do not know.
Yes, it should be found under /usr/bin as that should be avaiblabe as standard path.

I see you alerady marked your answer as solution, thanks.

kind regards,

sefr

I did. :slight_smile:

Oh I see.
Thank you Robin.

Kind regards

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed. Contact an admin if you think this should be re-opened.