Category: junos-automation

Fetching JUNOS config as xml

If you want to fetch a junos device config remotely first configure netconf on the device via; junos#set system services netconf ssh junos#commit Then connect to the junos device (IP via an ssh client from a linux host and redirect the output to a file which is the xml config of the device indeed:
Read More »

Simple Junos Commit Script

Here is a simple junos commit script that checks if a given interface is assigned to trust zone or not. It is very basic of course but can be extended using junos automation reference documents. /* basic-sanity-check.slax */ version 1.0; ns junos = "*/junos"; ns xnm = ""; ns jcs = ""; import "../import/junos.xsl"; match
Read More »