Showing posts with label 23ai. Show all posts
Showing posts with label 23ai. Show all posts

April 24, 2025

Installing Oracle 23ai on Linux 9

 

Installing Oracle 23ai on Linux 9: A Step-by-Step Guide for Modern DBAs

Pre-requisites

 

- 20+ GB free disk space

- At least 8 GB RAM

- x86_64 architecture

- Oracle Linux 9 (preferred with UEK)

OS Requirements:

 

Before diving in, let’s get our system ready.

 

Step 1: Install Required Packages

Oracle provides a handy pre-install RPM that handles dependencies and kernel tuning.

 

Command:

[root@rd opc]# dnf install -y oracle-database-preinstall-23ai

 

This will:

- Set kernel parameters

- Create required groups and users (if not done)

- Install packages like `binutils`, `glibc`, `ksh`, etc.

Step 2: Download and Install Oracle 23ai RPM

Download the Oracle 23ai Free RPM package from Oracle’s official site.

Official link for download:- https://www.oracle.com/database/free/get-started/

OR

Using wget utility directly download the rpm into the server

[root@rd u01]# wget https://download.oracle.com/otn-pub/otn_software/db-free/oracle-database-free-23ai-1.0-1.el9.x86_64.rpm

Install using:

[root@rd u01]# sudo dnf install -y oracle-database-free-23ai-1.0-1.el9.x86_64.rpm

 

 

This installs Oracle binaries in `/opt/oracle/product/23ai/dbhomeFree`.

Step 3: Configure the Database

Create and configure your Oracle 23ai database with:

 

[root@rd dbhomeFree]# sudo /etc/init.d/oracle-free-23ai configure

Specify a password to be used for database 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]. Note that the same password will be used for SYS, SYSTEM and PDBADMIN accounts:

Confirm the password:

Configuring Oracle Listener.

Listener configuration succeeded.

Configuring Oracle Database FREE.

Enter SYS user password:                                                                                                                                                                                     ************

Enter SYSTEM user password:

*************

Enter PDBADMIN User Password:

*************

Prepare for db operation

7% complete

Copying database files

29% complete

Creating and starting Oracle instance

30% complete

33% complete

36% complete

39% complete

43% complete

Completing Database Creation

47% complete

49% complete

50% complete

Creating Pluggable Databases

54% complete

71% complete

Executing Post Configuration Actions

93% complete

Running Custom Scripts

100% complete

Database creation complete. For details check the logfiles at:

 /opt/oracle/cfgtoollogs/dbca/FREE.

Database Information:

Global Database Name:FREE

System Identifier(SID):FREE

Look at the log file "/opt/oracle/cfgtoollogs/dbca/FREE/FREE.log" for further details.

 

Connect to Oracle Database using one of the connect strings:

     Pluggable database: rd/FREEPDB1

 

 

The script will:

- Set up the Oracle listener

- Initialize the database

- Start the database service

Step 4: Test the Installation

Switch to the `oracle` user and test the environment:

 

sudo su – oracle

Environment Variables

To make life easier, set the following in `.bash_profile` for the `oracle` user:

export ORACLE_HOME=/opt/oracle/product/23ai/dbhomeFree

export ORACLE_SID=FREE

export PATH=$ORACLE_HOME/bin:$PATH

 

Apply the changes:

source ~/.bash_profile

 

To connect root container:-

[oracle@rd ~]$ sqlplus sys@//localhost:1521/free as sysdba

 Enter password:

SQL*Plus: Release 23.0.0.0.0 - Production on Thu Apr 24 04:24:50 2025

Version 23.7.0.25.01

 

Copyright (c) 1982, 2025, Oracle.  All rights reserved.

 

Enter password:

 

Connected to:

Oracle Database 23ai Free Release 23.0.0.0.0 - Develop, Learn, and Run for Free

Version 23.7.0.25.01

 

SQL> show pdbs

 

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED

---------- ------------------------------ ---------- ----------

         2 PDB$SEED                       READ ONLY  NO

         3 FREEPDB1                       READ WRITE NO

SQL> show con_name

 

CON_NAME

------------------------------

CDB$ROOT

SQL>

 

To connect Pluggabe database

[oracle@rd ~]$ sqlplus sys@//localhost:1521/freepdb1 as sysdba

 Enter password:

SQL*Plus: Release 23.0.0.0.0 - Production on Thu Apr 24 04:26:47 2025

Version 23.7.0.25.01

 

Copyright (c) 1982, 2025, Oracle.  All rights reserved.

 

Enter password:

 

Connected to:

Oracle Database 23ai Free Release 23.0.0.0.0 - Develop, Learn, and Run for Free

Version 23.7.0.25.01

SQL> show con_name

 

CON_NAME

------------------------------

FREEPDB1

 

 

Optional: Enable Auto-Start on Boot

To enable Oracle to start automatically after reboot:

[root@rd u01]# sudo systemctl enable oracle-free-23ai

oracle-free-23ai.service is not a native service, redirecting to systemd-sysv-install.

Executing: /usr/lib/systemd/systemd-sysv-install enable oracle-free-23ai

 

Database service can be stopped and started using following command from root user

[root@rd opc]# /etc/init.d/oracle-free-23ai stop

[root@rd opc]# /etc/init.d/oracle-free-23ai start

Final Thoughts

"23ai" = Oracle 23c: Oracle renamed the release from 23c to 23ai to reflect its built-in artificial intelligence and machine learning capabilities.

 Free Edition: It's the lightweight version of the full Oracle Database, similar to what Oracle 21c XE was, but even easier to install and use (especially with the RPM installer).

 

Oracle Database 26ai Installation Using RPM on Oracle Linux 9 (OEL 9) – Step-by-Step Guide

  In this post I will describe the installation of Oracle Database 26ai 64-bit on Oracle Linux 9 (OL8) 64-bit. The installation requires a m...