Thursday, September 23, 2021

Start and Stop R12.2 services and their logs

EBS R12.2 scripts have more options to start and stop its services

1.  Start /stop services on all nodes by running command on Master node:

First, use below line to check if it is a Master node:
$ grep s_adminserverstatus $CONTEXT_FILE
            <oa_service_status oa_var="s_adminserverstatus">enabled</oa_service_status>

$ { echo apps ; echo appsPWD ; echo wlsPWD ; } | adstpall.sh @ -mode=allnodes -nopromptmsg
... ... 
All enabled services for this node are started.
adstrtal.sh: Exiting with status 0
adstrtal.sh: check the logfile $LOG_HOME/appl/admin/log/adstrtal.log for more information ...

or 
$ ./adstrtal.sh apps/appsPWD -mode=allnodes

You are running adstrtal.sh version 120.24.12020000.11

Enter the WebLogic Server password: 
Running command in node node_name
All enabled services for this node are started.

adstrtal.sh: Exiting with status 0
adstrtal.sh: check the logfile $LOG_HOME/appl/admin/log/adstrtal.log for more information ...

$ adstpall.sh apps/appsPWD -mode=allnodes

You are running adstpall.sh version 120.22.12020000.7

Enter the WebLogic Server password:
Running command in node node_name
Running command in node node_name
All enabled services on this node are stopped.

adstpall.sh:Exiting with status 0
adstpall.sh: check the logfile $LOG_HOME/appl/admin/log/adstpall.log for more information ...

2. Start services on any one node (Doc ID 1902776.1):

{ echo apps ; echo appsPWD ; echo wlsPWD ; } | adstpall.sh @ -nopromptmsg

You may have to start app service on Master node first to avoid errors:
ERROR: Skipping startup of oacore_server1 since the AdminServer is down. AdminServer needs to be up before starting/stopping the managed servers.
Doc ID 2053781.1 (R12.2. Adadminsrvctl.sh Failed to Start WLS Adminserver When Using -secureapps Option)

3. Quicker stop (and so, quicker start)

./adstpall.sh apps/appsPWD -skipNM -skipAdmin

For help:
$ ./adstpall.sh -help
$ ./adstrtal.sh -help

4. Start services on Secondary node (when Primary node is not fully up)

{ echo apps ; echo appsPWD ; echo wlsPWD ; } | adstrtal.sh @ -msimode -nopromptmsg

Using -msimode option to avoid error 
ERROR: Skipping startup of oacore_server2 since the AdminServer is down. AdminServer needs to be up before starting/stopping the managed servers.
Doc ID 2052792.1 (EBS 12.2 Service Startup On Secondary Node Fails When Primary Node is Down)

5. For troubleshooting, start/stop individual component

For example, if login page is not up and available,  run

$ adopmnctl.sh status

You are running adopmnctl.sh version 120.0.12020000.2
Checking status of OPMN managed processes...
Processes in Instance: EBS_web_OHS1
---------------------------------------+--------------------+---------+---------
ias-component                     | process-type       |     pid    | status
---------------------------------------+--------------------+---------+---------
EBS_web                             | OHS                    |   30358 | NONE

It reads file in $IAS_ORACLE_HOME/instances/EBS_web_OHS1/config/OHS/EBS_web

To start Apache, run 
$ ./adapcctl.sh start

Timeout specified in context file: 100 second(s)
script returned:
****************************************************
You are running adapcctl.sh version 120.0.12020000.6
Starting OPMN managed Oracle HTTP Server (OHS) instance ...
adapcctl.sh: exiting with status 0
adapcctl.sh: check the logfile $LOG_HOME/adapcctl.txt for more information ...

In R12,2, Opmn only manages the Apache server.
WLS (Weblogic server) manages the oacore, forms and oafm services. To check a component's status:

$ sh $ADMIN_SCRIPTS_HOME/admanagedsrvctl.sh status oacore_server1
You are running admanagedsrvctl.sh version 120.14.12020000.12
Enter the WebLogic Admin password:
oacore_server1 is running.
Server specific logs are located at $FMW_HOME/user_projects/domains/...

