oracleoracle-apexoracle-apex-5oracle-apex-5.1ora-24247

Oracle APEX 5.0 to 5.1 up gradation XS$ACE_TYPE must be declared


I want to upgrade Oracle APEX 5.0 to 5.1. In the access control stage, an error shows in the oracle database 11gR2.

    BEGIN
    DBMS_NETWORK_ACL_ADMIN.APPEND_HOST_ACE (
    HOST => '*',
    ace => xs$ace_type (privilege_list => xs$name_list ('connect'),
                       principal_name => 'APEX_050100',
                       principal_type => xs_acl.ptype_db)
    );
    END;
    /

The following error show in XS$ACE_TYPE

    ERROR at line 4:
    ORA-06550: line 4, column 8:
    PLS-00201: identifier 'XS$ACE_TYPE' must be declared
    ORA-06550: line 2, column 1:
    PL/SQL: Statement ignored

Solution

  • Give a try - worked for me :

    Step 1:

        SQL> grant execute on utl_http to username;
    
        Grant succeeded.
    

    Step 2: Conn as sysdba conn / as sysdba

        BEGIN
                DBMS_NETWORK_ACL_ADMIN.CREATE_ACL (
                acl => 'sonudev.xml',
                description => 'Permissions to access  mail',
                principal => 'USERNAME',
                is_grant => TRUE,
                privilege => 'connect',
                start_date => SYSTIMESTAMP,
                end_date => NULL);
                COMMIT;
        END;
        /
        PL/SQL procedure successfully completed.
    

    Step 3:

        BEGIN
                DBMS_NETWORK_acl_ADMIN.ADD_PRIVILEGE(
                acl => 'sonudev.xml',
                principal => 'USERNAME',
                is_grant => true,
                privilege => 'resolve'
                );
                COMMIT;
        END;
        /
        PL/SQL procedure successfully completed.
    

    Step 4:

        BEGIN
                DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL (
                acl => 'sonudev.xml',
                host => '*');
                COMMIT;
        END;
        /
    

    Step 5:

        select acl , host , lower_port , upper_port from DBA_NETWORK_ACLS;
    
        select acl , principal , privilege , is_grant from DBA_NETWORK_ACL_PRIVILEGES
    

    Reference : https://mohamedazar.com/2015/11/26/ora-24247-network-access-denied-by-access-control-list-acl/