Programming__WebObjects-Web Applications-Deployment-Solaris WO5.3.3

Version 28.1 by Johann Werner on 2008/01/01 11:56

Setup WebObjects 5.3.3 on Solaris 10 x86
Rev 1 1.01.2008
Johann Werner (werner@isd.uni-stuttgart.de)
based on description of Francois Bientz for setup on FreeBSD

That's the very first time I am using Solaris so I don't guarantee that my instructions are complete nor comply to standard Solaris naming/best-practice/whatsoever conventions. Feel free to comment/correct it!

What I used to test this setup:

Parallels Desktop
Solaris 10 8/07 x86 (Entire Solaris Software Group installation)
Access to an OS X Server 10.4.x machine that has the WO 5.3.3 files

WebObjects 5.3.3 installation

This section discusses how you "install" WO 5.3.3 on Solaris to use it as pure application server. You will be able to connect to WO apps by direct connect or use that machine from another machine that runs Apache with WOAdaptor.

Under Solaris create the following directory where all WO related files will be contained:


/opt/Apple

Inside of this directory create:


/opt/Apple/Logs
/opt/Apple/Library/Frameworks
/opt/Apple/Library/PrivateFrameworks
/opt/Apple/Library/WebObjects
/opt/Apple/Local/Library/WebObjects/Applications
/opt/Apple/Local/Library/WebObjects/Extensions

Then copy from the OS X Server machine these files from /System/Library/Frameworks


JavaDirectToWeb.framework
JavaDTWGeneration.framework
JavaEOAccess.framework
JavaEOApplication.framework
JavaEOCocoa.framework
JavaEOControl.framework
JavaEODistribution.framework
JavaEOGeneration.framework
JavaEOInterface.framework
JavaEOInterfaceCocoa.framework
JavaEOInterfaceSwing.framework
JavaEOProject.framework
JavaEORuleSystem.framework
JavaEOTool.framework
JavaFoundation.framework
JavaJDBCAdaptor.framework
JavaJNDIAdaptor.framework
JavaWebObjects.framework
JavaWebServicesClient.framework
JavaWebServicesGeneration.framework
JavaWebServicesSupport.framework
JavaWOExtensions.framework
JavaWOJSPServlet.framework
JavaXML.framework

to /opt/Apple/Library/Frameworks

Next copy from the OS X Server machine these files from /System/Library/PrivateFrameworks


EOPlaceholders.framework
JavaMonitor.framework

to /opt/Apple/Library/PrivateFrameworks

Copy from the OS X Server machine these files from /System/Library/WebObjects


JavaApplications
WODocumentRoot

to /opt/Apple/Library/WebObjects

Finally you have to copy these files from /Library/WebObjects/Extensions


axis-ant.jar
axis.jar
commons-discovery.jar
commons-logging.jar
jaxrpc.jar
log4j-1.2.8.jar
saaj.jar
wsdl4j.jar

to /opt/Apple/Local/Library/WebObjects/Extensions

Create startup scripts for wotaskd and javamonitor

To be able to use the machine as an application server wotaskd has to run. To automatically start wotaskd on startup create the file /etc/rc3.d/S110.wotaskd


#!/bin/sh

NEXT_ROOT=/opt/Apple

case "$1" in
       start)
          export NEXT_ROOT
           ${NEXT_ROOT}/Library/WebObjects/JavaApplications/wotaskd.woa/wotaskd &
          echo -n ' wotaskd'

          ;;
       stop)
          lsof -i tcp:1085 |grep LISTEN | sort -u | awk '{print"kill -9 " $2}' | sh
               ;;
       *)
          echo ""
          echo "Usage: `basename $0` { start | stop }"
          echo ""
          exit 64
               ;;
esac

Then

chmod \+x /etc/rc3.d/S110.wotaskd

If you need to start JavaMonitor too on that machine (remember: only one JavaMonitor per subnet) create /etc/rc3.d/S150.javamonitor


#!/bin/sh

NEXT_ROOT=/opt/Apple

case "$1" in
       start)
          export NEXT_ROOT
           ${NEXT_ROOT}/Library/WebObjects/JavaApplications/JavaMonitor.woa/JavaMonitor -WOPort 56789 &
          echo -n 'JavaMonitor'
                       ;;
       stop)
          lsof -i tcp:56789 |grep LISTEN | sort -u |awk '{print"kill -9 "$2}' | sh
           ;;
       *)
          echo ""
          echo "Usage: `basename $0` { start | stop }"
          echo ""
          exit 64
           ;;
esac

Then

chmod \+x /etc/rc3.d/S150.javamonitor

To be done: Starting wotaskd and JavaMonitor under a specific user/group. As it is shown here the two apps will run with root priviliges. Another approach would be to put them into a Solaris Zone.

Installing JDBC drivers

If you want to access a database from your WO apps you have to install appropriate JDBC drivers. In this guide I will use FrontBase drivers as an example.

Download the database specific drivers from www.frontbase.com (called "WebObjects 5 Plugin" on the download page) and extract the archive. Then you should have two files:


FrontBasePlugIn.framework
frontbasejdbc.jar

The first file is the one you have to add to your WO project. If you have WOnder you can exchange it with the one that comes with WOnder as it is an improved version (though I did not check for differences emoticon_smile).
Put that file into


/opt/Apple/Local/Library/Frameworks

The second file has to be put into the extensions directory of java


/usr/java/jre/lib/ext

Reboot and you should be able to connect to a FB database from WO.

Setting up Apache

To be done yet.