Community Blog The Microservices Engine (MSE) Diagnostic Tool Has Launched

The Microservices Engine (MSE) Diagnostic Tool Has Launched

This article discusses how to use the MSE diagnostic tool to find problems on the client.

By Zikui


Clients may fail to connect to the Microservices Engine (MSE) cluster in daily development and production environments due to network failure or other factors. If this is the case, you need to check the status of the cluster and the client. In most cases, you need to query the corresponding exception interpretation in the document to locate the problem, which is complicated and time-consuming. Therefore, MSE provides a quick diagnostic tool to find problems on the client → server link and provide suggestions, making troubleshooting faster.

Easy to Get Started

In daily use, there may be an exception log that says the MSE instance port and the client port are unavailable.


At this time, we can use mseutil to diagnose network problems quickly.

1.  Download the mseutil tool of the corresponding platform through the documentation. The tool is an independent binary package that can run independently. Then, you can obtain the serverAddr of the MSE instance on the details page.


2.  Run the following command to perform a quick diagnosis:

mseutil {subproduct name} inspect --serverAddr mse-xxxxx.aliyuncs.com

Diagnostics include basic network issue diagnostics and API diagnostics. Network issue diagnostics tests whether the network connection between the client environment and the MSE instance is available and whether the port is accessible. API diagnostics tests APIs of different sub-products. It mainly tests the availability of APIs and the latency of API calls.

mseutil zookeeper inspect --serverAddr mse-xxx-p.zk.mse.aliyuncs.com
mseutil nacos inspect --serverAddr mse-xxx-p.zk.mse.aliyuncs.com


At this time, we know that the DNS resolution is normal, but there is a problem with the network connection. We can find that the public network whitelist is not configured according to the exception description in the document. In this case, we only need to configure the public network whitelist.

If all goes well, the following results will be output:


Based on the diagnosis results, we can see that the network between the client environment and the MSE instance is not connected. Then, we can troubleshoot the specific causes through the corresponding documents of MSE. The diagnostic procedure of Nacos is the same as that of ZooKeeper.

Operations on MSE Instance

mseutil provides the ability to do operations on the data of MSE instances. It is compatible with zkCli and provides the Four Letter Word query capability. For specific usage, -h can be used to query the usage method. mseuti also supports querying and modifying Nacos service information and configuration information, making it easier to troubleshoot problems in online environments. mseutil can run independently on Windows, Linux, and OSX in x86 and arm64 environments with no complicated environment configuration, so it is easy to use.

Support for Querying Server Status with Four Letter Words and Compatibility With zkCli

mseutil supports the Four Letter Words of ZooKeeper. For example, you can query the summary of the current status of the Server through the following command:

mseutil zookeeper 4lw --serverAddr mse-xxx.aliyuncs.com stat


mseutil supports all Four Letter Words of ZooKeeper. You can view the specific usage through mseuitl zookeeper 4lw -h.

mseutil is compatible with zkCli and allows you to query and modify the data in MSE ZooKeeper.

For example, you can query the Znode data of the corresponding Path in the instance with the following command:

mseutil zookeeper get --serverAddr=mse-xxxx.aliyuncs.com /zookeeper

mseutil also supports commands (such as set, delete, ls, and stat) for more help through mseutil zookeeper -h.

Support for Querying and Updating Service Information of Nacos Instances

mseutil supports quick diagnostics of Naocs and basic instance query and instance registration features.

Quick diagnostics:

mseutil nacos inspect --serverAddr ${Instance Connection Address}


Querying the list of service instances:

mseutil nacos get instance -n ${namespaceId} -s ${serviceName} -g ${groupName}

Registering the instance of the corresponding service:

mseutil nacos create instance <IP>:<PORT> -n ${namespaceId} -s ${serviceName} -g ${groupName} -c ${clusterName}

In addition, the diagnostics tool supports the Nacos 1.x client protocol and the Nacos 2.x client protocol. These two protocols can be switched by parameters:

mseutil nacos get instance -s ${serviceName} --v2

This way, all basic scenarios on the client can be fully covered, reducing the cost of troubleshooting.


mseutil will support more MSE sub-products and more fine-grained and intelligent diagnostic capabilities (including network message analysis from clients to MSE instances, client load status analysis, resource occupancy level of specific applications, and GC analysis) to help users more easily troubleshoot problems during the use of MSE products and improve O&M efficiency.

0 1 0
Share on

Alibaba Cloud Native

135 posts | 12 followers

You may also like


Alibaba Cloud Native

135 posts | 12 followers

Related Products