Juniper ZTP/Homer
Goal
In this Tutorial, we are going to setup a ZTP environment to be able to run the basic configuration on a new Juniper switch. Once the basic configuration is done, we will run homer to deploy the switch configuration. If you want to know more about homer please check: https://wikitech.wikimedia.org/wiki/Homer
Prerequisites
For this tutorial I will be using :
- EVE-NG 2.0.3-112
- VQFX model: vqfx-10000 running JUNOS 19.4R1.10
- DHPC/TFTP VM (IP:10.192.16.5/install1001.dfw.labnet)
- Homer VM(IP:10.192.32.17/homer1001.dfw.labnet)
- Netbox VM(IP:10.192.32.3/netbox1001.dfw.labnet)
All the VM's are running on Proxmox 7.3.4
Diagram
Setup and Configuration
The section is the just the section needed to make ztp work
DHCP configuration
#######################################################################
# ZTP Sample Config begins here:
#######################################################################
option option-150 code 150 = ip-address;
set vendor-string = option vendor-class-identifier;
option space ZTP;
option ZTP.image-file-name code 0 = text;
option ZTP.config-file-name code 1 = text;
option ZTP.image-file-type code 2 = text;
option ZTP.transfer-mode code 3 = text;
option ZTP.alt-imagefile-name code 4 = text;
option ZTP-encapsulation code 43 = encapsulate ZTP;
# mgmt nework
subnet 10.193.0.0 netmask 255.255.255.0 {
authoritative;
option subnet-mask 255.255.255.0;
option option-150 10.192.16.5; #TFTP server
option routers 10.193.0.1;
option broadcast-address 10.193.0.255;
option domain-name "mgmt.dfw.labnet";
default-lease-time 600;
max-lease-time 7200;
}
group {
vendor-option-space ZTP;
include "/etc/dhcp/juniper_ztp";
}