Re: Basic Scripts for Database Administration

From: exazonk <exazonk_at_gmail.com>
Date: Wed, 24 Jun 2009 17:35:00 -0700 (PDT)
Message-ID: <1492f15f-88eb-4d7f-9ee5-19c79ab43905_at_e13g2000pra.googlegroups.com>



On Jun 25, 12:46 am, John Hurley <johnbhur..._at_sbcglobal.net> wrote:
> On Jun 24, 1:48 am, exazonk <exaz..._at_gmail.com> wrote:
>
>
>
>
>
> > Has anyone come across a few scripts that would make Oracle database
> > administration easier?
>
> > For example, the following command:
>
> > execSql -d=DB_NAME -f=/ora/sql/chk_tspaces.sql -a=80 -e=on_output -
> > g=DBA
>
> > The above command would run the sql file (probably using sqlplus)
> > using the argument, 80%, as a threshold to check to see if any
> > tablespaces had exceeded this. If the script returned any output, then
> > this would cause an email to be sent to the DBA group.
>
> > Or to run statspack every day from crontab:
>
> > execSql -d=DB_NAME -c "exec perfstat.statspack.snap;" -e on_error -
> > g=DBA
>
> > So the above command would be run and if it produced an error, it
> > would email the DBA group.
>
> > The execSql script could then be used to run an entire suite of sql
> > files, or rman scripts, so that database administration was easier.
>
> > The script, execSql, would probably be scripted in perl so that is was
> > multi-platform.
>
> > Thanks
>
> Are you new to this game?
>
> People have been defining/collecting and putting out free and not free
> versions of stuff like this for 10/15+ years in the oracle area.
>
> While certainly new features and what you need to do has changed since
> the 7.3 days ... it was all pretty much done and developed.
>
> Religious wars develop about if you should use perl or just basic
> shell scripting.
>
> Someone published a book on perl scripting for oracle stuff not long
> ago so maybe that's what you want to look at buying ( that book ... I
> am sure someone will supply details ).
>
> Other people these days thing you should stick with OEM and let oracle
> do the development work.
>
> Have fun!- Hide quoted text -
>
> - Show quoted text -

I guess there are many ways to skin a cat, but there are probably only a few that are the most efficient.

It is interesting finding out how people admin their databases as each DBA probably thinks that they have the best method.

I'm just wondering if there are any good sites that focus on production DBA stuff on a large amount of databases spread out over a lot of servers.

If you just got a new job in which you inherited 10 servers, with 10 databases on each server, and no administration for the databases existed yet, what approach would you take to providing DBA support? Assume the databases are equally divided among windows and unix servers and range in version from 9i, 10g to 11g.

Health checks would obviously be needed for things like disk space, tablespaces, log monitoring, load monitoring, statspack, Data Guard etc. Received on Wed Jun 24 2009 - 19:35:00 CDT

Original text of this message