Difference between revisions of "SQWareCentral:sybase"
Expdbtools (talk | contribs) (→sqwc_DbRefVar.cfg) |
Expdbtools (talk | contribs) (→sqwc_ExpVar.cfg) |
||
Line 126: | Line 126: | ||
export gvsqw_RootSQWareProductionSybase="~$gvsqw_UserUniqueSybase/SQWareProduction/sybase" | export gvsqw_RootSQWareProductionSybase="~$gvsqw_UserUniqueSybase/SQWareProduction/sybase" | ||
export gvsqw_VersSQWareProductionSybase='prod' | export gvsqw_VersSQWareProductionSybase='prod' | ||
− | export gvsqw_VersDeplSQWareProductionSybase=' | + | export gvsqw_VersDeplSQWareProductionSybase='v3.1' |
export gvsqw_Mail_sybase='dba' | export gvsqw_Mail_sybase='dba' | ||
export gvsqw_MailMsg_sybase='TrtSybAuto' | export gvsqw_MailMsg_sybase='TrtSybAuto' |
Revision as of 06:18, 28 June 2011
auto
sqwsyb_CheckNetworker.ksh
Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_CheckNetworker.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_CheckNetworker.ksh.
Check Networker backups for Sybase
Action:
lfsqw_Action() { isql -n -b -w200 -U$gvsqw_DbRefUser_sybase -S$gvsqw_DbRefInstance_sybase -D$gvsqw_DbRefDatabase_sybase << EOFSQL $gvsqw_DbRefPass_sybase delete tsqw_Networker go delete tsqw_Networker_retard go EOFSQL while read lvsqw_HostName lvsqw_UserName do echo "${c_info}$lvsqw_UserName@$lvsqw_HostName${c_normal}" ssh -T $lvsqw_UserName@$lvsqw_HostName <<EOFSSH & $gvsqw_RootSQWareProductionSybase/$gvsqw_VersSQWareProductionSybase/bin/sqwsyb_CheckNetworker.ksh -c $lvsqw_HostName EOFCAT EOFSSH sleep 10 done <$gvsqw_TmpFile.lst wait }
sqwsyb_DeplScripts.ksh
Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_DeplScripts.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_DeplScripts.ksh.
SQWareProduction deployment for Sybase
Action:
lfsqw_Action() { while read lvsqw_HostName lvsqw_UserName do echo "${c_info}$lvsqw_UserName@$lvsqw_HostName${c_normal}" ssh -T $lvsqw_UserName@$lvsqw_HostName <<EOFSSH mkdir -p $gvsqw_RootSQWareProductionSybase/$gvsqw_VersDeplSQWareProductionSybase cd $gvsqw_RootSQWareProductionSybase rm -f $gvsqw_VersSQWareProductionSybase ln -s $gvsqw_VersDeplSQWareProductionSybase $gvsqw_VersSQWareProductionSybase EOFSSH rsync -aHv $gvsqw_RsyncPathSybase --delete $gvsqw_RootSQWareProduction/sybase/$gvsqw_VersDeplSQWareProductionSybase $lvsqw_UserName@$lvsqw_HostName:$gvsqw_RootSQWareProductionSybase/. done <$gvsqw_TmpFile.lst }
sqwsyb_GatherIndicators.ksh
Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_GatherIndicators.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_GatherIndicators.ksh.
Sybase indicators collection
Action:
lfsqw_Action() { while read lvsqw_HostName lvsqw_UserName lvsqw_Instance do echo "${c_info}$lvsqw_UserName@$lvsqw_HostName $lvsqw_Instance${c_normal}" ssh -T $lvsqw_UserName@$lvsqw_HostName <<EOFSSH & . \$gvsqw_SybBin/../tools/sqwsyb_SetEnv.ksh $lvsqw_Instance \$gvsqw_SybBin/sqwsyb_RunJob.ksh -S $lvsqw_Instance -A IndicDba EOFSSH sleep 1 done <$gvsqw_TmpFile.lst wait }
etc
CrontabRef.cfg
Configuration file $gvsqw_RootexpdbCentral/action/sybase/etc/CrontabRef.cfg:
It contains the operating variables of SQWareCentral for sybase.
If you want to overload default variables,
put in $gvsqw_RootexpdbCentral/action/sybase/etc_cust/CrontabRef.cfg
your modifications (only variables you want to modify).
sqwc_DbRefVar.cfg
Configuration file $gvsqw_RootexpdbCentral/action/sybase/etc/sqwc_DbRefVar.cfg:
It contains the operating variables of SQWareCentral for sybase.
If you want to overload default variables,
put in $gvsqw_RootexpdbCentral/action/sybase/etc_cust/sqwc_DbRefVar.cfg
your modifications (only variables you want to modify).
File content:
export gvsqw_DbRefType_sybase='sybase' export gvsqw_DbRefPort_sybase='InstancePortForSybase' export gvsqw_DbRefInstance_sybase='InstanceNameForSybase' export gvsqw_DbRefDatabase_sybase='DatabaseInstanceNameForSybase' export gvsqw_DbRefUser_sybase='ConnexionUserForSybase' export gvsqw_DbRefPass_sybase='ConnexionPassForSybase'
Variable explanation:
gvsqw_DbRefDatabase_sybase => Database of SQWareRepository for Sybase gvsqw_DbRefInstance_sybase => Dataserver of SQWareRepository for Sybase gvsqw_DbRefPass_sybase => password to connect to SQWareRepository for Sybase gvsqw_DbRefPort_sybase => Not used gvsqw_DbRefType_sybase => type of RDBMS for SQWareRepository for Sybase gvsqw_DbRefUser_sybase => user to connect to SQWareRepository for Sybase
sqwc_ExpVar.cfg
Configuration file $gvsqw_RootexpdbCentral/action/sybase/etc/sqwc_ExpVar.cfg:
It contains the operating variables of SQWareCentral for sybase.
If you want to overload default variables,
put in $gvsqw_RootexpdbCentral/action/sybase/etc_cust/sqwc_ExpVar.cfg
your modifications (only variables you want to modify).
File content:
export gvsqw_RootSQWareProductionSybase="~$gvsqw_UserUniqueSybase/SQWareProduction/sybase" export gvsqw_VersSQWareProductionSybase='prod' export gvsqw_VersDeplSQWareProductionSybase='v3.1' export gvsqw_Mail_sybase='dba' export gvsqw_MailMsg_sybase='TrtSybAuto'
Variable explanation:
gvsqw_MailMsg_sybase => begining of email subject for Sybase gvsqw_Mail_sybase => email adress for Sybase gvsqw_RootSQWareProductionSybase => SQWareProduction directory source for Sybase gvsqw_VersDeplSQWareProductionSybase => version of SQWareProduction to deploy for Sybase gvsqw_VersSQWareProductionSybase => link for current version of SQWareProduction for Sybase
sqwc_GlobalVar.cfg
Configuration file $gvsqw_RootexpdbCentral/action/sybase/etc/sqwc_GlobalVar.cfg:
It contains the operating variables of SQWareCentral for sybase.
If you want to overload default variables,
put in $gvsqw_RootexpdbCentral/action/sybase/etc_cust/sqwc_GlobalVar.cfg
your modifications (only variables you want to modify).
File content:
export gvsqw_UserUniqueSybase='sysdba'
Variable explanation:
gvsqw_UserUniqueSybase => user to deploy SQWareProduction for Sybase
.profile_confort
File to put aliases $gvsqw_RootexpdbCentral/action/sybase/etc/.profile_confort:
Contains confort aliases of SQWareCentral for RDBMS sybase.
Alias explanation:
act_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/prod;ls -al' depl_syb => '$gvsqw_RootexpdbCentral/bin/sqwc_TrtAuto.ksh sybase sqwsyb_DeplScripts.ksh sqwsyb_GenLstUnique.ksh NOLOG CONFIRM' repind_syb => '$gvsqw_RootexpdbCentral/bin/sqwc_TrtAuto.ksh sybase sqwsyb_GatherIndicators.ksh sqwsyb_GenLstRepind.ksh NOLOG' gen_syb => '$gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_GenRefSybase.ksh'
lst
sqwc_GenRefDbSybase.ksh
List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_GenRefDbSybase.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwc_GenRefDbSybase.ksh.
Query used:
select 'SYB;' + vol.DataServer + ';' + vol.Database_name + ';' + ref.Env + ';' + from tsqw_Repository ref, tsqw_VolDb vol, tsqw_GenHisto hist where hist.Month = convert(smalldatetime,'01'+substring(convert(char(10),getdate(),103),3,8),103) and hist.DataServer = vol.DataServer and hist.Gather_date = vol.Gather_date and ref.DataServer = hist.DataServer and ref.Status!='OFF' and vol.Database_name not in ('dbccdb','master','tempdb','sybsecurity','sybsystemdb','sybsystemprocs','model','audsa','auditdb','sybmgmtdb') and vol.Database_name not like 'temp%' order by vol.Database_name, vol.DataServer
sqwc_GenRefSybase.ksh
List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_GenRefSybase.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwc_GenRefSybase.ksh.
Query used:
select convert(char(18),Virt_Hostname) "VirtHost", from tsqw_Repository select convert(char(18),Virt_Hostname) "VirtHost", from tsqw_RepositoryOther order by 6,2,1,3,4
sqwsyb_GenLstDataserver.ksh
List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstDataserver.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstDataserver.ksh.
Generation of the list of Sybase dataservers (tsqw_Repository)
Query used:
select convert(varchar(70),Virt_Hostname+' '+Username+' '+DataServer) from tsqw_Repository where Status = 'ON' order by Virt_Hostname, Username
sqwsyb_GenLstNetworker.ksh
List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstNetworker.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstNetworker.ksh.
Generation of the list of unix users Sybase (tsqw_Repository)
Query used:
select distinct convert(varchar(70),Virt_Hostname+' '+Username) from tsqw_Repository where Status = 'ON' order by Virt_Hostname, Username
sqwsyb_GenLstRepind.ksh
List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstRepind.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstRepind.ksh.
Generation of the list for reprise of indicators (tsqw_Repository/tsqw_GenHisto)
Query used:
select convert(varchar(70),ref.Virt_Hostname+' '+ref.Username+' '+ref.DataServer) from tsqw_Repository ref where ref.Status = 'ON' and not exists ( select 1 from tsqw_GenHisto inf where inf.Gather_date = convert(smalldatetime,convert(char(10),getdate(),103),103) and ref.DataServer = inf.DataServer) order by Virt_Hostname, Username
sqwsyb_GenLstUnique.ksh
List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstUnique.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstUnique.ksh.
Generation of the user unique list (tsqw_Repository/tsqw_RepositoryOther)
Query used:
select distinct Hostname||' $gvsqw_UserUniqueSybase' from tsqw_Repository where Status != 'OFF' select distinct Hostname||' $gvsqw_UserUniqueSybase' from tsqw_RepositoryOther order by 1