This topic describes how to install OceanBase Diagnostic Tool (obdiag).
Environment requirements
- The server where obdiag is to be installed runs on Linux.
- A Python environment (Python 2.7.x or Python 3 to 3.9) exists on the server where obdiag is to be installed.
Prerequisites
Network access is available between the server where obdiag is to be installed and the target host whose information and logs are to be collected and analyzed.
Procedure
You can use obdiag independently or in combination with OceanBase Deployer (OBD).
Method 1: Use obdiag independently
If the cluster to be diagnosed is not deployed by using OBD, you can run the following commands to install and deploy obdiag:
Online deployment (when Internet access is available)
sudo yum install -y yum-utils sudo yum-config-manager --add-repo https://mirrors.aliyun.com/oceanbase/OceanBase.repo sudo yum install -y oceanbase-diagnostic-tool source /usr/local/oceanbase-diagnostic-tool/init.shOffline deployment (when Internet access is unavailable)
Download the latest version of obdiag from OceanBase Download Center.
yum install -y oceanbase-diagnostic-tool.*rpm source /usr/local/oceanbase-diagnostic-tool/init.sh
Method 2: Use obdiag in combination with OBD
If the cluster to be diagnosed is deployed by using OBD, we recommend that you upgrade OBD to V2.1.0 or later. Then, you can directly run obdiag commands on OBD. For more information about the commands, see obdiag commands.
Online deployment (when Internet access is available)
# Enable the remote image pull mode on OBD obd mirror enable remote # Deploy obdiag by using OBD obd obdiag deployOffline deployment (when Internet access is unavailable)
Download the latest version of obdiag from OceanBase Download Center.
# Copy the offline obdiag package to the image repository of OBD. obd mirror clone oceanbase-diagnostic-tool-xxxxxxxx.rpm # Deploy obdiag by using OBD obd obdiag deploy
