Do A Daily Automatic Oracle Database Performance Check Using Stori
Do a daily automatic performance check using Stori
If you're like most Oracle Database Administrators, you want a way to automatically and periodically run an Oracle Database performance analysis. This is especially true if, like most organizations, you have periodic peak times. This is a perfect use case for Stori!
Here's a typical situation: Suppose the peak processing time occurs daily between 10am to noon. When you arrive back from lunch you want a short performance summary in your inbox. You want to ensure everything was OK. If not, you need to know what happened and what to do about it.
Here's what to do...
First, place the below commands into a Playback file, which is simply a plain text file. Let's name the Playback file, dailyAnal.pbf. Only the below two lines are required.
set scope today 1000 120 analyze summary
You can run the Playback file manually. Even better would be to run it via cron! To run it manually you can run it within Stori or as part of invoking Stori. Here's how to run it from the OS command line:
$ ./storiLin64 -pbf dailyAnal.pbf
To run the command from within Stori ask, start pbf dialyAnal.pbf. To automatically run via cron use the command line option as a guide.
Want to go a step further?
What made the example so straightforward is the use of the Playback Facility and the flexible analysis scope change. There is a lot more you can do with Playback files. For more information ask Stori, help pb or check out the Stori FAQ | Advanced Use | Can I script a sequence of commands?
Also key in this example is a quick and flexible analysis scope change. There are a number of ways to tell Stori to change the analysis scope. Notice I did not need to know the snap_ids or even the date! I simply asked Stori to reset the analysis scope for today starting at 10am and lasting 120 minutes. It can't get any easier than that! For more information about changing the analysis scope ask Stori, help scope.
All the best in your Oracle database performance tuning work!
If you have any questions or comments, feel free to email me directly at craig at orapub.com.
|Fixed In Oracle Database 12c? Session CPU Consumption Statistics||The Oracle Database LGWR Three Second Rule. Really?||Is Oracle Database 12c (18.104.22.168.0) Faster Than Previous Releases|