查询集群日志详情
最近更新时间: 2026-09-17 00:05:46
1. 接口描述
接口请求域名: tbdsnew.api3.fincloud.tencent.cn。
在集群监控的日志搜索,在查询得到的列表的某一项可以点击查看上下文来查询集群日志上下文信息
默认接口请求频率限制:20次/秒。
接口更新时间:2024-11-21 15:19:37。
接口既验签名又鉴权。
2. 输入参数
以下请求参数列表仅列出了接口请求参数和部分公共参数,完整公共参数列表见公共请求参数。
| 参数名称 | 必选 | 允许NULL | 类型 | 描述 |
|---|---|---|---|---|
| Action | 是 | 否 | String | 公共参数,本接口取值:DescribeLogDetail |
| Version | 是 | 否 | String | 公共参数,本接口取值:2019-01-03 |
| Region | 是 | 否 | String | 公共参数,地域信息可通过DescribeRegions接口查看产品支持的地域列表 |
| InstanceId | 是 | 否 | String | 集群实例ID 示例值: tbds-1vzudj86 |
| Role | 是 | 否 | String | 角色 示例值: HiveMetaStore |
| Host | 是 | 否 | String | 节点ip 示例值: 172.16.0.89 |
| MinLevel | 是 | 否 | String | 最小日志级别 示例值: INFO |
| FileName | 是 | 否 | String | 文件名 示例值: hadoop-hivemetastore |
| Direction | 否 | 否 | Int64 | 0-上下;1-下;-1-上 示例值: 0 |
| UniqueId | 是 | 否 | String | 日志的唯一id 示例值: l-wMDJcB0KNu_-Ayy6j-17482538413602524706 |
| ToLatestLog | 否 | 否 | Bool | 是否查询最新时间 示例值: False |
3. 输出参数
| 参数名称 | 类型 | 描述 |
|---|---|---|
| Source | String | 日志路径 示例值: 1 |
| FirstLogTime | String | 第一条日志时间 示例值: 1 |
| LogSearchRespItems | Array of LogSearchRespItem | 日志内容 注意:此字段可能返回 null,表示取不到有效值。 示例值:查看 |
| LastLogTime | String | 最后一条日志时间 示例值: 1 |
| ExistAheadLog | Bool | 是否还存在上文日志 示例值: 1 |
| RequestId | String | 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。 |
4. 错误码
以下仅列出了接口业务逻辑相关的错误码,其他错误码详见公共错误码。
| 错误码 | 描述 |
|---|---|
| ResourceNotFound.MetricsMetaNotFound | 无法找到监控元数据。 |
| InternalError | 内部错误。 |
| ResourceNotFound.ClusterNotFound | 无法找到该实例。 |
| UnauthorizedOperation.AppIdMismatched | appid不一致。 |
5. 示例
示例1 查询集群日志详情
输入示例
POST / HTTP/1.1
Host: tbdsnew.api3.{conf.main_domain}
Content-Type: application/json
X-TC-Action: DescribeLogDetail
<公共请求参数>
{
"InstanceId": "tbds-1vzudj86",
"Role": "HiveMetaStore",
"Host": "172.16.0.89",
"FileName": "hadoop-hivemetastore",
"MinLevel": "INFO",
"UniqueId": "l-wMDJcB0KNu_-Ayy6j-*1748253841360*2524706",
"Direction": 0,
"ToLatestLog": false
}
输出示例
{
"Response": {
"ExistAheadLog": true,
"FirstLogTime": "2025-05-26 17:55:06.375",
"LastLogTime": "2025-05-26 18:04:06.407",
"LogSearchRespItems": [
{
"Host": "172.16.0.89",
"Role": "HiveMetaStore",
"FileName": "hadoop-hivemetastore",
"TimeStamp": "2025-05-26 17:55:06.375",
"Content": "occurred during processing of message.\norg.apache.thrift.transport.TTransportException: org.apache.thrift.transport.TTransportException: Socket is closed by peer.\n\tat org.apache.hadoop.hive.metastore.security.HadoopThriftAuthBridge$Server$TUGIAssumingTransportFactory.getTransport(HadoopThriftAuthBridge.java:729) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:227) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) ~[?:?]\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) ~[?:?]\n\tat java.lang.Thread.run(Thread.java:829) ~[?:?]\nCaused by: org.apache.thrift.transport.TTransportException: Socket is closed by peer.\n\tat org.apache.thrift.transport.TIOStreamTransport.read(TIOStreamTransport.java:184) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.transport.TTransport.readAll(TTransport.java:109) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.transport.TSaslTransport.receiveSaslMessage(TSaslTransport.java:151) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.transport.TSaslServerTransport.handleSaslStartMessage(TSaslServerTransport.java:108) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.transport.TSaslTransport.open(TSaslTransport.java:238) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.transport.TSaslServerTransport.open(TSaslServerTransport.java:44) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.thrift.transport.TSaslServerTransport$Factory.getTransport(TSaslServerTransport.java:199) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.hadoop.hive.metastore.security.HadoopThriftAuthBridge$Server$TUGIAssumingTransportFactory$1.run(HadoopThriftAuthBridge.java:711) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat org.apache.hadoop.hive.metastore.security.HadoopThriftAuthBridge$Server$TUGIAssumingTransportFactory$1.run(HadoopThriftAuthBridge.java:707) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\tat java.security.AccessController.doPrivileged(Native Method) ~[?:?]\n\tat javax.security.auth.Subject.doAs(Subject.java:361) ~[?:?]\n\tat org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:2045) ~[hadoop-common-3.2.2-TBDS-5.3.1_2025p1-20250407.105716-115.jar:?]\n\tat org.apache.hadoop.hive.metastore.security.HadoopThriftAuthBridge$Server$TUGIAssumingTransportFactory.getTransport(HadoopThriftAuthBridge.java:707) ~[hive-exec-3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT.jar:3.1.3-TBDS-5.3.1_2025p1-SNAPSHOT]\n\t... 4 more",
"Level": "ERROR",
"UniqueId": "LuUEDJcBgg5gwAD2o9cT*1748253306375*10031810",
"IsSupportMonitor": true
}
],
"RequestId": "dee52406-2042-408b-9ae3-268c73def960",
"Source": "/data/emr/hive/logs/hadoop-hivemetastore"
}
}