skip to main content
TCMAN Reference : Server actions : Display and manage an instance's configuration (config)
 

Display and manage an instance's configuration (config)

Purpose

View, add, update, or delete the property values specified in ../conf/appserver.properties and in ../conf/catalina.properties.
When you run tcman.sh config with no parameters, it displays the core Tomcat server’s configuration, and all the properties in both .../conf/appserver.properties and .../conf/jvm.properties. Note, however, that you can only view jvm.properties. You cannot modify its contents with the config action.

Syntax

tcman.sh config [general_options] [prop_name|prop_name=value|+prop_name=value|~prop_name]

Parameters

general_options
Specify one or more of the general TCMAN options. Run tcman.sh help config to see which general options are appropriate.
prop_name
Display the specified property and its value.
prop_name=value
Set the value of a property that exists in .../conf/appserver.properties.
+prop_name=value
Add a new property to .../conf/appserver.properties and set its value.
~prop_name
Remove the specified property from .../conf/appserver.properties.

Examples

Show the configuration and properties of acme1, an instance of the core server, pashome:
$: /psc/acme1/bin/tcman.sh config
Using CATALINA_BASE: /psc/acme1
Using CATALINA_HOME: /psc/pashome
Using CATALINA_TMPDIR: /psc/acme1/temp
Using JRE_HOME: /tools/linuxx86_64/java64/jdk1.7.0_02/
Using CLASSPATH: /psc/pashome/bin/bootstrap.jar:/psc/pashome/bin/tomcat-juli.jar
Using CATALINA_PID: /psc/acme1/temp/catalina.pid
Server version: Apache Tomcat/7.0.42
Server built: Jul 2 2013 08:57:41
Server number: 7.0.42.0
OS Name: Linux
OS Version: 2.6.18-164.el5
Architecture: amd64
JVM Version: 1.7.0_02-b13
...
Display the value of a single property:
$: /psc/acme1/bin/tcman.sh config psc.as.http.port
psc.as.http.port=8501
Update the value of a property that exists in the appserver.properties file and then check the value:
$: /psc/acme1/bin/tcman.sh config psc.as.http.port=6543
$: tcman.sh config psc.as.http.port
psc.as.http.port=6543
Add a new property/value pair to the appserver.properties file and check the value:
$: /psc/acme1/bin/tcman.sh config +my.home.dir=/home/jarhead
$: tcman.sh config my.home.dir
my.home.dir=/home/jarhead
Update the server certificate in the catalina.properties file (see https://docs.oracle.com/cd/E19879-01/821-0185/ablqz/index.html for information about generating, exporting, and downloading a new server certificate):
$: /psc/acme1/bin/tcman.sh config psc.as.https.keyalias=myNewCert
Remove a property/value pair from the appserver.properties file and check if deletion was successful:
$: /psc/acme1/bin/tcman.sh config ~my.home.dir
$: tcman.sh config my.home.dir
Property does not exist - my.home.dir
Caution: There are no restrictions to property removal. The server will be unable to start if you remove a property required by conf/server.xml.

Notes

*All property names are case sensitive.
*You cannot enter multiple property names (prop_name) on the command line to view, update, or add properties to the appserver.properties file.
*You cannot use the config action to update existing values or add new values to the jvm.properties file