Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Multiple DBs per Server and OEM
For what it's worth, here's the solution I'm implementing:
[[ -z "$IN_SID_LIST" ]] && USAGE
for SID in $IN_SID_LIST
do
if grep -cw "$SID" /etc/oratab 1>/dev/null 2>&1; then ORAENV_ASK="NO" . oraenv "$SID" echo "[$(date +%m/%d/%Y' '%H:%M:%S)] Running $THISFILE for SID: $SID" ...
The point of all of this is to pass a valid list of SIDs to the script. If any of the "valid" SIDs are found on that server's /etc/oratab, then run the script with ORACLE_SID=$SID.
Works? Yes. Over engineered? Yes.
Dave
> -----Original Message-----
> From: Howard Latham [mailto:howard.latham_at_rsmb.co.uk]
> Sent: Tuesday, April 12, 2005 9:37 AM
> To: thomas.mercadante_at_labor.state.ny.us; Herring Dave - dherri; oracle-
> l_at_freelists.org
> Subject: RE: Multiple DBs per Server and OEM
>
> I just tried some jobs on NT (Yes sad isn't it - no cron!)
> And the run DBA Script appears to connect via the SQLNET
> Route so you could get the SID by select name from v$database
> And pass that to Unix.
>
> Howard A. Latham
>
> Tech Services Director UK Oracle User Group.
>
> SENIOR DATABASE ADMINISTRATOR
> RSMB Television Research Ltd,
> The Communications Building,
> 48 Leicester Square,
> London. WC2H 7LT
>
>
> Tel: +44 (0)20 7808 3619
> SW: +44 (0)20 7808 3600
> Fax: +44 (0)20 7839 7446
>
> mailto:Howard.latham_at_rsmb.co.uk
>
> http://www.rsmb.co.uk
>
-- http://www.freelists.org/webpage/oracle-lReceived on Tue Apr 12 2005 - 18:32:27 CDT
![]() |
![]() |