Oracle Database Error Solutions – Easy & Practical Guides

Welcome to a dedicated platform for solving common Oracle Database errors like ORA-01194, ORA-01555, ORA-01017, ORA-12154 and more.

Learn step-by-step solutions, real-world troubleshooting, and best practices to handle Oracle issues efficiently.

View All Oracle Error Solutions

Unable to Stop Apache – adapcctl.sh Exiting With Status 1 in Oracle E-Business Suite (EBS) R12/11i

Unable to Stop Apache – adapcctl.sh Exiting With Status 1 in Oracle E-Business Suite (EBS) R12/11i

Oracle E-Business Suite administrators frequently use the adapcctl.sh utility script to start and stop Apache services on the application tier. However, in some environments, attempting to stop Apache may fail with the following error:

unable to stop apache

adapcctl.sh: exiting with status 1

ERROR:
Service cannot be stopped using this script

This issue is commonly encountered in Oracle E-Business Suite 11i and R12 environments and is usually related to inconsistencies in the Apache runtime files stored under the Oracle Application Server logs directory.

In this guide, we will explain the root cause, troubleshooting methodology, and step-by-step resolution for the adapcctl.sh exiting with status 1 error.


Applies To

  • Oracle E-Business Suite 11.5.10.2
  • Oracle E-Business Suite R12
  • Oracle Application Server (Apache)
  • Oracle Apps DBA Administration

Error Symptoms

When attempting to stop Apache using adapcctl.sh, the following message appears:

adapcctl.sh stop

adapcctl.sh: exiting with status 1

ERROR:
Service can not be stopped using this script

Despite the stop command being executed correctly, Apache remains running or the script refuses to proceed.


What is adapcctl.sh?

The adapcctl.sh script is an Oracle Applications utility used to manage Apache services on the application tier.

Common usage includes:

adapcctl.sh start
adapcctl.sh stop
adapcctl.sh status

The script checks Apache runtime files and determines whether Apache is running in NORMAL mode or RESTRICTED mode before performing administrative actions.


Root Cause Analysis

After investigation, the issue was traced to the following directory:

$IAS_ORACLE_HOME/Apache/Apache/logs/

The directory contained a mixture of files created by different Apache startup modes.

The following files were present simultaneously:

httpd.pid
httpd_pls.pid
apache_runmode.properties

Understanding Apache Startup Modes

Normal Mode

When Apache starts in NORMAL mode, Oracle creates:

httpd.pid
httpd_pls.pid

These files are used by adapcctl.sh to identify and manage active Apache processes.


Restricted Mode

When Apache starts in RESTRICTED mode, Oracle creates:

apache_runmode.properties

This file identifies Apache as running in maintenance or restricted mode.


Why adapcctl.sh Fails

The adapcctl.sh script expects Apache to be running in only one mode at a time.

When both types of files exist simultaneously:

  • httpd.pid
  • httpd_pls.pid
  • apache_runmode.properties

The script becomes confused regarding the current Apache state.

As a safety mechanism, Oracle prevents the stop operation and returns:

adapcctl.sh: exiting with status 1

How This Situation Occurs

This condition may occur after:

  • Unexpected server shutdown
  • Incomplete Apache restart
  • Manual process termination
  • Application tier cloning
  • Failed AutoConfig execution
  • Filesystem restoration
  • Maintenance mode transitions

Step-by-Step Solution

The following procedure resolves the issue safely.

Step 1: Stop Apache Processes

Identify any running Apache processes.

ps -ef | grep httpd

If Apache processes exist, stop them gracefully.

If necessary:

kill -9 PID

Only use forceful termination when graceful shutdown is unsuccessful.


Step 2: Backup Apache Logs Directory

Create a backup before making changes.

cd $IAS_ORACLE_HOME/Apache/Apache

cp -rp logs logs_backup

This allows rollback if required.


Step 3: Remove Stale Runtime Files

Navigate to the logs directory:

cd $IAS_ORACLE_HOME/Apache/Apache/logs

Delete the stale files:

rm -f *

Alternatively, remove only the runtime files:

rm -f httpd.pid
rm -f httpd_pls.pid
rm -f apache_runmode.properties

Step 4: Restart Apache

Start Apache using:

adapcctl.sh start

Monitor the startup process carefully.


Step 5: Verify Apache Status

adapcctl.sh status

Confirm that Apache starts successfully.


Step 6: Retest Stop Command

adapcctl.sh stop

The command should now execute successfully without status 1 errors.


Additional Verification Checks

Check Apache Port Usage

netstat -an | grep LISTEN

Verify Apache ports are active.


Verify HTTP Processes

ps -ef | grep httpd

Review Apache Logs

Check:

$IAS_ORACLE_HOME/Apache/Apache/logs/error_log

Look for startup or shutdown related messages.


Real Production Scenario

In a production Oracle E-Business Suite environment, administrators switched between restricted mode and normal mode during patching activities.

Following the maintenance window, Apache could not be stopped and consistently returned:

adapcctl.sh: exiting with status 1

Investigation revealed that:

  • httpd.pid existed
  • httpd_pls.pid existed
  • apache_runmode.properties also existed

After clearing stale files and restarting Apache, the issue was resolved immediately.


Best Practices for Oracle Apps DBAs

  • Always stop services cleanly
  • Avoid manual deletion of runtime files while Apache is running
  • Monitor Apache logs regularly
  • Backup configuration before maintenance
  • Validate service status after patching
  • Execute AutoConfig after major changes
  • Document maintenance mode procedures

Common DBA Mistakes

  • Killing Apache processes without cleanup
  • Ignoring stale PID files
  • Starting Apache multiple times
  • Mixing restricted and normal startup modes
  • Skipping log reviews after failures

Troubleshooting Checklist

Before escalating the issue, verify:

  • Apache processes are stopped
  • PID files are valid
  • apache_runmode.properties is correct
  • Ports are available
  • Filesystem permissions are correct
  • AutoConfig completed successfully

Frequently Asked Questions (FAQ)

What causes adapcctl.sh exiting with status 1?

The most common cause is conflicting Apache runtime files indicating different startup modes.

Can I delete files from the logs directory?

Yes, but only after Apache has been completely stopped and a backup has been taken.

Does this issue affect Oracle EBS R12?

Yes. Similar behavior can occur in both Oracle EBS 11i and R12 environments.

Should AutoConfig be executed?

If configuration inconsistencies exist, running AutoConfig is recommended after resolving the issue.

Is Apache corruption involved?

Typically no. The issue is usually caused by stale runtime files rather than Apache software corruption.


Conclusion

The adapcctl.sh exiting with status 1 error is typically caused by conflicting Apache runtime files that incorrectly indicate multiple Apache startup modes.

By stopping Apache, backing up the logs directory, removing stale runtime files, and restarting services, Oracle Apps DBAs can quickly restore normal Apache administration functionality.

Regular monitoring, proper shutdown procedures, and maintenance best practices can help prevent this issue from recurring in Oracle E-Business Suite environments.


Your comments, especially which will help us improve the functionality, will be greatly appreciated. Do not forget to follow my Blog.


About the Author

Rana Abdul Wahid is an Oracle Database Administrator (DBA) with expertise in Oracle RMAN recovery, Oracle EBS administration, backup and recovery, performance tuning, database cloning, and troubleshooting critical Oracle database issues.

No comments:

Post a Comment

Contact / Feedback Form

Name

Email *

Message *