Wednesday, May 13, 2020

Oracle Apex & ORDS Installation & Apache Tomcat Server Configuration


Apex Configuration :

  1. Run--------@apexins.sql sysaux sysaux temp /i/

  2. Go To Apex Location Folder => Run--------@apex_epg_config.sql  D:/Oracle/apex/apex <parent of apex directory> (@apex_epg_config.sql)

  3. @apxconf.sql
  4. alter user anonymous account unlock;
  5. @apxconf.sql

  6. @apex_rest_config.sql
  7. Unlock All Locked User (

                select username,account_status from dba_users  where username like 'APEX%';

                select username,account_status from dba_users  where username like  'ORDS%';

      
OR
        select username,account_status from dba_users where lock_date is not null

                 and username like 'APEX%'; )

Run Procedure For ACL Create


 DECLARE

  ACL_PATH  VARCHAR2(4000);

BEGIN

  -- Look for the ACL currently assigned to '*' and give APEX_050100----------( Or APEX_050000)

  -- the "connect" privilege if APEX_050100 does not have the privilege yet.

 

  SELECT ACL INTO ACL_PATH FROM DBA_NETWORK_ACLS

   WHERE HOST = '*' AND LOWER_PORT IS NULL AND UPPER_PORT IS NULL;

 

  IF DBMS_NETWORK_ACL_ADMIN.CHECK_PRIVILEGE(ACL_PATH, 'APEX_050100',

     'connect') IS NULL THEN

      DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH,

     'APEX_050100', TRUE, 'connect');

  END IF;

 

EXCEPTION

  -- When no ACL has been assigned to '*'.

  WHEN NO_DATA_FOUND THEN

  DBMS_NETWORK_ACL_ADMIN.CREATE_ACL('power_users.xml',

    'ACL that lets power users to connect to everywhere',

    'APEX_050100', TRUE, 'connect');

  DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL('power_users.xml','*');

END;

/

COMMIT;



DECLARE

  ACL_PATH  VARCHAR2(4000);

BEGIN

  -- Look for the ACL currently assigned to 'localhost' and give APEX_050100

  -- the "connect" privilege if APEX_050100 does not have the privilege yet.

  SELECT ACL INTO ACL_PATH FROM DBA_NETWORK_ACLS

   WHERE HOST = 'localhost' AND LOWER_PORT IS NULL AND UPPER_PORT IS NULL;

   

  IF DBMS_NETWORK_ACL_ADMIN.CHECK_PRIVILEGE(ACL_PATH, 'APEX_050100',

     'connect') IS NULL THEN

      DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH,

     'APEX_050100', TRUE, 'connect');

  END IF;

  

EXCEPTION

  -- When no ACL has been assigned to 'localhost'.

  WHEN NO_DATA_FOUND THEN

  DBMS_NETWORK_ACL_ADMIN.CREATE_ACL('local-access-users.xml',

    'ACL that lets users to connect to localhost',

    'APEX_050100', TRUE, 'connect');

  DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL('local-access-users.xml','localhost');

END;

/

COMMIT;


ORDS Configuration :

  1. Go To ORDS Location=======>>D:\Oracle\ords

         Connect SQL Plus & Execute===>>EXEC DBMS_XDB.SETHTTPPORT(0);

2. Copy Image Folder From Apex Folder To Ords Folder.

3. java -jar ords.war instal


 Enter the location to store configuration data:C:\Oracle\OracleApp\apex\ords\cofig
Enter the name of the database server [localhost]:localhost
Enter the database listen port [1521]:1521
Enter 1 to specify the database service name, or 2 to specify the database SID1]:1
Enter the database service name:orcl
Enter the database password for ORDS_PUBLIC_USER:
Confirm password:
Please login with SYSDBA privileges to verify Oracle REST Data Services schema.
Enter the username with SYSDBA privileges to verify the installation [SYS]: sys
Enter the database password for sys:
Confirm password:
Enter 1 if you want to use PL/SQL Gateway or 2 to skip this step:2
If using Oracle Application Express or migrating from mod_plsql then you must enter 1 [1]:1
Enter the database password for APEX_PUBLIC_USER:
Confirm password:
   Enter 1 to specify passwords for Application Express RESTful Services database
   sers (APEX_LISTENER, APEX_REST_PUBLIC_USER) or 2 to skip this step [1]:1
   Enter the database password for APEX_LISTENER:
   Confirm password:
   Enter the database password for APEX_REST_PUBLIC_USER:
  Confirm password:
Enter 1 if you wish to start in standalone mode or 2 to exit [1]:1
Enter the APEX static resources location:C:\Oracle\OracleApp\apex\ords\images
Enter 1 if using HTTP or 2 if using HTTPS [1]:1


Internal Server Error (500):

alter system flush buffer_cache;

alter system flush shared_pool;


Apex ORDS Database Verification : (When Image Showing Problem then validate database) :

java -jar ords.war validate --database apex;


Apex ORDS 404 Error:(The request could not be mapped to any database. Check the request URL is correct, and that URL to database mappings have been correctly configured) :


1.SELECT username, account_status, created, lock_date, expiry_date FROM dba_users WHERE account_status != 'OPEN';

2.Then perform a bunch of “alter user xxx identified as xxxx account unlock”.

3.After you have open every necessary user account, perform the following in your console as administrator:

After Run Command(Java -jar ords.war setup)







7 comments:


  1. Iam so thrilled because of finding your alluring website here.Actually i was searching for Oracle DBA.Your blog is so astounding and informative too..Iam very happy to find such a creative blog. Iam also find another one by mistake while am searching the same topicOracle APEX.Thank you soo much..

    ReplyDelete

  2. Iam so thrilled because of finding your alluring website here.Actually i was searching for Oracle CPQ BML.Your blog is so astounding and informative too..Iam very happy to find such a creative blog. Iam also find another one by mistake while am searching the same topic Oracle PPM Cloud.Thank you soo much.

    ReplyDelete
  3. I wish to show thanks to you just for bailing me out of this particular trouble. As a result of checking through the net and meeting techniques that were not productive, Same as your blog I found another one Oracle OSB 12c.Actually I was looking for the same information on internet for Oracle OSB 12c and came across your blog. I am impressed by the information that you have on this blog. Thanks once more for all the details.

    ReplyDelete

Image File store outside of Oracle Database and show image into Apex Application

Directory Create : grant execute on utl_file to HRMS; CREATE OR REPLACE DIRECTORY STOCK_DIRECTORY AS 'C:\Program Files (x86)\Apache Sof...