BCM-Tool-Frequently Asked Questions
1. During installation, it prompts that BCM-Tool cannot be found?
This issue typically arises with older systems that lack preconfigured BCM-Tool source files (CentOS: /etc/yum.repos.d/baidu-bcm.repo, Ubuntu: /etc/apt/sources.list.d/baidu-bcm.list), which must be manually added as follows.
CentOS Machine:
1cat > /etc/yum.repos.d/baidu-bcm.repo <<EOF
2[baidu-bcm]
3name=Baidu cloud monitor(BCM)
4baseurl=http://repo.bcm.baidubce.com/yum
5gpgcheck=0
6enabled=1
7EOF
Description:
For users in internal production environments, use baseurl=http://repo.bcm.baidubce.com/yum-internal.
Ubuntu Machine:
1cat > /etc/apt/sources.list.d/baidu-bcm.list <<EOF
2# Baidu cloud monitor(BCM)
3deb http://repo.bcm.baidubce.com/deb/ all main
4EOF
Description:
For users in internal production environments, use http://repo.bcm.baidubce.com/deb-internal/ all main.
Then proceed with the installation according to [ Installation Method ](BCM/BCM-Tool/Installation method.md).
2. When installation failed, it prompts that Python does not exist or version is not correct?
BCM-Tool supports Python 2.6 and 2.7. During installation, it checks the system's Python version. Versions below 2.6 or above 2.7 will result in installation failure. Installing Python 2.6 or 2.7 under the root user allows BCM-Tool to install successfully.
3. When installation succeeded, running BCM-Tool fails with "python not found" or "invalid syntax" errors?
This issue occurs due to a missing Python environment or a version mismatch for the current user.
Use the which python command to check if the environment exists. If already installed, verify whether the version number meets requirements via python --version.
The installation is successful because the user performing the installation is the root user. Successful installation suggests that the root user's Python environment is functional, while the BCM-Tool user may be using a different Python environment.
4. When executing the bcm-tool command, what if "command not found" appears?
There are two possible reasons for this problem: either BCM-Tool has not been installed or its installation failed, or the soft link for BCM-Tool could not be created at the end of the installation.
- First, confirm whether the BCM-Tool is successfully installed (check if the /opt/bcm-tool directory exists). Run
/opt/bcm-tool/bin/bcm-tooldirectly. If it runs normally, the BCM-Tool itself is functional. - Then check if
/usr/bin/bcm-tool(soft link of /opt/bcm-tool/bin/bcm-tool) exists. If not, useln-s /opt/bcm-tool/bin/bcm-tool /usr/bin/bcm-toolto create it manually.
5. When pushing or querying monitoring data, why does it prompt data point has illegal timestamp that is later than 2 hours after current time or earlier than two weeks ago?
BCM requires the Timestamp of monitoring data for pushing and querying to neither be earlier than two weeks nor later than two hours in the future. If you encounter such a prompt, please check the Timestamp.
6. When pushing or querying monitoring data, it prompts that argument -t/--timestamp is invalid?. What to do?
This prompt indicates a Timestamp format error. BCM supports the ISO8601 Timestamp format: standard formats include 2015-01-01T12:00:00Z or 2015-01-01T20:00:00+08:00:00, where the Z suffix denotes UTC time, and +08:00:00 denotes Beijing time.
7. When using BCM-Tool, why does it prompt Invalid scope, your scope can't be started with "BCE_" or "BCM_"?
BCM-Tool requires users not to push any scope starting with BCM_ or BCE_, as BCM and BCE are used by the public cloud internal systems.
8. How to retrieve "user id", "access key", and "secret access key"?
"user id" can be viewed under User Info -> Basic Info -> User ID, while "access key" and "secret access key" can be found under My Services -> Security Authentication -> My Access Key. Please refer to [ Retrieve AK/SK ](Reference/Retrieve AK and SK/How to Obtain AKSK.md).
