Unable to start HTTP server after restore

After a restore of the Application Server and Oracle SOA Suite we were unable to start OHS (Oracle HTTP Server). The result of opmnctl status was:

Processes in Instance: <<>>
---------------------------------+--------------------+---------+---------
ias-component                    | process-type       |     pid | status
---------------------------------+--------------------+---------+---------
OC4JGroup:admin_group            | OC4J:admin_apps    |  241672 | Alive
ASG                              | ASG                |     N/A | Down
OC4JGroup:default_group          | OC4J:oc4j_soa      |  409618 | Alive
OC4JGroup:default_group          | OC4J:home          |  340092 | Alive
HTTP_Server                      | HTTP_Server        |  462964 | Down

The command opmnctl startproc ias-component=HTTP_Server resulted in:

Error
--> Process (pid=13365)
failed to start a managed process after the maximum retry limit

The log file /opmn/logs/HTTP_Server~1.log. Was not very helpfull:

--------
09/08/19 10:25:37 Start process
--------
ORACLE_HOME/Apache/Apache/bin/apachectl startssl: execing httpd

After a lot of Google, OTN and searching on our server we found out that the owner and rights for the .apachectl somehow got lost during the back up (compression?) or restore operation. On UNIX the HTTP server should run as root. Changing the ownership and rights as described in the link solved our problem:

  • Change to root user
  • Navigate to ORACLE_HOME/Apache/Apache/bin and execute the following command:
  • chown root .apachectl
  • chmod 6750 .apachectl
  • Exit root.

8 thoughts on “Unable to start HTTP server after restore

  1. Frits Hoogland

    It’s only needed to set SUID and SGID if the port or ports on which the webserver is set to run is < 1024 and if it’s on unix or linux.

    indeed the daemon itself then runs using UID ‘0’, the ‘childs’ of the daemon (with which clients communicate) run with the userid and groupid set in the apache configuration.

    compression does not reset file properties. if using tar, there are limitations on the properties of files, like rights, ownership, etc. (a normal user can not restore a file with root ownership and SUID and/or SGID bits)

  2. chris smith

    I had a similar issue. Same error. my .apachectl file is owned by oracle and that seems to work.
    Stopped everything including the database (check for leftover processes ps -ef). My home/oms/Appache/Appache/logs directory was really full. Cleared out the logs and deleted the httpd.pid file.
    did ./opmctl startall.

    took a while but eventually came back. I think the httpd.pid file was the key but i can’t be sure.

    thanks
    Chris

  3. dberthel

    One other solution /* before */ changing any configuration

    Go to the directory $OMS_HOME/Apache/Apache/logs then
    rm error_log *.sem access_log

    Cause could be an $OMS_HOME/Apache/Apache/logs/error_log file to large

  4. alka

    Hi all,
    Just have the same error and I fixed it as follow:
    1. Stop the OMS, Application Server Control (if running) from this OMS Home:
    /opmn/bin
    opmnctl stopall
    emctl stop iasconsole

    2. Check for any and defunct /stuck processes:
    $ ps -ef |grep oms10g
    $ ps -ef |grep httpd

    From the ‘ps’ output, check for any processes that have been started from the ‘oms10g’ path.
    ===> If any process is still present, kill them using the command : kill -9

    3. Take a backup and all the below files to clean up the OMS environment:
    /opmn/logs/*.*
    /opmn/logs/states/*
    /Apache/Apache/logs/*
    /j2ee/OC4J_EM/persistence/OC4J_EM_default_island_1/*
    /j2ee/OC4J_EMPROV/persistence/OC4J_EMPROV_default_island_1/*
    /j2ee/home/persistence/home_default_island_1/*

    4.Start the OMS
    /opmn/bin
    opmnctl startall

    Thanks

  5. recommended

    I was recommended this blog by my cousin. I am not sure whether this post is
    written by him as nobody else know such detailed about my problem.
    You are wonderful! Thanks!

Leave a Reply

Your email address will not be published. Required fields are marked *