Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add db restart option after spfile init parameter change #342

Merged
merged 5 commits into from
Jul 7, 2023

Conversation

bartowl
Copy link
Contributor

@bartowl bartowl commented Jun 22, 2023

This PR adds 2 features:

  • possibility to automatically restart database(s) after applying change to init parameter scoped on spfile in order to make the changes effective
  • enhances oracle_db module with state: restarted that restarts the database
    It additionally introduces some code cleanup and simplifications in oracle_db module.

@bartowl bartowl force-pushed the feature/spfile-changed-reboot branch 2 times, most recently from 09446d6 to 949e26e Compare June 22, 2023 14:14
@Rendanic Rendanic added this to the 3.8 milestone Jun 22, 2023
@bartowl bartowl force-pushed the feature/spfile-changed-reboot branch from 949e26e to 4d00481 Compare June 23, 2023 11:53
@bartowl
Copy link
Contributor Author

bartowl commented Jun 23, 2023

I had to move the sleep(10) to start_instance as otherwise if oradb_manage_parameters role has been followed by another that immediately tried to connect to the database, the database was not yet ready and playbook failed. Now every one start of the database will wait 10 seconds for the db to fully start and register in listener.

@Rendanic
Copy link
Collaborator

I did some test and 1 important point.
Oracle rounds some values in spfile to v$parameter.

Example:
SPFILE: sga_target = 1800M

v$parameter: sga_target = 1808M

I have no idea, how Oracle rounds the values.

We have to live with this effect for the moment...

Don't forget - this affects all memory parameter. sga_target is just 1 example. I had it with streams_pool_size and pga_aggreaget_target as well.

It's a good idea to start with restart_spparameter_changed: false as default.
Otherwise the instance is bounced each time oradb_mange_parameter is executed...

@bartowl bartowl force-pushed the feature/spfile-changed-reboot branch 2 times, most recently from 8131a4c to 0b3c0fb Compare July 6, 2023 13:26
@bartowl bartowl force-pushed the feature/spfile-changed-reboot branch from 0b3c0fb to b226e7d Compare July 6, 2023 13:29
@bartowl
Copy link
Contributor Author

bartowl commented Jul 6, 2023

Rebased against Rendanic/proracle_db and added some missing fixes. This has been tested against FS storage 19c with python3 and works excellent.

@Rendanic Rendanic added the has dependency Has a dependency to another Issue/PR label Jul 7, 2023
@Rendanic Rendanic merged commit 841108c into oravirt:master Jul 7, 2023
@Rendanic Rendanic mentioned this pull request Jul 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement has dependency Has a dependency to another Issue/PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants