How to run standalone Oracle APEX Listener 2.0 with Oracle 11g XE and APEX 4.1.1
This is short guide on how to run standalone Oracle APEX Listener 2.0 beta with Oracle 11g XE. I’m using Oracle Enterprise Linux 5.7 for running Oracle APEX Listener and Oracle Database 11g XE with APEX 4.1.1. Although running APEX Listener standalone is not supported I’m using it to run several internal applications for company needs.
When using APEX Listener with Oracle XE, APEX won’t work properly and white screen appears when APEX is open. This is because the APEX images are stored in the XML DB repository, but APEX Listener have to be run with parameter –apex-images pointing to directory containing the images at the filesystem. To solve this I downloaded the latest patch of APEX and copied the images from the patch.
If you have another database running on the same machine, keep in mind this.
Install Oracle 11g XE and update Oracle APEX to latest version:
2. Install Oracle 11g XE:
rpm -ivh oracle-xe-11.2.0-1.0.x86_64.rpm
3. Configure Express Edition:
4. Update APEX to 4.1
Download APEX 4.1
unzip -q apex_4.1.zip
sqlplus / as sysdba
@apexins SYSAUX SYSAUX TEMP /i/
5. Update APEX to version 4.1.1
Download patch set 13331096 from MOS
Disable Oracle XML DB HTTP server:
SQL> EXEC DBMS_XDB.SETHTTPPORT(0);
PL/SQL procedure successfully completed.
SQL> SELECT DBMS_XDB.GETHTTPPORT FROM DUAL;
Run apxpatch.sql to patch the system:
Update the Images Directory When Running the Embedded PL/SQL Gateway:
Once the update finished do not enable Oracle XML DB HTTP server, because we’ll be using Oracle APEX Listener, which will setup next.
Install APEX Listener 2.0.0
Unpack to /opt/jre1.6.0_34
3. Unlock and set password for apex_public_user at the Oracle XE database:
alter user APEX_PUBLIC_USER account unlock;
alter user APEX_PUBLIC_USER identified by secret;
4. Patch Oracle APEX to support RESTful Services:
sqlplus / as sysdba @catpatch.sql
Set passwords for both users APEX_LISTENER and APEX_REST_PUBLIC_USER.
5. Install Oracle APEX Listener:
Now this is tricky, for XE edition the images are kept in the XML DB repository, so images have to be copied from the patch to the listener home:
cp /tmp/patch/images .
6. Configure Oracle APEX Listener:
Set APEX listener config dir:
java -jar apex.war configdir $PWD/config
Configure the listener:
java -jar apex.war
Once configuration is complete, listener is started. It has to be stopped and run with appropriate parameters, use Ctrl-C to stop it.
7. Finally start the listener:
java -jar apex.war standalone –apex-images /oracle/apxlsnr/images
In case you want to run it in background here’s how to do it:
nohup java -jar apex.war standalone –apex-images /oracle/apxlsnr/images > apxlsnr.log &
Periodically I was seeing exceptions like these:
Caused by: oracle.ucp.UniversalConnectionPoolException: Universal Connection Pool already exists in the Universal Connection Pool Manager. Universal Connection Pool cannot be added to the Universal Connection Pool Manager
I found that if APEX Listener is not configured with RESTful Services then these messages appeared in the log and could be safety ignored.
- Not able to update Web service process in APEX 4.1
- Oracle Exadata Database Recommended Patch (BP9) came out
- Automatically backup Oracle APEX applications to Subversion
- How I run Oracle VM 2.2 guests with custom network configuration
- Oracle 11g XE listener does not start when there is another database running