SYS_并发管理系列1_并发程序管理器概要(案例)

2012-03-01 Created By BaoXinjian

一、摘要


区别于普通功能的处理机制,并发处理机制其实是一个异步处理机制,它把程序放到后台来运行,前台的操作还给用户,允许用户可以继续做其他业务。

技术上将,异步处理的好处是降低系统特定时间点的负载,提升系统资源的整体使用率。感受上讲,异步的机制可以有效提升整体的使用感受,减少用户无效的等待时间。

 

1. 并发处理机制(Current Processing)的两类组件

并发管理器(Concurrent Managers)

并发请求(Concurrent Requests)

像公司中“经理”一样,Manager给Worker安排任务,Worker负责具体的执行。

Oracle EBS中的Concurrent Managers就是负责安排工作,Concurrent Requests负责具体的执行。

 

2. 并发管理器是如何管理并发请求

并发请求从提交到运行大概的过程是这样的,

用户首先提交并发程序运行请求,并发请求会首先放入请求队列中,

再由Internal Concurrent Manager根据特定的规则找到对应的Concurrent Manager(是Standard Manager,还是特定的并发管理器)来运行这些请求。

下图为一个典型的并发管理器管理并发请求的流程图:

 

3. 并发管理器的定义

并发管理器(Concurrent Manager) =  参数(缓存大小、节点设置...) + 特殊规则(Specialization Rules) + 工作班次(Work Shifts)

 

 


4. 并发器分类

(1). Concurrent Manager

并发程式管理器,用于管理并发程式

(2). Internal Concurrent Manager (ICM)

ICM实际上是一个后台进程,用于管理其他Manager(start/stop).DBA要保证ICM处于运行状态,否则其他的Concurrent Manager无法Start/Stop.

(3). Standard Manager (SM)

默 认的Concurrent Manager,如果request没有指定具体的Concurrent Manager(比如Inventory Manager, Receivables Tax Manager, etc),那么SM就会作为默认的Mananger来处理这个Request。

(4).产品相关的Concurrent Manager

有很多产品相关的Concurrent Managers,比如Inventory Manager,MRP Manager,Receiving Transaction Manager。

这些Managers针对特定模块来构建的,用于统一管理特定模块的Program。

 

二、并发管理器预览


1. 并发管理器

2. 内部并发管理器设定

 

三、基本概念


1. 常用的管理器

(1). Internal Manager:用以管理其他并发器

(2). Standard Manager:用户定义的Program等

(3). Inventory Manager: 管理Inventory的Interface交易

(4). Interface Manager

 

四、典型异常处理


1. 出现问题执行后发现状态为inactive,No Manager

2. 检查并发管理器

(1). 正常情况Actual>0

(2). 异常情况下Actual=0

(3). 处理 

Step1 : login as testmgr on hrms-test 

Step2 : cd $INST_TOP/admin/scripts  ( or  cd $ADMIN_SCRIPTS_HOME ) 

Step3 : $ adcmctl.sh start apps/<apps password>

 

五、并发管理器运行状态


1. 操作系统下如何检查Concurrent Mananger的运行情况

FNDLIBR进程是否启动,这个表示Internal Concurrent Manager进程是否运行

System Admin > Concurrent > Manager > Define > FNDLIBR:Concurrent Manager

[applvis@paleonode1 ~]$ ps -ef | grep FNDLIBR
applvis   4480  4475  0 17:56 pts/1    00:00:01 FNDLIBR
applvis   4798  4629  0 17:58 ?        00:00:00 FNDLIBR
applvis   4799  4629  0 17:58 ?        00:00:00 FNDLIBR
applvis   4800  4629  0 17:58 ?        00:00:00 FNDLIBR

/*FNDLIBR process indicates that concurrent mnagers are up and requests are running on the system.*/ /*Sometimes it happens that even after stopping the concurrent managers by adcmctl.sh stop apps/apps some of the requests might continue running.*/ /*In such cases you can wait for say 5 minutes and then if it dos not stop then you can kill those FNDLIBR processes bykill -9 <processid>*/

 

2. 如何start/stop Internal Concurrent Manage

