junos-ex-conf-virtual-chassis

Junos virtual-chassis configuration module

  • Version: 2019-01-01

    junos-ex-conf-virtual-chassis@2019-01-01


    
      module junos-ex-conf-virtual-chassis {
    
        yang-version 1;
    
        namespace
          "http://yang.juniper.net/junos-ex/conf/virtual-chassis";
    
        prefix jc-virtual-chassis;
    
        import junos-common-ddl-extensions {
          prefix junos;
          revision-date "2019-01-01";
        }
        import junos-common-types {
          prefix jt;
          revision-date "2019-01-01";
        }
        import junos-ex-conf-root {
          prefix jc;
          revision-date "2019-01-01";
        }
    
        organization "Juniper Networks, Inc.";
    
        contact "yang-support@juniper.net";
    
        description
          "Junos virtual-chassis configuration module";
    
        revision "2019-01-01" {
          description "Junos: 21.3R1.9";
        }
    
    
        augment /jc:configuration {
          uses virtual-chassis-group;
        }
    
        augment /jc:configuration/jc:groups {
          uses virtual-chassis-group;
        }
    
        grouping virtual-chassis-group {
          container virtual-chassis {
            junos:must "(!("forwarding-options hyper-mode"))";
            junos:must-message "To configure virtual-chassis, 'forwarding-options hyper-mode' should not be configured";
            description
              "Virtual chassis configuration";
            uses apply-advanced;
    
            container auto-sw-update {
              presence "enable auto-sw-update";
              description "Auto software update";
              uses apply-advanced;
    
              leaf package-name {
                type string {
                  junos:posix-pattern "![*]";
                  junos:pattern-message "Package name cannot contain '*'.  Use TAB for filename completion";
                }
                description
                  "URL or pathname of software package";
              }
    
              container ex-4200 {
                presence "enable ex-4200";
                description
                  "URL or pathname of EX-42xx software package";
                uses apply-advanced;
    
                leaf package-name {
                  type string {
                    junos:posix-pattern "![*]";
                    junos:pattern-message "Package name cannot contain '*'.  Use TAB for filename completion";
                  }
                  description
                    "URL or pathname of software package";
                }
              }  // container ex-4200
    
              container ex-4500 {
                presence "enable ex-4500";
                description
                  "URL or pathname of EX-45xx software package";
                uses apply-advanced;
    
                leaf package-name {
                  type string {
                    junos:posix-pattern "![*]";
                    junos:pattern-message "Package name cannot contain '*'.  Use TAB for filename completion";
                  }
                  description
                    "URL or pathname of software package";
                }
              }  // container ex-4500
            }  // container auto-sw-update
    
            choice provisioning {
              leaf preprovisioned {
                type empty;
                description
                  "Only accept preprovisioned members";
              }
    
              case case_2 {
              }  // case case_2
            }  // choice provisioning
    
            leaf id {
              type jt:isosysid;
              description
                "Virtual chassis identifier, of type ISO system-id";
            }
    
            container graceful-restart {
              description
                "Configure graceful restart attributes";
              uses apply-advanced;
    
              choice enable-disable {
                leaf disable {
                  type empty;
                  description
                    "Disable graceful restart";
                }
              }  // choice enable-disable
            }  // container graceful-restart
    
            leaf no-split-detection {
              junos:must "(!("virtual-chassis heartbeat-address"))";
              junos:must-message "no-split-detection is not allowed when heartbeat-address is configured";
              type empty;
              description
                "Disable split detection. This command is recommended to only be enabled in a 2 member setup";
            }
    
            container traceoptions {
              description
                "Trace options for virtual chassis";
              uses juniper-virtual-chassis-traceoptions;
            }  // container traceoptions
    
            list member {
              key "name";
              ordered-by user;
              description
                "Member of virtual chassis configuration";
              leaf name {
                type union {
                  type string {
                    pattern "<.*>|$.*";
                  }
                  type int32;
                }
                description "Member identifier";
              }
    
              uses apply-advanced;
    
              leaf mastership-priority {
                type union {
                  type string {
                    pattern "<.*>|$.*";
                  }
                  type int32 {
                    range "0 .. 255";
                  }
                }
                description
                  "Member's mastership priority";
              }
    
              leaf role {
                type enumeration {
                  enum "routing-engine" {
                    value 0;
                    description
                      "Member to assume role of routing engine";
                  }
                  enum "line-card" {
                    value 1;
                    description
                      "Member to assume role of line card";
                  }
                }
                default "line-card";
                description "Member's role";
              }
    
              leaf serial-number {
                type string {
                  length "1 .. 12";
                }
                description
                  "Member's serial number";
              }
    
              leaf no-management-vlan {
                type empty;
                description
                  "Disable management VLAN";
              }
    
              leaf location {
                type string {
                  length "1 .. 254";
                }
                description "Member's location";
              }
            }  // list member
    
            container aliases {
              description
                "Aliases for serial numbers";
              uses apply-advanced;
    
              list serial-number {
                key "name";
                ordered-by user;
                description
                  "Set alias for a serial number";
                leaf name {
                  type string {
                    length "1 .. 12";
                  }
                  description
                    "Member's serial number";
                }
    
                uses apply-advanced;
    
                leaf alias-name {
                  type string {
                    length "1 .. 12";
                  }
                  description
                    "Provide an alias name for this serial-number";
                }
              }  // list serial-number
            }  // container aliases
    
            container mac-persistence-timer {
              description
                "How long to retain MAC address when member leaves virtual chassis";
              uses apply-advanced;
    
              leaf timer {
                type union {
                  type string {
                    pattern "<.*>|$.*";
                  }
                  type uint32 {
                    range "1 .. 60";
                  }
                }
                units "minutes";
                default "60";
                description
                  "MAC persistence time";
              }
    
              leaf disable {
                type empty;
                description
                  "Disable MAC persistence timer";
              }
            }  // container mac-persistence-timer
    
            container fast-failover {
              description
                "Fast failover mechanism";
              uses apply-advanced;
    
              leaf ge {
                type empty;
                description
                  "Fast failover on GE VC uplink ports (ring has to be formed)";
              }
    
              leaf xe {
                type empty;
                description
                  "Fast failover on XE VC uplink ports (ring has to be formed)";
              }
    
              leaf et {
                type empty;
                description
                  "Fast failover on ET VC uplink ports (ring has to be formed)";
              }
    
              container vcp {
                description
                  "Fast failover on VCP ports";
                uses apply-advanced;
    
                leaf disable {
                  type empty;
                  description "Disable";
                }
              }  // container vcp
            }  // container fast-failover
    
            container vc-port {
              presence "enable vc-port";
              description
                "Set vc ports lag hashing mode";
              uses apply-advanced;
    
              leaf lag-hash {
                type enumeration {
                  enum "packet-based" {
                    value 0;
                    description
                      "Hashing based on packet";
                  }
                  enum "source-port-based" {
                    value 1;
                    description
                      "Hashing based on source port";
                  }
                }
                default "packet-based";
                description
                  "Set vc ports lag hashing mode";
              }
            }  // container vc-port
    
            choice auto_conversion_choice {
              case case_1 {
              }  // case case_1
              leaf auto-conversion {
                type empty;
                description
                  "Enable automatic VC port conversion";
              }
            }  // choice auto_conversion_choice
    
            leaf vcp-no-hold-time {
              type empty;
              description
                "Set no hold time for vcp interfaces";
            }
          }  // container virtual-chassis
        }  // grouping virtual-chassis-group
    
        grouping apply-advanced {
          description
            "Apply advanced configuration logic";
          leaf-list apply-groups {
            type string;
            ordered-by user;
            description
              "Groups from which to inherit configuration data";
          }
    
          leaf-list apply-groups-except {
            type string;
            ordered-by user;
            description
              "Don't inherit configuration data from these groups";
          }
    
          list apply-macro {
            key "name";
            ordered-by user;
            description
              "Macro and parameters for commit script expansion";
            uses apply-macro-type;
          }  // list apply-macro
        }  // grouping apply-advanced
    
        grouping apply-macro-type {
          description
            "Macro data for commit-script expansion";
          leaf name {
            type string;
            description
              "Name of the macro to be expanded";
          }
    
          list data {
            key "name";
            uses macro-data-type;
          }  // list data
        }  // grouping apply-macro-type
    
        grouping juniper-virtual-chassis-traceoptions {
          description
            "Global tracing options for virtual chassis";
          uses apply-advanced;
    
          container file {
            description "Trace file options";
            uses vchassis_trace_file_type;
          }  // container file
    
          list flag {
            key "name";
            ordered-by user;
            description "Tracing parameters";
            leaf name {
              type enumeration {
                enum "parse" {
                  value 0;
                  description
                    "Trace configuration parsing";
                }
                enum "hello" {
                  value 1;
                  description
                    "Trace virtual chassis hello packets";
                }
                enum "psn" {
                  value 2;
                  description
                    "Trace partial sequence number (PSN) packets";
                }
                enum "csn" {
                  value 3;
                  description
                    "Trace complete sequence number (CSN) packets";
                }
                enum "lsp" {
                  value 4;
                  description
                    "Trace virtual link-state packets";
                }
                enum "normal" {
                  value 5;
                  description
                    "Trace normal events";
                }
                enum "task" {
                  value 6;
                  description
                    "Trace virtual chassis task processing";
                }
                enum "krt" {
                  value 7;
                  description
                    "Trace virtual chassis kernel events";
                }
                enum "spf" {
                  value 8;
                  description
                    "Trace virtual chassis SPF events";
                }
                enum "me" {
                  value 9;
                  description
                    "Trace virtual chassis master election events";
                }
                enum "packets" {
                  value 10;
                  description
                    "Trace virtual chassis packets";
                }
                enum "lsp-generation" {
                  value 11;
                  description
                    "Trace virtual chassis LSP generation";
                }
                enum "error" {
                  value 12;
                  description
                    "Trace virtual chassis errors";
                }
                enum "route" {
                  value 13;
                  description
                    "Trace virtual chassis routing information";
                }
                enum "state" {
                  value 14;
                  description
                    "Trace virtual chassis state transitions";
                }
                enum "auto-configuration" {
                  value 15;
                  description
                    "Trace virtual chassis ports auto configuration";
                }
                enum "graceful-restart" {
                  value 16;
                  description
                    "Trace graceful restart events";
                }
                enum "dcp-infra" {
                  value 17;
                  description
                    "Trace dcp infrastructure configuration";
                }
                enum "dcp-dev-state" {
                  value 18;
                  description
                    "Trace dcp infrastructure configuration";
                }
                enum "heartbeat" {
                  value 19;
                  description
                    "Trace virtual chassis heartbeat packets";
                }
                enum "all" {
                  value 20;
                  description "Trace everything";
                }
              }
            }
    
            leaf send {
              type empty;
              description
                "Trace transmitted packets";
            }
    
            leaf receive {
              type empty;
              description
                "Trace received packets";
            }
    
            leaf detail {
              type empty;
              description
                "Trace detailed information";
            }
    
            leaf disable {
              type empty;
              description
                "Disable this trace flag";
            }
          }  // list flag
        }  // grouping juniper-virtual-chassis-traceoptions
    
        grouping macro-data-type {
          leaf name {
            type string;
            description
              "Keyword part of the keyword-value pair";
          }
    
          leaf value {
            type string;
            description
              "Value part of the keyword-value pair";
          }
        }  // grouping macro-data-type
    
        grouping vchassis_trace_file_type {
          leaf filename {
            type string {
              junos:posix-pattern "![/ %]";
              junos:pattern-message "Must not contain '/', % or a space";
              length "1 .. 1024";
            }
            description
              "Name of file in which to write trace information";
          }
    
          leaf replace {
            type empty;
            description
              "Replace trace file rather than appending to it";
          }
    
          leaf size {
            type string;
            description
              "Maximum trace file size";
          }
    
          leaf files {
            type union {
              type string {
                pattern "<.*>|$.*";
              }
              type uint32 {
                range "2 .. 1000";
              }
            }
            default "10";
            description
              "Maximum number of trace files";
          }
    
          leaf no-stamp {
            type empty;
            description
              "Do not timestamp trace file";
          }
    
          choice world-readable-choice {
            leaf world-readable {
              type empty;
              description
                "Allow any user to read the log file";
            }
            leaf no-world-readable {
              type empty;
              description
                "Don't allow any user to read the log file";
            }
          }  // choice world-readable-choice
        }  // grouping vchassis_trace_file_type
      }  // module junos-ex-conf-virtual-chassis
    

© 2023 YumaWorks, Inc. All rights reserved.