文档首页> 虚拟私有云 VPC> API参考> API V3> 流量镜像会话> 流量镜像会话移除镜像源
更新时间:2024-01-04 GMT+08:00
分享

流量镜像会话移除镜像源

功能介绍

流量镜像会话移除镜像源

URI

PUT /v3/{project_id}/vpc/traffic-mirror-sessions/{traffic_mirror_session_id}/remove-sources

表1 路径参数

参数

是否必选

参数类型

描述

project_id

String

项目ID

traffic_mirror_session_id

String

流量镜像会话ID

请求参数

表2 请求Body参数

参数

是否必选

参数类型

描述

traffic_mirror_session

TrafficMirrorSourcesOption object

流量镜像会话对象

表3 TrafficMirrorSourcesOption

参数

是否必选

参数类型

描述

traffic_mirror_sources

Array of strings

功能说明:镜像源ID列表

响应参数

状态码: 200

表4 响应Body参数

参数

参数类型

描述

traffic_mirror_session

TrafficMirrorSession object

流量镜像会话对象

request_id

String

请求ID

表5 TrafficMirrorSession

参数

参数类型

描述

id

String

功能说明:流量镜像会话ID

project_id

String

功能说明:项目ID

name

String

功能说明:流量镜像会话名称

取值范围:1-64个字符,支持数字、字母、中文、_(下划线)、-(中划线)、.(点)

description

String

功能说明:流量镜像会话的描述信息

取值范围:0-255个字符,不能包含“<”和“>”

traffic_mirror_filter_id

String

功能说明:流量镜像筛选条件ID

traffic_mirror_sources

Array of strings

功能说明:镜像源ID列表,支持弹性网卡作为镜像源。

约束:一个镜像会话默认最大支持10个镜像源。

traffic_mirror_target_id

String

功能说明:镜像目的ID

traffic_mirror_target_type

String

功能说明:镜像目的类型

取值范围: eni,弹性网卡;elb,私网弹性负载均衡

virtual_network_id

Integer

功能说明:指定VNI,用于区分不同会话的镜像流量

取值范围:0~16777215

默认值:1

packet_length

Integer

功能说明:最大传输单元MTU

取值范围:1~1460

默认值:96

priority

Integer

功能说明:会话优先级

取值范围:1~32766

enabled

Boolean

功能说明:是否开启会话

取值范围:true、false

默认值:false

type

String

功能说明:支持的镜像源类型

取值范围: eni,弹性网卡

created_at

String

功能说明:创建时间戳

updated_at

String

功能说明:更新时间戳

请求示例

移除ID为e15a6e40-2580-4949-bf2a-55ee7cd49392的镜像会话中的镜像源6134900d-31a6-4b71-8453-dbca7f26982a。

PUT https://{endpoint}/v3/{project_id}/vpc/traffic-mirror-sessions/e15a6e40-2580-4949-bf2a-55ee7cd49392/remove-sources

{
  "traffic_mirror_session" : {
    "traffic_mirror_sources" : [ "6134900d-31a6-4b71-8453-dbca7f26982a" ]
  }
}

响应示例

状态码: 200

OK

{
  "traffic_mirror_session" : {
    "name" : "test-session",
    "created_at" : "2023-02-23T06:57:39Z",
    "updated_at" : "2023-02-23T06:57:39Z",
    "id" : "e15a6e40-2580-4949-bf2a-55ee7cd49392",
    "project_id" : "7365fcd452924e398ec4cc1fe39c0d12",
    "description" : "",
    "traffic_mirror_filter_id" : "b765ba87-c0b4-4f1a-9ec3-d5b1d1ddb137",
    "traffic_mirror_sources" : [ ],
    "traffic_mirror_target_id" : "",
    "traffic_mirror_target_type" : "",
    "virtual_network_id" : 1,
    "packet_length" : 96,
    "priority" : 6,
    "enabled" : true,
    "type" : "eni"
  },
  "request_id" : "6f107fc1-93be-4d5a-af71-4099da7eeaa9"
}

状态码

状态码

描述

200

OK

错误码

请参见错误码

分享:

    相关文档

    相关产品