🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: cn.bbs.comp.lang.java
Article #18524

Re: ���˺���һ������ô�����־���

#18524
From: �׾Թ�϶
Date: Wed, 11 Feb 2004 08:04
247 lines
14713 bytes
��������ǰ�Ҳο������ƫ���£����Լ���һʱ�Ҳ�����
����ο�
NO.1
������: flood@smth.org (�������ֱ�ļӷ�è ), ����: Java
��  ��: ��win20����apache2.0.44+Tomcat4.1.18+mod_jk2.0.43
����վ: BBS ˮľ�廪վ (Wed Mar 19 16:11:46 2003)
ת��վ: SJTU!news.neu.edu.cn!feed2.newsreader.com!newsreader.com!newsfeed.me
dia
��װapacheʱ����ͷ����������ip��ַ
����װ��jbuilder��oracle�ȣ��˿�80�Ѿ���ʹ�ã����Ը�listen��severname�˿�Ϊ8
021
tomcat ��Ĭ�ϵ�8080�˿ڣ�admin ����Ϊ��
1.��װapache�����ٶ���װĿ¼ΪAPACHE_HOME�������ʵ�ʰ�װ�����滻��
�ϻ�����˵����װ���޸�APACHE_HOME/CONF/httpd.conf ����6���ط���
1�� listen 8021 ����80 ����
2�� ServerName 192.168.0.15:8021
3)  DocumentRoot "e:/www_jsp_root"  (Ϊ�˷������㣬�����Լ�����Ŀ¼��Ϊ�ĵ���
)
4)  ��ԭ����<Directory "APACHE_HOME/htdocs">��Ϊ
    <Directory "e:/www_jsp_root">
5)  ���index.jspΪȱʡ���������ļ�
<IfModule mod_dir.c>
    DirectoryIndex index.html index.jsp
</IfModule>
�޸�TOMCAT_HOME�µ�confĿ¼�е�server.xml
1) ����㲻�뿴TOMCAT������Ϣ����ô����
    <Logger name="tc_log"
         path="logs/tomcat.log"
            verbosityLevel = "INFORMATION"
    />
����һ��PATH="logs/tomcat.log" �Ϳ�����
2) ��tomcat�ĵ�8081�ϣ�һ����˵www������80����8080�ϣ�
<!-- Normal HTTP -->
<Connector className="org.apache.tomcat.service.PoolTcpConnector">
<Parameter name="handler"
value="org.apache.tomcat.service.http.HttpConnectionHandler"/>
<Parameter name="port" value="8081"/>
</Connector>
3)����APJ13Э��֧��
<!-- Apache AJP13 support. This is also used to shut down tomcat.  -->
<Connector className="org.apache.tomcat.service.PoolTcpConnector">
  <Parameter name="handler" value="org.apache.tomcat.service.connector.Ajp13

ConnectionHandler"/>
  <Parameter name="port" value="8009"/>
</Connector>
�ͷ���ԭ����APJ12����������Ϳ�����
4)���APACHE�޸��ĵ���Ŀ¼
<!-- �ĵ���Ŀ¼ -->
<Context path="/" docBase="e:/java_jsp" >  �������������
</Context>
5)Ϊ�������Ӳ��ԣ����ø�һ��EXAMPLES��CONTEXT:
<Context path="/examples"
 docBase="TOMCAT_HOME/webapps/examples" crossContext="false" >
</Context>
������: flood@smth.org (�������ֱ�ļӷ�è ), ����: Java
��  ��: ��win20����apache2.0.44+Tomcat4.1.18+mod_jk2.0.43
����վ: BBS ˮľ�廪վ (Wed Mar 19 16:11:46 2003)
ת��վ: SJTU!news.neu.edu.cn!feed2.newsreader.com!newsreader.com!newsfeed.me
dia
���ļ����Ѿ���װ��apache2.0.44��tomcat4.1.18
JK��mod_jserv�������APACHE��TOMCAT�����ӡ�JK2��JK�Ľṹ���˺ܴ��������

