Skip to main content
Previous section   Next section

Using Apache DSOs under HP-UX

This section describes how to resolve a common start-up problem that can be encountered when using the Gateway Apache DSOs (CSPa[n][Sys].so) under the HP-UX operating system.
The essential symptom is that Apache fails to start and reports an error message to the console indicating a missing symbol, such as
(or similar).

apachectl start
Syntax error on line 1137 of /opt/hpws/apache/conf/httpd.conf:
Cannot load /opt/cspgateway/bin/ into server: 
Unresolved symbol: sem_init (code) from /opt/cspgateway/bin/
The Semaphore functions are contained in the standard run-time library, This is one of a series of libraries that have to be preloaded when thread-safe libraries (such as the Gateway DSOs) are used. This holds true if the hosting executable (Apache
in this case) doesn't explicitly link to the affected libraries at start-up time.
The run-time library is usually found in the /usr/lib/ directory.
Libraries are set for preloading by including them in the LD_PRELOAD environment variable.
For example:
export LD_PRELOAD=/usr/lib/
apachectl start
setenv LD_PRELOAD /usr/lib/
apachectl start
Alternatively, if sudo is used to start Apache:
sudo sh -c "export LD_PRELOAD=/usr/lib/; apachectl start" 
After pre-loading the run-time librtary, Apache should start without reporting any further error conditions.
Previous section   Next section