cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
8967
Views
13
Helpful
12
Replies

Template locked

pp490a001
Level 1
Level 1

I was trying to edit device template for multiple devices, while I was crosschecking the new configs with existing, vManage timed out and logged out my session.

Now when I try to edit the template again, I get following message:

Template locked in edit mode.: Template is locked by user: since:2019-12-11 18:46:39,218

How can I clear the lock?

Will it be cleared by itself?

1 Accepted Solution

Accepted Solutions

HashamM
Cisco Employee
Cisco Employee

you can use the API call to clear the stuck process for template push

 

https://<vmanage-ip>/dataservice/device/action/status/tasks

 

Find the process id and then clear it


https://<vmanage-ip>/dataservice/device/action/status/tasks/clean?processId=<Process-id>

View solution in original post

12 Replies 12

HashamM
Cisco Employee
Cisco Employee

you can use the API call to clear the stuck process for template push

 

https://<vmanage-ip>/dataservice/device/action/status/tasks

 

Find the process id and then clear it


https://<vmanage-ip>/dataservice/device/action/status/tasks/clean?processId=<Process-id>

This didn't work for me - I have no processes running but still get the msg?

Not for me either. I have vManage verion 18.4.4 and have no task running but still get the message.

Yeah I gave up,b just copied the locked feature templates and moved the device templates over to the new ones and trashed the old ones.

Have hit this in production as well as lab so I think there's some niche scenario with your browser and not logging out properly

Hi  Johann Lo,

When template gets locked, then in this case you just have to logged out from vManage and login again or you can wait for 60 second to expire the session.

 

There is nothing you can do about it. I have faced many time with the same issue.

Regards,
Rohit Raj

This worked for me.

Thanks a lot for sharing

RohitRaj03827
Spotlight
Spotlight

You can either wait for the session to expire or just logged out from vmanage and refresh the web url and login again. It will automatically clear the session. I have faced many time with the template locked issue. By default timer is 60 second.

 

If this post has answered your query, please mark as a solve and hit helpful button.

 

 

Regards,

Rohit Raj

Regards,
Rohit Raj

This time waiting for 60 seconds doesn't help. Rebooting the vManage doesn't help either. It is still locked. Someting weird is going on in vManage in general. Loading feature template page takes ages. I opened TAC case about this.

Hi ,

Has TAC Reverted on this on how to remove the Lock ? 

Rgds,

You may need a TAC case. But can check the possible reason by following below steps

 

Step 1 : Login to vManage

Step 2 : Go to https://vManage_IP/logsettings.html

Step 3 :  Enable viptela.enable.query.builder.log

Step 4 : Recreate the issue

Step 5 : Check logs in vmanage-server.log

If you see similar to below logs, then get TAC's assistance to clear the lock

21-Apr-2019 06:08:29,309 UTC INFO  [EMSUROVMA1] [Neo4JDBQueryBuilder] (default task-505) |default| Executing builtQuery :MATCH (n:vmanagedbTEMPLATELOCKNODE)  WHERE (n.`templateId` in ['7332ae09-c00e-4038-9197-ee2609a0f0c3']) RETURN  n._rid as _rid, id(n) as _id,  n.`userSessionUserName` as `userSessionUserName` ,n.`startTime` as `startTime` , calledBy : com.viptela.vmanage.server.deviceconfig.template.lock.DeviceTemplateLock.isTemplateLocked:75
21-Apr-2019 06:08:29,312 UTC INFO  [EMSUROVMA1] [DeviceTemplateLock] (default task-505) |default| Template lock is present for templateId:7332ae09-c00e-4038-9197-ee2609a0f0c3
21-Apr-2019 06:08:29,312 UTC ERROR [EMSUROVMA1] [RestfulDefaultExceptionMapper] (default task-505) |default| Exception while processing request : com.viptela.vmanage.server.deviceconfig.template.TemplateException: Template is locked by user:afaragya since:2019-04-21 04:31:28,172
21-Apr-2019 06:08:29,306 UTC INFO  [EMSUROVMA1] [Neo4JDBQueryBuilder] (default task-505) |default| Executing builtQuery :MATCH (n:vmanagedbTEMPLATELOCKNODE)  WHERE (n.`sessionId` = '136QKqtWTU3_upOV3NvzqWwiRbqhKpIM3Jbd1MnT') RETURN  n, id(n) as _id, calledBy : com.viptela.vmanage.server.deviceconfig.template.lock.TemplateLock.isUserAlreadyEditing:153

Hi Hasham,

 

Thanks for your response . Is there any way to remove the Lock or some doc for the same ?  I have done a temporary Workaround but wanted to know the solution on how to unlock/release a Locked Template as will be very useful in Production Scenarios. Currently i do not have TAC access so unable to raise a Case. Any help will be appreciated . Thanks.

 

Rgds,

Saji Samuel 

 

I found a workaround for this. If your template is locked in edit mode while editing as the user xxxx, log out user xxxx and log in using admin and try to edit. Then vManage allows you to edit.

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: