Redirecting to styles/chan_serv_apache.xml...
If page does not load within 5 seconds, click here.
mPower Server: ChannelIT, ServIT
Apache/Tomcat Platform
For mPower applications:
ChannelIT
ServIT
Describes platform configuration and software installation for ChannelIT and ServIT on the Apache/Tomcat Platform.
This document assumes you have a working knowledge of Linux or Unix administration, as well as knowledge of Java, Apache, mod_jk, and Tomcat. Contact your NetSol representative for assistance if needed.
If you are using DocIT (Web Document Generation) in conjunction with ChannelIT, install and configure the DocIT server first. You will need the host address and listening port of Tomcat on the DocIT server to correctly configure the web.xml file on the mPower server so that the two can communicate.
General Preparation
System Requirements
Review the mPower Server hardware and software requirements. You must install and configure all required software before installing the mPower program files.
LeasePak Server
The mPower server requires an installed and working LeasePak server. Refer to documentation in the LeasePak System Administration Guide for more information.
mPower Users
To use one of the mPower applications, you must first set up the appropriate user(s) on the LeasePak server. For more information, refer to the mPower Users section of the document LeasePak and mPower Users.
To finish setting up the LinkIT (Web Services API) user or ServIT (Web Customer Self Service) users, you will need to install the mPower software (as detailed below) before editing the css_db.xml or web.xml files.
mPowerd Daemon on the LeasePak Server
You can install the mPower server on its own machine or on the same machine as the LeasePak server. In either case, you must set up the mPowerd daemon on the LeasePak server. For more information about daemons and services, refer to the document LeasePak Server Configuration and Maintenance in the LeasePak System Administration Guide.
On the LeasePak server:
All OS Platforms: create entry in /etc/services
official_service_nameport_number/protocol_name [aliases] [#comment]
Create an entry in the /etc/services file using the following format:
official_service_name
Must be unique for the server. For example, mPowerd_v53a_5356.
port_number/protocol_name
The port number must be greater than 1023 and unique for the server. By default 5356. The protocol name is tcp.
Example:
mPowerd_v53a_5356 5356/tcp # mPower v53a mPowerd /opt/msi/v53a
Multiple concurrent versions: if you have more than one version of mPower installed on the same server, each installation requires its own entry in /etc/services with a unique service name and port number.
Create entry in inetd.conf or xinetd.d
HP and Sun: create an entry in the /etc/inetd.conf file.
The entry or file consists of one line. Delimit fields with a space or tab. If you need to continue the entry on a second line, end the first line with a backslash (\).
Example:
mPowerd_v53a_5356 stream tcp nowait root \
/opt/msi/v53a/live/bin/mPowerd mPowerd \
-d /opt/msi/v53a -l /opt/msi/v53a/log/mPowerd.log -f /opt/msi \
/v53a/etc/hostname_v53a_rt.lpkd
where hostname is the name of your LeasePak server machine.
Linux: create a file service_name in the /etc/xinetd.d directory
Create a file in /etc/xinetd.d where service_name is the official service name (official_service_name) from /etc/services. From the above example the name would be mPowerd_v53a_5356.
Example:
# mPowerd v53a daemon
service mPowerd_v53a_5356
{
disable = no
id = mPowerd_v53a_5356
socket_type = stream
user = root
server = /opt/msi/v53a/live/bin/mPowerd
wait = no
protocol = tcp
port = 5356
server_args = -d /opt/msi/v53a -l /opt/msi/v53a/log/mPowerd.log -f /opt/msi/v53a/etc/hostname_v53a_rt.lpkd
}
where hostname is the name of your LeasePak server machine.
Apache Installation and Configuration
If Apache is not included in your Linux installation, download Apache (version 2.0.x) from the Apache HTTP Server Project site (httpd.apache.org) and follow the instructions for installing the software.
conf.d Directory
If it doesn't already exist, create the directory conf.d under apache_root_dir, where apache_root_dir is the root directory of the Apache web server on your machine. Use this directory for all *.conf files you want to include during Apache startup. You should place both your mod_jk.conf and ssl.conf files here.
httpd.conf
Locate the httpd.conf file in the apache_root_dir/conf directory, where apache_root_dir is the root directory of the Apache web server on your machine. Modify the httpd.conf directives (parameters) shown below, substituting your values as necessary. You may also need to modify other file directives, depending on your web server setup. For more information on all Apache directives, refer to the Apache HTTP Server Version 2.0 Documentation. The directives here are listed in alphabetical order.
Do not copy and paste the following examples into your httpd.conf file; use them as a reference only.
# DirectoryIndex
#
# Specifies which files Apache should attempt to serve when the user
# requests a directory without a file name. In addition to index.html
# and index.htm, NetSol recommends also listing index.jsp. Files listed
# can either be relative to the requested directory or on another path
# (use / to begin a new path).
#
DirectoryIndex index.html index.htm index.jsp /mpower/default/index.html
# ErrorLog
#
# Tells the server where to write any errors it encounters. You can
# specify a path relative to ServerRoot or an absolute path (use /
# to start an absolute path).
#
ErrorLog logs/httpd.log
# Include
#
# Specifies any other configuration files for Apache to include on startup.
# NetSol recommends creating a conf.d directory under your ServerRoot directory
# and placing all additional *.conf files (including mod_jk.conf) in it.
#
Include ../conf.d/*.conf
# LoadModule
#
# This directive instructs Apache to load a module, in this case the
# mod_jk module. It takes two arguments: the module name (for mod_jk,
# it's called jk_module) and the path (relative to your Apache ServerRoot
# directory) to the module's .so file (mod_jk.so).
#
LoadModule jk_module modules/mod_jk.so
# RedirectMatch
#
# Depending on your needs, you can use Redirect, RedirectPermanent, or RedirectTemp
# instead of RedirectMatch. RedirectMatch uses regular expressions to redirect
# incoming requests from one path to another path or even another server. For example,
# at MSI we wanted all requests including the mpower directory to be redirected to
# the secure mPower portal.
#
RedirectMatch http\:*/mpower* https://mpower.mccue.com/mpower
# ServerAdmin
#
# Email address of the server administrator. Set this to the appropriate
# address if you set ServerSignature to EMail.
#
ServerAdmin [email protected]
# ServerRoot
#
# The root directory of your Apache web server installation. Many other
# directives use this setting, including ErrorLog and LoadModule.
#
ServerRoot /etc/httpd
# ServerSignature
#
# NetSol recommends setting this to Off to minimize the server information
# displayed when a user encounters a 403 Forbidden, 404 Not Found, or
# other error requesting unavailable pages. If you set it to EMail, you
# must also set the directive ServerAdmin.
#
ServerSignature Off
# ServerTokens
#
# NetSol recommends setting this to Prod to minimize the server information
# displayed when a user encounters a 403 Forbidden, 404 Not Found, or
# other error requesting unavailable pages.
#
ServerTokens Prod
Additional LoadModule Directives
The following are a list of LoadModule directives for including modules you may need with Apache:
LoadModule access_module modules/mod_access.so
LoadModule alias_module modules/mod_alias.so # needed for Redirect, RedirectMatch, etc.
LoadModule auth_anon_module modules/mod_auth_anon.so
LoadModule auth_digest_module modules/mod_auth_digest.so
LoadModule deflate_module modules/mod_deflate.so
LoadModule dir_module modules/mod_dir.so # needed for DirectoryIndex
LoadModule headers_module modules/mod_headers.so
LoadModule include_module modules/mod_include.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule setenvif_module modules/mod_setenvif.so
ssl.conf
One of the files in your conf.d directory should be ssl.conf, which contains settings for the Secure Socket Layer (SSL) protocol. Below are some of the directives (parameters) you may need to set for the mPower server. For more information, refer to the Apache Module mod_ssl documentation.
SSLMutex sem
SSLRandomSeed startup builtin
SSLSessionCache none
You will find these additional parameters within the section:
SSLEngine On
SSLCertificateFile conf/ssl/server.crt
SSLCertificateKeyFile conf/ssl/server.key
where web_server_name is your IP or host.domain.suffix name (or you can use _default_).
Java Installation
Download Java (J2SE v 1.4.2_xSDK). For Linux (including Red Hat), Microsoft Windows, and Sun Solaris, you can download the software from Sun Microsystem's Java Technology (Sun Developer Network) site (java.sun.com). For HP-UX, you can download the software from HP's Java Technology Software site (www.hp.com/java). Follow either Sun's or HP's instructions for installing the software. No additional configuration is needed.
Tomcat Installation and Configuration
Download Tomcat 4 (version 4.1.x) from the Apache Tomcat (Apache Jakarta Project) site (jakarta.apache.org/tomcat) and follow the instructions for installing the software.
tomcat4.conf
If you have a tomcat4.conf (or tomcat.conf) file in your CATALINA_HOME/conf directory (CATALINA_HOME represents the root directory of the Tomcat installation on your machine), you may need to edit it for the following environment variables:
JAVA_HOME="java_root_dir"
JAVA_OPTS="-Xmx768M"
CATALINA_HOME="tomcat_root_dir"
JASPER_HOME="tomcat_root_dir"
CATALINA_TMPDIR="tomcat_tmpdir"
TOMCAT_USER="tomcat_user"
SHUTDOWN_WAIT=30
CATALINA_PID=tomcat_pid_file
where java_root_dir is the root directory of the Java installation on your machine (for example, /usr/java/j2sdk1.4.2_02).
JAVA_OPTS is set to a percentage of the total system memory. In this example, where the server is exclusively an mPower server, JAVA_OPTS is set to 75% of total system memory. System memory is 1 GB, so the variable is set to 768 MB. If you are installing LeasePak and mPower on the same server, adjust the amount accordingly. Contact your NetSol representative for assistance if needed.
The variable tomcat_root_dir is the root directory of the Tomcat installation on your machine (for example, /var/tomcat4), tomcat_tmpdir is the temp file directory under the Tomcat root directory (for example, /var/tomcat4/temp), tomcat_user is the name of the Tomcat user, SHUTDOWN_WAIT is set to 30 seconds (the default), and tomcat_pid_file is the file where the system stores the Tomcat process ID (PID) after Tomcat starts (for example, /var/run/tomcat4.pid.
If the tomcat4.conf file does not exist, you may need to instead edit the Tomcat startup script in /etc/init.d (file will be either tomcat4 or tomcat) to set values for JAVA_HOME and JAVA_OPTS.
Startup and Shutdown Scripts
If you install Tomcat directly (for example, using tar instead of the RPM or package installer), you may just have the script files startup.sh and shutdown.sh in your tomcat_home_dir/bin directory (where tomcat_root_dir is the root directory of Tomcat on your machine--for example, /var/tomcat4). In this case, you will need to use export or setenv to set values for JAVA_HOME and JAVA_OPTS before using these scripts. Contact your NetSol representative for assistance if needed.
mod_jk Installation and Configuration
Download mod_jk (version 1.2.1x) from the Apache Jakarta Tomcat Connector page (jakarta.apache.org/tomcat/tomcat-4.1-doc/jk2/index.html) and follow Apache Jakarta's instructions for installation.
workers.properties
The file workers.properties should be in your apache_root_dir/conf directory (where apache_root_dir is your Apache ServerRoot directory). Use vi or another editor to make the necessary changes for your server. Refer to the Tomcat 4 Servlet/JSP Container (Tomcat 4.1 documentation) site (jakarta.apache.org/tomcat/tomcat-4.1-doc/index.html) for instructions on how to set this file properly for your site.
workers.tomcat_root_dir=tomcat_root_dir
workers.java_root_dir=java_root_dir
ps=/
worker.list=ajp13
worker.ajp13.port=8009
worker.ajp13.host=localhost
worker.ajp13.type=ajp13
worker.ajp13.lbfactor=1
worker.loadbalancer.type=lb
worker.loadbalancer.balanced_workers=ajp13
worker.inprocess.type=jni
worker.inprocess.class_path=$(workers.tomcat_root_dir)$(ps)common$(ps)lib $(ps)servlet.jar
worker.inprocess.class_path=$(workers.tomcat_root_dir)$(ps)server$(ps)lib $(ps)catalina.jar
worker.inprocess.class_path=$(workers.java_root_dir)$(ps)lib$(ps)tools.jar
worker.inprocess.cmd_line=start
worker.inprocess.jvm_lib=$(workers.java_root_dir)$(ps)jre$(ps)lib$(ps)i386 $(ps)server$(ps)libjvm.so
worker.inprocess.stdout=$(workers.tomcat_root_dir)$(ps)logs $(ps)inprocess.stdout
worker.inprocess.stderr=$(workers.tomcat_root_dir)$(ps)logs $(ps)inprocess.stderr
where tomcat_root_dir is the root directory of Tomcat on your machine (for example, /var/tomcat4), java_root_dir is the root directory of Java on your machine (for example, /usr/java/j2sdk1.4.2_02), and ps=/ is the path separator between directories (in this case, for Unix, the forward slash).
mod_jk.conf
If it is not already there, place the file mod_jk.conf in your apache_root_dir/conf.d directory (where apache_root_dir is your Apache ServerRoot directory) and use vi or another editor to make the necessary changes for your server.
# Change paths and other variables to match your system configuration.
SetEnv JAVA_HOME "java_root_dir"
SetEnv CLASSPATH
"tomcat_root_dir/common/lib;$JAVA_HOME/lib/tool.jar;tomcat_root_dir/mpower_dir/WEB-INF
/classes"
Alias /mpower_dir "tomcat_root_dir/webapps/mpower"
SSLRequireSSL
Options Indexes FollowSymLinks
JkMount /mpower_dir/servlet/* ajp13
JkMount /mpower_dir/*.jsp ajp13
JkMount /mpower_dir/*.do ajp13
JkMount /mpower_dir/ ajp13
AllowOverride None
deny from all
JkWorkersFile "apache_root_dir/conf/workers.properties"
JkLogFile "tomcat_root_dir/logs/mod_jk.log"
#
JkLogLevel error
server.xml
The file server.xml should be in your tomcat_root_dir/conf directory (where tomcat_root_dir is the root directory of Tomcat on your machine). Use vi or another editor to make the necessary changes for your server. Refer to the Tomcat 4 Servlet/JSP Container (Tomcat 4.1 documentation) site (jakarta.apache.org/tomcat/tomcat-4.1-doc/index.html) for instructions on how to set this file properly for your site.
Make sure the following connector is commented out:
Then make sure the following connector is not commented out. This is the connector you will need:
Additional ServIT Configuration
To use ServIT (customer self service) and enable the sending of e-mail, you must modify server.xml to point mail.smtp.host to the actual e-mail host servIT will use. Modify the ResourceParams section as follows:
mail.smtp.host
localhost
where localhost is the mail.smtp.host servIT will use, and verify that the Tomcat server can connect to the specified host.
mPower Installation
To install the mPower software:
Stop Tomcat if it is running. For Linux, if you installed Tomcat using the RPM, use the service tomcat4 stop command. Otherwise, use the shutdown.sh script in the tomcat_root_dir/bin directory.
Copy the file mpower-v53a.war to the CATALINA_HOME/webapps directory (CATALINA_HOME represents the root directory of the Tomcat installation on your machine).
Execute the following commands:
cd CATALINA_HOME/webapps
mkdir mpower-v53a
cd mpower-v53a
$JAVA_HOME/bin/jar -xvf (path to war file)/mpower-v53a.war
(where JAVA_HOME represents the root directory of your Java installation).
mPower Configuration
leasepak.xml
Edit the following parameters in leasepak.xml, located in the mpower/WEB-INF/envs directory:
leasepak_server
leasepak_environment
mPowerd_port
where leasepak_server is the IP address or name of your LeasePak server, leasepak_environment is the name of the LeasePak environment, and mPowerd_port is the TCP port number for the mPowerd daemon (not the leasepakd daemon).
web.xml
Edit the web.xml file, located in the mpower/WEB-INF directory.
First, find the following element group:
LPCODES_UPDATE_INTERVAL
value
java.lang.String
ChannelIT and ServIT users: set the value of LPCODES_UPDATE_INTERVAL to 5 (minutes) or more to specify the interval at which the program updates LeasePak codes (the LPCODES.TXT file). NetSol recommends a minimum of 60 minutes. If you add or change LeasePak codes frequently, you can set this number lower, but no lower than 5 (minutes).
LinkIT users: set value to 0 if you are not using ChannelIT or ServIT. By itself, LinkIT does not use this, and setting value to anything other than 0 can create performance issues.
Next, find the customization section of the file and edit as needed:
apiuid
api_username_value
java.lang.String
apipwd
api_password_value
java.lang.String
docgen_endpoint
http://host:port/dxGen-v53a/services/DocGenWsdl
java.lang.String
smtp_mail_host
mail_host.domain.suffix
java.lang.String
The API username is the account you have designated for use with the mPower server (ChannelIT, LinkIT, or ServIT) and the API password is the LeasePak client string password created for the account. For more information on LeasePak passwords, refer to the document LeasePak and mPower Users.
ServIT Configuration
If you are not using ServIT, skip to the next section, mPower Deployment.
css_db.xml
Edit the css_db.xml file, located in the mpower_dir/WEB-INF directory. For each ServIT user, create a element:
where user_name is the ServIT user's account name, password is the password (this is an arbitrary password, not a LeasePak client string, server, or DBMS account password, and client_number is the corresponding Lessee number (ral.les_s) of the user in LeasePak.
mPower Deployment
To deploy the mPower software:
Use chown -R owner:group on the mpower directory and all its contents (including subdirectories and contents), where owner:group is the Tomcat user and corresponding group.
Start Tomcat. For Linux, if you installed Tomcat using the RPM, use the service tomcat4 start command. Otherwise, use the startup.sh script in the tomcat_root_dir/bin directory.
LeasePakTM 5.3a mPower Documentation
© 2005 by NetSol Technologies Inc. All rights reserved.
The information contained in this document is the property of NetSol Technologies Inc. Use of the information contained herein is restricted. Conditions of use are subject to change without notice. NetSol Technologies Inc. assumes no liability for any inaccuracy that may appear in this document; the contents of this document do not constitute a promise or warranty. The software described in this document is furnished under license and may be used or copied only in accordance with the terms of said license. Unauthorized use, alteration, or reproduction of this document without the written consent of NetSol Technologies Inc. is prohibited.