Centos configures Apache, Php, Jdk, Resin
About this at present configuration has many version on the net,As a whole,Basic measure is correct,But,In the place of a few detail,Having more or less discrepancy.Here,Oneself according to today's configuration process,Write the outline with basic the next:According to this compendium,Should be can install normally.
1,The module that installation system place needs:
[Root@cathysky81 ~]# Vi Install.sh
Yum Install GccYum Install CppYum Install Gcc-c++Yum Install NcursesYum Install Ncurses-develYum Install Gd-devel Php-gdYum Install Gd-develYum Install GccYum Install CppYum Install Gcc-c++Yum Install NcursesYum Install Ncurses-develYum Install Gd-devel Php-gdYum Install Gd-develYum Install Zlib-develYum Install Freetype-devel Freetype-demos Freetype-utilsYum Install Libpng-devel Libpng10 Libpng10-develYum Install Libjpeg-develYum Install ImageMagickYum Install Php-gdYum Install FlexYum Install ImageMagick-devel
[Root@cathysky81 ~]# Sh Install.sh
Installed the module that the system needs
2,About the installation of Mysql, Apache, Php,With before installation is same,If you do not have the combination that has configured + Php of Mysql + Apache correctly,Ask the about this installation documentation in referenced Php documentation
3,Install Jdk.The installation process of Jdk is such:
1) to Http://java.sun.com/ download Jdk,At present,Still recommend download to use:J2sdk-1_4_2_11-linux-i586.bin,In the documentation because of the Resin from the back,Of the description also is Jdk1.4 version.
2) Chmod A+x J2sdk-1_4_2_11-linux-i586.bin
3) . / J2sdk-1_4_2_11-linux-i586.bin
Can press in the solution below present list,Make a list that the name is J2sdk_1_4xxxxx to wait,Mv J2sdk_1_4xxxxx /usr/local/jdk
4) is revised / Etc/profile
Add following content:
JAVA_HOME=/usr/local/jdk
RESIN_HOME=/usr/local/resin
CLASSPATH= . : $JAVA_HOME/lib:$JAVA_HOME/jre/lib:$RESIN_HOME/lib:/usr/local/jdbcExport RESIN_HOME JAVA_HOME CLASSPATH
Notice:Export is this paragraph must write,When if be not written,starting Resin,Meeting occurrence mistake!!
5) save / Etc/profile
4, install Resin:
1) to Http://www.caucho.com download Resin-3.0.18.tar.gz,This is current newest version
2) solution pressing generates catalog Resin-3.0.18
3) executive Mv Resin-3.0.18 /usr/local/resin
4) compile Resin afresh:
. / Configure- - With-apxs=/usr/local/apache/bin/apxs- - With-java-home=/usr/local/jdk/- - Prefix=/usr/local/resinMake %26amp;%26amp; Make Install %26amp;%26amp; Make Clean
If / if Etc/profile setting does not have a problem,This measure can move normally
5,Configuration
1) revise / Usr/local/apache/conf/httpd.conf
Increase:
LoadModule Caucho_module /usr/local/apache/libexec/mod_caucho.so
ResinConfigServer Localhost 6802
CauchoStatus Yes
%26lt;Location /caucho-status%26gt;
SetHandler Caucho-status
%26lt;/Location%26gt;
2) revise / Usr/local/resin/conf/resin.conf
Gules part is need modification segment:
%26lt;cluster%26gt;
%26lt;srun Server-id=%26quot;%26quot; Host=%26quot;127.0.0.1%26quot; Port=%26quot;6802%26quot;/%26gt;%26lt;/cluster%26gt;
%26lt;host Id=%26quot; %26quot;%26gt;
%26lt;web-app Id='/' Document-directory=%26quot;/usr/local/apache/htdocs%26quot;/%26gt;%26lt;/host%26gt;
3)
6,
Start Apache afresh,
/ Usr/local/apache/bin/apachectl Start
The Resin that start
/ Usr/local/resin/bin/httpd.sh Start
Write a simple script to be able to check,Jsp is carried out successful:
Create A Test File '/usr/local/apache/htdocs/test.jsp'
2 + 2 = %26lt;%= 2 + 2 %%26gt;
If the character below can see on the page,The configuration that shows you succeeded already completely.
2 + 2 = 4
Textual link:Http://chinaunix.net/jh/13/719530.html
...