tencent cloud

Feedback

CloneLoadBalancer

Last updated: 2022-07-26 10:23:32

    1. API Description

    Domain name for API request: clb.tencentcloudapi.com.

    This API is used to create a clone of the source CLB instance with the same forwarding rules and binding relations. Note that this API is asynchronous, which means that changes to the source CLB after invocation of the API are not included in the clone.

    Use limits:
    Unsupported instance types: Classic network CLB, Classic CLB, IPv6 CLB, and NAT64 CLB.
    Monthly subscribed CLB instances are not supported.
    QUIC and port listeners are not supported.
    The CLB backend service cannot be a target group or an SCF function.
    The following settings will not be cloned automatically and require manual configuration: "Custom Configuration", "Redirection Configuration" and "Allow Traffic by Default in Security Group".

    Notes:
    If you are using a BGP bandwidth package, you need to pass the package ID.
    To create a dedicated cluster-based CLB by cloning the source CLB, you need to pass the cluster ID. Otherwise, a normal CLB is created.
    This API is only available for beta users. If you want to try it out, please submit a ticket.

    A maximum of 20 requests can be initiated per second for this API.

    We recommend you to use API Explorer
    Try it
    API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

    2. Input Parameters

    The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

    Parameter Name Required Type Description
    Action Yes String Common Params. The value used for this API: CloneLoadBalancer.
    Version Yes String Common Params. The value used for this API: 2018-03-17.
    Region Yes String Common Params. For more information, please see the list of regions supported by the product.
    LoadBalancerId Yes String CLB instance ID
    LoadBalancerName No String Clones the name of the CLB instance. The name must be 1-60 characters containing letters, numbers, "-" or "_".
    Note: if the name of a new CLB instance already exists, a default name will be generated automatically.
    ProjectId No Integer Project ID of the CLB instance, which can be obtained through the DescribeProject API. If this field is not specified, it will default to the default project.
    MasterZoneId No String Sets the primary AZ ID for cross-AZ disaster recovery, such as 100001 or ap-guangzhou-1, which is applicable only to public network CLB.
    Note: By default, the traffic goes to the primary AZ. The secondary AZs only carry traffic when the primary AZ is unavailable. The optimal secondary AZ is chosen automatically. You can query the primary and secondary AZ of a region by calling DescribeResources).
    SlaveZoneId No String Specifies the secondary AZ ID for cross-AZ disaster recovery, such as 100001 or ap-guangzhou-1. It is applicable only to public network CLB.
    Note: The traffic only goes to the secondary AZ when the primary AZ is unavailable. You can query the list of primary and secondary AZ of a region by calling DescribeResources.
    ZoneId No String Specifies an AZ ID for creating a CLB instance, such as ap-guangzhou-1, which is applicable only to public network CLB instances.
    InternetAccessible No InternetAccessible CLB network billing mode. This parameter is applicable only to public network CLB instances.
    VipIsp No String This parameter is applicable only to public network CLB instances. Valid values: CMCC (China Mobile), CTCC (China Telecom), CUCC (China Unicom). If this parameter is not specified, BGP will be used by default. ISPs supported in a region can be queried with the DescribeSingleIsp API. If an ISP is specified, only bill-by-bandwidth-package (BANDWIDTH_PACKAGE) can be used as the network billing mode.
    Vip No String Applies for CLB instances for a specified VIP
    Tags.N No Array of TagInfo Tags a CLB instance when purchasing it
    ExclusiveCluster No ExclusiveCluster Dedicated cluster information
    BandwidthPackageId No String Bandwidth package ID. If this parameter is specified, the network billing mode (InternetAccessible.InternetChargeType) will only support bill-by-bandwidth package (BANDWIDTH_PACKAGE).
    SnatPro No Boolean Whether to support binding cross-VPC IPs or cross-region IPs
    SnatIps.N No Array of SnatIp Creates SnatIp when the binding IPs of other VPCs feature is enabled
    ClusterIds.N No Array of String ID of the public network CLB dedicated cluster
    SlaType No String Guaranteed performance specification.
    ClusterTag No String Tag of the STGW dedicated cluster
    Zones.N No Array of String Availability zones for nearby access of private network CLB instances to distribute traffic
    EipAddressId No String Unique ID of an EIP, which can only be used when binding the EIP of a private network CLB instance (e.g., eip-11112222)

    3. Output Parameters

    Parameter Name Type Description
    RequestId String The unique request ID, which is returned for each request. RequestId is required for locating a problem.

    4. Example

    Example1 Cloning a CLB instance

    Input Example

    https://clb.tencentcloudapi.com/?Action=CloneLoadBalancer
    &LoadBalancerId=lb-xxxx
    &<Common request parameters>
    

    Output Example

    {
    "Response": {
      "RequestId": "83129908-a282-4f9f-8ab-131a3025ba22"
    }
    }
    

    5. Developer Resources

    SDK

    TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

    Command Line Interface

    6. Error Code

    The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

    Error Code Description
    AuthFailure CAM signature/authentication error
    DryRunOperation DryRun operation, which means the DryRun parameter is passed in yet the request will still be successful.
    FailedOperation Operation failed.
    FailedOperation.InvalidLBStatus Exceptional CLB instance status
    InternalError Internal error.
    InvalidParameter Parameter error.
    InvalidParameter.FormatError Wrong parameter format.
    InvalidParameter.LBIdNotFound Wrong CLB instance ID.
    InvalidParameter.ListenerIdNotFound Wrong listener ID.
    InvalidParameter.LocationNotFound Unable to find eligible forwarding rules.
    InvalidParameter.PortCheckFailed Listener port checks failed due to port conflicts or other reasons.
    InvalidParameter.ProtocolCheckFailed Listener protocol checks failed because the protocol used is incompatible with the corresponding operation.
    InvalidParameter.RegionNotFound Invalid region.
    LimitExceeded Quota exceeded.
    MissingParameter Missing parameter.
    OperationDenied Operation denied.
    RequestLimitExceeded The number of requests exceeds the frequency limit.
    ResourceInUse The resource is occupied.
    ResourceInsufficient Insufficient resources.
    ResourcesSoldOut The resources have been sold out.
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support