[原创]Apache1.3+Tomcat4在solaris7/8下配置步骤[1]

[入库:2005年9月19日] [更新:2007年3月24日]

本文简介:


[这个贴子最后由realice在 2002/09/03 05:29pm 编辑]

准备工作:
给系统打补丁先,去sunsolve.sun.com下载最新的Recommended patches
你的solaris当然要有c编译器喽,没有?
去sunfreeware下个gcc 3.2
顺便下载autoconf 2.5 / libtool 1.4 / m4 1.4
安装这些咚咚,记得将/usr/local/bin加入path..建议加在/usr/sbin之前


1. 安装apache1.3.26
很简单,tar出来.configure就好,加上参数 --enable-module=so 
象这样: ./configure --prefix=/opt/apache1.3.26  --enable-module=so 
然后make ; make install

2. 安装JDK1.4.01
需要下载相应sun os的jdk patch..然后默认安装

3. 安装tomcat4.04
在运行目录tar出来,添加CATALINA_HOME=...到你的环境变量

4. 编译mod_webapp.so
最麻烦的步骤开始了
去下载webapp-module-1.0-tc40-src.tar / apr_APACHE_2_0_35.tar
建议在/var/tmp下解开来
然后在webapp-module目录下运行
./configure --with-apxs=/opt/apache1.3.26/bin/apxs --with-apr=/var/tmp/apr
make
编译完成,你会在webapp-module../apache1.3/ 下找到mod_webapp.so
将它copy到apache1.3.26的linexec目录中

5. 完结篇
编辑httpd.conf,加入 
LoadModule webapp_module libexec/mod_webapp.so
AddModule mod_webapp.c
WebAppConnection warpConnection warp localhost:8008
WebAppDeploy examples warpConnection /examples/ 
这就不用解释啦...  注意需要分行加入

运行tomcat , 运行apache
浏览http://localhost/examples  看到可爱的小猫了?
恭喜,成功啦

以上步骤在sparc solaris7 & 8环境下都编译成功


补充:原文是在快下班的时候写的,大概步骤就是这样了,其间也许会遇到小问题..
1. libtool/m4/autoconf都有,但是编译mod_webapp.so还是报错,无法解释as..
   检查系统 路径,加入/usr/ccs/bin..  搞定
2. apache编译安装完毕,运行报错..."can't find correct group id xxxx..."
   检查httpd.conf,发现group是#1,改成nobody搞定(或者实际存在的group name)

 cinc 回复于:2002-09-02 18:34:20
呵呵,好样的,请到 Java 版多做交流。:)

 realice 回复于:2002-09-03 17:30:54
刚才补充了一些想到的问题...呵呵
上周我也是看了N多E文,非常苦闷的说..
希望大家都能成功搞定

 czc9 回复于:2002-09-03 17:38:52
很好,基本上我也是这样做的,但是make没法通过,你能把编译好的mod_webapp.so for s7/8的发到我的邮箱上吗,谢谢
stdxzcc@21cn.com

 realice 回复于:2002-09-03 17:45:26
用apache2.04编译mod_webapp.so一直失败,说找不到apr...指定路径无用..
有没有哪位兄弟有心得?

 wudicc 回复于:2002-09-03 17:59:57
按照  realice  写的,我出现了这样问题:
# build/ltconfig: build/ltconfig: cannot open
build/ltconfig:: not found
请问 realice 这该怎样解决?谢谢!!!!

 race 回复于:2002-09-03 21:55:41
有空 我也找台ULTRA80去试去

 study12 回复于:2002-09-04 08:17:44
我现在都成功编译了mod_webapp.so,但无法用。

 realice 回复于:2002-09-04 11:42:30
to wudicc:  你在哪一步报这个错?  

to study12: 编译完就成功99%啦,呵呵,你看看在httpd.conf里面的LoadModule webapp_module libexec/mod_webapp.so ,用你自己实际路径代替

 study12 回复于:2002-09-04 18:20:53
这不会错的,我搞了很长时间了.
提示是不能找到ligapr.so

 ncwangw 回复于:2002-09-10 22:34:24
