-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 5/05/10 1:53 PM, Geoff Crompton wrote: > This might be a crazy idea, but it just popped into my head, and I > wanted to know if it's possible. Perhaps not possible right now, but > possible in a theoretical sense. > > Is it possible that puppet could be modified to be used to manage > switches that have a command line based interface? > > When I manage our Allied Telesis switches (which have a CLI similar to > cisco IOS) I wonder if I could control it via a puppet-like node: > > node 'switch-101' { > vlan { storage: > id => 1234, > untagged_ports => "3/e1, 4/e3", > tagged_ports => "1/e1-2/e48", > } > include gvrp > include stp::rstp > stp::portfast { "1/e1-e48,2/e1-48",3/e1-48": } > } > > > Now I know we probably can't get puppet to run on the switch, but we can > get a host to ssh or telnet to the switch, and to download the current > configuration of the switch. >
It's feasible - you could create a type and provider that connects to the switch and interacts with the CLI to retrieve the configuration, manipulate it in some way (depending on how complex the format is) and then send it back and apply it. Obviously there would be limitations - no Factor facts and you'd have to create a dummy node I guess because the switch wouldn't be a real "node". Others may have niftier ideas on how to do this - an easier mechanism might be use Puppet's REST API to integrate with the switches own management tool if it has an exposed API. Regards James Turnbull - -- Author of: * Pro Linux System Administration (http://tinyurl.com/linuxadmin) * Pulling Strings with Puppet (http://tinyurl.com/pupbook) * Pro Nagios 2.0 (http://tinyurl.com/pronagios) * Hardening Linux (http://tinyurl.com/hardeninglinux) -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEVAwUBS+DzNCFa/lDkFHAyAQKpsAf+J2ILNsTi6+A8JekLF5tAES+BNHdqnd9s tlouVVokiMebNmh0m51aguvmTN2V4pa5RYQpmbfVqK1SI3m/UT68EH871vMbc6KG xUpZTbR2zhin46qMWVZReWsJq2r9yLXex3fM66/YTh25J7S9j/kP8OpUKdguAW5L cB66vXTlJjO7IXSZwyZzP3lvllShJ0sZAb/RvIrfKE9XXnCU5x7kF8gMLpQqjrqB E/Dnm0Vi02b+agpzeapqbPf+CEHgBVaBIdZoPg7hAyBPIsvNoD1/pUIXkfU7/96/ ADF5O+BXbXXS5S0CgZ/SoD979VCEWwWW2Dy0CmuTLgfxJeuhdg0/KQ== =QYIs -----END PGP SIGNATURE----- -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-us...@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.