Ҳ����ˡ�JK2��ΪAPACHE2.0��Ƶ�,���ʺ϶��̵߳�WEB SERVER��
������JK����JK2
1. ����mod_jk: http://jakarta.apache.org/builds/jakarta-tomcat-connectors/jk

/release/
        �õ�mod_jk-2.0.43.dll��.so��.dll��win32ϵͳ��˵���ǺϷ��ġ��ŵ� Apac
he��mod
ulesĿ¼��
        ע�ⲻ��mod_jk2-2.0.43.dll����ʵӦ����mod_jk-2.0.44.dll������2.0.43��
Ҳ����
2. ����apache
        ��httpd.conf����LoadModules������ϣ�
        LoadModule jk_module modules/mod_jk-2.0.43.dll
        ����õ���jk2����jk2_module��
        �������dos���ڲ���һ���귢�Ƿ���ȷ��APACHE_HOME\bin\> apache -t
        ������ʾ Syntax OK
3. ����tomcat������mod_jk.conf
        �޸�tomcat-4-1-18\conf\server.xml
        ��<Server port="8005" shutdown="SHUTDOWN" debug="0">  ��������ϣ�

        <Listener className="org.apache.ajp.tomcat4.config.ApacheConfig" mod
Jk="$AP
ACHE_HOME/modules/mod_jk-2.0.43.dll" />//·��ֻ��д���·�����������û�����
��
        ��<Host name="localhost" debug="0" appBase="webapps" unpackWARs="tru
e" auto
Deploy="true">  ��������ϣ�
        <Listener className="org.apache.ajp.tomcat4.config.ApacheConfig" app
end="tr
ue" forwardAll="false" modJk="$APACHE_HOME/modules/mod_jk-2.0.43.dll" />
        ���������tomcat������$TOMCAT_HOME\tomcat-4-1-18\conf\�����auto�ļ�
������
��mod_jk.conf������ļ�ÿ����TOMCATһ�ξ����һ�Ρ�
        ��һ�����õ���JK2����һ��Ҳ���ˡ������岽�ͳ����⣬��˵mod_jk.conf��
��������
�����ԡ�
4. ���workers.properties���
        ��APACHE�У�ʹ��WORKER����TOMCAT����/������Ϣ�����ļ���Ҫ��Ϣ���£�
        # BEGIN workers.properties
        # Definition for Ajp13 worker
        workers.tomcat_home=D:\Program Files\Apache Group\Tomcat 4.1
        workers.java_home=D:\jdk1.3.1_07
        ps=\
        worker.list=ajp13
        worker.ajp13.port=8009
        worker.ajp13.host=localhost
        worker.ajp13.type=ajp13
        # END workers.properties
        ��workers.properties�ļ��ŵ�$TOMCAT_HOME\tomcat-4-1-18\conf\jk\�¡���
��˵��
�Էŵ���ĵط�����������һ�²��С�
 5. ���޸�apache��httpd.conf
        ���������⼸�仰��
        JkWorkersFile c:\tomcat_4.1.18\conf\jk\workers.properties
        JkLogFile c:\tomcat_4.1.18\logs\mod_jk.log
        Include c:\tomcat_4.1.18\conf\auto\mod_jk.conf
6. �����
        ����tomcat���ĵ���˵��Ϊservice�������ҵ��������ˣ���Ϊָ��ij��򲻶�
�����
����tomcat4��1��bug����������ν����ôstartup�����ԡ�
        ����apache
        1������http://localhost:8021/��apache�Ƿ���
        2������http://localhost:8080/examples/jsp/index.html��tomcat�Ƿ���

        3������http://localhost:8021/examples/jsp/index.html��apache��tomcat
