Closed Fleury93 closed 7 months ago
Hey @Fleury93,
Thanks a lot for using these images!
While I cannot comment on how successful other users have been with using tmpfs for the /opt/oracle/oradata
location (I'd also love to hear from users if they use it and how much benefit they see from it), I can confidently say that using tmpfs
is possible and I believe the error you are receiving above is because of something else. Somehow the controlfile can no longer be found. The alert log should have more information as to why.
When I use tmpfs with Podman, the database comes up just fine:
[gvenzl@localhost ~]$ podman run --name test -p 1521:1521 --mount=type=tmpfs,tmpfs-size=4g,destination=/opt/oracle/oradata -e ORACLE_PASSWORD=LetsTest1 gvenzl/oracle-free:slim
CONTAINER: starting up...
CONTAINER: first database startup, initializing...
CONTAINER: uncompressing database data files, please wait...
CONTAINER: done uncompressing database data files, duration: 6 seconds.
CONTAINER: starting up Oracle Database...
LSNRCTL for Linux: Version 23.0.0.0.0 - Production on 28-JAN-2024 02:30:28
Copyright (c) 1991, 2023, Oracle. All rights reserved.
Starting /opt/oracle/product/23c/dbhomeFree/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 23.0.0.0.0 - Production
System parameter file is /opt/oracle/product/23c/dbhomeFree/network/admin/listener.ora
Log messages written to /opt/oracle/diag/tnslsnr/810a2268e147/listener/alert/log.xml
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC_FOR_FREE)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=0.0.0.0)(PORT=1521)))
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC_FOR_FREE)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 23.0.0.0.0 - Production
Start Date 28-JAN-2024 02:30:28
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Default Service FREE
Listener Parameter File /opt/oracle/product/23c/dbhomeFree/network/admin/listener.ora
Listener Log File /opt/oracle/diag/tnslsnr/810a2268e147/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC_FOR_FREE)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=0.0.0.0)(PORT=1521)))
The listener supports no services
The command completed successfully
ORACLE instance started.
Total System Global Area 1603679416 bytes
Fixed Size 5313720 bytes
Variable Size 738197504 bytes
Database Buffers 855638016 bytes
Redo Buffers 4530176 bytes
Database mounted.
Database opened.
CONTAINER: Resetting SYS and SYSTEM passwords.
User altered.
User altered.
#########################
DATABASE IS READY TO USE!
#########################
####################################################################
CONTAINER: The following output is now from the alert_FREE.log file:
####################################################################
===========================================================
Unable to obtain current patch information due to error: 20013
===========================================================
2024-01-28T02:30:37.685769+00:00
PDB$SEED(2):Opening pdb with Resource Manager plan: DEFAULT_PLAN
FREEPDB1(3):Autotune of undo retention is turned on.
2024-01-28T02:30:39.307884+00:00
FREEPDB1(3):Opening pdb with Resource Manager plan: DEFAULT_PLAN
Completed: Pluggable database FREEPDB1 opened read write
Completed: ALTER DATABASE OPEN
2024-01-28T02:30:46.512843+00:00
Thread 1 advanced to log sequence 14 (LGWR switch), current SCN: 2337254
Current log# 1 seq# 14 mem# 0: /opt/oracle/oradata/FREE/redo01.log
And I can confirm that the container is using tmpfs for the /opt/oracle/oradata
location:
bash-4.4# mount | grep /opt/oracle/oradata
tmpfs on /opt/oracle/oradata type tmpfs (rw,nosuid,nodev,relatime,size=4194304k,uid=1000,gid=1000,inode64)
bash-4.4# df -h
Filesystem Size Used Avail Use% Mounted on
overlay 250G 189G 62G 76% /
tmpfs 64M 0 64M 0% /dev
tmpfs 794M 124K 794M 1% /etc/hosts
shm 63M 0 63M 0% /dev/shm
tmpfs 4.0G 2.9G 1.2G 72% /opt/oracle/oradata
devtmpfs 4.0M 0 4.0M 0% /dev/tty
bash-4.4#
I've tried to run a container with --tmpfs mount for oracle data. I way wondering to get some performance benefits for integration tests. Has anybody tried it? I would like to use tmpfs for all possible database files for speedup.
I've tried --tmpfs /opt/oracle/oradata, but unfortunately get this result:
Thanks for the help or any advice.