我为什么没有autoconf这个文件?

 ncwangw 回复于:2002-09-15 19:21:25
我顶

 race 回复于:2002-09-15 23:44:10
下载安装, realice 不是说了嘛

 ncwangw 回复于:2002-09-17 10:35:27
hehe 
我还以为是配置文件呢

 jackylau 回复于:2003-07-18 08:55:45
我按照最上面的老史说的。我的出错信息,怎么解决呀?    
 # cd var/tmp
# ls
apr                             wsconAAAFQaiFa:0.0
apr_APACHE_2_0_35.tar           wsconAAAXSaGIa:0.0
webapp-module                   wsconAAAhmaOEa:0.0
webapp-module-1.0-tc40          wsconAAAtFaqEa:0.0
webapp-module-1.0-tc40-src.tar  wsconAAAu3aq5a:0.0
wsconAAA8vaO6a:0.0              wsconAAAysaaXa:0.0
wsconAAA94aiEa:0.0
# cd webapp*
# ls
INSTALL.txt   Makefile.win  apr           configure     java
LICENSE.txt   README.txt    confdefs.h    configure.in  lib
Makedefs.in   apache-1.3    config.cache  docs          nsapi
Makefile.in   apache-2.0    config.log    include       support
# ./configure --with-apxs=/usr/local/apache/bin/apxs --with-apr=/var/tmp/apr
loading cache ./config.cache
checking for test... /bin/test
checking for true... /bin/true
checking for echo... /bin/echo
checking for grep... /bin/grep
checking for cat... /bin/cat
checking for sed... /bin/sed
checking for ln... /bin/ln
checking for rm... /bin/rm
checking host system type... sparc-sun-solaris2.7
checking for sources directory... /var/tmp/webapp-module-1.0-tc40
checking for targets directory... /var/tmp/webapp-module-1.0-tc40

C-Language compilation tools
checking for ar... /usr/ccs/bin/ar
checking for ranlib... /usr/ccs/bin/ranlib
checking for gcc... gcc
checking whether the C compiler (gcc   works... yes
checking whether the C compiler (gcc   is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking for gcc... /bin/gcc
checking whether /bin/gcc and cc understand -c and -o together... yes
checking how to run the C preprocessor... /bin/gcc -E
checking for debug build... no

JAVA-Language compilation tools
checking for java support... no

API documentation generation
checking for C API documentation... no
checking for Java API documentation... no

Target web-server
checking for Apache apxs... yes
checking target module... apache-1.3
checking for full APR directory path... /var/tmp/apr

Building APR configure script
  Invoking: "./buildconf" in "/var/tmp/apr"
    APR buildconf: buildconf: checking installation...
    APR buildconf: buildconf: autoconf version 2.57 (ok)
    APR buildconf: buildconf: libtool version 1.5
    APR buildconf:
    APR buildconf: 2003 (ok)
WARNING: Using auxiliary files such as `acconfig.h', `config.h.bot'
WARNING: and `config.h.top', to define templates for `config.h.in'
WARNING: is deprecated and discouraged.

WARNING: Using the third argument of `AC_DEFINE' and
WARNING: `AC_DEFINE_UNQUOTED' allows to define a template without
WARNING: `acconfig.h':

WARNING:   AC_DEFINE([NEED_MAIN], 1,
WARNING:             [Define if a function `main' is needed.])

WARNING: More sophisticated templates can also be produced, see the
WARNING: documentation.
    APR buildconf: Copying libtool helper files ...
    APR buildconf: Creating include/arch/unix/apr_private.h.in ...
autom4te: need GNU m4 1.4 or later: /usr/ccs/bin/m4
autoheader: /usr/local/bin/autom4te failed with exit status: 1
    APR buildconf: Creating configure ...
autom4te: need GNU m4 1.4 or later: /usr/ccs/bin/m4
  Execution of ./buildconf returned 0

Configuring APR

本文关键:[原创]Apache1.3+Tomcat4在solaris7/8下配置步骤
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top