�Ƿ���һ��
����
no��2
������: doublefish(Ц�����Ƶ�), ����: Java
��  ��: �޷ϻ�Apache+Tomcat����
����վ: ��ˮ˼Դ (Wed Jun  5 16:01:47 2002) , ת��
//���ٿ����������Ϲ���apache��tomcat�����ã�����֧֧���ᣬ����Ҫ��
//��ƪ���·dz�ʵ�ã��������˵������һ��Сʱ���Ϳ������úͲ��Ժû���
//����˵�� �޷ϻ�Apache+Tomcat���ã�ǿ���Ƽ�!
eyzz   ���ڣ�2000-12-24 11:00:11
�����ǰ�쵰�����˵�˵�������Ū�����Ժ����ʵ�����װ���Ǻܼ򵥣���������

�����㶨��
���裺
apache��װĿ¼ΪAPACHE_HOME
tomcat��װĿ¼ΪTOMCAT_HOME ��Ҫ�赽���������У�
jdk��װĿ¼ΪJAVA_HOME��Ҫ�赽���������У�
1.��װapache�����ٶ���װĿ¼ΪAPACHE_HOME�������ʵ�ʰ�װ�����滻��
�ϻ�����˵����װ���޸�APACHE_HOME/CONF/httpd.conf ����6���ط���
1�� Port 8080 ����80 ����
2�� ServerName localhost
3)  DocumentRoot "e:/www"  (Ϊ�˷������㣬�����Լ�����Ŀ¼��Ϊ�ĵ���)
4)  ��ԭ����<Directory "APACHE_HOME/htdocs">��Ϊ
    <Directory "e:/www">
5)  ���index.jspΪȱʡ���������ļ�
<IfModule mod_dir.c>
    DirectoryIndex index.html index.jsp
</IfModule>
6�� ������ؼ�һ������httpd.conf������
#tomcat֧��
include TOMCAT_HOME/conf/mod_jk.conf-auto
ֻ��Ҫ��һ��͹��ˣ�������Щ�׳յĻ�������ʲôtomcat-apache.conf����û��.
��mod_jk.dll������APACHE_HOME/moduleĿ¼
����Ȳ���apache�ˣ�������tomcat3.2
���裺
��tomcat��ѹ�������������Ŀ¼jarakar-tomcat��������Ҫ��Ŀ¼��TOMCAT_HOME
�޸�TOMCAT_HOME�µ�confĿ¼�е�server.xml
1) ����㲻�뿴TOMCAT������Ϣ����ô����
    <Logger name="tc_log"
         path="logs/tomcat.log"
            verbosityLevel = "INFORMATION"
    />
����һ��PATH="logs/tomcat.log" �Ϳ�����
2) ��tomcat�ĵ�8081�ϣ�һ����˵www������80����8080�ϣ�
<!-- Normal HTTP -->
<Connector className="org.apache.tomcat.service.PoolTcpConnector">
<Parameter name="handler"
value="org.apache.tomcat.service.http.HttpConnectionHandler"/>
<Parameter name="port" value="8081"/>
</Connector>
3)����APJ13Э��֧��
<!-- Apache AJP13 support. This is also used to shut down tomcat.  -->
<Connector className="org.apache.tomcat.service.PoolTcpConnector">
  <Parameter name="handler" value="org.apache.tomcat.service.connector.Ajp13

ConnectionHandler"/>
  <Parameter name="port" value="8009"/>
</Connector>
�ͷ���ԭ����APJ12����������Ϳ�����
4)���APACHE�޸��ĵ���Ŀ¼
<!-- �ĵ���Ŀ¼ -->
<Context path="/" docBase="e:/www" >
</Context>
5)Ϊ�������Ӳ��ԣ����ø�һ��EXAMPLES��CONTEXT:
<Context path="/examples"
 docBase="TOMCAT_HOME/webapps/examples" crossContext="false" >
</Context>
Ҫʹ��MOD_JK���ø�һ��ͬһĿ¼�µ�WORKERS.PROPERTIES�ļ���
1�� workers.tomcat_home=TOMCAT_HOME
2)  workers.java_home=JAVA_HOME
3)  ps=\  �Ұ�windows �պ�
����ok�ˣ���ʼ������
��ţ���������˳�����⣬ע�Ⱑ��������tomcat�����Լ��޸�һ�����ã���һ��һ��

