Jive-Managed Applications

An installation of the Jive platform will host one or more distinct applications. All managed applications have both system-level scripts that are invoked at system startup and shutdown, as well as scripts locally available to the "jive" system user created when the platform is installed. The following operations are available for managing and monitoring managed applications.

Start Jive-Managed Applications

To start all Jive-managed applications, a standard "init" script is avialable for use by the root user. This script is invoked at system boot to start all managed applications.

[root@biodome:~]$ /etc/init.d/jive-application start
JIVE_HOME set to /usr/local/jive
Starting jive-application: 
All applications started successfully (1 total).

In addition to the system scripts, the jive user may start any individual application or all managed applications using the appstart command. The appstart command is automatically added to the jive user's interactive shell path and may be run after becoming the jive user (commonly via the "su" command). The following example demonstrates the root user using the "su" command to become the jive user and then the use of the appstart command to start the "sbs" application.

[root@biodome:~]$ su - jive
[1456][jive@biodome:~]$ appstart --verbose sbs
Handling applications ['sbs']
Starting sbs...
Executing /usr/local/jive/applications/sbs/bin/manage start
sbs started successfully.

Stop Jive-Managed Applications

To stop all Jive-managed applications, execute the system stop script.

[root@biodome:~]$ /etc/init.d/jive-application stop
JIVE_HOME set to /usr/local/jive
Stopping jive-application: 
All applications stopped successfully (1 total).

Similar to the appstart command, the appstop command may be executed to stop managed applications as the jive user.

[1457][jive@biodome:~]$ appstop --verbose
Stopping sbs...
Executing /usr/local/jive/applications/sbs/bin/manage stop
sbs stopped successfully.
Cleaning sbs application work directory at /usr/local/jive/var/work/sbs.
All applications stopped successfully (1 total).

Monitoring Jive-Managed Applications

To show all running Jive-managed applications, execute the appls command with the "--running" flag as the jive user as in the following example.

[1507][jive@biodome:~]$ appls --running
               stage    running (pid=2799)

In this example, the "stage" application is currently running with a process ID of 2799. To monitor the individual process, standard tools like the "ps" command can be used with the process ID from appls output as in the following example.

[1542][jive@biodome:~]$ ps -ef | grep 2799 | grep -v grep
jive      2799     1  0 15:06 pts/0    00:00:16 /usr/local/jive/java/bin/java -XX:+PrintClassHistogram -XX:+PrintTenuringDistribution -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true -Xloggc:/usr/local/jive/var/logs/stage-gc.log -Xmx2048m -Xms2048m -XX:MaxPermSize=512m -Djive.home=/usr/local/jive -Djive.instance.home=/usr/local/jive/applications/stage/home -Djive.name=stage -Djive.context=/stage -Djive.logs=/usr/local/jive/var/logs -Djive.application=/usr/local/jive/applications/stage/application -Djive.work=/usr/local/jive/var/work/stage -Djive.app.cache.ttl=10000 -Djive.app.cache.size=10240 -Dserver.port=9500 -Dhttp.addr='127.0.0.1' -Dhttp.port=9502 -Dajp.addr=127.0.0.1 -Dajp.port=9501 -Dajp.buffer.size=4096 -Dajp.max.threads=50 -Dlog4j.configuration=file:///usr/local/jive/applications/stage/conf/log4j.properties -Dtangosol.coherence.clusteraddress='224.224.224.224' -Dtangosol.coherence.clusterport=9503 -Dcatalina.base=/usr/local/jive/applications/stage -Dcatalina.home=/usr/local/jive/tomcat -Djava.io.tmpdir=/usr/local/jive/var/work/stage -classpath /usr/local/jive/applications/stage/bin//bootstrap.jar:/usr/local/jive/applications/stage/bin/tomcat-juli.jar::/usr/local/jive/java/lib/tool.jar org.apache.catalina.startup.Bootstrap start

Alternatively, the following example combines both operations into a single command.

[1539][jive@biodome:~]$ ps -ef | grep  'appls --running | awk -F'=' '{print $2}' | tr -cd '[:digit:]''
jive      2799     1  0 15:06 pts/0    00:00:16 /usr/local/jive/java/bin/java -XX:+PrintClassHistogram -XX:+PrintTenuringDistribution -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true -Xloggc:/usr/local/jive/var/logs/stage-gc.log -Xmx2048m -Xms2048m -XX:MaxPermSize=512m -Djive.home=/usr/local/jive -Djive.instance.home=/usr/local/jive/applications/stage/home -Djive.name=stage -Djive.context=/stage -Djive.logs=/usr/local/jive/var/logs -Djive.application=/usr/local/jive/applications/stage/application -Djive.work=/usr/local/jive/var/work/stage -Djive.app.cache.ttl=10000 -Djive.app.cache.size=10240 -Dserver.port=9500 -Dhttp.addr='127.0.0.1' -Dhttp.port=9502 -Dajp.addr=127.0.0.1 -Dajp.port=9501 -Dajp.buffer.size=4096 -Dajp.max.threads=50 -Dlog4j.configuration=file:///usr/local/jive/applications/stage/conf/log4j.properties -Dtangosol.coherence.clusteraddress='224.224.224.224' -Dtangosol.coherence.clusterport=9503 -Dcatalina.base=/usr/local/jive/applications/stage -Dcatalina.home=/usr/local/jive/tomcat -Djava.io.tmpdir=/usr/local/jive/var/work/stage -classpath /usr/local/jive/applications/stage/bin//bootstrap.jar:/usr/local/jive/applications/stage/bin/tomcat-juli.jar::/usr/local/jive/java/lib/tool.jar org.apache.catalina.startup.Bootstrap start

List Jive-Managed Applications

A list of all managed applications can be obtained by executing the appls command as the jive user as shown in the following example.

[1507][jive@biodome:~]$ appls
               stage    running (pid=2799)
         development    stopped (pid=None)

In the output above, the "stage" application is running with process ID 2799, the "development" application is not running.

Jive-Managed Application Networking

The network ports and addresses used by a managed Jive application will vary depending on usage. The default Jive application will work on the following addresses and ports.

Service Protocol Address
Application server management TCP 127.0.0.1:9000
HTTP TCP

127.0.0.1:9001

AJP TCP 127.0.0.1:9002
Multicast Cluster UDP/Multicast 224.224.224.224:9003

Note that managed applications should not be accessed directly via the HTTP 9001 port and it is recommended that a firewall prevent access to that port. Its existence is for troubleshooting and support purposes only and is not intended for production use.

To validate that the TCP services are present for a default install, execute the following command.

[root@melina ~]# lsof -n -P | grep jive | grep java | grep LISTEN
java      3204      jive   30u     IPv6      31631                 TCP 127.0.0.1:9001 (LISTEN)
java      3204      jive   31u     IPv4      31632                 TCP 127.0.0.1:9002 (LISTEN)
java      3204      jive   39u     IPv4      38046                 TCP 127.0.0.1:9000 (LISTEN)

Jive-Managed Application Logs

Log files for Jive-managed applications are located in the var/logs directory of the jive user's home directory (/usr/local/jive/var/logs). The following log files can be consulted for further information on the status of individual applications. Each file will be prefixed with the name of the corresponding application. For example, for the "stage" application, the container log file will be named "stage-container.log".