All Products
Search
Document Center

Anti-DDoS:Export multiple port configurations at a time

Last Updated:May 10, 2024

Anti-DDoS Pro and Anti-DDoS Premium allow you to export multiple port configurations at a time. You can export the port configurations of an Anti-DDoS Pro or Anti-DDoS Premium instance as a TXT file. For example, you can export manually created forwarding rules, session and health check settings, and mitigation policies. You can also download the file to your computer. The exported file has the same format as the file that is used to import the configurations. This topic describes how to export multiple port configurations at a time.

Procedure

  1. Log on to the Anti-DDoS Proxy console.

  2. In the top navigation bar, select the region of your instance.

    • Anti-DDoS Proxy (Chinese Mainland): If your instance is an Anti-DDoS Proxy (Chinese Mainland) instance, select Chinese Mainland.

    • Anti-DDoS Proxy (Outside Chinese Mainland): If your instance is an Anti-DDoS Proxy (Outside Chinese Mainland), select Outside Chinese Mainland.

  3. In the left-side navigation pane, choose Provisioning > Port Config.

  4. On the Port Config page, select the instance that you want to manage. In the lower part of the rule list, choose Batch Export > Export Rule, Batch Export > Export Session and Health Check Settings, or Batch Export > Export Mitigation Policy.

  5. Click OK. In the upper-right corner of the Port Config page, click Tasks. In the Tasks panel, click Download in the Actions column that corresponds to the export task after the export task is complete.

    Note

    If the task is in the Pending state, wait until the task is complete.

    After the exported file is downloaded to your computer, you can open the TXT file to view the rules or settings. For more information about the format of the content in the TXT file, see Format of content in the files.

  6. Optional. In the Tasks panel, find the task that you no longer require and click Delete in the Actions column.

Format of content in exported files

All exported files are in the TXT format. The format of the files varies based on the exported content.

Note

If you use Anti-DDoS Proxy (Chinese Mainland), the name of the exported file starts with DDoSCoo_. If you use Anti-DDoS Proxy (Outside Chinese Mainland), the name of the exported file starts with DDoSDip_. The formats of the files exported from the Anti-DDoS Proxy (Chinese Mainland) and Anti-DDoS Proxy (Outside Chinese Mainland) consoles are the same.

  • Forwarding rule files

    Each row represents a forwarding rule that contains four fields. From left to right, the fields are the forwarding protocol, forwarding port, port of the origin server, and IP address of the origin server. For more information, see Manage forwarding rules.

    tcp 8001 8888 118.178.XX.XX
    tcp 8002 8888 118.178.XX.XX
    tcp 8003 8888 118.178.XX.XX
  • Files of session and health check settings

    Each row represents a rule. From left to right, the fields in each rule are the forwarding port, forwarding protocol, timeout period for session persistence, health check type, health check port, timeout period for a health check, health check interval, threshold at which a port is declared unhealthy, threshold at which a port is declared healthy, health check path, and domain name. If the value of the timeout period for session persistence is 0, session persistence is disabled. If no value is specified for the health check type, the health check feature is disabled, and the values of all fields that follow the health check type are also left empty. The values of the health check path and domain name are provided only for HTTP-based health checks. For more information, see Configure session persistence and Configure a health check.

    8001 tcp 0 
    8002 tcp 0 
    8003 tcp 900 tcp 8003 5 15 3 3 
  • Files of mitigation policies

    Each row represents a rule. From left to right, the fields in each rule are the forwarding port, forwarding protocol, maximum number of new connections from a source IP address, maximum number of concurrent connections from a source IP address, maximum number of new connections to a destination IP address, maximum number of concurrent connections to a destination IP address, minimum packet length, maximum packet length, whether to turn on False Source, and whether to turn on Empty Connection. The values of the last two fields take effect only when TCP is used. You must turn on False Source before you can turn on Empty Connection. For more information, see Create multiple anti-DDoS protection policies.

    8001 tcp 20000 50000 100000 0 0 6000 on off 
    8002 tcp 0 0 100000 0 0 6000 on on 
    8003 tcp 0 0 100000 0 0 6000 on off