huawei-ifm-trunk

Define the trunk bundling technology that bundles multiple physical interfaces into a logical interface.

  • Version: 2020-02-14

    huawei-ifm-trunk@2020-02-14


    
      module huawei-ifm-trunk {
    
        yang-version 1;
    
        namespace
          "urn:huawei:yang:huawei-ifm-trunk";
    
        prefix ifm-trunk;
    
        import huawei-pub-type {
          prefix pub-type;
        }
        import huawei-ifm {
          prefix ifm;
        }
        import huawei-extension {
          prefix ext;
        }
    
        organization
          "Huawei Technologies Co., Ltd.";
    
        contact
          "Huawei Industrial Base
    Bantian, Longgang
    Shenzhen 518129
    People's Republic of China
    Website: http://www.huawei.com
    Email: support@huawei.com";
    
        description
          "Define the trunk bundling technology that bundles multiple physical interfaces into a logical interface.";
    
        revision "2020-02-14" {
          description
            "Modify the description of nodes.";
          reference
            "Huawei private.";
    
        }
    
        revision "2019-06-30" {
          description "Initial revision.";
          reference
            "Huawei private.";
    
        }
    
        ext:task-name "trunk";
    
        typedef trunk-member-role {
          type enumeration {
            enum "slave" {
              value 0;
              description
                "Configure the slave interface in the Eth-Trunk interface working in 1:1 master/slave mode.";
            }
            enum "master" {
              value 1;
              description
                "Configure the master interface in the Eth-Trunk interface working in 1:1 master/slave mode.";
            }
            enum "common" {
              value 3;
              description
                "Trunk member interface.";
            }
          }
          description "Trunk member role.";
        }
    
        typedef trunk-type {
          type enumeration {
            enum "eth-trunk" {
              value 1;
              description
                "Indicate that an Eth-Trunk link consists of only Ethernet links.";
            }
            enum "ip-trunk" {
              value 2;
              description
                "Indicate that an IP-Trunk link consists of only the Packet over SONET/SDH (POS) links.";
            }
          }
          description "Trunk interface type.";
        }
    
        typedef member-status {
          type enumeration {
            enum "down" {
              value 0;
              description
                "The interface is in the down state.";
            }
            enum "up" {
              value 1;
              description
                "The interface is in the up state.";
            }
          }
          description "Trunk member state.";
        }
    
        typedef trunk-mode {
          type enumeration {
            enum "manual" {
              value 1;
              description
                "Specify the manual load balancing mode. It is a basic link aggregation mode. In this mode, you must manually create a trunk interface, add interfaces to the trunk interface, and specify active member interfaces. LACP is not involved.";
            }
            enum "dynamic" {
              value 2;
              description
                "Specify the dynamic LACP mode. In dynamic LACP mode, if the Eth-Trunk interface has not be configured on the other end and the physical interfaces on two ends are both Up, dynamic LACP mode will set Eth-Trunk member interfaces to Indep, indicating the physical interfaces of the server and of the device are independent. This ensures that physical interfaces of the device can forward data to the server.";
            }
            enum "static" {
              value 3;
              description
                "Specify the static LACP mode. In this mode, you must manually add interfaces to the Eth-Trunk interface. Different from link aggregation in manual load balancing mode, active member interfaces are selected based on LACP packets.";
            }
            enum "backup" {
              value 4;
              description
                "Specify the 1:1 active/standby load balancing mode. In this mode, an Eth-Trunk interface contains only two member interfaces (one active interface and one standby interface).";
            }
            enum "invalid" {
              value 5;
              description
                "Nonexistent trunk working mode.";
            }
          }
          description "Trunk work mode.";
        }
    
        typedef trunk-hash-type {
          type enumeration {
            enum "ip" {
              value 1;
              description
                "Specify the IP-address-based per-destination load balancing mode. In this mode, data flows are differentiated based on IP addresses of packets to ensure that the packets of the same data flow are transmitted over the same member link.";
            }
            enum "mac" {
              value 2;
              description
                "Specify the MAC-address-based per-destination load balancing mode. In this mode, data flows are differentiated based on MAC addresses of packets to ensure that the packets of the same data flow are transmitted over the same member link.";
            }
            enum "packet-all" {
              value 3;
              description
                "Specifies the per-packet load balancing mode. In this mode, one packet (not a data flow) is regarded as a unit, and packets are dispersed and transmitted among different member links.";
            }
            enum "des-ip" {
              value 4;
              description
                "Load balancing based on the destination IP address. In this mode, the system obtains the specified three bits from each of the destination IP address and the TCP or UDP port number in outgoing packets to perform the Exclusive-OR calculation, and then selects the outbound interface from the Eth-Trunk table based on the calculation result.";
            }
            enum "des-mac" {
              value 5;
              description
                "Load balancing based on the destination MAC address. In this mode, the system obtains the specified three bits from each of the destination MAC address, VLAN ID, Ethernet type, and inbound interface information to perform the Exclusive-OR calculation, and then selects the outbound interface from the Eth-Trunk table based on the calculation result.";
            }
            enum "src-ip" {
              value 6;
              description
                "Load balancing based on the source IP address. In this mode, the system obtains the specified three bits from each of the source IP address and the TCP or UDP port number in incoming packets to perform the Exclusive-OR calculation, and then selects the outbound interface from the Eth-Trunk table based on the calculation result.";
            }
            enum "src-mac" {
              value 7;
              description
                "Load balancing based on the source MAC address. In this mode, the system obtains the specified three bits from each of the source MAC address, VLAN ID, Ethernet type, and inbound interface information to perform the Exclusive-OR calculation, and then selects the outbound interface from the Eth-Trunk table based on the calculation result.";
            }
            enum "enhanced" {
              value 8;
              description
                "Load balancing mode based on the enhanced profile.";
            }
            enum "resilient" {
              value 9;
              description
                "Load balancing mode based on the enhanced resilient profile.";
            }
            enum "invalid" {
              value 10;
              description
                "Nonexistent hash type of trunk interfaces.";
            }
            enum "l4" {
              value 11;
              description
                "According to source/destination IP, source/destination port and protocol hash arithmetic.";
            }
            enum "random" {
              value 12;
              description
                "Load balancing mode based on random selects the outbound interface from the Eth-Trunk.";
            }
            enum "round-robin" {
              value 13;
              description
                "Load balancing mode based on round-robin selects the outbound interface from the Eth-Trunk.";
            }
            enum "symmetric" {
              value 14;
              description
                "Symmetric hash arithmetic.";
            }
            enum "symmetric-complement" {
              value 15;
              description
                "Symmetric complement hash arithmetic.";
            }
          }
          description "Trunk hash type.";
        }
    
        typedef trunk-lacp-negotiation-mode {
          type enumeration {
            enum "active" {
              value 1;
              description "Active mode.";
            }
            enum "passive" {
              value 2;
              description "Passive mode.";
            }
          }
          description "Lacp negotiation mode.";
        }
    
        container ifm-trunk {
          description
            "Define the trunk bundling technology. It bundles multiple physical interfaces into a logical interface.";
          container global {
            description
              "Configure trunk global system attributes.";
            leaf trunk-member-trap-enable {
              type boolean;
              default "false";
              description
                "Enable/disable trunk member trap.";
            }
          }  // container global
        }  // container ifm-trunk
    
        rpc trunk-switch {
          description "1:1 trunk switch.";
          input {
            leaf if-name {
              type leafref {
                path "/ifm:ifm/ifm:interfaces/ifm:interface/ifm:name";
              }
              mandatory true;
              description "Interface name.";
            }
          }
        }  // rpc trunk-switch
      }  // module huawei-ifm-trunk
    

© 2023 YumaWorks, Inc. All rights reserved.