Vyatta NOS documentation

Learn how to install, configure, and operate Vyatta Network Operating System (Vyatta NOS), which helps to drive our virtual networking and physical platforms portfolio.

Browse YANG file contents

An example of how to display the content of a YANG file in a tree-like structure.

You can browse YANG files to determine all configuration and state options, together with notifications and RPCs. The pyang utility is useful as it makes it easier to visualize and filter parts of the information.

In this example, we use this utility to display a YANG module in a tree-like structure.

Use pyang to display the YANG module named vyatta-service-ssh-v1.
$ pyang -f tree vyatta-service-ssh-v1.yang
module: vyatta-service-ssh-v1
  augment /system:system/system-login:login:
  augment /service:service:
    +--rw ssh!
       +--rw allow-root? empty
       +--rw authentication-retries? uint32
       +--rw client-alive-interval? uint32
       +--rw client-alive-attempts? uint16
       +--rw timeout? uint32
       +--rw key-security-strength? enumeration
       +--rw disable-password-authentication? empty
       +--rw port* uint32
       +--rw listen-address* union
       +--rw disable-host-validation? empty
       +--rw disable-tcp-forwarding? empty
       +--rw permit {ssh-cbc}?
          +--rw cipher* enumeration
          +--rw key-exchange-algorithm* enumeration