Uploaded image for project: 'Percona Monitoring and Management'
  1. Percona Monitoring and Management
  2. PMM-941

ParseSocketFromNetstat finds incorrect socket

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: High
    • Resolution: Fixed
    • Affects Version/s: 1.1.3
    • Fix Version/s: 1.9.0
    • Component/s: PMM Client
    • Labels:
    • Environment:

      CentOS Linux release 7.3.1611 (Core)

      Description

      The method used to find the mysqld socket can return an incorrect socket if there are other processes that contain "mysql" and use sockets (e.g. the VividCortex agent). For example:

      [e_benefits] root@fdb001.mp.prd.chi1: mysql # netstat -anp | grep ^unix | grep mysql
      unix 2 [ ACC ] STREAM LISTENING 225385314 28413/vc-mysql-metr /var/run/vividcortex/vc-mysql-metrics_31/ipc
      unix 2 [ ACC ] STREAM LISTENING 215855662 6009/mysqld /var/lib/mysql/mysql.sock
      unix 3 [ ] STREAM CONNECTED 248750213 28413/vc-mysql-metr /var/run/vividcortex/vc-mysql-metrics_31/ipc
      unix 2 [ ] STREAM CONNECTED 215853819 6009/mysqld
      unix 3 [ ] STREAM CONNECTED 225393890 28388/vc-mysql-quer
      unix 3 [ ] STREAM CONNECTED 225398052 28413/vc-mysql-metr
      unix 3 [ ] STREAM CONNECTED 248747275 28388/vc-mysql-quer

      In this case, theĀ /var/run/vividcortex/vc-mysql-metrics_31/ipc socket is used.

        Smart Checklist

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  Unassigned
                  Reporter:
                  daniel.kowalewski@percona.com Daniel Kowalewski (Inactive)
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  7 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Time Tracking

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - 0 minutes
                    0m
                    Logged:
                    Time Spent - 3 hours, 50 minutes
                    3h 50m