sql >> Base de Datos >  >> RDS >> Oracle

Acceso denegado al configurar DBMS_XDB.SETHTTPORT

Mira esto:

SQL> conn hr/hr
Connected.
SQL> exec dbms_xdb.sethttpport(3000);
BEGIN dbms_xdb.sethttpport(3000); END;

*
ERROR at line 1:
ORA-31050: Access denied
ORA-06512: at "XDB.DBMS_XDB", line 528
ORA-06512: at "XDB.DBMS_XDB", line 667
ORA-06512: at line 1


SQL> conn / as sysdba
Connected.
SQL> exec dbms_xdb.sethttpport(3000);

PL/SQL procedure successfully completed.

SQL> grant execute on dbms_xdb to hr
  2  /

Grant succeeded.

SQL> conn hr/hr
Connected.
SQL> exec dbms_xdb.sethttpport(3002);
BEGIN dbms_xdb.sethttpport(3002); END;

*
ERROR at line 1:
ORA-31050: Access denied
ORA-06512: at "XDB.DBMS_XDB", line 528
ORA-06512: at "XDB.DBMS_XDB", line 667
ORA-06512: at line 1


SQL> conn / as sysdba
Connected.
SQL> grant sysdba to hr
  2  /

Grant succeeded.

SQL> conn hr/hr as sysdba
Connected.
SQL> exec dbms_xdb.sethttpport(3003);

PL/SQL procedure successfully completed.

Por lo tanto, debe tener el privilegio SYSDBA para ejecutar este paquete.