Oracle AI Database 26ai Free and Bucket Configuration in Linux Server

Step 1: Install the Oracle Preinstallation RPM

  • wget https://yum.oracle.com/repo/OracleLinux/OL10/appstream/x86_64/getPackage/oracle-ai-database-preinstall-26ai-1.0-1.el10.x86_64.rpm
  • dnf install -y oracle-ai-database-preinstall*
  • wget https://download.oracle.com/otn-pub/otn_software/db-free/oracle-ai-database-free-26ai-23.26.3-1.el10.x86_64.rpm
  • sudo dnf clean all
  • sudo dnf install -y oracle-ai-database-free-26ai-23.26.3-1.el10.x86_64.rpm


To configure Oracle AI Database Free, 

  • sudo chown -R oracle:oinstall /u01
  • sudo chown -R oracle:oinstall /opt/oracle
  • sudo chmod -R 775 /u01
  • sudo chmod -R 775 /opt/oracle
  • /opt/oracle/product/26ai/dbhomeFree/root.sh
  • Modify the parameters in '/etc/sysconfig/oracle-free-26ai.conf' 
  • Run '/etc/init.d/oracle-free-26ai configure' as root.
# --- Oracle Database 26ai Environment Variables ---
export ORACLE_SID=FREE
export ORACLE_BASE=/u01/app/oracle
export ORACLE_HOME=/opt/oracle/product/26ai/dbhomeFree
export TNS_ADMIN=$ORACLE_HOME/network/admin
export PATH=$ORACLE_HOME/bin:$PATH 
# --- Optional but highly recommended additions ---
export LD_LIBRARY_PATH=$ORACLE_HOME/lib:/lib:/usr/lib
export CLASSPATH=$ORACLE_HOME/jlib:$ORACLE_HOME/rdbms/jlib
export NLS_LANG=AMERICAN_AMERICA.AL32UTF8
Create .bash_profile as oracle user 


Bucket Configuration


Step 1: Create the User & Group in OCI

  • Object Storage permissions are assigned to Groups rather than individual users.
  • Identity & Security -> Domains -> Default -> User Management -> Groups → Create Group -> bkp_grp -> create 
  • Users -> Create User -> Name: support@mygmail.com -> Groups (bky_grp) -> create
  • Access Key = 
  • Identity & Security -> Domains -> Default -> User Management -> User -> <tenancy_user> -> customer secret keys -> copy access key 
  • Secret Keys = Customer secret keys -> generate secret keys -> Copy 


Step 2: Configure the Storage Bucket & 200GB Limit

  • Storage -> Buckets -> Create Bucket -> Bucket Name: bkt_backup -> Standard storage tier -> Click Create. 
  • bkp_backup -> Create Folder -> Name: backup 
  • Use a Compartment Quota Policy for 200GB limit on bucket usage. 
  • Move or Create the Bucket in a Dedicated Compartment:
  • Identity & Security -> Compartments -> Create Compartment -> mycompartment
  • Move bucket to new compartment 
  • buckets -> backup_bucket -> 3 dotes (...) -> Move resource -> mycompartment -> move 
  • Create the Quota Policy:
  • Quota Policies -> Create Quota Policy -> create 
  • Quota policy
  • set object-storage quota storage-bytes to 214748364800 in compartment backup-compartment


Step 3: Apply Granular IAM Policies

  • Identity & Security → Policies → Create Policy - Create below policy 
  • # Allow the group to see the layout of the bucket structure and grant read/write capabilities strictly inside the isolated folder path
  • policyname: bucket_user_access_policy
  • Allow group bkp_grp to read buckets in compartment mycompartment
  • Allow group bkp_grp to manage objects in compartment mycompartment where all {target.bucket.name='bkt_backup', target.object.name='backup/*'}


Step 4: Install and Mount via Rclone on RHEL 10

# 1. Update system registries and install fuse3 compatibility layers
sudo dnf install -y fuse3

# 2. Download and install rclone 
curl https://rclone.org/install.sh | sudo bash

# 3. Initialize rclone interactive setup
rclone config

  • name: oci-backup
  • Storage Type: Choose Amazon S3 Compliant Storage (Object storage endpoints use S3 compatibility wrappers seamlessly)
  • provider: AnyOther
  • env_auth: false
  • access_key_id: Paste the Access Key 
  • secret_access_key: Paste the Secret Key 
  • region: <region_name>  
  • endpoint: https://<your-tenancy-namespace>.compat.objectstorage.<your-region>.oraclecloud.com

Step 5: Mount the Directory Target

# Ensure target mount point is established
sudo mkdir -p /backup

# Mount the directory explicitly with read/write caching features enabled
sudo rclone mount oci-backup:backup-bucket/backup /backup --allow-other  --vfs-cache-mode writes --daemon

Step 6: Automate Mount on System Boot

vi /etc/systemd/system/rclone-backup.service

[Unit]
Description=Rclone Mount for OCI Bucket Backup
After=network-online.target

[Service]
Type=simple
ExecStart=/usr/bin/rclone mount oci-backup:server-backup-bucket/rhel10-backup /backup --allow-other --vfs-cache-mode writes
ExecStop=/bin/fusermount3 -u /backup
Restart=on-failure
User=root

[Install]
WantedBy=multi-user.target


Step 7: Reload the system configurations

  • sudo systemctl daemon-reload
  • sudo systemctl enable --now rclone-backup.service


=======================================================================

Comments

Popular posts from this blog

Database Network : Configuration Parameters

Undo Segments : Drop Problematic Undo Segments