Author: Guo Aomen

DBLE team member, responsible for developing new features of distributed database middleware, answering general questions raised by the community/customers/internal.

Source of this article: original contribution

* Produced by the open source community of ecoson, the original content is not allowed to be used without authorization, please contact the small edition and indicate the source.

background

Kunpeng 920 processor is a high-performance data center processor released by Huawei in January 2019. It is independently developed and designed by Huawei to meet the needs of diverse computing and green computing in data centers. Kunpeng processor is based on ARM architecture.

ARM is a CPU architecture that differs from the CISC complex instruction set used in Intel&AMD CPUs. ARM CPU uses the Reduced Instruction Set Computer (RISC).

In recent years, in order to respond to the call of localization, more and more domestic manufacturers gradually use Huawei’s Kun Peng 920 server to replace the previous server. Recently, many community partners have encountered some problems when installing DBLE on Kunpeng’s server. Here is a summary of the installation steps.

steps

The GitHub documentation for DBLE “0.3 Quick Start” is a tutorial for installing x86 processor based servers. When installing DBLE on an ARM processor based server, you may report the following error:

[root@huawei bin]# ./dble start
Unable to locate any of the following operational binaries:
  /opt/dble/bin/./wrapper-linux-aarch64-64
  /opt/dble/bin/./wrapper-linux-aarch64-32
  /opt/dble/bin/./wrapper

In this case, we need to perform the following steps:

1. Complete the files required in the wrapper

  • Download and extract the ARM schema files from the Java Service Wrapper
Wget https://download.tanukisoftware.com/wrapper/3.5.40/wrapper-linux-armhf-64-3.5.40.tar.gz tar ZXVF Wrapper - Linux - armhf - 64-3.5.40. Tar. Gz
  • Copy bin/wrapper to dble/bin
  • Copy lib/libwrapper.so to dble/lib

2. Install the Kunpeng JDK

The environment variables and other issues are not discussed here. Google will solve them by itself (AdoptopenJDK website, compiler tool — AdoptopenJDK).

3. Start DBLE

Check wrapper.log for a log similar to the following to indicate that DBLE started successfully.

STATUS | wrapper | 2021/01/08 13:45:15 | --> Wrapper Started as Daemon STATUS | wrapper | 2021/01/08 13:45:15 | Java A Service Wrapper Community Edition 64 - bit 3.5.40 STATUS | Wrapper | 2021/01/08 13:45:15 | Copyright Tanuki (C) 1999-2019 Software, Ltd. All Rights Reserved. STATUS | wrapper | 2021/01/08 13:45:15 | http://wrapper.tanukisoftware.com STATUS | wrapper | 2021/01/08 13:45:15 | STATUS | wrapper | 2021/01/08 13:45:16 | Launching a JVM... INFO | jvm 1 | 2021/01/08 13:45:16 | Listening for transport dt_socket at address: 8088 INFO | jvm 1 | 2021/01/08 13:45:16 | WrapperManager: Initializing... INFO | jvm 1 | 2021/01/08 13:45:19 | Server startup successfully. dble version is [5.7.21 dble - 3.20.10.99 cdc0923be854d91a0f942a9027bef1454057bde3-20210107185349]. Both Please see logs in logs/dble. The log

4. Connection verification

View the shardingUser in the user.xml file and use the MySQL client to establish a connection. The connection is successful if the following conditions occur

[root@localhost ~]# mysql -uroot -p123456 -P8066 -hyour_ip
mysql: [Warning] Using a password on the command line interface can be insecure. Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 1 Server version: 5.7.11 dble - 3.20.10.0 - b29c7c91ac638509dbc4f2c146aea41c3f9f0b83-20201203053354 dble Server (ActionTech) Copyright (c) 2000, 2020, Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its affiliates. Other names may be trademarks of their respective owners. Type 'help; ' or '\h' for help. Type '\c' to clear the current input statement. mysql> show databases; + -- -- -- -- -- -- -- -- -- -- + | DATABASE | + -- -- -- -- -- -- -- -- -- -- + | testdb | + -- -- -- -- -- -- -- -- -- -- + 1 row in the set (0.04 SEC) mysql > use testdb; Database changed

Pay attention to

  • The version of Wrapper is 3.5.40. Any discrepancy in Wrapper will result in an error
INFO | jvm 1 | 2021/01/08 16:12:21 | WrapperManager: ERROR - The version of The Wrapper which launched this JVM is "3.5.42" INFO 1 | | JVM 2021/01/08 16:12:21 | WrapperManager: while the version of the Wrapper jar file currently in use INFO | jvm 1 | 2021/01/08 16:12:21 | WrapperManager: Is "3.5.40". The INFO 1 | | JVM 2021/01/08 16:12:21 | WrapperManager: STATUS | wrapper | 2021/01/08 16:12:23 | <-- Wrapper Stopped
  • JDK without Kunpeng version can be started successfully, but unexpected problems may occur in the actual use process (for example, when I met the ARM version JDK using Oracle before, DBLE can be started, but the queue cannot work and the task will be blocked).