在 vSRX 虚拟防火墙上部署 phone-home 客户端和全自动部署
您可以使用 phone-home 客户端和 ZTP 为 vSRX 虚拟防火墙提供用户定义的配置文件。VMWare、KVM(基于内核的虚拟机)虚拟机管理程序以及各种部署环境(如 AWS(Amazon Web Service)、GCP(Google Cloud Platform)、OCI(Oracle Cloud Infrastructure)和 Microsoft Azure)支持 phone-home 客户端和 ZTP。
vSRX 虚拟防火墙的出厂默认配置
以下是 phone-home 客户端的出厂默认配置:
set system services web-management http interface fxp0.0 set system services web-management https system-generated-certificate set system services web-management https interface fxp0.0 set system name-server 8.8.8.8 set system name-server 8.8.4.4 set system syslog file messages any any set system license autoupdate url https://ae1.juniper.net/junos/key_retrieval set system phone-home server https://redirect.juniper.net set system phone-home rfc-compliant set interfaces fxp0 unit 0 family inet dhcp
注意:
在首次重新启动之前,您必须执行“KVM 上的 vSRX 虚拟防火墙 XML”和“vSRX 虚拟防火墙虚拟机编辑设置”中建议的更改。这可确保在首次启动期间使用 PHC 命令加载正确的出厂默认配置。
在 KVM 上部署 ZTP
要在 KVM 上部署 ZTP,请在虚拟机部署 XML 文件中设置 entry name='version' to phone-home-true 。
例如:
<os> …. <smbios mode='sysinfo'/> </os> <sysinfo type='smbios'> <system> <entry name='version'>phonehome=true</entry> </system> </sysinfo>
在 VMWare 上部署 ZTP
要在 VMWare 上部署 ZTP,请在 VMWare GUI 中启用 开放式虚拟化格式 (OVF) 设置,并将 phone-home 设置为 true。
- 要在 VMWare GUI 中启用 OVF,请转至 编辑虚拟机设置 | vApp 选项 |OVF 设置:OVF 环境透明 |VMWare 工具:启用。
- 要在 VMWare GUI 中启用 phone-home 客户端,请转至 编辑虚拟机设置 | vApp 选项 |属性 |phone-home true .
在 Amazon Web Services、Google Cloud Platform 和 Oracle CIoud Infrastructure 上部署 ZTP
要在 Amazon Web Services、Google Cloud Platform 和 Oracle CIoud Infrastructure 上启用 ZTP,请在 CLOUD-INIT USER-DATA 文件中添加以下 phone-home 客户端配置:
system { name-server { 8.8.8.8; 8.8.4.4; } syslog { file messages { any any; } } services { ssh; web-management { http { interface fxp0.0; } https { system-generated-certificate; interface fxp0.0; } } } license { autoupdate { url https://ae1.juniper.net/junos/key_retrieval; } } phone-home { server https://redirect.juniper.net; rfc-compliant; } } interfaces { fxp0 { unit 0 { family inet { dhcp; } } } }
在 Microsoft Azure 上部署 ZTP
若要在 Microsoft Azure 上启用 ZTP,请在CLOUD_INIT_CONFIG的“ write_files ”部分添加以下电话主客户端配置 。JSON 文件:
{ "content": "configure\nset system name-server 8.8.8.8\nset system name-server 8.8.4.4\nset system phone-home server https://redirect.juniper.net\nset system phone-home rfc-compliant\nset interfaces fxp0 unit 0 family inet dhcp\ncommit\n", "path": "/var/tmp/test_config" },