· linux虚拟机两个【一个也行,这是为了更好的测试】
· JDK1.7左右
· tomcat7.0两个以上:http://tomcat.apache.org/download-70.cgi下载如图所示:
· httpd-2.2.27.tar.gz:http://httpd.apache.org/download.cgi下载如图所示:
· openssl-1.0.1g.tar.gz:http://www.openssl.org/source/openssl-1.0.1g.tar.gz
· ERROR1安装gcc:【yum install gcc】在服务器任意地方直接copy这段语句运行(它会问你y/N,回答它y)。
错误为:configure: error: in`/root/httpd-2.2.27/srclib/apr':
configure: error: no acceptable C compiler found in $PATH
See `config.log' for more details
configure failed for srclib/apr
· ERROR2安装zlib:【yum install zlib-devel -y】在服务器任意地方直接copy这段语句运行。
错误为:checking for zliblocation... not found
tar zxf openssl-1.0.1g.tar.gz
cd openssl-1.0.1g
./config--prefix=/home/admin/app/openssl
make;make install
如果出现
./configure --prefix=/ytxt/apache2/ --enable-ssl --enable-rewrite --enable-so --with-ssl=/usr/local/openssl/
报错:
configure: error: ... Error, SSL/TLS libraries were missing or unusable
在服务器上执行 export LDFLAGS=-ldl
你需要按照如下方式进行(配置有可能出ERROR1与ERROR2,解决这两个错误之后请重新把配置语句执行一遍):
· 使用root用户(最好是root)上传:httpd-2.2.27.tar.gz
· 解压:tar -xvfhttpd-2.2.27.tar.gz
· 制作:make
· 安装:make install
· Over,安装完成。
· tomcat_A,配置server.xml(${tomcatHome}/conf/server.xml),我的配置是:
Xml代码
1.
26.
27.
28.
29.
30.
31.
32.
33.
34.
56.
57.
58. maxThreads="500" minSpareThreads="20" maxIdleTime="60000"/>
59.
60.
73.
74.
75. port="8080" protocol="HTTP/1.1"
76. connectionTimeout="20000"
77. redirectPort="8443" URIEncoding="UTF-8" acceptCount="256"/>
78.
79.
90.
91.
92.
93.
100.
101.
102.
103.
145.
146.
27.
28.
29.
30.
31.
32.
33.
34.
35.
57.
58.
59. maxThreads="500" minSpareThreads="20" maxIdleTime="60000"/>
60.
61.
74.
75.
76. port="8080" protocol="HTTP/1.1"
77. connectionTimeout="20000"
78. redirectPort="8443" URIEncoding="UTF-8" acceptCount="256"/>
79.
80.
91.
92.
93.
94.
101.
102.
103.
104.
105.
147.
148.