5.1 Installing Oracle Database XE Using RPM Packages

Perform the following steps to install and configure Oracle Database XE using RPM packages.

Before attempting to install Oracle Database XE 18c, uninstall any existing Oracle Database XE or database with the SID XE from the target system.

An Oracle Database XE installation will consume around 9 gigabytes of disk space under /opt. If this disk partition does not have the required disk space available, you must add space or mount an alternative partition as /opt/oracle. This disk partition is the defined Oracle Base where the software and database will reside.

Note:

The Oracle Database XE installation does not support usage of symbolic links (symlink) for that disk.

Installing Oracle Database XE RPM

  1. Execute as user root using sudo.

    $ sudo -s
  2. For Oracle Linux, the Database Preinstallation RPM is pulled automatically, proceed to the next step. For Red Hat compatible Linux distributions, download and install the Database Preinstallation RPM using the following:

    1. For Red Hat Enterprise Linux 6, run these commands:

      # curl -o oracle-database-preinstall-18c-1.0-1.el6.x86_64.rpm https://yum.oracle.com/repo/OracleLinux/OL6/latest/x86_64/getPackage/oracle-database-preinstall-18c-1.0-1.el6.x86_64.rpm
      # yum -y localinstall oracle-database-preinstall-18c-1.0-1.el6.x86_64.rpm

      For Red Hat Enterprise Linux 7, run these commands:

      # curl -o oracle-database-preinstall-18c-1.0-1.el7.x86_64.rpm https://yum.oracle.com/repo/OracleLinux/OL7/latest/x86_64/getPackage/oracle-database-preinstall-18c-1.0-1.el7.x86_64.rpm
      # yum -y localinstall oracle-database-preinstall-18c-1.0-1.el7.x86_64.rpm

      Note:

      Use the -y option if you want yum to skip the package confirmation prompt.
  3. Access the software download page for Oracle Database RPM-based installation from Oracle Technology Network :

    https://www.oracle.com/technetwork/database/database-technologies/express-edition/downloads/index.html

  4. Download the oracle-database-xe-18c-1.0-1.x86_64.rpm file required for performing an RPM-based installation to a directory of your choice.

  5. Install the database software using the yum localinstall command.

    # yum -y localinstall oracle-database-xe-18c-1.0-1.x86_64.rpm

The Database Preinstallation RPM automatically creates Oracle installation owner and groups and sets up other kernel configuration settings as required for Oracle installations. If you plan to use job-role separation, then create the extended set of database users and groups depending on your requirements. Check the RPM log file to review the system configuration changes.

For example, review this file for latest changes: /var/log/oracle-database-preinstall-18c/results/orakernel.log .

The installation of Oracle Database software is now complete.

After successful installation, you can delete the downloaded RPM files, for example:

# rm oracle-database-preinstall-18c-1.0-1.el6.x86_64.rpm
# rm oracle-database-preinstall-18c-1.0-1.el7.x86_64.rpm
# rm oracle-database-xe-18c-1.0-1.x86_64.rpm

Creating and Configuring an Oracle Database

The configuration script creates a container database (XE) with one pluggable database (XEPDB1) and configures the listener at the default port (1521) and Enterprise Manager Express on port 5500.

You can modify the configuration parameters by editing the /etc/sysconfig/oracle—xe–18c.conf file.

The parameters set in this file are explained in more details in the silent mode installation procedure: Performing a Silent Installation.

To create the Oracle XE database with the default settings, perform the following steps:

  1. Execute as user root using sudo.

    $ sudo -s
  2. Run the service configuration script:

    # /etc/init.d/oracle-xe-18c configure

    At the prompt, specify a password for the SYS, SYSTEM, and PDBADMIN administrative user accounts. Oracle recommends that the password entered should be at least 8 characters in length, contain at least 1 uppercase character, 1 lower case character and 1 digit [0-9].

    See Also:

    The same password will be used for these accounts. The password should conform to the Oracle recommended standards. See Oracle Database Security Guide for more information about guidelines for securing passwords

    After the configuration completes, the database and listener are started.

Configuration, Database Files and Logs Location

Table 5-1 Configuration, Database Files and Logs Location

File Name and Location Purpose

/opt/oracle

Oracle Base. This is the root of the Oracle Database XE directory tree.

/opt/oracle/product/18c/dbhomeXE

Oracle Home. This home is where the Oracle Database XE is installed. It contains the directories of the Oracle Database XE executables and network files.

/opt/oracle/oradata/XE

Database files.

/opt/oracle/diag subdirectories

Diagnostic logs. The database alert log is /opt/oracle/diag/rdbms/xe/XE/trace/alert_XE.log

/opt/oracle/cfgtoollogs/dbca/XE

Database creation logs. The XE.log file contains the results of the database creation script execution.

/etc/sysconfig/oracle-xe-18c.conf

Configuration default parameters.

/etc/init.d/oracle-xe—18c

Configuration and services script.