/*$COMMON_TOP/admin/scripts for 11i*/
/*$INST_TOP/admin/scripts for R12*/
[applvis@paleonode1 gavin_apps]$ cd $INST_TOP/admin/scripts
[applvis@paleonode1 scripts]$ pwd /u2/VIS/visappl/inst/apps/PROD_paleonode1/admin/scripts
[applvis@paleonode1 scripts]$ adcmctl.sh stop apps/apps You are running adcmctl.sh version 120.17.12010000.3 Shutting down concurrent managers for PROD ... ORACLE Password: oracle Submitted request 5816470 for CONCURRENT FND SHUTDOWN adcmctl.sh: exiting with status 0 adcmctl.sh: check the logfile /u2/VIS/visappl/inst/apps/PROD_paleonode1/logs/appl/admin/log/adcmctl.txt for more information ...

 

3. 如何starting the Internal Concurrent Manager with diag=Y for detailed info

[applvis@paleonode1 scripts]$ adcmctl.sh  start apps/apps diag=Y
You are running adcmctl.sh version 120.17.12010000.3
Starting concurrent manager for PROD ...
Starting PROD_0105@PROD Internal Concurrent Manager
Default printer is noprint
adcmctl.sh: exiting with status 0
adcmctl.sh: check the logfile /u2/VIS/visappl/inst/apps/PROD_paleonode1/logs/appl/admin/log/adcmctl.txt for more information ... 

 

4. 如何checking the Internal Concurrent Manager status

[applvis@paleonode1 scripts]$ adcmctl.sh  start apps/apps diag=Y
You are running adcmctl.sh version 120.17.12010000.3
Starting concurrent manager for PROD ...
Starting PROD_0105@PROD Internal Concurrent Manager
Default printer is noprint
adcmctl.sh: exiting with status 0
adcmctl.sh: check the logfile /u2/VIS/visappl/inst/apps/PROD_paleonode1/logs/appl/admin/log/adcmctl.txt for more information ...  

[applvis@paleonode1 scripts]$ adcmctl.sh  status apps/apps
You are running adcmctl.sh version 120.17.12010000.3
Internal Concurrent Manager is Active.
adcmctl.sh: exiting with status 0
adcmctl.sh: check the logfile /u2/VIS/visappl/inst/apps/PROD_paleonode1/logs/appl/admin/log/adcmctl.txt for more information ...  

[applvis@paleonode1 scripts]$ ps -ef | grep FNDLIBR
applvis   4480  4475  0 17:56 pts/1    00:00:01 FNDLIBR
applvis   8619  8614  0 18:54 pts/2    00:00:00 FNDLIBR
applvis   8743  7502  0 18:55 pts/2    00:00:00 grep FNDLIBR

 

5. Internal Concurrent Manager log file?

ICM log文件位于$APPLCSF/$APPLLOG或者$FND_TOP/$APPLLOG.

ICM日志的格式:<SID>_MMDD.mgr

 

四、并发管理器相关表和脚本


1. 相关表Related Tables

FND_CONCURRENT_PROGRAMS

FND_CONCURRENT_REQUESTS

FND_CONCURRENT_PROCESSES

FND_CONCURRENT_QUEUES

2. 相关视图Related View

FND_CONCURRENT_PROGRAMS_VL

FND_CONCURRENT_QUEUES_VL

FND_CONC_REQ_SUMMARY_V

FND_EXECUTABLES_VL

3. 相关脚本Related Scripts

$FND_TOP/sql Scripts

 * afimchk.sql Tells the status of the ICM

 * afcmstat.sql Lists active manager processes

 * afrqrun.sql Lists all the running, waiting and Terminating requests

 * afrqwait.sql Lists requests that are constrained and waiting for the ICM to release them.

 * afrqscm.sql Prints log file name of managers that can run a given request.

 * afcmcreq.sql Prints the log file name of the manager that processed the request

 * afrqstat.sql Summary of completed concurrent requests grouped by completion status and execution type..

 * afimlock.sql Lists locks that the ICM is waiting to get

 * afcmrrq.sql Lists managers that currently are running a request

 

Thanks and Regards

posted on 2012-03-01 14:32  东方瀚海  阅读(352)  评论(0编辑  收藏  举报