OneClick Upgrade Fails On fediz_config.xml - "keyStore" must not contain the '<' character

book

Article ID: 225078

calendar_today

Updated On:

Products

CA Spectrum DX NetOps

Issue/Introduction

While upgrading OneClick  from 10.4.1 to  21.2.X the install fails and the following error is seen in the postinst.xx.xx log file

********** Started: Wed Sep 29 10:33:33 2021 **********
running Custom Script Install-Tools/CUS/tomct.cus
 Starting tomct.cus
Tomcat upgrades from: 10.4.1.0.215 09/28/2021 17:12
~
~
Updating log4j configuration
Starting ServerConfigurationCreator
[Fatal Error] fediz_config.xml:9:33: The value of attribute "file" associated with an element type "keyStore" must not contain the '<' character.
com.aprisma.tomcat.install.TomcatConfigException: Error occurred while updating SAML config files.
org.apache.commons.configuration2.ex.ConfigurationException: Error parsing file:/opt/Spectrum/Install-Tools/LOGS/21.2.2.0.15_xxxxxxxx/tomcatBackup/fediz_config.xml
 at com.aprisma.tomcat.install.ServerConfigurationCreator.updateSAMLConfigs(ServerConfigurationCreator.java:321)
 at com.aprisma.tomcat.install.ServerConfigurationCreator.doCreateConfiguration(ServerConfigurationCreator.java:234)
 at com.aprisma.tomcat.install.ServerConfigurationCreator.createConfiguration(ServerConfigurationCreator.java:122)
 at com.aprisma.tomcat.install.ServerConfigurationCreator.main(ServerConfigurationCreator.java:98)

** ERROR during creating tomcat configurations

Script Install-Tools/CUS/tomct.cus has FAILED
********** Completed: Wed Sep 29 10:33:35 2021 **********

It may happen that the error message doesn't include the file name fediz_config.xml, but still this document applies to resolve that problem:

********** Started: Wed Feb 23 10:57:27 2022 **********
running Custom Script Install-Tools/CUS/tomct.cus
 Starting tomct.cus
Tomcat upgrades from: 10.4.1.0.215 02/23/2022 09:47
~
~
Updating log4j configuration
~
~
Starting ServerConfigurationCreator
com.aprisma.tomcat.install.TomcatConfigException: JAXBException occurred while updating SAML config files.
javax.xml.bind.UnmarshalException
 - with linked exception:
[org.xml.sax.SAXParseException; lineNumber: 9; columnNumber: 33; The value of attribute "file" associated with an element type "keyStore" must not contain the '<' character.]
 at com.aprisma.tomcat.install.ServerConfigurationCreator.updateSAMLConfigs(ServerConfigurationCreator.java:349)
 at com.aprisma.tomcat.install.ServerConfigurationCreator.doCreateConfiguration(ServerConfigurationCreator.java:245)
 at com.aprisma.tomcat.install.ServerConfigurationCreator.createConfiguration(ServerConfigurationCreator.java:133)
 at com.aprisma.tomcat.install.ServerConfigurationCreator.main(ServerConfigurationCreator.java:109)

** ERROR during creating tomcat configurations

Script Install-Tools/CUS/tomct.cus has FAILED
********** Completed: Wed Feb 23 10:57:27 2022 **********
 

Cause


The installer was trying to preserve settings from the just backed up fediz_config.xml file and ran into a parse error due to an improperly formatted word.

The fediz_config.xml file contained <SPECROOT> inside of xml tags.

example line that caused the parse errors

Environment

Release : 10.4.x, 21.2.x

Component : OneClick

Resolution


Manually modified the backed up fediz_config.xml changing the <SPECROOT> reference to $SPECROOT
  
$SPECROOT/Install-Tools/LOGS/21.2.x.x.xx_xxxxxxxx/tomcatBackup/fediz_config.xml
 


Reran the 21.2.x installer which completed successfully and Spectrum is fully functional.

Additional Information


Preventative Measure:
     Check existing fediz_config.xml files for <SPECROOT> and if found, change to $SPECROOT prior to running the upgrade. If not found then
        the problem should not occur.

On Linux systems using find/exec/grep  from bash (replace install dir /usr/Spectrum as necessary)

    find /usr/Spectrum/ -name fediz_config.xml -exec grep keyStore {} \;

     

Attachments