IBM Support

How to manage IBM HTTP Server from a non-root running Application Server administrative console

Troubleshooting


Problem

After configuring WebSphere Application Server to run with a non-root user, IBM HTTP Server can not be managed from WebSphere Application Server Administrative console since non-root users can not bind to ports lower than 1024 on most systems.
Following messages appear in nodeagent SystemOut.log file: ADMN1001I: An attempt is made to launch webserver61 on node myNode02. ADML0040E: The process timed out waiting for server "webserver1" initialization: 1200 seconds

Resolving The Problem

How to manage IBM HTTP Server from a non-root running WebSphere Aplication Server Administrative console

Assumptions:
- IHS_INSTALL_ROOT = /usr/IBM/HTTPServer/
- non-root WebSphere Application Server administration user is wasadm/wasgrp

1. Edit /etc/sudoers as follows :

wasadm ALL=NOPASSWD: /usr/IBM/HTTPServer/bin/apachectl -k start -f /usr/IBM/HTTPServer/conf/httpd.conf, /usr/IBM/HTTPServer/bin/apachectl -k stop -f /usr/IBM/HTTPServer/conf/httpd.conf

Note that above is whole one line.

2. Create a script named run.sh in IHS_INSTALL_ROOT/bin folder as follows :

/usr/bin/sudo /usr/IBM/HTTPServer/bin/apachectl "$@"

3. Change owner of this created script to wasadm and make executable

chown wasadm:wasgrp IHS_INSTALL_ROOT/bin/run.sh
chmod 755 IHS_INSTALL_ROOT/bin/run.sh

4. On WebSphere Application Server Administrative console change startCommand and stopCommand of managed IBM HTTP Server node to invoke "run.sh" instead of apachectl

5. Now you can start/stop IBM HTTP Server from WebSphere Application Server administrative console.

[{"Line of Business":{"code":"LOB45","label":"Automation"},"Business Unit":{"code":"BU059","label":"IBM Software w\/o TPS"},"Product":{"code":"SSEQTJ","label":"IBM HTTP Server"},"ARM Category":[{"code":"a8m50000000Cd10AAC","label":"IHS"}],"ARM Case Number":"","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All Version(s)"}]

Document Information

Modified date:
09 November 2020

UID

swg21268036