简体   繁体   中英

What's the equivalent to Postgres's fsync setting in OracleDB?

I have an OracleDB database running in a CI pipeline. It gets setup and torn-down on each test run; and it's bloody slow.

Since I don't care about integrity, is it possible to run OracleDB with no flushing to disk? Much like Postgres's fsync setting?

I believe that the COMMIT_WAIT Oracle parameter is similar to PostgreSQL's fsync setting. After running the below command, Oracle will not wait for commits to be flushed to disk:

alter system set commit_wait = nowait;

But in my limited experience with that parameter, it does not significantly improve performance unless your system is doing a ridiculous number of commits. Perhaps you should also look into using NOARCHIVELOG mode. Oracle will still write transaction data to disks, but it will at least stop making an extra copy:

SQL> shutdown  immediate;
SQL> startup mount
SQL> alter database noarchivelog;
SQL> alter database open;

But even those settings probably won't significantly improve administrative task times. Oracle instances will never be small, lightweight processes. The closest thing is the multi-tenant option, which enables rapidly creating pluggable databases. But that option requires setting up a central container database, which is probably what you're trying to avoid in the first place.

Can you provide more information about your CI pipeline? There might be some optimizations specific to your environment. For example, I think that Oracle has some code to support Docker (although I'm not familiar with those options).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM