@@ -82,9 +82,10 @@ table_id table_name comment
82
82
35 table_fragments_all Partitions of the tables
83
83
36 table_replicas_all Fragment replicas of the tables
84
84
37 stored_tables Information about stored tables
85
+ 38 processes Process ID and Name information for connected nodes
85
86
SELECT COUNT(*) FROM ndb$tables;
86
87
COUNT(*)
87
- 38
88
+ 39
88
89
SELECT * FROM ndb$tables WHERE table_id = 2;
89
90
table_id table_name comment
90
91
2 test for testing
@@ -122,6 +123,7 @@ table_id table_name comment
122
123
35 table_fragments_all Partitions of the tables
123
124
36 table_replicas_all Fragment replicas of the tables
124
125
37 stored_tables Information about stored tables
126
+ 38 processes Process ID and Name information for connected nodes
125
127
SELECT * FROM ndb$tables WHERE table_name = 'LOGDESTINATION';
126
128
table_id table_name comment
127
129
SELECT COUNT(*) FROM ndb$tables t, ndb$columns c
@@ -162,6 +164,7 @@ table_id table_name
162
164
9 nodes
163
165
14 operations
164
166
3 pools
167
+ 38 processes
165
168
7 resources
166
169
21 restart_info
167
170
37 stored_tables
@@ -252,6 +255,7 @@ table_id
252
255
35
253
256
36
254
257
37
258
+ 38
255
259
256
260
TRUNCATE ndb$tables;
257
261
ERROR HY000: Table 'ndb$tables' is read only
@@ -1638,3 +1642,61 @@ node_id DataMemory
1638
1642
1 20M
1639
1643
2 20M
1640
1644
1645
+ desc ndb$processes;
1646
+ Field Type Null Key Default Extra
1647
+ reporting_node_id int(10) unsigned YES NULL
1648
+ node_id int(10) unsigned YES NULL
1649
+ node_type int(10) unsigned YES NULL
1650
+ host_addr varchar(512) YES NULL
1651
+ node_version varchar(512) YES NULL
1652
+ process_id int(10) unsigned YES NULL
1653
+ angel_process_id int(10) unsigned YES NULL
1654
+ process_name varchar(512) YES NULL
1655
+ connection_name varchar(512) YES NULL
1656
+ application_port int(10) unsigned YES NULL
1657
+ show create table processes;
1658
+ View Create View character_set_client collation_connection
1659
+ processes CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY INVOKER VIEW `processes` AS select distinct `ndb$processes`.`node_id` AS `node_id`,(case `ndb$processes`.`node_type` when 0 then 'NDB' when 1 then 'API' when 2 then 'MGM' else NULL end) AS `node_type`,`ndb$processes`.`host_addr` AS `host_addr`,`ndb$processes`.`node_version` AS `node_version`,nullif(`ndb$processes`.`process_id`,0) AS `process_id`,nullif(`ndb$processes`.`angel_process_id`,0) AS `angel_process_id`,`ndb$processes`.`process_name` AS `process_name`,`ndb$processes`.`connection_name` AS `connection_name`,nullif(`ndb$processes`.`application_port`,0) AS `application_port` from `ndb$processes` latin1 latin1_swedish_ci
1660
+
1661
+ SELECT reporting_node_id, node_id, node_type, process_name, connection_name
1662
+ FROM ndb$processes
1663
+ ORDER BY reporting_node_id, node_id;
1664
+ reporting_node_id node_id node_type process_name connection_name
1665
+ 1 1 0 ndbmtd
1666
+ 1 3 2 ndb_mgmd
1667
+ 1 16 1 mysqld mysqld --server-id=2
1668
+ 1 32 1 mysqld mysqld --server-id=2 (connection 2)
1669
+ 1 48 1 mysqld mysqld --server-id=2 (connection 3)
1670
+ 1 49 1 mysqld mysqld --server-id=1
1671
+ 1 63 1 mysqld mysqld --server-id=1 (connection 2)
1672
+ 1 127 1 mysqld mysqld --server-id=1 (connection 3)
1673
+ 2 2 0 ndbmtd
1674
+ 2 3 2 ndb_mgmd
1675
+ 2 16 1 mysqld mysqld --server-id=2
1676
+ 2 32 1 mysqld mysqld --server-id=2 (connection 2)
1677
+ 2 48 1 mysqld mysqld --server-id=2 (connection 3)
1678
+ 2 49 1 mysqld mysqld --server-id=1
1679
+ 2 63 1 mysqld mysqld --server-id=1 (connection 2)
1680
+ 2 127 1 mysqld mysqld --server-id=1 (connection 3)
1681
+
1682
+ SELECT node_id,
1683
+ node_type,
1684
+ process_name,
1685
+ if(process_id is null, "null", "not_null") as proc_id,
1686
+ if(angel_process_id is null, "null", "not_null") as angel_proc_id,
1687
+ process_name,
1688
+ connection_name,
1689
+ if(application_port is null, "null", "not_null") as port
1690
+ FROM processes
1691
+ ORDER BY node_id;
1692
+ node_id node_type process_name proc_id angel_proc_id process_name connection_name port
1693
+ 1 NDB ndbmtd not_null not_null ndbmtd null
1694
+ 2 NDB ndbmtd not_null not_null ndbmtd null
1695
+ 3 MGM ndb_mgmd not_null null ndb_mgmd not_null
1696
+ 16 API mysqld not_null null mysqld mysqld --server-id=2 not_null
1697
+ 32 API mysqld not_null null mysqld mysqld --server-id=2 (connection 2) not_null
1698
+ 48 API mysqld not_null null mysqld mysqld --server-id=2 (connection 3) not_null
1699
+ 49 API mysqld not_null null mysqld mysqld --server-id=1 not_null
1700
+ 63 API mysqld not_null null mysqld mysqld --server-id=1 (connection 2) not_null
1701
+ 127 API mysqld not_null null mysqld mysqld --server-id=1 (connection 3) not_null
1702
+
0 commit comments