[Edit 1] Creating an "Advanced" template with the same prerequisite and action actually works, even though the template preview function tells me that they do exactly the same thing. Just wonder if anyone else has seen this or is it just my installation has somehow gone bad.
<hr>
Created a simple template to remove the "enable password" command if a device has the "enable secret". I called the template "noEnablePassword".
It's a "Basic" template that applies to Routers, Switches and Hubs.
It has "Check for compliance only if the following condition is satisfied" with a global CLI command:
+ [#enable secret .*#]
In the "Compliance Block" it simply has one global CLI command:
- [#enable password .*#]
I save the template. LMS says that it is successfully created.
Next I went to "Compliance Check". I selected the template just created and clicked the "Compliance Check" button.
And I got this (every time I do compliance check, in LMS 3.2 and after upgrading to 3.2.1):
HTTP Status 500 -
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
java.util.NoSuchElementException
java.util.StringTokenizer.nextToken(StringTokenizer.java:332)
com.cisco.nm.rmeng.dcma.ui.helper.BaseLineTableData.setTable(BaseLineTableData.java:90)
com.cisco.nm.rmeng.dcma.ui.action.DCMABaseLineComplianceAction.perform(DCMABaseLineComplianceAction.java:1030)
org.apache.struts.action.ActionServlet.processActionPerform(ActionServlet.java:1786)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1585)
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:509)
javax.servlet.http.HttpServlet.service(HttpServlet.java:647)
javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
com.cisco.nm.cmf.util.AccessLogFilter.doFilter(AccessLogFilter.java:128)
note The full stack trace of the root cause is available in the Apache Tomcat/5.5.29 logs.