4
20/03/13 Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 | Oracle Apps Notes oracleappsnotes.wordpress.com/2012/03/14/upgrade-apex/ 1/4 Oracle Apps Notes Oracle Apps Notes A collection of my random notes, primarily on Oracle Apps A collection of my random notes, primarily on Oracle Apps Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 My previous post listed the steps I had followed while configuring APEX 3.2.1 in Oracle Database 11gR2. Later, I checked the Oracle APEX website and found that the current version was 4.1.1 and it had quite a few interesting new features . The features seemed exting enough to warrant an upgrade. So, here are the steps for upgrading APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2. The installation guide provides the steps in details. 1. Download APEX and unzip it in your server, preserving the directory names. Here, I have kept the zip file under the base directory /home/oracle . When you unzip it, a directory called apex will be created under the base directory. 2. Change your working directory to apex. For installing a full development environment, connect as sysdba and run apexins.sql passing the following four arguments: @apexins tablespace_apex tablespace_files tablespace_temp images tablespace_apex is the name of the tablespace for the Oracle Application Express application user tablespace_files is the name of the tablespace for the Oracle Application Express files user tablespace_temp is the name of the temporary tablespace images is the virtual directory for Oracle Application Express images. To support future Oracle Application Express upgrades, define the virtual image directory as /i/ I ran the script using the following parameters: It took around 20 minutes for the script to complete execution in my environment and it ended with the following messages. 1 2 3 4 5 [oracle@db 11 gr 2 ~]$ pwd /home/oracle [oracle@db 11 gr 2 ~]$ ls apex_ 4.1 . 1 _en.zip bin data [oracle@db 11 gr 2 ~]$ unzip apex_ 4.1 . 1 _en.zip 1 2 3 [oracle@db 11 gr 2 ~]$ ls apex apex_ 4.1 . 1 _en.zip bin data [oracle@db 11 gr 2 ~]$ 1 @apexins SYSAUX SYSAUX TEMP /i/ 1 2 3 4 5 6 7 8 9 10 11 12 ...Begin key object existence check 01:13:31 ...Completed key object existence check 01:13:31 ...Setting DBMS Registry 01:13:31 ...Setting DBMS Registry Complete 01:13:31 ...Exiting validate 01:13:31 timing for: Validate Installation Elapsed: 00:02:04.78 timing for: Development Installation Elapsed: 00:14:06.07 Disconnected from Oracle Database 11 g Enterprise Edition Release 11.2 . 0.1 . 0 - Production With the Partitioning, OLAP, Data Mining and Real Application Testing options [oracle@db 11 gr 2 apex]$

Atualização - Upgrade APEX 3.2.1 to 4.1

Embed Size (px)

Citation preview

Page 1: Atualização - Upgrade APEX 3.2.1 to 4.1

20/03/13 Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 | Oracle Apps Notes

oracleappsnotes.wordpress.com/2012/03/14/upgrade-apex/ 1/4

Oracle Apps NotesOracle Apps Notes A collection of my random notes, primarily on Oracle AppsA collection of my random notes, primarily on Oracle Apps

Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2

My previous post listed the steps I had followed while configuring APEX 3.2.1 in Oracle Database 11gR2. Later, I

checked the Oracle APEX website and found that the current version was 4.1.1 and it had quite a few interesting new

features. The features seemed exting enough to warrant an upgrade. So, here are the steps for upgrading APEX 3.2.1

to 4.1.1 on Oracle Database 11gR2. The installation guide provides the steps in details.

1. Download APEX and unzip it in your server, preserving the directory names. Here, I have kept the zip file under the

base directory /home/oracle.

When you unzip it, a directory called apex will be created under the base directory.

2. Change your working directory to apex. For installing a full development environment, connect as sysdba and

run apexins.sql passing the following four arguments:

@apexins tablespace_apex tablespace_files tablespace_temp images

tablespace_apex is the name of the tablespace for the Oracle Application Express application user

tablespace_files is the name of the tablespace for the Oracle Application Express files user

tablespace_temp is the name of the temporary tablespace

images is the virtual directory for Oracle Application Express images. To support future Oracle Application Express

upgrades, define the virtual image directory as /i/

I ran the script using the following parameters:

It took around 20 minutes for the script to complete execution in my environment and it ended with the following

messages.

12345

[oracle@db11gr2 ~]$ pwd/home/oracle[oracle@db11gr2 ~]$ lsapex_4.1.1_en.zip bin data[oracle@db11gr2 ~]$ unzip apex_4.1.1_en.zip

123

[oracle@db11gr2 ~]$ lsapex apex_4.1.1_en.zip bin data[oracle@db11gr2 ~]$

1 @apexins SYSAUX SYSAUX TEMP /i/

123456789101112

...Begin key object existence check 01:13:31

...Completed key object existence check 01:13:31

...Setting DBMS Registry 01:13:31

...Setting DBMS Registry Complete 01:13:31

...Exiting validate 01:13:31timing for: Validate InstallationElapsed: 00:02:04.78timing for: Development InstallationElapsed: 00:14:06.07Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - ProductionWith the Partitioning, OLAP, Data Mining and Real Application Testing options[oracle@db11gr2 apex]$

Page 2: Atualização - Upgrade APEX 3.2.1 to 4.1

20/03/13 Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 | Oracle Apps Notes

oracleappsnotes.wordpress.com/2012/03/14/upgrade-apex/ 2/4

3. Connect as sysdba and run the apxldimg.sql script to update the images directory. Include, as a parameter, the path

to the base directory where the APEX installation file was unzipped in step#1.

4. Enable network services for APEX. This is not a mandatory step but is required in case you want to access network

services from APEX. Please check the installation document for additional details. To allow access to network services,

grant connect privileges to any host for the APEX_040100 database user. This can be done by using the following

script. Please check the installation guide on how to allow more fine grained access.

12345678910111213141516171819202122

SQL> connect sys as sysdbaEnter password:Connected.SQL> @apxldimg.sql /home/oracle PL/SQL procedure successfully completed. old 1: create directory APEX_IMAGES as '&1/apex/images'new 1: create directory APEX_IMAGES as '/home/oracle/apex/images' Directory created.PL/SQL procedure successfully completed.PL/SQL procedure successfully completed.PL/SQL procedure successfully completed.Commit complete. timing for: Load ImagesElapsed: 00:01:21.55 Directory dropped. SQL>

12345678910111213141516171819202122232425262728293031323334353637

DECLARE ACL_PATH VARCHAR2(4000); ACL_ID RAW(16);BEGIN -- Look for the ACL currently assigned to '*' and give APEX_040100 -- the "connect" privilege if APEX_040100 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; -- Before checking the privilege, ensure that the ACL is valid -- (for example, does not contain stale references to dropped users). -- If it does, the following exception will be raised: -- -- ORA-44416: Invalid ACL: Unresolved principal 'APEX_040100' -- ORA-06512: at "XDB.DBMS_XDBZ", line ... -- SELECT SYS_OP_R2O(extractValue(P.RES, '/Resource/XMLRef')) INTO ACL_ID FROM XDB.XDB$ACL A, PATH_VIEW P WHERE extractValue(P.RES, '/Resource/XMLRef') = REF(A) AND EQUALS_PATH(P.RES, ACL_PATH) = 1; DBMS_XDBZ.ValidateACL(ACL_ID); IF DBMS_NETWORK_ACL_ADMIN.CHECK_PRIVILEGE(ACL_PATH, 'APEX_040100', 'connect') IS NULL THEN DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH, 'APEX_040100', 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_040100', TRUE, 'connect'); DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL('power_users.xml','*');END;

Page 3: Atualização - Upgrade APEX 3.2.1 to 4.1

20/03/13 Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 | Oracle Apps Notes

oracleappsnotes.wordpress.com/2012/03/14/upgrade-apex/ 3/4

This completes the upgrade leaving you with a new, shiny and feature-filled Oracle APEX 4.1.1 installation.

3839

/COMMIT;

Page 4: Atualização - Upgrade APEX 3.2.1 to 4.1

20/03/13 Upgrade APEX 3.2.1 to 4.1.1 on Oracle Database 11gR2 | Oracle Apps Notes

oracleappsnotes.wordpress.com/2012/03/14/upgrade-apex/ 4/4

Share this:

Like this:

One blogger likes this.

Like★★

← Configure APEX in Oracle Database 11gR2 List of JDR_UTILS APIs →

APEX, Database 11gR2

Comments are closed.Comments are closed.

About these ads

Email Facebook Twitter Google +1 More

↑ TopBlog at WordPress.com. Theme: zBench by zwwooooo.