ITPub博客

首页 > Linux操作系统 > Linux操作系统 > 误删Profile后的处理

误删Profile后的处理

原创 Linux操作系统 作者:OracleDPer 时间:2008-07-15 14:12:42 0 删除 编辑
紧急求助:误删除一个重要的profile

我不小心,将 MO:业务实体这个profile在SITE级的设置删除,并不小心点了一下保存。现在系统用不了,管理员帐户也登录不进去了。有什么方法可以解决阿?
-------------------------------------


Subject:         Unable to login: &REASON has been detected in &ROUTINE
          Doc ID:         Note:311329.1         Type:         PROBLEM
          Last Revision Date:         28-NOV-2006         Status:         PUBLISHED

In this Document
  Symptoms
  Changes
  Cause
  Solution

Applies to:
Oracle Application Object Library - Version: 11.5.5 to 11.5.10
This problem can occur on any platform.
Unable to login into applications. So, everything gets effected.
Symptoms

When logging into the applications, we get the following error:

Oracle error &ERRNO: &REASON has been detected in &ROUTINE.

We will be unable to login using none of the seeded users nor custom users. Applications will not allow any user to be logged in.
Changes

Change in Profile option "MO: Operation Unit"
Cause

For a VISION instance(only), if the Profile option "MO: Operation Unit" (short name for this profile options is ORG_ID) is changed to any other value apart from "Vision Operations", we encounter the above specified error.

Another place where we can check the error is when we run adstrtal.sh or adstpall.sh scripts. The following errors can be found in the log file:

Oracle error -20001: ORA-20001: FND-ORG_ID PROFILE CANNOT READ: N, OPTION, MO: Operating Unit has been detected in FND_GLOBAL.INITIALIZE.
Solution

Following are steps to change the profile option from backend:

1. Get the Profile option ID using the following query:

SQL> Select PROFILE_OPTION_ID,PROFILE_OPTION_NAME from fnd_profile_options
where PROFILE_OPTION_NAME ='ORG_ID';

2. Run the following procedure which changes the profile option:

DECLARE
stat boolean;
BEGIN
dbms_output.disable;
dbms_output.enable(100000);
stat := FND_PROFILE.SAVE('ORG_ID',, 'SITE');
IF stat THEN
dbms_output.put_line( 'Stat = TRUE - profile updated' );
ELSE
dbms_output.put_line( 'Stat = FALSE - profile NOT updated' );
END IF;
commit;
END;

3) Restart the apache server
-----------------------------------------------
 
------------------------------------------------
这个方法有点问题,首先需要把profile限制放开
update fnd_profile_options
set site_enabled_flag = 'Y' , resp_enabled_flag = 'Y' , user_enabled_flag = 'Y'
where profile_option_name = 'ORG_ID' and start_date_active <= sysdate and nvl(end_date_active, sysdate) >= sysdate ;
 
然后按照LZ的方法即可,例子里面的102 替换成你的org_id
DECLARE stat boolean;
BEGIN dbms_output.disable;
dbms_output.enable(100000);
stat := FND_PROFILE.SAVE('ORG_ID', 102, 'SITE');
IF stat THEN dbms_output.put_line( 'Stat = TRUE - profile updated' );
ELSE dbms_output.put_line( 'Stat = FALSE - profile NOT updated' );
END IF;
commit;
END;
 
DECLARE stat boolean;
BEGIN dbms_output.disable;
dbms_output.enable(100000);
stat := FND_PROFILE.SAVE('ORG_ID', 102, 'SITE');
IF stat THEN dbms_output.put_line( 'Stat = TRUE - profile updated' );
ELSE dbms_output.put_line( 'Stat = FALSE - profile NOT updated' );
END IF;
commit;
END;
用这个方法,可以使sysadmin用户可用,我我本来的管理员用户还是用不了。不过有了SYSADMIN已经保险了,我进系统后把profile设置了一下就OK了。还是搞定了,

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/785120/viewspace-401661/,如需转载,请注明出处,否则将追究法律责任。

上一篇: Item Category API
下一篇: ORACLE_AQ 队列
请登录后发表评论 登录
全部评论

注册时间:2007-12-06

  • 博文量
    13
  • 访问量
    24480