$ sh $ADMIN_SCRIPTS_HOME/admanagedsrvctl.sh status oafm_server1
You are running admanagedsrvctl.sh version 120.14.12020000.12
Enter the WebLogic Admin password:
oafm_server1 is running.

Command                                          (Component)

$ adnodemgrctl.sh start                         (Node Manager)
$ adadminsrvctl.sh start                         (Weblogic Admin Server only on Primary node)
$ adalnctl.sh start                                       (Application Listener)
$ adopmnctl.sh start                                   (Oracle Process Manager)
$ adapcctl.sh start                                       (Apache Services)
$ admanagedsrvctl.sh start oacore_server1  (Managed Server for OACORE Services)
$ admanagedsrvctl.sh start forms_server1   (Managed Server for FormsServices)
$ admanagedsrvctl.sh start oafm_server1   (Managed Server for Fusion MiddleWare Services)
$ admanagedsrvctl.sh start forms-c4ws_server1  (Managed Server for Forms web Services)
$ adcmctl.sh start apps/apps                                (Concurrent Manager Service)
$ jtffmctl.sh start                                                  (Fullfillment Serer Services)

6. Log files

./adstrtal.sh 

You are running adstrtal.sh version 120.24.12020000.11
Enter the APPS username: apps
Enter the APPS password:
Enter the WebLogic Server password:
The logfile for this session is located at $INST_TOP/logs/appl/admin/log/adstrtal.log

Executing service control script: $INST_TOP/admin/scripts/jtffmctl.sh start
Timeout specified in context file: 100 second(s)
script returned:
*************************
You are running jtffmctl.sh version 120.3.12020000.4
Validating Fulfillment patch level via $RUN_BASE/EBSapps/comn/java/classes
Fulfillment patch level validated.
Starting Fulfillment Server for $TWO_TASK on port 9341 ...
jtffmctl.sh: exiting with status 0

.end std out.
.end err out.
****************************************************

Executing service control script: $INST_TOP/admin/scripts/adopmnctl.sh start
Timeout specified in context file: 100 second(s)
script returned:
***********************
You are running adopmnctl.sh version 120.0.12020000.2
Starting Oracle Process Manager (OPMN) ...
adopmnctl.sh: exiting with status 0
adopmnctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adopmnctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $INST_TOP/admin/scripts/adapcctl.sh start
Timeout specified in context file: 100 second(s)
script returned:
************************
You are running adapcctl.sh version 120.0.12020000.6
Starting OPMN managed Oracle HTTP Server (OHS) instance ...
adapcctl.sh: exiting with status 0
adapcctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adapcctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $INST_TOP/admin/scripts/adnodemgrctl.sh start -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
***********************
You are running adnodemgrctl.sh version 120.11.12020000.12

Calling txkChkEBSDependecies.pl to perform dependency checks for ALL MANAGED SERVERS
Perl script txkChkEBSDependecies.pl got executed successfully

Starting the Node Manager...
Refer $INST_TOP/logs/appl/admin/log/adnodemgrctl.txt for details
NodeManager log is located at $FMW_HOME/wlserver_10.3/common/nodemanager/nmHome1
adnodemgrctl.sh: exiting with status 0
adnodemgrctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adnodemgrctl.txt for more information ...

.end std out.
*** ALL THE FOLLOWING FILES ARE REQUIRED FOR RESOLVING RUNTIME ERRORS
*** Log File = $INST_TOP/logs/appl/rgf/TXK/txkChkEBSDependecies_Tue_Feb_16_21_51_31_2021/txkChkEBSDependecies_Tue_Feb_16_21_51_31_2021.log
.end err out.
****************************************************

Executing service control script: $INST_TOP/admin/scripts/adalnctl.sh start
Timeout specified in context file: 100 second(s)
script returned:
**********************
adalnctl.sh version 120.3.12020000.4
Checking for FNDFS executable.
Starting listener process APPS_${TWO_TASK}.
adalnctl.sh: exiting with status 0

adalnctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adalnctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $INST_TOP/admin/scripts/adcmctl.sh start
Timeout specified in context file: 1000 second(s)
script returned:
**********************
You are running adcmctl.sh {TWO_TASK} version 120.19.12020000.7
Starting concurrent manager for {TWO_TASK}...
Starting ${TWO_TASK}_0413@${TWO_TASK} Internal Concurrent Manager
Default printer is noprint
adcmctl.sh: exiting with status 0

adcmctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adcmctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Then, it may stay here for a while from running "adadminsrvctl.sh start -nopromptmsg":

Executing service control script: $INST_TOP/admin/scripts/adadminsrvctl.sh start -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
************************
You are running adadminsrvctl.sh version 120.10.12020000.11
Starting WLS Admin Server...
Refer $INST_TOP/logs/appl/admin/log/adadminsrvctl.txt for details
AdminServer logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/AdminServer/logs
adadminsrvctl.sh: exiting with status 0
adadminsrvctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adadminsrvctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script:
$INST_TOP/admin/scripts/admanagedsrvctl.sh start forms_server1 -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
***********************
You are running admanagedsrvctl.sh version 120.14.12020000.12
Starting forms_server1...
Server specific logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/forms_server1/logs
admanagedsrvctl.sh: exiting with status 0
admanagedsrvctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adformsctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script:
$INST_TOP/admin/scripts/admanagedsrvctl.sh start oafm_server1 -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
*********************
You are running admanagedsrvctl.sh version 120.14.12020000.12
Starting oafm_server1...
Server specific logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/oafm_server1/logs
admanagedsrvctl.sh: exiting with status 0
admanagedsrvctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adoafmctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script:
$INST_TOP/admin/scripts/admanagedsrvctl.sh start oacore_server1 -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
***********************
You are running admanagedsrvctl.sh version 120.14.12020000.12
Starting oacore_server1...
Server specific logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/oacore_server1/logs

admanagedsrvctl.sh: exiting with status 0
admanagedsrvctl.sh: check the logfile $INST_TOP/logs/appl/admin/log/adoacorectl.txt for more information ...

.end std out.
.end err out.
****************************************************

All enabled services for this node are started.
adstrtal.sh: Exiting with status 0
adstrtal.sh: check the logfile $INST_TOP/logs/appl/admin/log/adstrtal.log for more information ...


$ ./adstpall.sh apps/apps_PWD

You are running adstpall.sh version 120.22.12020000.7
Enter the WebLogic Server password:
The logfile for this session is located at $LOG_HOME/appl/admin/log/adstpall.log

Executing service control script: $ADMIN_SCRIPTS_HOME/adapcctl.sh stop
Timeout specified in context file: 100 second(s)
script returned:
****************************************************
You are running adapcctl.sh version 120.0.12020000.6
Stopping OPMN managed Oracle HTTP Server (OHS) instance ...
adapcctl.sh: exiting with status 0
adapcctl.sh: check the $LOG_HOME/appl/admin/log/adapcctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/adcmctl.sh stop
Timeout specified in context file: 1000 second(s)
script returned:
****************************************************
You are running adcmctl.sh version 120.19.12020000.7
Shutting down concurrent managers for EBSDEV ...
ORACLE Password:
Submitted request 43081823 for CONCURRENT FND SHUTDOWN

adcmctl.sh: exiting with status 0

adcmctl.sh: check the logfile $LOG_HOME/appl/admin/log/adcmctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/jtffmctl.sh stop
Timeout specified in context file: 100 second(s)
script returned:
****************************************************
You are running jtffmctl.sh version 120.3.12020000.4
Shutting down Fulfillment Server for IFSDEV on port 9331 ...
jtffmctl.sh: exiting with status 0

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/adopmnctl.sh stop
Timeout specified in context file: 100 second(s)
script returned:
****************************************************
You are running adopmnctl.sh version 120.0.12020000.2
Stopping Oracle Process Manager (OPMN)  and the managed processes ...
opmnctl stopall: stopping opmn and all managed processes...
adopmnctl.sh: exiting with status 0
adopmnctl.sh: check the logfile $LOG_HOME/appl/admin/log/adopmnctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/admanagedsrvctl.sh abort forms_server1 -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
****************************************************
You are running admanagedsrvctl.sh version 120.14.12020000.12
Stopping forms_server1...
Refer $LOG_HOME/appl/admin/log/adformsctl.txt for details
Server specific logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/forms_server1/logs
admanagedsrvctl.sh: exiting with status 0
admanagedsrvctl.sh: check the logfile $LOG_HOME/appl/admin/log/adformsctl.txt for more information ...