Ҫ��tomcat���Ժ����޸�tomcat�����ã�������������apache�ˡ�
ok ������tomcat������TOMCAT_HOME/bin�����startup.bat
����:Startting tomcat. Check logs/tomcat.log for error messages.�ǾͶ���
�������tomcat�����
�������e:\www����Ÿ�index.jsp�ļ���������
<%="������jsp��һ�����У�"%>
���������http://localhost:8081
�������Ļ����֣���ô���ĵ��ͳɹ��ˣ����������Ӳ���һ�£���������򿪣�

http://localhost:8081/examples/jsp
���в�������Ϸ�������ȷ�ˣ�˵�����ǵ�examples������Ҳ������ȷ����ͼ��ˡ�

ʣ�¾�������apache��
����apache��������ôһ�У�
Apache/1.3.14 (win32) with mod_jk running...�ǾͶ���
�����������ǵ���ϣ����������http://localhost:8080(�Ҽ�������8080�˿ڣ���

����80�˿ڣ��Ǿ���http://localhost
���ǿ����Ǿ䡰������jsp��һ�����У���
���˵��apache��tomcat�����ˣ�
���������http://localhosy:8080/examples/jsp����һ�����ӡ�
����ô�򵥣������mod_jk�㶨�ˣ�


�� �� mifeng.bbs@freecity.cnzju.net (�Ұס��Ե·���) �Ĵ������ᵽ: ��
: ���˺���һ���ƽ̨��ϳɹ���ô���δͽ�
: Winxp-sp1+Apache2+Tomcat4���                                                
: ���׼����                                                                   
:     1.j2sdk1.4.2                                                             
:     2.Apache2.0.48: apache_2.0.48-win32-x86-no_ssl.msi                       
:     3.Tomcat4.1.12��jakarta-tomcat-4.1.29.exe                                
:     4.ApacheJServ-1.1.2-2.exe  
:      1.PATH,��ֵΪ�� E:\program files\j2sdk1.4.2\bin                         
:      2.JAVA_HOME����ֵΪ��E:\program files\j2sdk1.4.2                        
:      3.TOMCAT_HOME����ֵΪ��C:\program files\Tomcat4                         
: .................������ʡ�ԣ�

--
�q �q�����r�r
�t�T@ @ =�T�s   ����ᵶƽ����
 �qoo �����r
 �t�r ���s �b�r      ����ؼ����С
 �� �����r ���t=o
 ������������0�� 
�� ��Դ:����ˮ˼Դ bbs.sjtu.edu.cn��[FROM: 202.120.8.13]
Technical Details
Message-ID: <4Abf2K$AOM@bbs.sjtu.edu.cn>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshub.sdsu.edu!newshosting.com!nx02.iad01.newshosting.com!feed2.newsreader.com!newsreader.com!maily.cic.tsinghua.edu.cn!news.ccie.net.cn!SJTU

Show Full Headers
Complete Article Headers
X-Google-Language: Chinese,GB
X-Google-Thread: f6cb0,4ade09ea26806f24
X-Google-Attributes: gidf6cb0,public
X-Google-ArrivalTime: 2004-02-11 00:04:06 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news2.google.com!news.maxwell.syr.edu!newshub.sdsu.edu!newshosting.com!nx02.iad01.newshosting.com!feed2.newsreader.com!newsreader.com!maily.cic.tsinghua.edu.cn!news.ccie.net.cn!SJTU
From: airfire.bbs@bbs.sjtu.edu.cn (�׾Թ�϶)
Newsgroups: cn.bbs.comp.lang.java
Subject: Re: ���˺���һ������ô�����־���
Date: 11 Feb 2004 08:04:01 GMT
Organization: ��ˮ˼Դ
Message-ID: <4Abf2K$AOM@bbs.sjtu.edu.cn>
Mime-Version: 1.0
Content-Type: text/plain; charset="gb2312"
Content-Transfer-Encoding: 8bit
X-Filename: Java/M.1076486516.A
Lines: 247