My Oracle Support Banner

DB Upgrade to 19c failing with ORA-01956: invalid command when OS_ROLES are being used (Doc ID 3016248.1)

Last updated on APRIL 23, 2024

Applies to:

Oracle Database - Enterprise Edition - Version 19.3.0.0.0 and later
Information in this document applies to any platform.

Symptoms

DB Upgrade from 11.2.0.4 to 19c fails with below errors -

REASON:
ERRORS FOUND: During Upgrade
FILENAME: /xxx/<SID>/log/<SID>/101/dbupgrade/catupgrd20240405120034<SID>0.log AT LINE NUMBER: 856720
ERRORS FOUND: During Upgrade
FILENAME: /xxx/<SID>/log/<SID>/101/dbupgrade/catupgrd20240405120034<SID>0.log AT LINE NUMBER: 1012909
------------------------------------------------------
Identifier CATALOG 24-04-05 12:12:02
SCRIPT = [/<19c OH>/rdbms/admin/c18.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used ORA-06512: at line 4
ORA-06512: at line 2
]
STATEMENT = [begin
execute immediate 'revoke resource from outln';
exception when others then
if sqlcode in (-1951) then null; else raise; end if;
end;]
------------------------------------------------------
------------------------------------------------------
Identifier CATALOG 24-04-05 12:12:02
SCRIPT = [/<19c OH>/rdbms/admin/c18.sql]
ERROR = [ORA-06512: at line 4 ORA-06512: at line 2
]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier CATALOG 24-04-05 12:12:02
SCRIPT = [/<19c OH>/rdbms/admin/c18.sql]
ERROR = [ORA-06512: at line 2]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:13:53
SCRIPT = [/<19c OH>/rdbms/admin/catgwm.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT gsmuser_role to gsmuser]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:14:00
SCRIPT = [/<19c OH>/rdbms/admin/catqueue.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT aq_administrator_role TO system WITH ADMIN OPTION]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:15:29
SCRIPT = [/<19c OH>/rdbms/admin/cathcsx.sql]
ERROR = [ORA-01924: role 'DBMS_MDX_INTERNAL' not granted or does not exist]
STATEMENT = [GRANT DBMS_MDX_INTERNAL TO PACKAGE SYS.DBMS_MDX_ODBO]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:21:39
SCRIPT = [/<19c OH>/rdbms/admin/catumfusr.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT sysumf_role TO sys$umf]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:21
SCRIPT = [/<19c OH>/rdbms/admin/catsnmp.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant OEM_MONITOR to DBSNMP]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:21
SCRIPT = [/<19c OH>/rdbms/admin/catsnmp.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant CDB_DBA to DBSNMP]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:29
SCRIPT = [/<19c OH>/rdbms/admin/catadmprvs.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT select_catalog_role TO sysbackup]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:30
SCRIPT = [/<19c OH>/rdbms/admin/catadmprvs.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT aq_administrator_role TO sysrac]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:30
SCRIPT = [/<19c OH>/rdbms/admin/catgwmcat.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant gsm_pooladmin_role to gsmadmin_internal with admin option]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:30
SCRIPT = [/<19c OH>/rdbms/admin/catgwmcat.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant DATAPUMP_EXP_FULL_DATABASE to gsmadmin_internal]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:30
SCRIPT = [/<19c OH>/rdbms/admin/catgwmcat.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant DATAPUMP_IMP_FULL_DATABASE to gsmadmin_internal]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:30
SCRIPT = [/<19c OH>/rdbms/admin/catgwmcat.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant aq_administrator_role to gsmcatuser]
------------------------------------------------------
------------------------------------------------------
Identifier CATPROC 24-04-05 12:25:36
SCRIPT = [/<19c OH>/rdbms/admin/catgwmcat.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT gsmadmin_role, gsm_pooladmin_role to gsmcatuser]
------------------------------------------------------
------------------------------------------------------
Identifier JAVAVM 24-04-05 12:30:58
SCRIPT = [/<19c OH>/javavm/install/jvma121.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used ORA-06512: at "SYS.INITJVMAUX", line 28
ORA-06512: at line 4
]
STATEMENT = [begin
initjvmaux.drp('drop role dbjavascript');
initjvmaux.exec('create role dbjavascript');
initjvmaux.exec('grant dbjavascript to sys');
initjvmaux.drp('drop package sqljutl2');
end;]
------------------------------------------------------
------------------------------------------------------
Identifier JAVAVM 24-04-05 12:30:58
SCRIPT = [/<19c OH>/javavm/install/jvma121.sql]
ERROR = [ORA-06512: at "SYS.INITJVMAUX", line 28 ORA-06512: at line 4
]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier JAVAVM 24-04-05 12:30:58
SCRIPT = [/<19c OH>/javavm/install/jvma121.sql]
ERROR = [ORA-06512: at line 4]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier CATJAVA 24-04-05 12:31:45
SCRIPT = [/<19c OH>/rdbms/admin/catjava.sql]
ERROR = [ORA-20000: JServer has not been correctly loaded into the database. ORA-06512: at line 3
]
STATEMENT = [BEGIN
IF sys.dbms_registry.is_loaded('JAVAVM',sys.dbms_registry.release_version) != 1 THEN
RAISE_APPLICATION_ERROR(-20000,
'JServer has not been correctly loaded into the database.');
END IF;
END;]
------------------------------------------------------
------------------------------------------------------
Identifier CATJAVA 24-04-05 12:31:45
SCRIPT = [/<19c OH>/rdbms/admin/catjava.sql]
ERROR = [ORA-06512: at line 3]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier CONTEXT 24-04-05 12:32:00
SCRIPT = [/<19c OH>/ctx/admin/ctxdbmig.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant RESOURCE, UNLIMITED TABLESPACE to ctxsys]
------------------------------------------------------
------------------------------------------------------
Identifier CONTEXT 24-04-05 12:32:00
SCRIPT = [/<19c OH>/ctx/admin/s1102000.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant resource, unlimited tablespace to ctxsys]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:34:30
SCRIPT = [/<19c OH>/rdbms/admin/catsodaddl.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant SODA_APP to XDB with admin option]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:34:33
SCRIPT = [/<19c OH>/rdbms/admin/catsodaddl.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant SODA_APP to XDB with admin option]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:34:58
SCRIPT = [/<19c OH>/rdbms/admin/prvtxsfsclient.plb]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [grant dbfs_role to xdb]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:35:31
SCRIPT = [/<19c OH>/rdbms/admin/dbmsxdbt_int.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used]
STATEMENT = [GRANT ctxapp TO xdb]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:37:06
SCRIPT = [/<19c OH>/rdbms/admin/prvtgwmco.plb]
ERROR = [ORA-00600: internal error code, arguments: [kzdrdg], [180], [0], [], [], [], [], [], [], [], [], []
]
STATEMENT = [GRANT datapump_imp_full_database TO package gsmadmin_internal.exchange]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:37:06
SCRIPT = [/<19c OH>/rdbms/admin/prvtgwmco.plb]
ERROR = [[], [], [], [], [], []]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:37:11
SCRIPT = [/<19c OH>/rdbms/admin/prvtgwmco.plb]
ERROR = [ORA-00600: internal error code, arguments: [kzdrdg], [180], [0], [], [], [], [], [], [], [], [], []
]
STATEMENT = [GRANT datapump_exp_full_database TO package gsmadmin_internal.exchange]
------------------------------------------------------
------------------------------------------------------
Identifier XDB 24-04-05 12:37:11
SCRIPT = [/<19c OH>/rdbms/admin/prvtgwmco.plb]
ERROR = [[], [], [], [], [], []]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier SDO 24-04-05 12:39:10
SCRIPT = [/<19c OH>/md/admin/catmdh.sql]
ERROR = [ORA-01956: invalid command when OS_ROLES are being used ORA-06512: at line 23
ORA-06512: at line 17
]
STATEMENT = [declare
already_exists exception;
pragma exception_init(already_exists, -01920);
role_not_granted exception;
pragma exception_init(role_not_granted, -01951);
begin
begin
execute immediate
' create user MDDATA no authentication ';
exception
when already_exists then NULL;
when others then
SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
'EXCEPTION[catmdh.sql(' || $$PLSQL_LINE || ')2]: ' || SQLERRM); RAISE;
end;
begin
execute immediate
' revoke connect from MDDATA ';
exception
when role_not_granted then NULL;
when others then
SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
'EXCEPTION[catmdh.sql(' || $$PLSQL_LINE || ')2]: ' || SQLERRM); RAISE;
end;
begin
execute immediate
' revoke resource from MDDATA ';
exception
when role_not_granted then NULL;
when others then
SYS.DBMS_SYSTEM.KSDWRT(SYS.DBMS_SYSTEM.TRACE_FILE,
'EXCEPTION[catmdh.sql(' || $$PLSQL_LINE || ')2]: ' || SQLERRM); RAISE;
end;
end;]
------------------------------------------------------
------------------------------------------------------
Identifier SDO 24-04-05 12:39:10
SCRIPT = [/<19c OH>/md/admin/catmdh.sql]
ERROR = [ORA-06512: at line 23 ORA-06512: at line 17
]
STATEMENT = [as above]
------------------------------------------------------
------------------------------------------------------
Identifier SDO 24-04-05 12:39:10
SCRIPT = [/<19c OH>/md/admin/catmdh.sql]
ERROR = [ORA-06512: at line 17]
STATEMENT = [as above]
------------------------------------------------------

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.