Oracle Database 12c: Getting Started with DB Express

Oracle DB Express is the new replacement for Oracle DB Console in the Oracle 12c database. Here are some first steps to get started.

Oracle DB Express makes use of what is called the “XDB Protocol Server”, which among others supports the Oracle APEX standalone PL/SQL Gateway. For people who are unknown still how to set this up, hereby some ideas how to get started with this cool new administrative alternative.

First enable the HTTP functionality of the XDB Protocol Server. You are allowed to do this via the SYS account or have the XDBADMIN role.

Via the missing HTTP/RAW entry in the listener status overview or the return value “0” while using DBMS_XDB_CONFIG, you can check that the listener is not listening for HTTP calls. Be also aware that DBMS_XDB_CONFIG is now, from Oracle 12c and onwards, the package to use to configure XDB, instead of the deprecated functions and procedures in DBMS_XDB.

Be aware that assigning port numbers, like port 80, under 1024 need privileged OS user rights like root or administrator privileges. Most of the time, when installing on Windows, the Oracle software owner has these rights, but when on Linux and others, extra steps have to be taken to get this working. See the Oracle XMLDB Developer Guide documentation on how to achieve this.

I normally register this functionality with the listener immediately via a “alter system register” and enable 5 shared servers for it, so browser response is a bit more snappy. You need SYS or DBA role privileges to do the following:

SQL> alter system register;
System altered.
SQL> alter system set shared_servers=5 scope=both;
System altered.

If you check via DBMS_XDB_CONFIG or the listener status now, you will see your changes and the listener actively listening on port 8080 for HTTP calls.

In Oracle 12c, authentication is now supported for “basic” and “digest” authentication besides the already supported TCP and TCPS.

Digest Access Authentication Access to the Repository

Users can now access Oracle XML DB Repository using digest access authentication (also known as digest authentication), in addition to basic authentication. This provides encryption of user credentials (name, password, etc.) without the overhead of complete data encryption.

Note that user credentials are case-sensitive. In particular, a user name to be authenticated must exactly match the name as it was created (which by default is all uppercase).

You can now connect to DB Express via (default) http://localhost:8080/em or, instead of “localhost”, the TCP/IP number of your database server or (even better), while using the Fully Qualified Domain Name for your database server. In my case that could have been: http://orcl12.homework.local:8080/em

Issues…?

Most of the problems to get this started are caused by incorrect server name resolution, that is that the listener can not find or is bound to the incorrect hostname of your database server. The easiest way to check this is to stop the listener via “lsnrctl stop”, remove (temporarily) or rename the listener.ora file in (most of the time) $ORACLE_HOME/network/admin, start the listener without a listener.ora file in place via “lsnrctl start” and check after a while how the “listener status” recognizes your Fully Qualified Domain Name (FQDN). If the hostname reference is different than expected, alter the content of you host in the listener.ora file or create an extra entry in your hosts file (/etc/hosts) in the following manner: {TCP/IP Number} {Fully Qualified Domain Name} {Hostname}. So for example “10.1.0.11 myserver.domain.local myserver”. In most cases, that should do the trick…

About Author

Marco Gralike, working for AMIS Services BV as a Principal Oracle Database Consultant in the Netherlands, has experience as a DBA since 1994 (Oracle 6). Marco is also eager and skillful in other fields, like Operating System Administration and Application Servers, mainly to find working, performing solutions. Marco has been specializing in Oracle XMLDB, since 2003, focusing on his old love, database administration and performance.He is an Oracle XMLDB enthusiast ever since. He is also a dedicated contributor of the Oracle User Group community, helping people with their steep XMLDB learning curve. To this purpose, Marco also devoted his personal blog site to XMLDB and other Oracle issues. Marco is a member of the OakTable network and an Oracle ACE Director (specialization Oracle XMLDB).

1 Comment

DB Express 12C was initially accessible on port 5500 while the newly configured & implemented APEX defaulted on port 8080. This lasted until a windows update, reboot,& shutdown. Now, both DB Express & Apex is using port 8080. Is there a way to reassign port 5500 to DB Express 12c without affecting Apex?

Marco Gralike

Marco Gralike, working for AMIS Services BV as a Principal Oracle Database Consultant in the Netherlands, has experience as a DBA since 1994 (Oracle 6). Marco is also eager and skillful in other fields, like Operating System Administration and Application Servers, mainly to find working, performing solutions. Marco has been specializing in Oracle XMLDB, since 2003, focusing on his old love, database administration and performance.

He is an Oracle XMLDB enthusiast ever since. He is also a dedicated contributor of the Oracle User Group community, helping people with their steep XMLDB learning curve. To this purpose, Marco also devoted his personal blog site to XMLDB and other Oracle issues. Marco is a member of the OakTable network and an Oracle ACE Director (specialization Oracle XMLDB).

Follow us on Twitter

meta

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 323 other subscribers

Email Address

About

AMIS is internationally recognized for its deep technological insight in Oracle technology. This knowledge is reflected in the presentations we deliver at international conferences such as Oracle OpenWorld, Hotsos and many user conferences around the world. Our AMIS Technology Blog, the most referred Oracle technology knowledge base outside the oracle.com domain. However you arrived here, we appreciate your interest in AMIS. Link to our Google+ Profile AMIS