cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
622
Views
6
Helpful
6
Replies
Highlighted
Enthusiast

Deleting/Updating Templates

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
Cisco Employee

Re: Deleting/Updating Templates

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
Highlighted
Cisco Employee

Re: Deleting/Updating Templates

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.

Highlighted
Enthusiast

Re: Deleting/Updating Templates

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

Highlighted
Cisco Employee

Re: Deleting/Updating Templates

Hi Zak,

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

Highlighted
Cisco Employee

Re: Deleting/Updating Templates

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

Highlighted
Enthusiast

Re: Deleting/Updating Templates

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.

Cisco Employee

Re: Deleting/Updating Templates

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

This widget could not be displayed.