cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2036
Views
6
Helpful
6
Replies

Deleting/Updating Templates

zlantz
Level 4
Level 4

Since the addition of templates and configurations as separate entities, we have been using templates to hold our general templates for a certain switch model. This includes our full standard deployment config with variables for vlan differences. Configurations we have been using for very specific deployments. For example, we are starting our 3750G LCM. So we will take a copy of the config before swapping them out and convert that over to what works with our 3850/3650s and use an entire full config, hard coded essentially, and deploy the new switches using that "configuration". 

The issue I am running into is that as our environment changes, I need to update our templates. I would like to delete the old and add the new because I time stamp the updates within the template itself. However, I can't delete the templates if they are associated with any rule, failed, pending, or provisioned.  So I end up with multiple "3850/3650 template" under templates. I would also l like to keep a record of all deployments that were done with PNP so I wouldn't go an delete every rule once they are provisioned, and deleting rules warns you that it might reset the device so I am always wary of doing so in production.

Just looking for a solution or maybe I am misunderstanding what configurations and templates are and how they are meant to be used from the dev's aspects.

1 Accepted Solution

Accepted Solutions

Sairam,

I think Zak brought up a good point on version control of template. If we just keep replacing the old version, it is hard to track which device config from which version of the same template if we do not have version control. Obviously, this will be enhancement. Also need to consider if we can have a report on the number of device config generated by which template.

Regards,

Peng

View solution in original post

6 Replies 6

sairasan
Cisco Employee
Cisco Employee

Hello Zak,

If you have templates/configs associated with provisioned devices, you should be able to delete them. Devices pending, in error etc. have this restriction in order to prevent dangling configs associated with devices but have been deleted.

You could simply upload the template again without deleting and it will get updated. But if there are new properties added, those will have to be taken care of before trying to provision.

I have a device that provisioned successfully, but I can not delete the template I used for that device. Just upgraded to the latest version of APIC-EM this morning and still having this issue.2017-02-13_1618.png

Here is the device mentioned in the error when attempting to delete the template:2017-02-13_1619.png

Hi Zak,

This looks like a bug and we will fix it for provisioned devices.

Hi Zak,

if it helps, you can replace, rather than delete/upload a configuration file.  You should be able to do this for templates too.

Rather than delete the file, just select upload, and choose replace.

Adam

I had done this last week and ran into an issue where it would overwrite the template, but I would apply it to a new rule in a existing project and it would take the old version of the template and try and use that within the new rule. I eventually had to delete the whole project and start another one. This resolved the issue but I haven't been able to reproduce it so far to give you guys any info on it.

Sairam,

I think Zak brought up a good point on version control of template. If we just keep replacing the old version, it is hard to track which device config from which version of the same template if we do not have version control. Obviously, this will be enhancement. Also need to consider if we can have a report on the number of device config generated by which template.

Regards,

Peng

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:


This community is intended for developer topics around Data Center technology and products. If you are looking for a non-developer topic about Data Center, you might find additional information in the Data Center and Cloud community