This appendix describes common problems that you might encounter when using Oracle HTTP Server (OHS), and explains how to solve them. It includes the following topics:
Section C.1, "Oracle HTTP Server Unable to Start Due to Port Conflict"
Section C.2, "System Overloaded by Number of httpd Processes"
Section C.3, "Permission Denied When Starting Oracle HTTP Server On a Port Below 1024"
Section C.4, "Oracle HTTP Server May Fail To Start If PM Files Are Not Located Correctly"
Section C.5, "Exception Thrown when Unsetting PerSetEnv and Removing Variable"
You can get the following error if Oracle HTTP Server cannot start due to port conflict:
[VirtualHost: main] (98)Address already in use: make_sock: could not bind to address [::]:7777
Determine what process is already using that port, and then either change the IP:port address of Oracle HTTP Server or the port of the conflicting process.
When too many httpd processes run on a system, the response time degrades because there are insufficient resources for normal processing.
Lower the value of MaxClients
to a value the machine can accommodate.
You will get the following error if you try to start Oracle HTTP Server on a port below 1024:
[VirtualHost: main] (13)Permission denied: make_sock: could not bind to address [::]:443
Oracle HTTP Server will not start on ports below 1024 because root privileges are needed to bind these ports.
Follow the steps in Section 4.3.2.4, "Starting Oracle HTTP Server Instances on a Privileged Port (UNIX Only)" to start Oracle HTTP Server on a Privileged Port.
If Oracle HTTP Server is not able to locate Perl module (PM) files in the path defined in the PERL5LIB
variable, Oracle HTTP Server may encounter the following errors, and fail to start:
[error] Can't locate mod_perl.pm in @INC (@INC contains:$ORACLE_HOME/perl/...)
or:
[error] Can't locate Apache::Registry.pm in @INC (@INC contains: $ORACLE_HOME/perl/...)
Check that ORACLE_HOME/ohs/bin/apachectl is correctly defined in the PERL5LIB variable. It should point to the path(s) containing the PM files. By default, it points to PM files in the following directories:
ORACLE_HOME/ohs/mod_perl/lib/site_perl/5.10.0 ORACLE_HOME/perl/lib/5.10.0 ORACLE_HOME/perl/lib/site_perl/5.10.0
If you configure mod_perl by using the EM mod_perl configuration page and try to remove a previously configured PerSetEnv
variable from the Environment field, this error is thrown:
Failed to invoke operation save on MBean oracle.as.management.mbeans.register:type=component,name=ohs1,instance=webtier _inst7971,Location=AdminServer Apply failed, modify required parameters and save again. Validation of configuration trying to apply failed . . .
To correct this situation:
Close the pop-up error and click Revert.
Remove the PerSetEnv
by doing one of the following:
Go to the Advanced Configuration page of Fusion Middleware Control and modify the mod_perl.conf file directly.
OR
Go to the DOMAIN_HOME/config/fmwconfig/components/OHS/componentName/moduleconf/mod_perl.conf and edit the configuration file directly to remove the PerSetEnv
value.
Restart OHS.
You can use the following log files to help locate errors:
This log file is necessary for debugging when mod_rewrite is used. The log file produces a detailed analysis of how the rewriting engine transforms requests. The level of detail is controlled by the RewriteLogLevel
directive.
This log file enables you to record the input to and output from the CGI scripts. This should only be used in testing, and not for production servers.
See Also:
ScriptLog in the Apache HTTP Server documentation at:http://httpd.apache.org/docs/current/mod/mod_cgi.html#scriptlog
This log file records overall server problems. Refer to Chapter 7, "Managing Oracle HTTP Server Logs" for details on configuring and viewing error logs.
If you need to recover an Oracle HTTP Server instance that is installed on a remote host (that is, a host with just managed servers but no Administration Server), you must use tar
and untar
; pack.sh
and unpack.sh
do not work in this scenario.
The following are performance issues, along with their solutions, that you might encounter when running Oracle HTTP Server:
Oracle HTTP Server uses locks for its internal processing, which in turn use lock files. These files are created dynamically when the lock is created and are accessed every time the lock is taken or released. If these files reside on a slower file system (for example, network file system), then there could be severe performance degradation. To counter this issue:
On Linux
In httpd.conf, change AcceptMutex
fcntl
to AcceptMutex sysvsem
(two places).
In httpd.conf, comment-out the LockFile
directive (three places).
On Solaris
In httpd.conf, change AcceptMutex fcntl
to AcceptMutex pthread
(two places).
In httpd.conf, comment-out the LockFile
directive (three places).
Other UNIX Platforms
In httpd.conf, change the LockFile
directive to point to a local filesystem (three places).
mod_cgid and mod_fastcgi are not enabled by default. If enabled, these modules use UNIX sockets internally. If UNIX sockets reside on a slower file system (e.g., network file system), a severe performance degradation could be observed. You can set the following directives to avoid the issue:
If mod_cgid is enabled, use the ScriptSock
directive to place mod_cgid's UNIX socket on a local filesystem.
If mod_fastcgi is enabled, use the FastCgiIpcDir
directive to place mod_fastcgi's UNIX sockets on a local filesystem.
If you are using mod_wl_ohs to route the requests to back-end WLS server/cluster, and the DocumentRoot is on a slower file system (e.g., network file system), then every request that is routed to the backend server can experience performance issues. This can be overcome by setting WLSRequest
to ON
instead of SetHandler
weblogic-handler
.
In some extreme configurations, you might see the following message in the OHS error log:
dms_fail_shm_expansion: out of DMS shared memory in pid XXX, disabling DMS; increase DMSThreadSharedMem directive from YYY
This is because of an incorrect calculation of required shared memory for OHS DMS. This can be resolved by setting DMSThreadSharedMem
to a larger value than the default of 350. Continue setting DMSThreadSharedMem
50% higher until the problem is resolved.
In a configuration with a very large number of virtual hosts (hundreds or thousands), if the above workaround does not work, you can instead set the environment variable OHS_DMS_BLOCKSIZE to the desired value.