For users who often learn Linux, they must know that the Linux operating system has developed very rapidly over the past decade. If you learn the Linux operating system, you may encounter apache and resin problems in the redhat environment, here we will introduce the solutions to the apache and resin problems in the redhat environment, and share them with you here.
1. install apache
- [root@localhost httpd-2.2.11]#
- ./configure --prefix=/usr/local/apache2 --enable-so
- make
- make install
2. install resin
- [root@localhost resin-pro-3.1.8]#
- ./configure --prefix=/usr/local/resin2 --with-apxs=/usr/local/apache2/bin/apxs --with-
- apache=/usr/local/apache2/
- make
- make install
3. Check whether the mod_caucho.so module has been generated in apache. The following figure shows whether the mod_caucho.so module has been generated:
- [root@localhost modules]# pwd
- /usr/local/apache2/modules
- [root@localhost modules]# ls
- httpd.exp mod_caucho.so
4. check whether the main configuration file of apache has been automatically written into the Integrated Configuration:
- [root@localhost conf]# pwd
- /usr/local/apache2/conf
- [root@localhost conf]# vi httpd.conf
The last section has been written:
- LoadModule caucho_module /usr/local/apache2/modules/mod_caucho.so
- ResinConfigServer localhost 6800
- CauchoConfigCacheDirectory /tmp
- CauchoStatus yes
Add it as follows:
- SetHandler caucho-status
- AddHandler caucho-request jsp
- SetHandler caucho-request
In addition, change the main directory for resolution:
- DocumentRoot "/home/XXX/"
- # This should be changed to whatever you set DocumentRoot to.
- #
- <Directory "/home/XXX"> #
Note that you need to change the value here. Otherwise, apache will report a 403 error.
5. Configure the resolution directory of resin to point to the apache DocumentRoot:
<! -- <Web-app id = "/" root-directory = "webapps/ROOT"/> --> comment out the default resolution directory.
Add a new host
- <host id="" root-directory=".">
- <redeploy-mode>manual</redeploy-mode>
- <web-app id="/" document-directory="/home/XXX">
- <access-log path="/home/XXXlog/access.log"
- format="%h`%l`%u`%{%Y-%m-%d %H:%M:%S}t`%r`%s`%b`%{Referer}i`%{User-Agent}i`%{X-Up
- -Calling-Line-ID}i"
- rollover-period='1D'
- archive-format='%Y-%m-%d.access.XXX.log'/>
- </web-app>
- </host>
6. Start apache and start resin.
You only need to access the apache Port during access. I hope it will help you learn the Linux operating system.
- Configuration notes: configure the DNS server in Linux
- How to display Chinese Characters in RedHat Linux 5
- How to disable SELinux in Redhat Enterprise Linux
- Install the KDE package in Linux
- Redhat Linux Remote Desktop configuration