MaxCompute CLI tool odpscmd

Install odpscmd

Install odpscmd by using YUM (Red Hat and CentOS)

sudo yum -y install odpscmd

Install odpscmd by using APT (Ubuntu and Debian)

sudo apt-get -y install odpscmd

Download one of the following packages to perform a local installation.

Configure and use odpscmd

  1. After installation, odpscmd creates the .odpscmd directory in the home directory to store the odpscmd configuration file ~/.odpscmd/odps_config.ini. The file contains the following settings:
project_name=
access_id=<accessid>
access_key=<accesskey>
end_point=http://service.odps.aliyun.com/api
tunnel_endpoint=http://dt.odps.aliyun.com
log_view_host=http://logview.odps.aliyun.com
https_check=true
  1. Open the file, add the logon information, such as the project name, AccessId, and AccessKey, save the file, and then exit.

  2. Enter odpscmd at the CLI, and press Enter. The output is as follows:

> odpscmd
Aliyun ODPS Command Line Tool
Version 0.29.1
@Copyright 2015 Alibaba Cloud Computing Co., Ltd. All rights reserved.
odps@ proj_name>
  1. The proj_name parameter specifies the project name. Enter list tables to list all table names under the project.
odps@ proj_name>list tables;

this_is_a_user_name:this_is_a_table_name
...
  1. For more information about using odpscmd, see Client.

GitHub

Source code is now available for this project. For more information about managing the project with GitHub, see GitHub.