With this suite, you can run a performance test with a single click after a simple configuration. This topic describes how to install the AHBench-jenkins test suite on an ECS instance and run a performance test.
Prerequisites
Ensure that your ECS instance meets the following requirements:
-
Located in the same VPC as the Lindorm instance.
-
(Recommended) The ECS instance has 16 vCPUs or more.
-
Linux operating system.
-
JDK 1.8 or later.
-
Python 2.7.
Notes
-
The instance under test may experience high loads during the stress test. Do not run this test suite in a production environment.
-
The test suite runs only one test set at a time, and tasks within a set are executed serially. Do not run other test tasks in parallel.
-
The test suite uses the
ahbenchtest-readandahbenchtest-writetables for testing. These tables may be deleted and recreated during the test. Ensure that these tables can be safely deleted. -
Ensure that the instance under test has sufficient storage space.
-
ECS instances run in a virtualized environment. Performance test results for the same instance type may fluctuate by 5% to 10%, which is within the expected range.
-
Before you start the service, ensure that you have configured the ECS security group to allow inbound access on port 8080. Otherwise, you cannot access the AHBench-jenkins service.
Before you begin
-
Add the primary private IP address of the ECS instance to the whitelist of the Lindorm instance. For more information, see Set a whitelist.
-
Configure the ECS security group to allow inbound access on port 8080.
-
Download the AHBench-jenkins test suite, upload it to your ECS instance, and decompress the package.
Step 1: Start the service
-
Start the AHBench-jenkins service.
# Use the following command to set the port for the suite. The default port is 8080.
cd AHBench-jenkins-v1.0.0
./start.sh 8080
-
In a web browser, access the service by entering the public endpoint of the ECS instance and the service port number in the format http://<ip>:<port>.
http://47.96.XX.XX:8080
Step 2: Select a test set template
-
Click a test set template.
Test set templates include FastTest and FullTest.
-
FastTest: Contains 10 million data entries. The test runs for about 2 hours, depending on the instance specifications, and requires at least 25 GB of storage space.
-
FullTest: Contains 2 billion data entries. The test runs for about 25 hours, depending on the instance specifications, and requires at least 2 TB of storage space.
-
-
After you select a test set template, click Build with Parameters in the left-side navigation pane to configure the test task.
Step 3: Configure the test task
Required configurations
Lindorm
|
Parameter |
Description |
How to obtain |
|
cluster_addr |
The HBase Java API endpoint for the wide table engine of the Lindorm instance. |
On the Database Connection page of the Lindorm console, click Wide Table Engine to view the HBase Java API endpoint. If AHBench-jenkins is deployed on an ECS instance in the same VPC, use the internal endpoint. Otherwise, enable and use the public endpoint. |
|
username |
The database user for accessing the Lindorm instance. Ensure that the user has global read, write, admin, trash, and system permissions. |
In the cluster management system, click to grant permissions to the user. For more information, see Log on to the cluster management system and Manage ACL permissions. |
|
password |
The password for the database user. |
If you forget the password, you can reset it in the cluster management system for the wide table engine. Click to change the password. For more information, see Log on to the cluster management system and Manage users. |
HBase Performance-enhanced Edition
|
Parameter |
Description |
How to obtain |
|
cluster_addr |
The Java API endpoint of the ApsaraDB for HBase Performance-enhanced Edition instance. |
On the Database Connection page of the ApsaraDB for HBase console, you can find the Java API Access Address in the Connection Information section. If AHBench-jenkins is deployed on an ECS instance in the same VPC, use the internal endpoint. Otherwise, request and use a public endpoint. |
|
username |
The database user for accessing the ApsaraDB for HBase Performance-enhanced Edition instance. Ensure that the user has global read, write, admin, trash, and system permissions. |
In the cluster management system, click to grant permissions to the user. For more information, see Log on to the cluster management system and Manage ACL permissions. |
|
password |
The password for the database user. |
If you forget the password, you can reset it in the cluster management system. Click to change the password. For more information, see Log on to the cluster management system and Manage users. |
HBase Standard Edition
|
Parameter |
Description |
How to obtain |
|
cluster_addr |
The ZooKeeper connection string for the ApsaraDB for HBase Standard Edition instance. |
On the Database Connection page of the ApsaraDB for HBase console, you can find the Java API Access Address in the Connection Information section. If AHBench-jenkins is deployed on an ECS instance in the same VPC, use the internal endpoint. Otherwise, request and use a public endpoint. |
General configurations (optional)
Step 4: Start the test
Click the BUILD button to submit the test task to the execution queue.
Step 5: Analyze test results
After the test cases finish running, a CSV file is generated. View and download the file in your browser.
The generated files include result files for each test case (batchwrite.csv, scan.csv, singleread.csv, singlewrite.csv, and workloada.csv to workloadf.csv), the test parameter file (test_params.csv), and the summary result file (total_result.csv).
Copy the data to a data analysis application, such as Excel or Numbers, for further analysis. The following example shows the results in a CSV file.
TestName,OperationType,Throughput(rows/s),AverageLatency(us),P95Latency(us),P99Latency(us),P999Latency(us)
batchwrite,BATCH,101437.0,125750.6753771419,210431.0,254463.0,314111.0
scan,SCAN,1655724.0,7704.259769699419,21295.0,58655.0,85887.0
singleread,READ,75501.0,1689.6162362271912,2044.0,2669.0,22415.0
singlewrite,INSERT,42512.0,3001.4856138550078,4483.0,9263.0,50271.0
workloada,READ,26010.0,1996.9924856520854,2789.0,4135.0,27535.0
workloada,UPDATE,26011.0,2907.7582520171654,3963.0,5891.0,31071.0
workloadb,READ,59728.0,1989.3114753677578,2771.0,3699.0,19631.0
workloadb,UPDATE,3150.0,2770.810318072335,4025.0,5311.0,22783.0
workloadc,READ,67388.0,1892.5555709970954,2555.0,3433.0,17103.0
workloadd,READ,61513.0,1926.9758923129186,2717.0,3705.0,15391.0
workloadd,INSERT,3237.0,2781.8499603085943,4055.0,5623.0,18815.0
workloade,INSERT,188.0,4851.740461394097,13071.0,48319.0,109183.0
workloade,SCAN,349277.0,26626.44060447983,68415.0,417535.0,463615.0
workloadf,READ,28806.0,2688.784531208804,4383.0,10071.0,55967.0
workloadf,UPDATE,14402.0,3481.2656232319496,5551.0,8895.0,55455.0
workloadf,READ-MODIFY-WRITE,14402.0,6398.633906954003,9551.0,24639.0,66623.0
Troubleshooting
If a test exits with an error, check the following:
-
Java and Python are installed with the correct versions.
-
The test instance address and required configurations are correct.
-
The test instance supports the specified compression algorithm.
-
The test instance is running correctly.