Configuring Mac OS X Server Tiger for WebObjects Deployment
This are the steps to setup a brand new
installation of OS X Server Tiger. This is for an "all in one" server typical
for a small or startup WebObjects website or as a server used for testing. This
setup is for MySQL 4.1, WebObjects 5.3, Apache webserver. The mechanics of
WebObjects setup on a new installation of OS X Tiger is straight-forward and
easier than with previous versions of OS X Server.
For this exercise, I performed a clean 'Erase and
Install' installation of OS X Server 10.4.7 on a compatible Mac. After
installation I ran software update to bring it up to 10.4.8 Server. WebObjects
deployment is already included by default in OS X Server, so no additional
WebObjects software installs are
necessary.DO NOT INSTALL WebObjects
Deployment 5.3 SINCE IT IS PREINSTALLED in Tiger!!!! (Tiger 10.4.8 has WO 5.3.2
preinstalled)Java
VersionIn a clean 10.4.7 install, the
default java version is 1.5. By default on Tiger, WO apps launch using some 1.4
compatability jar that is included in the 1.5 installation. Java 1.5 is not
officially "certified" for WebObjects, and I don't like this 14 compatability
jar thing, so I'm putting my Tiger Server machines back to 1.4 for WO
deployment. Although 1.5 is unofficially supported, I am developing for 1.4, so
I am going to change the server to use 1.4 by default. Also,
In a terminal navigate to
/System/Library/Frameworks/JavaVM.framework/VersionsHere
is the terminal
transcript:server1:/System/Library/Frameworks/JavaVM.framework/Versions
admin$ ls -altotal
40drwxr-xr-x 11 root wheel 374
Sep 16 07:36 .drwxr-xr-x 9 root
wheel 306 Sep 16 07:36 ..lrwxr-xr-x
1 root wheel 5 Sep 16 07:35 1.3 ->
1.3.1drwxr-xr-x 8 root wheel 272
Sep 16 07:35 1.3.1lrwxr-xr-x 1
root wheel 5 Sep 16 07:35 1.4 ->
1.4.2drwxr-xr-x 8 root wheel 272
Sep 16 07:35 1.4.2lrwxr-xr-x 1
root wheel 5 Sep 16 07:35 1.5 ->
1.5.0drwxr-xr-x 10 root wheel 340
Sep 21 00:10 1.5.0drwxr-xr-x 5
root wheel 170 Sep 16 12:22
Alrwxr-xr-x 1 root wheel 1 Sep
16 07:36 Current -> Alrwxr-xr-x
1 root wheel 3 Sep 16 07:35 CurrentJDK ->
1.5server1:/System/Library/Frameworks/JavaVM.framework/Versions
admin$ sudo rm CurrentJDK
server1:/System/Library/Frameworks/JavaVM.framework/Versions
admin$ ls -altotal
32drwxr-xr-x 10 root wheel 340
Sep 21 00:11 .drwxr-xr-x 9 root
wheel 306 Sep 16 07:36 ..lrwxr-xr-x
1 root wheel 5 Sep 16 07:35 1.3 ->
1.3.1drwxr-xr-x 8 root wheel 272
Sep 16 07:35 1.3.1lrwxr-xr-x 1
root wheel 5 Sep 16 07:35 1.4 ->
1.4.2drwxr-xr-x 8 root wheel 272
Sep 16 07:35 1.4.2lrwxr-xr-x 1
root wheel 5 Sep 16 07:35 1.5 ->
1.5.0drwxr-xr-x 10 root wheel 340
Sep 21 00:10 1.5.0drwxr-xr-x 5
root wheel 170 Sep 16 12:22
Alrwxr-xr-x 1 root wheel 1 Sep
16 07:36 Current ->
Aserver1:/System/Library/Frameworks/JavaVM.framework/Versions
admin$ sudo ln -s 1.4
CurrentJDKserver1:/System/Library/Frameworks/JavaVM.framework/Versions
admin$ ls -altotal
40drwxr-xr-x 11 root wheel 374
Sep 21 00:11 .drwxr-xr-x 9 root
wheel 306 Sep 16 07:36 ..lrwxr-xr-x
1 root wheel 5 Sep 16 07:35 1.3 ->
1.3.1drwxr-xr-x 8 root wheel 272
Sep 16 07:35 1.3.1lrwxr-xr-x 1
root wheel 5 Sep 16 07:35 1.4 ->
1.4.2drwxr-xr-x 8 root wheel 272
Sep 16 07:35 1.4.2lrwxr-xr-x 1
root wheel 5 Sep 16 07:35 1.5 ->
1.5.0drwxr-xr-x 10 root wheel 340
Sep 21 00:10 1.5.0drwxr-xr-x 5
root wheel 170 Sep 16 12:22
Alrwxr-xr-x 1 root wheel 1 Sep
16 07:36 Current -> Alrwxr-xr-x
1 root wheel 3 Sep 21 00:11 CurrentJDK ->
1.4server1:/System/Library/Frameworks/JavaVM.framework/Versions
admin$ java -versionjava version
"1.4.2_09"Java(TM) 2 Runtime
Environment, Standard Edition (build
1.4.2_09-244)Java HotSpot(TM) Client
VM (build 1.4.2-67, mixed
mode)WebObjects
ServiceOpen Server Admin and
authenticate.Select WebObjects in Computers and
Services for this local server.Click on
Settings in the bottom of the WebObjects
pane.Check the "Turn Monitor On"
checkbox.Click
Save.Click Start Service in
toolbar.Verify by simply opening browser on the
server and going to http://localhost:56789 (assuming you did not change default
ports)IMPORTANT: Setup password security
on Monitor using the Preferences tabIn
Monitor, you may need to do these tasks too:-
Setup your WebObjects applications in Hosts
tab- Enter your HTTP Adaptor URL under the Site
tabIf this is a new machine it might also
be a good time to create your app logs directory and set owner/privs on
it.Apache Web
ServiceOpen Server Admin and set up
sites/domains/SSL, etc. Also turn off the performance cache in the Options tab
for any sites that are for WebObjects apps amd/or that use SSL. Note that Server
Admin now has a global certificates admin now under
Server-Name/Settings/Certificates. You can import certs there and they appear in
a popup menu in the SSL site configuration settings. Then start the Web
service.Java
ExtensionsInstall any required basic java
extensions that your environment needs.For
example, if using MySQL, then install MySQL Connector/J for JDBC connection to
MySQL (put the mysql-connector.jar file in /Library/Java/Extensions of the
deployment server). I recommend Connector/J 3.0.XX and not 3.1.XX for use with
MySQL 4.1WebObjects
ExtensionsIdeally you should make
frameworks for your 3rd party jars and include them as needed for each app, but
if you have some jars and you just want to share them with all your apps, then
put them in
/Library/WebObjects/ExtensionsPermissionsIn
Tiger, by default apps are launched as user = appserver ( "Application Server"
). See its details by doing:$ niutil -read .
/users/name=appserverIt belongs to a
group named appserveradm. See more on that by
doing:$ niutil -read .
/groups/name=appserveradmSo, we need to
make sure that the user appserver has ownership of our apps and read ability of
what it needs and write ability of what it needs to function. Also for security,
we want to keep everyone else out, so something like this would be in order for
your /Library/WebObjects/Applications
directory$ sudo chown -R appserver:appserveradm
/Library/WebObjects/Applications$ sudo chmod -R
770
/Library/WebObjects/ApplicationsReferences:http://docs.info.apple.com/article.html?artnum=304041
http://docs.info.apple.com/article.html?artnum=75505
Posted: Fri - November 10, 2006 at 12:16 PM