百度智能云

All Product Document

          Intelligent Edge

          FAQs

          This article mainly provides questions and solutions related to deployment and activation of Baidu IntelliEdge (BIE) in all systems and platforms.

          Question 1: When Baidu IntelliEdge (BIE) is started in the container mode, it prompts that it lacks startup dependency configuration file.

          docker-engine-conf-miss.png

          Reference solution: As shown in the figure above, it prompts that the service lacks startup dependency configuration file. See GitHub-BAETYL example folder to supplement the corresponding configuration file (located in etc /baetyl/conf.yml).

          Question 2: after the command docker info is entered under Ubuntu/Debian, the following information is displayed: "WARNING: No swap limit support"

          Reference solution:

          1. Modify the /etc/default/grub file and edit or add GRUB_CMDLINE_LINUX in it as follows:

          GRUB_CMDLINE_LINUX="cgroup_enable=memory swapaccount=1"

          1. Execute the command sudo update-grub after saving it. After completion, it will take effect when the system is re-started.

          Note: If an error is prompted when step 2 is performed, it may be due to incorrect setting of grub. Please check it and repeat steps 1 and 2.

          Question 3: the following information is prompted when Baetyl service is started: "WARNING: Your kernel does not support swap limit capabilities. Limitation discarded".

          Reference solution: See question 2.

          Question 4: The following information is prompted when Baetyl service is started:"Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.38/images/json: dial unix /var/run/docker.sock: connect: permission denied".

          Reference solution:

          1. Provide administrator privileges
          2. Add the current user to the docker user group through the following command

            sudo usermod -aG docker ${USER} su - ${USER}

          If it prompts that there is no docker group, use the following command to create a new docker user group and then execute the above command:

          sudo groupadd docker 

          Question 5: the following information is prompted when Baidu IntelliEdge (BIE) service is started: "Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?".

          Reference solution: If it is still reported after the solution for question 4 is implemented, restart the docker service.

          For example, start the command under CentOS:

          systemctl start docker 

          Question 6: the following information is prompted when Baidu IntelliEdge (BIE) service is started:"failed to create master: Error response from daemon: client version 1.39 is too new. Maximum supported API version is 1.38".

          Reference solution: Set an environment variable ‘DOCKER_API_VERSION=1.38’.

          For specific settings, see the following method:

          sudo vim ~/.bash_profile 
          export DOCKER_API_VERSION=1.38 
          source ~/.bash_profile 

          Question 7: how does Baidu IntelliEdge (BIE) use NB-IoT to connect to Baidu AI Cloud management suite or IoT Hub?

          Reference solution: NB-IoT is a network standard which is similar to 2/3/4G, with narrow bandwidth and low power consumption. NB-IoT supports TCP-based MQTT communication protocols, so NB-IoT card can be used to connect to Baidu AI Cloud IoT Hub and deploy Baidu IntelliEdge (BIE) applications and BIE cloud management communication. However, among the three major domestic network service operators, China Telecom restricts their NB cards and only allows it to be connected to the cloud service IP of China Telecom, so currently only China Mobile NB cards and China Unicom NB cards can be used to connect to Baidu AI Cloud services.

          Question 8: Does Baidu IntelliEdge (BIE) send the result to Kafka after it supports data computing?

          Reference solution: Yes, you can see the article How to write Python Script for Python operation, subscribe to messages in Hub, and write the messages to Kafka one by one. You can also see How to develop a Baetyl custom module. The module is used to subscribe to messages in Hub and write them to Kafka in batches.

          Question 9: How to change Baidu IntelliEdge (BIE) configuration? Can the configuration only be changed through Cloud management suite?

          Reference solution: Currently, we recommend you to use the cloud management suite to define and distribute configurations, but you can also manually change the configuration files on the core device and then restart the service to make it effective.

          Question 10: I downloaded the Linux MQTTBOX client and placed the executable file in the /usr/local/bin directory after decompressing (other loading directories for starting the system are the same, such as /usr/bin, /bin and /usr/sbin). The following information is prompted when I start the client: “error while loading shared libraries: libgconf-2.so.4: cannot open shared object file: No such file or directory”.

          Reference solution: This is due to the lack of libgconf-2.so.4 library when MQTTBOX is started. You need take the following steps:

          • Step 1: Download and decompress the MQTTBOX software package;
          • Step 2: Enter the decompressed directory of the MQTTBOX software package and configure execution privileges for MQTTBox executable files;
          • Step 3: Set soft connection for MQTTBox: sudo ln -s /path/to/MQTTBox /usr/local/bin/MQTTBox
          • Step 4: Enter the terminal and execute MQTTBox.

          Question 11: After Baidu IntelliEdge (BIE) is used to distribute configuration, the baetyl service is started locally, the function computing module is used for message processing and it is found that localfunc could not process messages. funclog is viewed and the following error information is reported:

          level=error msg="failed to create new client" dispatcher=mqtt error="dial tcp 0.0.0.0:1883:connect:connection refused"

          Reference solution: If Baidu IntelliEdge (BIE) cloud management suite is used to distribute configuration, the following points should be noted:

          1. For configuration distribution by the cloud, only the container mode is supported.
          2. If configuration is distributed by the cloud, the hub address configured in localfunc should be localhub instead of 0.0.0.0 .

          Make judgement based on the above information combined with the actual error report. Distribute configuration from the cloud again as needed, or see Configuration Resolution Documentation for verification and configuration.

          Question 12: How to select the CFC function when Baidu IntelliEdge (BIE) cloud management suite is used?

          Reference solution: 1.Make sure your Baidu IntelliEdge (BIE) configuration and CFC configuration are in the same region, for example, in Beijing/Guangzhou; 2.Make sure your function has been released on the CFC platform; 3.Select “CFC function template” when you create storage, and then import the corresponding CFC function. For more information about storage volume application, please see How to use a storage volume correctly

          Question 13: What is the relationship between ports in the configuration file and listen in the Hub configuration file?

          Reference solution: 1.Port mapping relationship between host and container is configured in ports; 2.listen is the monitoring port of Hub. If Hub is in the process mode, it monitors the host port, and if Hub is in the container mode, it monitors the port in the container; 3.Please see Configuration File Resolution Documentation.

          Question 14: After message is transmitted to Baidu AI Cloud IoT Hub through Baidu IntelliEdge (BIE), how data are subsequently processed in the cloud?

          Reference solution: After message arrives at IoT Hub, a simple SQL processing can be conducted through Rule engine, or it can be transmitted to other cloud services such as Baidu AI Cloud function computing platform through rule engine. For more configuration information, please see Rule Engine Operation Guide. For more configurations, see the article Through IntelliEdge -BIE- Desensitize and then Store Data in the Cloud - TSDB.

          Question 15: How to use remote communication function to connect Baidu IntelliEdge (BIE) to Baidu AI Cloud IoT Hub device-type project?

          Reference solution: Baidu IntelliEdge (BIE) end-cloud collaboration forces to use certificate authentication. Currently, IoT Hub device-type projects do not support certificate authentication. As a temporary solution, user name and password can be configured manually and locally to interact with the device-type projects.

          Question 16: How to make sure that all messages are not lost and can be synchronized to the cloud?

          Reference solution: Need to meet the following two conditions:

          The QoS of the message sent to the local Hub must be 1 to make sure the message becomes locally persistent. The QoS of Remote subscribing messages in the local Hub and the QoS of Remote releasing messages to the cloud Hub must both be 1 to make sure message is successfully uploaded to the cloud. See Configuration File Description .

          Question 17: When configuration is distributed from the cloud to the edge, it is started in docker mode by default. After mode: native is modified and the service is started, error like the following is reported:"failed to update system: open /Users/xxx/baetyl_native/var/run/baetyl/services/agent/lib/baetyl/hub.baidubce.com/baetyl/baetyl-agent:latest/package.yml: no such file or directory".

          Reference solution: Currently, the cloud management does not support the process mode. If you want to start Baetyl locally in the process mode, please see the configuration content in example/native, execute the command make install-native to install and use the command sudo baetyl start to start it in the process mode.

          Question 18: Error like the following is reported when an image is downloaded:”error=”Error response from daemon: Get https://hub.baidubce.com/v2/: x509: failed to load system roots and no roots provided” baetyl=master”.

          Reference solution: This is because the ca-certificates package is missing in the system, and it has to be installed. For example, if the host system is debian, the following command can be used to operate: For specific settings, see the following method:

          sudo apt-get update && sudo apt-get install ca-certificates 

          For others systems, please query related installation operations by yourself.

          Previous
          Best Practices
          Next
          Compatibility Problem of Changing Name of Openedge to Baetyl