메뉴 건너뛰기

Cloudera, BigData, Semantic IoT, Hadoop, NoSQL

Cloudera CDH/CDP 및 Hadoop EcoSystem, Semantic IoT등의 개발/운영 기술을 정리합니다. gooper@gooper.com로 문의 주세요.


curl -u 'xxxx':'xxxx' 'http://CM_server.domain.com:7180/api/v11/clusters/cluster/services/impala/impalaQueries?from=2017-10... statement RLIKE ".*fawzea.*"' >>f.json


http://CM-server.domain.com:7180/api/v19/clusters/cluster/services/impala/impalaQueries?statment%20RLIKE%20%22.*test.*%22




*참고 : https://cloudera.github.io/cm_api/apidocs/v19/index.html

Introduction

This document describes the Cloudera Manager REST API. All requests and responses are presented in Javascript Object Notation (JSON).

The API resources listed below follow standard Create-Read-Update-Delete (CRUD) semantics where the HTTP request path defines the entity to be acted on and the HTTP method expresses the type of action to perform.

HTTP MethodOperation
POSTCreate entries
GETRead entries
PUTUpdate or edit entries
DELETEDelete entries

All collections in the API use plural names, 'users', instead of the singular, 'user'. To address a specific user in the system, expand the URL path to include the user identifier. For example, '/users/foo' identifies user 'foo' and '/users/bar' identifies user 'bar'.

CollectionPOST (create)GET (read)PUT (update)DELETE (delete)
/usersCreate a new userList all users in the systemBulk update all usersDelete all users
/users/fooerrorRead information about user 'foo'If user 'foo' exists, update their information; otherwise, error.Delete user 'foo'

Keep in mind that not all collections support all operations. For example, events in the system are read-only; you cannot create new events with the API.

You can list the entries in a collection using one of two views: 'summary' or 'full'. The default 'summary' view provides the core information about each entry. The 'full' view is more heavyweight and provides a fully expanded view of each entry. The view is controlled by a query parameter called 'view' e.g. 'GET /users?view=full'.

HTTP requests should set the "Content-Type" header to "application/json" for most calls, unless specified otherwise.

Authentication

The Cloudera Manager API uses HTTP basic access authentication. It accepts the same user credentials as the web interface. Different users may have different levels of access, as defined by their roles. (See the user management API calls for more.) With every authenticated request, the server returns a session cookie, which can be subsequently used for authentication.

Error Code

The API returns HTTP code in the 400s and 500s upon errors:

  • 400 — Invalid request parameters; Malformed requests
  • 401 — Authentication failure
  • 403 — Authorization failure
  • 404 — Object not found
  • 500 — Internal API error
  • 503 — Response temporarily unavailable; caller should retry later

See /tools/echoError for a discussion on the body of an error response.

API Usage Tutorial

Tutorial link.

API Version

The API can be queried for the latest version it supports. By making a GET request to the '/version' URL, a string will be returned with the highest supported version (for example, "v2").

Note that servers that only support API v1 do not support this call. In that case, a 404 error will be returned, and can be used to detect that the server only supports v1.

The version should be prepended to the path of the REST resources listed below. The documentation of the different resources lists the version which added the particular functionality.

REST Resources

This API supports a Representational State Transfer (REST) model for accessing a set of resources through a fixed set of operations. The following resources are accessible through the RESTful model:

There is also a WADL document describing the REST API.

Data Model

All endpoints act on a common set of data. The Cloudera Manager API uses JSON.

Data Elements

번호 제목 날짜 조회 수
367 znode /hbase recursive하게 지우기 2015.05.06 4291
366 hbase CustomFilter만들기 (0.98.X이상) 2015.05.08 4773
365 hbase가 기동시키는 zookeeper에서 받아드리는 ip가 IPv6로 사용되는 경우가 있는데 이를 IPv4로 강제적용하는 방법 2015.05.08 4571
364 secureCRT에서 backspace키가 작동하지 않는 경우 해결방법 2015.05.11 4468
363 Nodes of the cluster (unhealthy)중 1/1 log-dirs are bad: 오류 해결방법 2015.05.17 4498
362 Permission denied: user=hadoop, access=EXECUTE, inode="/tmp":root:supergroup:drwxrwx--- 오류해결방법 2015.05.17 3409
361 java.lang.ClassNotFoundException: org.apache.hadoop.util.ShutdownHookManager 오류조치사항 2015.05.20 4264
360 flume 1.5.2 설치및 테스트(source : file, sink : hdfs) in HA 2015.05.21 4414
359 hbase shell 필드 검색 방법 2015.05.24 5705
358 Error: Could not find or load main class nodemnager 가 발생할때 해결하는 방법 2015.06.05 4449
357 Error: E0501 : E0501: Could not perform authorization operation, User: hadoop is not allowed to impersonate hadoop 해결하는 방법 2015.06.07 4249
356 "File /user/hadoop/share/lib does not exist" 오류 해결방법 2015.06.07 4200
355 hadoop 2.6.0에 sqoop2 (1.99.5) server및 client설치 == fail 2015.06.11 4526
354 Exception in thread "main" java.lang.NoSuchMethodError: org.apache.hadoop.http.HttpConfig.getSchemePrefix()Ljava/lang/String; 해결->실패 2015.06.14 2614
353 hortonworks에서 제공하는 메모리 설정값 계산기 사용법 file 2015.06.14 4275
352 java.lang.RuntimeException: org.apache.hadoop.hive.ql.metadata.HiveException: Hive Runtime Error: Unable to deserialize reduce input key from...오류해결방법 2015.06.16 5944
351 Tracking URL = N/A 가발생하는 경우 - 환경설정값을 잘못설정하는 경우에 발생함 2015.06.17 4616
350 mongodb 2.6.6 설치(64bit) 2015.09.30 2633
349 SQL문장과 Mongo에서 사용하는 명령어를 비교한 것입니다. 2015.09.30 4038
348 root계정으로 MariaDB설치후 mysql -u root -p로 db에 접근하여 바로 해줘야 하는일..(케릭터셑은 utf8) 2015.10.02 3732
위로