.end std out.
WARNING - Unable to create log file <$FMW_HOME/modules/../logs/wlst_20210416093507.log>.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/admanagedsrvctl.sh abort oacore_server1 -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
****************************************************
You are running admanagedsrvctl.sh version 120.14.12020000.12
Stopping oacore_server1...
Refer $LOG_HOME/appl/admin/log/adoacorectl.txt for details
Server specific logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/oacore_server1/logs
admanagedsrvctl.sh: exiting with status 0
admanagedsrvctl.sh: check the logfile $LOG_HOME/appl/admin/log/adoacorectl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/admanagedsrvctl.sh abort oafm_server1 -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
****************************************************
You are running admanagedsrvctl.sh version 120.14.12020000.12
Stopping oafm_server1...
Refer $LOG_HOME/appl/admin/log/adoafmctl.txt for details
Server specific logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/oafm_server1/logs
admanagedsrvctl.sh: exiting with status 0
admanagedsrvctl.sh: check the logfile $LOG_HOME/appl/admin/log/adoafmctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/adalnctl.sh stop
Timeout specified in context file: 100 second(s)
script returned:
****************************************************
adalnctl.sh version 120.3.12020000.4
Shutting down listener process APPS_IFSDEV.
adalnctl.sh: exiting with status 0

adalnctl.sh: check the logfile $LOG_HOME/appl/admin/log/adalnctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/adadminsrvctl.sh stop -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
****************************************************
You are running adadminsrvctl.sh version 120.10.12020000.11
Stopping WLS Admin Server...
Refer $LOG_HOME/appl/admin/log/adadminsrvctl.txt for details
AdminServer logs are located at $FMW_HOME/user_projects/domains/EBS_domain_${TWO_TASK}/servers/AdminServer/logs
adadminsrvctl.sh: exiting with status 0
adadminsrvctl.sh: check the logfile $LOG_HOME/appl/admin/log/adadminsrvctl.txt for more information ...

.end std out.
.end err out.
****************************************************

Executing service control script: $ADMIN_SCRIPTS_HOME/adnodemgrctl.sh stop -nopromptmsg
Timeout specified in context file: -1 second(s)
script returned:
****************************************************
You are running adnodemgrctl.sh version 120.11.12020000.12

NodeManager log is located at $FMW_HOME/wlserver_10.3/common/nodemanager/nmHome1
adnodemgrctl.sh: exiting with status 0
adnodemgrctl.sh: check the logfile $LOG_HOME/appl/admin/log/adnodemgrctl.txt for more information ...

.end std out.
.end err out.
****************************************************

All enabled services on this node are stopped.
adstpall.sh:Exiting with status 0
adstpall.sh: check the logfile $LOG_HOME/appl/admin/log/adstpall.log for more information ...

7. All options

$ ./adstrtal.sh -help
USAGE:  adstrtal.sh <appsusername/appspassword> [-nothreading]
        adstrtal.sh <applications_username/applications_password> -secureapps
        adstrtal.sh -nodbchk
        adstrtal.sh -mode=allnodes
        adstrtal.sh -msimode

$ ./adstpall.sh -help
USAGE:  adstpall.sh <appsusername/appspassword> [-skipNM] [-skipAdmin] [-nothreading]
        adstpall.sh <applications_username/applications_password> -secureapps [-skipNM] [-skipAdmin]
        adstpall.sh -nodbchk [-skipNM] [-skipAdmin]
        adstpall.sh -mode=allnodes


No comments: