OCP Blog
Super DBA
APEX 4.0 Installation Guide
by Vazha Mantua Friday, November 12, 2010 3:14 PM

Oracle Application Express (Oracle APEX) is a rapid web application development tool for the Oracle database. Using only a web browser and limited programming experience, you can develop and deploy professional applications that are both fast and secure. Oracle APEX is a fully supported, no cost option of the Oracle database

Let’s start!

1.Oracle Application Express Installation Requirements

1.1 Oracle Database Requirement
Oracle Application Express version 4.0 requires an Oracle database (Enterprise Edition, Standard Edition or Standard Edition One) that is release 10.2.0.3 or higher. Application Express 4.0 can also be used with Oracle Database 10g Express.

1.1.1 Checking the shared_pool_size of the Target Database

Note:Ignore this requirement if your configuration uses non-null values for the database initialization parameters SGA_TARGET (in Oracle Database 10g and 11g) or MEMORY_TARGET (in Oracle Database 11g).
Oracle Application Express requires the shared_pool_size of the target database to be at least 100 MB.
To check the shared_pool_size of the target database:
1. Start the database:
SQL> STARTUP
2. If necessary, enter the following command to determine whether the system uses an initialization parameter file (initsid.ora) or a server parameter file (spfiledbname.ora):
SQL> SHOW PARAMETER PFILE;
3. Determine the current values of the shared_pool_size parameter:
SQL> SHOW PARAMETER SHARED_POOL_SIZE
4. If the system is using a server parameter file, set the value of the SHARED_POOL_SIZE initialization parameter to at least 100 MB:
SQL> ALTER SYSTEM SET SHARED_POOL_SIZE='100M' SCOPE=spfile;
5. Shut down the database:
SQL> SHUTDOWN
6. Restart the database:
SQL> STARTUP

1.2 Browser Requirements

To view or develop Oracle Application Express applications, Web browsers must support Java Script and the HTML 4.0 and CSS 1.0 standards. The following browsers are required to develop applications in Oracle Application Express:
· Microsoft Internet Explorer 7.0 or later version
· Mozilla Firefox 3.5 or later version
· Google Chrome 4.0 or later version
· Apple Safari 4.0 or later version
Application Express applications can be developed that support earlier Web browser versions, including Microsoft Explorer 6.0.

1.3 Disk Space Requirement

Oracle Application Express disk space requirements are as follows:
· Free space for Oracle Application Express software files on the file system: 450 MB if using English only download (apex_4_0_en.zip) and 1 GB if using full download (apex_4_0.zip).
· Free space in Oracle Application Express tablespace: 185 MB
· Free space in SYSTEM tablespace: 100 MB
· Free space in Oracle Application Express tablespace for each additional language (other than English) installed: 75 MB

1.4 Oracle XML DB Requirement

Oracle XML DB must be installed in the Oracle database that you want to use. If you are using a preconfigured database created either during an installation or by Database Configuration Assistant (DBCA), Oracle XML DB is already installed and configured.
See Also: Oracle XML DB Developer's Guide for more information about manually adding Oracle XML DB to an existing database
Tip: The installer does a prerequisite check for Oracle XML DB and will exit if it is not installed.
Tip: The installation of Oracle XML DB creates the user ANONYMOUS. In order for Oracle Application Express workspace provisioning to work properly, the ANONYMOUS user must not be dropped from the database.

1.5 PL/SQL Web Toolkit

Oracle Application Express requires the PL/SQL Web Toolkit version 10.1.2.0.6 or later. For instructions on determining the current version of the PL/SQL Web Toolkit, and for instructions on installing version 10.1.2.0.6, please review the README.txt file contained in the directory apex/owa.

2. install Oracle Application Express

2.1 Recommended Pre-installation Tasks

Before installing Oracle Application Express, Oracle recommends that you complete the following steps:

1. Shut down with normal or immediate priority the Oracle Database instances where you plan to install Oracle Application Express. On Oracle Real Application Clusters (Oracle RAC) systems, shut down all instances on each node.

2. Back up the Oracle Database installation. Oracle recommends that you create a backup of the current Oracle Database installation before you install Oracle Application Express. You can use Oracle Database Recovery Manager, which is included the Oracle Database installation, to perform the backup.
3. Start the Oracle Database instance that contains the target database. After backing up the system, you must start the Oracle instance that contains the target Oracle database. Do not start other processes such as the listener or Oracle HTTP Server. However, if you are performing a remote installation, make sure the database listener for the remote database has started.
2.2 Download and Install Oracle Application Express
To install Oracle Application Express:
1. For installations where the development will be in English only, download the file apex_4.0_en.zip from the Oracle Application Express download page. Where the development will include languages other than English, download apex_4.0.zip from the Oracle Application Express download page. See:
http://www.oracle.com/technology/products/database/application_express/download.html
Note that the actual file name may differ if a more recent release has shipped since this document was published.
2. Unzip downloaded zip file:
· UNIX and Linux: Unzip apex_4.0.zip
· Windows: Double click the file apex_4.0.zip in Windows Explorer
3. Change your working directory to apex.
4. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
And run the command:
     SQL>@apexins SYSAUX SYSAUX TEMP /i/
When Oracle Application Express installs it creates three new database accounts:
· APEX_040000 - The account that owns the Oracle Application Express schema and metadata.
· FLOWS_FILES - The account that owns the Oracle Application Express uploaded files.
· APEX_PUBLIC_USER - The minimally privileged account used for Oracle Application Express configuration with Oracle HTTP Server and mod_plsql or Oracle Application Express Listener.
2.3 Change the Password for the ADMIN Account
To change the password for the ADMIN account:
1. Change your working directory to the apex directory where you unzipped the installation software.
2. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
3. Run apxchpwd.sql. For example:
SQL>@apxchpwd
When prompted enter a password for the ADMIN account.
2.4 Restart Processes
After you install Oracle Application Express, you must restart the processes that you stopped before you began the installation, such as listener and other processes.
2.5 Configure the Embedded PL/SQL Gateway
2.5 .1 Running the apex_epg_config.sql Configuration Script
The embedded PL/SQL gateway installs with the Oracle Database 11g. However, you must configure it before you can use it with Oracle Application Express. To accomplish this, you run a configuration file and unlock the ANONYMOUS account.
To run the apex_epg_config.sql configuration script:
1. Change your working directory to the apex directory where you unzipped the Oracle Application Express software.
2. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
3. Run apex_epg_config.sql passing the file system path to the base directory where the Oracle Application Express software was unzipped as shown in the following example:
On Windows:
@apex_epg_config SYSTEM_DRIVE:\TEMP
On UNIX and Linux:
@apex_epg_config /tmp
4. Enter the following statement to unlock the ANONYMOUS account:
ALTER USER ANONYMOUS ACCOUNT UNLOCK;
2.5 .2 Verifying the Oracle XML DB HTTP Server Port
The embedded PL/SQL gateway runs in the Oracle XML DB HTTP server in the Oracle database. You can determine if the Oracle XML DB HTTP server is enabled by verifying the associated port number.
To verify the port number where the Oracle XML DB HTTP Server is running:
1. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
2. Enter the following statement to verify the port number:
SELECT DBMS_XDB.GETHTTPPORT FROM DUAL;
If the port number returns 0, the Oracle XML DB HTTP Server is disabled.
3. To enable it, follow the instructions in 2.5 .3 Enabling Oracle XML DB HTTP Server.
2.5 .3 Enabling Oracle XML DB HTTP Server
The embedded PL/SQL gateway runs in the Oracle XML DB HTTP server in the Oracle database.
To enable Oracle XML DB HTTP server:
1. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
2. Enter a statement similar to the following:
EXEC DBMS_XDB.SETHTTPPORT(port);
For example:
EXEC DBMS_XDB.SETHTTPPORT(8080);
2.6 Enable Network Services in Oracle Database 11g
By default, the ability to interact with network services is disabled in Oracle Database 11g release 1 or 2. Therefore, if you are running Oracle Application Express with Oracle Database 11g release 1 or 2, you must use the new DBMS_NETWORK_ACL_ADMIN package to grant connect privileges to any host for the APEX_040000 database user.
2. 6.1 Granting Connect Privileges
The following example demonstrates how to grant connect privileges to any host for the APEX_040000 database user. This example assumes you connected to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role.
DECLARE
  ACL_PATH  VARCHAR2(4000);
  ACL_ID    RAW(16);
BEGIN
  -- Look for the ACL currently assigned to '*' and give APEX_040000
  -- the "connect" privilege if APEX_040000 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_040000'
  -- 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_040000', 
     'connect') IS NULL THEN 
      DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH, 
     'APEX_040000', 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_040000', TRUE, 'connect');
  DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL('power_users.xml','*');
END;
/
COMMIT;
The following example demonstrates how to provide less privileged access to local network resources. This example would enable indexing the Oracle Application Express Online Help and could possibly enable email and PDF printing if those servers were also on the local host.
DECLARE
  ACL_PATH  VARCHAR2(4000);
  ACL_ID    RAW(16);
BEGIN
  -- Look for the ACL currently assigned to 'localhost' and give APEX_040000
  -- the "connect" privilege if APEX_040000 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;
 
  -- 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_040000'
  -- 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_040000', 
     'connect') IS NULL THEN 
      DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(ACL_PATH, 
     'APEX_040000', 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 power users to connect to everywhere',
    'APEX_040000', TRUE, 'connect');
  DBMS_NETWORK_ACL_ADMIN.ASSIGN_ACL('local-access-users.xml','localhost');
END;
/
COMMIT;
2.7 About Managing JOB_QUEUE_PROCESSES

JOB_QUEUE_PROCESSES determine the maximum number of concurrently running jobs. In Oracle Application Express release 4.0, transactional support and SQL scripts require jobs.
If JOB_QUEUE_PROCESSES is not enabled and working properly, you cannot successfully execute a script.
2.7.1 Viewing JOB_QUEUE_PROCESSES from SQL*Plus

SELECT VALUE FROM v$parameter WHERE NAME = 'job_queue_processes'
(We had 128)
2.7.2 Changing the Number of JOB_QUEUE_PROCESSES
You can change the number of JOB_QUEUE_PROCESSES by running a SQL statement in SQL*Plus:
To update the number of JOB_QUEUE_PROCESSES:
1. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
2. In SQL*Plus run the following SQL statement:
ALTER SYSTEM SET JOB_QUEUE_PROCESSES = <number>
For example, running the statement ALTER SYSTEM SET JOB_QUEUE_PROCESSES = 20 sets JOB_QUEUE_PROCESSES to 20.
2.8 Configuring the SHARED_SERVERS Parameter
The embedded PL/SQL gateway uses the shared server architecture of the Oracle Database. To achieve acceptable performance when using the embedded PL/SQL gateway, ensure the SHARED_SERVERS database initialization parameter is set to a reasonable value (that is, not 0 or 1). For a small group of concurrent users, Oracle recommends a value of 5 for SHARED_SERVERS.
Consider the following example:
1. Start SQL*Plus and connect to the database where Oracle Application Express is installed as SYS specifying the SYSDBA role. For example:
On Windows:
SYSTEM_DRIVE:\ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
On UNIX and Linux:
$ sqlplus /nolog
SQL> CONNECT SYS as SYSDBA
Enter password: SYS_password
2. Run the following statement:
ALTER SYSTEM SET SHARED_SERVERS = 5 SCOPE=BOTH;
 
Note: If database is not started by spfile shutdown and start it by spfile.
Go to the link to check if it works
 
http://hostname:port/apex/apex_admin

Tags: ,

Comments (38) -

11/16/2010 9:30:48 AM #

Arman Obosyan

test reCAPTCHA

Arman Obosyan Georgia

5/23/2011 7:23:03 PM #

Sea Breeze Travels

It’s really a nice and helpful piece of information. I’m glad that you shared this helpful info with us. Please keep us informed like this. Thanks for sharing.

Sea Breeze Travels United Kingdom

9/12/2011 8:46:13 PM #

floral fabric

When you could e-mail me with a few recommendations on simply how you made your weblog look this wonderful, I'd be grateful.

floral fabric United States

9/19/2011 11:53:43 AM #

best credit restoration company

Excellent post. I was checking constantly this blog and I'm impressed! Extremely helpful information specifically the last part  I care for such information much. I was looking for this certain information for a very long time. Thank you and best of luck.

best credit restoration company United States

9/19/2011 1:17:13 PM #

norton utilities

I am s grateful to find such wonderful post, keep it up.

norton utilities United States

9/20/2011 11:42:38 AM #

norton utilities

This is nice blog.I recently came across your blog and have been reading along.

norton utilities United States

9/21/2011 11:11:30 AM #

kettlebell training workouts

Hey friend Appreciate sharing this short article with us. Usually i can\'t inquire into Blogs and forums. But i just like it. If only extra articles and also written content on-line will be around handy and also beneficial as compared to this place. Good article, appreciate it Best regards.

kettlebell training workouts United States

9/21/2011 3:15:35 PM #

blackjack casino

Needed so as to thanks a great deal in this exceptional examine!! We without doubt adored each small amount associated with the item. I've someone added an individual's internet site take into consideration the hottest things an individual posting.

blackjack casino United States

9/30/2011 4:02:21 PM #

Development services

hi there, Thanks allot for sharing such an information. I needed this info very badly. Thanks once again.

Development services United States

10/3/2011 12:10:46 AM #

black fabric

Hey there!! This is a real awesome webpage.

black fabric United States

12/5/2011 3:03:49 AM #

Dsi solutions reviews

This site will provide for such a great and interesting topic that more helpful to all blogger espcially for me. Thanks!

Dsi solutions reviews United States

12/7/2011 8:03:03 PM #

Blogging Ideas

Thanks to your post I do not seem like an idiot. I had an argument with my friend and this proves I was right. Thanks!

Blogging Ideas United States

12/10/2011 6:51:56 AM #

credit report repair

Amazing write up. It's very informative. Thanks for posting this.

credit report repair United States

1/7/2012 4:56:01 PM #

Villas for Rent in Italy

This site will provide for such a great and interesting topic that more helpful to all blogger espcially for me. Thanks!

Villas for Rent in Italy United States

1/12/2012 12:19:55 PM #

Boutique PR Agency

hi there, Thanks allot for sharing such an information. I needed this info very badly. Thanks once again.

Boutique PR Agency United States

1/14/2012 2:23:10 PM #

Villas for Rent in Italy

Thank you so very much for sharing such a nice post thanks for your comments to.

Villas for Rent in Italy United States

1/23/2012 4:42:59 AM #

carpet cleaning kenmore

This is just what I was looking for. I was not expecting that I’d get so much out of reading your write up! You’ve just earned yourself a returning visitor.

carpet cleaning kenmore United States

2/12/2012 6:55:40 AM #

Flooring Ideas

If we are using Nested Master Pages ,with contentplaceholders in <head> section, then Page.Header.Controls exposes only the controls in the <head> tag that must be present in the outermost, most general master page. In either of these cases, If we try to skip head altogether and define the head tag in the asp:content of the content pages, ThenPage.Header simply becomes null when accessed.

Flooring Ideas United States

3/21/2012 10:43:49 PM #

software outsourcing



think this is extremely cool! I recognize your ingenuity and I am grateful for your illuminating post.

software outsourcing United States

3/21/2012 10:44:49 PM #

cheapest mobile contract


I must admit that this can be 1 excellent insight. It surely gives a company the opportunity to acquire in on the ground floor and really take part in creating something particular and tailored to their needs
UK based best various mobile shopping website
search mobile phone deals from UK’s leading retailers. Great mobile shopping Offers

cheapest mobile contract United States

3/22/2012 2:09:30 PM #

usb hard drive recovery

Nice information, many thanks to the author. It is incomprehensible to me now, but in general, the usefulness and significance is overwhelming. Thanks again and good luck

usb hard drive recovery United States

4/5/2012 1:25:26 PM #

classified websites in india

This article was extremely interesting, especially since I was searching for thoughts on this subject last week………………….

classified websites in india United States

4/5/2012 2:08:40 PM #

first time home buyer information

Your blog is so informative … keep up the good work!!!!!!!!!

first time home buyer information United States

4/5/2012 2:31:42 PM #

Windows news

This is a great site, very handy, just what i was looking for, keep up the good work, many thanks!!!!!!

Windows news United States

4/5/2012 3:21:01 PM #

Online video poker rules

it's a very nice blog. I will visit later……………….

Online video poker rules United States

4/5/2012 3:22:06 PM #

online keno rules

This is a great site, very handy, just what i was looking for, keep up the good work, many thanks!!!!!!

online keno rules United States

4/5/2012 3:22:56 PM #

online keno rules

Wow! Thank you! I constantly needed to write on my website something like that. Can I take a portion of your post to my blog………..

online keno rules United States

4/10/2012 10:30:26 PM #

Challenge Coins

I am now a days learning this course online from a well-known organization and I am very happy during my course as, it is very interesting for me.

Challenge Coins United States

4/25/2012 9:46:54 AM #

Computer Network



It’s really a nice and useful piece of information. I’m glad that you shared this helpful info with us. Please keep us up to date like this. Thanks for sharing.

Computer Network United States

5/2/2012 9:02:00 PM #

Ibiza Holiday

Hi there, I was searching the same content in google and I am here to your site by chance and I found your site too good with content as well as with the design, keep coming with such ideas.

Ibiza Holiday United States

5/2/2012 9:04:26 PM #

Cheap Custom Lapel Pins

Hi there, Its really very hard to stay at home having no job. The information's given above are very helpful in getting the job. keep it up man

Cheap Custom Lapel Pins United States

5/5/2012 11:34:30 AM #

Challenge Coins

Your page is so fantastic! You sure do know how to keep your audience entertained. Im so glad that I took the time to look at this blog, because let me tell you. Not a lot of people know how to balance knowledge of a subject and content. The videos are perfect!

Challenge Coins United Kingdom

6/3/2012 2:23:33 AM #

Directory Submission Service

3. Determine the current values of the shared_pool_size parameter:

Directory Submission Service United Kingdom

6/6/2012 6:58:39 AM #

Iraqi Dinar

Hi there, I was searching the same content in google and I am here to your site by chance and I found your site too good with content as well as with the design, keep coming with such ideas.

Iraqi Dinar United Kingdom

6/6/2012 12:21:21 PM #

moving company ny

Every day, you go new places. The moving companies of the Atlas network answer with the choices you need to take you there. That's why every day is moving day for us. See why we're the trusted partner when people need home moving.

moving company ny United States

6/20/2012 2:30:04 PM #

Diminished Value

After you install Oracle Application Express, you must restart the processes that you stopped before you began the installation, such as listener and other processes.

Diminished Value United Kingdom

6/21/2012 11:34:41 PM #

Challenge Coins

Your post rocks! Congrats. Seriously considered experienced learning this, an item wasn't just like another, what the heck is considered uncomfortable to go about. You have to do good work buddy.

Challenge Coins United States

7/7/2012 10:57:01 AM #

Ibiza Holiday

This is amazing blog page.I lately came across your website and have been learning along

Ibiza Holiday Thailand

Add comment

  Country flag

biuquote
  • Comment
  • Preview
Loading

Filter by APML

Calendar

<<  November 2017  >>
MoTuWeThFrSaSu
303112345
6789101112
13141516171819
20212223242526
27282930123
45678910

View posts in large calendar

TextBox