Baidu AI Cloud
中国站

百度智能云

Object Storage

Install BOSCLI

Precondition

BOS CLI command line tools (namely BCE CLI), based on Python 2.7 development, is installed with corresponding according to the operating system,Python 2.7 and supports Windows and Linux at present.

Operation Steps

1.Prepare for Python environment.

  • Windows environment

    Download python27.msi from the official website Python, and double click for installation.

  • Linux environment

    Take Ubuntu and Redhat as examples:

    # Ubuntu
    $ sudo apt-get install python python-dev python-setuptools python-pip
    
    # Redhat
    $ sudo yum install python python-dev python-setuptools python-pip

Note: Please execute python -V to view the version information of python after the python is installed, and ensure the version of python indicated is 2.7 or later. The users using BCC Centos 6.5 system of Baidu AI Cloud shall refer to the User's Installation Guide for BCC Centos 6.5 System of Baidu AI Cloud specified in the following. Installation

2.Install BOS CLI Tool Download Link

  • Windows environment

    (1) Extract CLI kit.

    (2) Execute the following command in cmd:

    cd $ BCE_PATH 
    $ python setup.py install 

    (3) Copy bce to the directory where the user needs to execute the program for ease of use.

    $ python $YOUR_DIR/bce 
  • Linux environment

    (1) Extract CLI kit.

    $ unzip bce-cli-0.10.8.zip 

    (2) Install the library of bcecli under the python directory of the system.

    $ python setup.py install 

the User's Installation Guide for BCC Centos 6.5 System of Baidu AI Cloud specified in the following:

1.Download BCC Centos6.5 mirror-specific CIL at first .

2.Extract CLI kit.

$ unzip bce-cli-0.10.8-centos6.5.zip 

3.Add the installation directory of bce-cli-0.10.8-centos6.5 into the environmental variables.

export PATH=bce-cli-path:$PATH

Note: For example, the path is/home/user1/bce-cli-0.10.8-centos6.5 after extraction of bce-cli-0.10.8-centos6.5.zip, you need to add the path/home/user1/bce-cli-0.10.8-centos6.5/into the environmental variable.

Previous
Overview
Next
Configure BOSCLI