junos_zeroize - Erase all data, including configuration and log files, on a device running Junos OS.

Author:Jeremy Schulman, Juniper Networks

Synopsis

New in version 1.0.0.

Execute the Junos OS request system zeroize command to remove all configuration information on the Routing Engines and reset all key values on a device running Junos OS. The command removes all data files, including customized configuration and log files, by unlinking the files from their directories. The command also removes all user-created files from the system including all plain-text passwords, secrets, and private keys for SSH, local encryption, local authentication, IPsec, RADIUS, TACACS+, and SNMP. This command reboots the device and sets it to the factory default configuration. After the reboot, you must log in through the console as root in order to access the device.

Options

parameter required default choices comments
console no None
    SERIAL or TERMINAL-SERVER port setting, per use with the netconify utility
    host no
      Set to {{ inventory_hostname }}
      logfile no None
        Path on the local server where the progress status is logged for debugging purposes
        passwd no assumes ssh-key active
          Login password
          port no 830
            TCP port number to use when connecting to the device
            user no $USER
              Login username
              zeroize yes None
                Safety mechanism. You MUST set this to 'zeroize'.

                Note

                Requires junos-eznc >= 1.2.2

                Note

                Requires junos-netconify >= 1.0.1, when using the console option

                Examples


                - junos_zeroize:
                    host={{ inventory_hostname }}
                    zeroize="zeroize"
                

                Note

                You MUST either use the host option or the console option to designate how the device is accessed.