0

I currently have a Cisco switch (CBS-350) which is autoconfigured with isc-dhcp-server and atftpd on Ubuntu 18.04. This is the dhcpd config:

subnet 192.168.0.0 netmask 255.255.255.0 {
      option routers 192.168.0.1;
      range 192.168.0.100 192.168.0.120;
      option tftp-server-name "192.168.0.1"; 
      option bootfile-name "config/cisco-switch1.cfg"; }

I would like to have another different switch model on the same subnet that I would like also to be autoconfigured. Any idea on how I can achieve this?

Both switches will not be running at the same time. I just would like to have each switches take the good autoconfig file.

Thanks for your help

CasimirEX
  • 13
  • 3

2 Answers2

1

Typically you would autoconfig enough of a device configlet to allow it to be manageable - VLANs, SNMP, username/password, routing, etc. You may not need to push a full config. Then the 'template' of this baseline config could be used for multiple devices, especially if DHCP allocated IPs are an option.

THEN you would use some 2nd stage configuration management system to push the remaining, device-specific parts.

Otherwise you have to start doing some distinguishing identifiers (eg. MAC address or serial number) and use that to map a device to a waiting config on the file server.

SNMPguy
  • 11
  • 3
0

I've found that using a SubClass might be an option:

      subclass "Vendor-Class" "CiscoPnP" {
          option bootfile-name "config/cisco-switch1.cfg"; 
      }

Unfortunately, both switches have the same Vendor-Class (CiscoPnP) so I cannot use this to distinguished them.

CasimirEX
  • 13
  • 3