Oracle Database 21c XE on OEL 7 User Guide
Overview
This guide covers deploying and configuring Oracle Database 21c Express Edition (XE) on OEL 7 using cloudimg's preconfigured AMI from the AWS Marketplace.
What's included in this AMI:
- Oracle Database 21c XE (version 21.3) preconfigured with a sample database instance
- Oracle XE database service configured to start on boot
- sqlplus command line tool for database administration
- AWS CLI v2
- Systems Manager Agent (SSM) for remote management
- CloudWatch Agent for monitoring
- Latest security patches applied at build time
- 24/7 cloudimg support with guaranteed 24 hour response SLA
Prerequisites
Before launching, ensure you have:
- An active AWS account
- An active subscription to the Oracle Database 21c XE on OEL 7 listing on AWS Marketplace
- An EC2 key pair in your target region
Recommended Instance Type: t3.medium (2 vCPU, 4 GB RAM)
Minimum Requirements: 1 vCPU, 1 GB RAM, 20 GB disk space
Security Group Configuration
| Port | Protocol | Source | Purpose |
|---|---|---|---|
| 22 | TCP | Your IP | SSH access |
| 1521 | TCP | Your IP | Oracle Database Listener |
Step 1: Launch the Instance
- Search for "Oracle Database 21c XE OEL cloudimg" on AWS Marketplace
- Click Continue to Subscribe, accept terms, then Continue to Configuration
- Select your Region and click Continue to Launch
- Choose Launch through EC2, select instance type and storage
- Configure security group, select key pair, and launch
Step 2: Connect via SSH
Once your instance passes 2/2 status checks:
ssh -i your-key.pem ec2-user@<PUBLIC_IP>
Switch to root if needed:
sudo su -
Note: Wait for 2/2 status checks before connecting.
Using Oracle Database XE
The Oracle XE database service is preconfigured to start on boot. Manage the database as follows.
Check the database service status:
sudo su -
systemctl status oracle-xe-21c
Stop and start the database service:
systemctl stop oracle-xe-21c
systemctl start oracle-xe-21c
Connect to the database via sqlplus:
sudo su - oracle
sqlplus / as sysdba
Credentials: The randomly generated SYSTEM user password is located in /stage/scripts/oracle-database-xe-config.log.
External connections (SQL Developer, etc.): Use the instance public IP, port 1521, and service name XE.
On Startup
An OS update script runs on first boot. To disable:
sudo rm -f /stage/scripts/initial_boot_update.sh
sudo crontab -e # Remove the @reboot line
Filesystem Configuration
| Mount Point | Description |
|---|---|
| / | Root filesystem |
| /boot | Operating System kernel files |
| /opt/oracle | Oracle software installation directory |
Server Components
| Component | Version | Install Path |
|---|---|---|
| Oracle Database 21c XE | 21.3 | /opt/oracle |
Scripts and Log Files
| Script/Log | Path | Description |
|---|---|---|
| initial_boot_update.sh | /stage/scripts | Updates the OS with the latest packages |
| initial_boot_update.log | /stage/scripts | Output log for the boot update script |
| oracle-database-xe-config.log | /stage/scripts | Oracle Database user credentials |
Troubleshooting
Cannot connect via SSH
- Wait for 2/2 status checks to pass
- Verify security group allows port 22 from your IP
- Check you are using the correct key pair as
ec2-user
Database service not running
- Check status:
systemctl status oracle-xe-21c - Start service:
systemctl start oracle-xe-21c - View logs:
journalctl -u oracle-xe-21c -f
Cannot connect to database remotely
- Ensure security group allows port 1521 from your IP
- Confirm the Oracle Listener is running by checking the service status
- Verify the service name is
XEin your connection settings
Support
- Email: support@cloudimg.co.uk
- Response Time: 24/7 with guaranteed 24 hour response SLA
- Website: https://www.cloudimg.co.uk