Not the answer you need?
Register and ask your own question!

monitor multiple mysql instance on one server but no data

liangyu5017liangyu5017 ContributorInactive User Role Novice


I monitored multiple mysql instances on one server:

Pmm-admin add mysql --user PMM --password PMM --socket= XXX 1.1.1.1-3308

Pmm-admin add mysql --user PMM --password PMM --socket= XXX 1.1.1.1-3309

Pmm-admin add mysql --user PMM --password PMM --socket= XXX 1.1.1.1-3310

And add Linux :metric

PMM - admin add Linux: metric 1.1.1.1

Now there is no data in the buffer pool size of total ram in the mysql overview of the monitoring interface. Does the mysql instance 1.1.1.1-3308 need to read the data of Linux :metric 1.1.1.1-3308? But what I added is the data of Linux :metric 1.1.1.1?

I tried to add more Linux :metric X.X.X.X, but the system could only add one.How can you make buffer pool size of total ram of multiple instances display data normally

Comments

  • Michael CoburnMichael Coburn Principal Architect, Percona Percona Staff Role
    Hi liangyu5017

    Based on the way you added hosts you probably have 3 hosts in the MySQL dashboards, and one host in the OS dashboards.

    PMM is limited to how many times you can use a friendly name, that is by default the hostname but you can override it. As an example I've added the same MySQL instance multiple times while changing the friendly name (ps1, ps2, ps3):
    [root@ip-10-178-0-149 ~]# pmm-admin add mysql:metrics --socket=/tmp/PS_NODE_1.sock ps1
    OK, now monitoring MySQL metrics using DSN root:***@unix(/tmp/PS_NODE_1.sock)
    [root@ip-10-178-0-149 ~]# pmm-admin add mysql:metrics --socket=/tmp/PS_NODE_1.sock ps2
    OK, now monitoring MySQL metrics using DSN root:***@unix(/tmp/PS_NODE_1.sock)
    [root@ip-10-178-0-149 ~]# pmm-admin add mysql:metrics --socket=/tmp/PS_NODE_1.sock ps3
    OK, now monitoring MySQL metrics using DSN root:***@unix(/tmp/PS_NODE_1.sock)
    [root@ip-10-178-0-149 ~]# pmm-admin list
    pmm-admin 1.17.0
    
    PMM Server      | 127.0.0.1
    Client Name     | ip-10-178-0-149
    Client Address  | 172.17.0.1
    Service Manager | linux-upstart
    
    -------------- ----- ----------- -------- ----------------------------------- --------
    SERVICE TYPE   NAME  LOCAL PORT  RUNNING  DATA SOURCE                         OPTIONS
    -------------- ----- ----------- -------- ----------------------------------- --------
    mysql:metrics  ps1   42002       YES      root:***@unix(/tmp/PS_NODE_1.sock)
    mysql:metrics  ps2   42003       YES      root:***@unix(/tmp/PS_NODE_1.sock)
    mysql:metrics  ps3   42004       YES      root:***@unix(/tmp/PS_NODE_1.sock)
    

    However with Linux metrics you can only add this service once per instance, even if you try to use a different friendly name:
    [root@ip-10-178-0-149 ~]# pmm-admin add linux:metrics ps1
    OK, now monitoring this system.
    [root@ip-10-178-0-149 ~]# pmm-admin add linux:metrics ps2
    Error adding linux metrics: there is already one instance with this name under monitoring.
    [root@ip-10-178-0-149 ~]# pmm-admin list
    pmm-admin 1.17.0
    
    PMM Server      | 127.0.0.1
    Client Name     | ip-10-178-0-149
    Client Address  | 172.17.0.1
    Service Manager | linux-upstart
    
    -------------- ----- ----------- -------- ----------------------------------- --------
    SERVICE TYPE   NAME  LOCAL PORT  RUNNING  DATA SOURCE                         OPTIONS
    -------------- ----- ----------- -------- ----------------------------------- --------
    linux:metrics  ps1   42000       YES      -
    mysql:metrics  ps1   42002       YES      root:***@unix(/tmp/PS_NODE_1.sock)
    mysql:metrics  ps2   42003       YES      root:***@unix(/tmp/PS_NODE_1.sock)
    mysql:metrics  ps3   42004       YES      root:***@unix(/tmp/PS_NODE_1.sock)
    

    You can see InnoDB Buffer Pool Size when looking at the MySQL instances you added ,not the linux instance name.

    I hope this helps - did I miss answering any questions?
  • liangyu5017liangyu5017 Contributor Inactive User Role Novice
    Please look at the following two pictures:Master and slave are on the same host,As you can see, the master's buffer size of total ram is normal,but the backup's buffer size of total ram is no value.

    Is this a bug? or Will you make improvements in the next version?
  • Michael CoburnMichael Coburn Principal Architect, Percona Percona Staff Role
    Hi liangyu5017
    That looks more like a bug. Can you open the SingleStat object and go to Query Inspector? I think you'll find an error, please share that with us so we can continue troubleshooting. Thanks!
Sign In or Register to comment.

MySQL, InnoDB, MariaDB and MongoDB are trademarks of their respective owners.
Copyright ©2005 - 2020 Percona LLC. All rights reserved.