pixie icon indicating copy to clipboard operation
pixie copied to clipboard

pixie can not collect mysql data?

Open lddlww opened this issue 2 years ago • 2 comments

i installed pixie reference https://docs.px.dev/installing-pixie/install-guides/self-hosted-pixie/,after i deployed a test mysql in mysqlcloud namespace,and i used mysql client to access the test mysql and execute some dml,then i exec px run px/mysql_data ,but there is no info output

Pixie CLI
*******************************
* ENV VARS
*        PL_CLOUD_ADDR=dev.withpixie.dev
*******************************
Table ID: mysql_data
  TIME   SOURCE  DESTINATION  REMOTE PORT  REQ CMD  REQ BODY  RESP STATUS  RESP BODY  LATENCY


==>  Live UI: https://work.dev.withpixie.dev:443/live/clusters/kubernetes-admin@kubernetes?destination_filter=&max_num_records=1000&script=px%2Fmysql_data&source_filter=&start_time=-5m

so am i missing something? or how can i collect mysqlcloud namespace pods data?

lddlww avatar Oct 10 '23 08:10 lddlww

Hi @lddlww, can you please provide more information on the client and server in this test? The px/mysql_data script will filter out anything that doesn't originate from a pod (source). Could you be running the client process outside of a pod?

ddelnano avatar Oct 10 '23 14:10 ddelnano

can you please provide more information on the client and server in this test?

yes

kubectl get all -n mysqlcloud

NAME                         READY   STATUS    RESTARTS   AGE
pod/mysql-794776ccb5-rc876   1/1     Running   0          40h

NAME                     TYPE       CLUSTER-IP    EXTERNAL-IP   PORT(S)          AGE
service/mysql-nodeport   NodePort   10.96.0.182   <none>        3306:32143/TCP   40h

NAME                    READY   UP-TO-DATE   AVAILABLE   AGE
deployment.apps/mysql   1/1     1            1           40h

NAME                               DESIRED   CURRENT   READY   AGE
replicaset.apps/mysql-794776ccb5   1         1         1       40h

mysql -h10.96.0.182 -P3306 -p

mysql> show tables;
+----------------+
| Tables_in_test |
+----------------+
| t1             |
+----------------+
mysql> delete from t1 where id=1;
Query OK, 1 row affected (0.00 sec)
mysql> select sleep(5);
+----------+
| sleep(5) |
+----------+
|        0 |
+----------+
1 row in set (5.00 sec)
mysql> select version();
+-----------+
| version() |
+-----------+
| 5.7.43    |
+-----------+
1 row in set (0.00 sec)

mysql --version

mysql  Ver 8.0.34-0ubuntu0.22.04.1 for Linux on x86_64 ((Ubuntu))

i used mysql -h10.96.0.182 -P3306 -p to access mysqld pod,and do some sqls,but there nothing info in px/mysql_data within live UI or script output

lddlww avatar Oct 11 '23 01:10 lddlww