SQWareProduction:db2:etc:sqwdb2 GlobalVar.cfg

De WikiFr

Configuration file $gvsqw_D2db2Bin/../etc/sqwdb2_GlobalVar.cfg:
Global var for Db2
Contient les variables operationnelles de SQWareProduction.

Contenu du fichier:

#!/bin/ksh
###################################################################
# SQWareProduction for Db2 module of dbSQWare
# 
# dbSQWare is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# CGU/CGA for more details.
# 
# You should have received a copy of the CGU/CGA
# along with this program.  If not, see <http://www.dbsqware.com/licenses/>.
# 
# For information : contact@dbsqware.com or www.dbsqware.com
###################################################################
## @Synopsis	Global var for Db2
## @Copyright	Copyright 2010-2020, dbSQWare (www.dbsqware.com)

#global
export gvsqw_RootAdmin='$HOME/admin/${lvsqw_InstanceParam}'
export gvsqw_RootAdminDisable='$HOME'
export gvsqw_RootAdminDist='$HOME/admin/db2/${lvsqw_InstanceParam}'
export gvsqw_RootCfg='$gvsqw_RootAdmin/sqwConfig'
export gvsqw_RootDbf='${HOME}/${DB2INSTANCE}'
export gvsqw_Db2ErrorMsg='^SQL[0-9][0-9]*'
export gvsqw_Db2ErrorMsgWarning='^SQL[0-9][0-9]*W'
export gvsqw_DbAlias='$lvsqw_InstanceParam'

#for indicators
export gvsqw_SizeMinTableIndicators=10

#For RUNSTAT
export gvsqw_NbThreadRunStats=2
export gvsqw_RunStatsOption='WITH DISTRIBUTION AND DETAILED INDEXES ALL'

#For reorg
export gvsqw_NbThreadReorganize=2
#CURRENT or UPDATE
export gvsqw_ReorgStat='UPDATE'
#USER ALL SYSTEM
export gvsqw_ReorgTypeTable='USER'
#Put off to desactivate RUNSTAT after reorg
export gvsqw_ReorgRunStatsOption='WITH DISTRIBUTION AND DETAILED INDEXES ALL'

#for Dump scripts
export gvsqw_NbThreadBackup=2
export gvsqw_RootBackup='/backup/db2/$lvsqw_InstanceParam'
export gvsqw_BackupRetention=30
#'USE TSM' 'TO DISK' 'USE XBSA'
export gvsqw_ToolCommand='USE TSM'
export gvsqw_ToolType='TSM'
export gvsqw_Compress='COMPRESS'
export gvsqw_RsyncDefaultSourceDir='/backup/db2/$lvsqw_InstanceParam'

#Put disable in gvsqw_TraceBackup if you don't want to trace backup execution in SQWareRepository
export gvsqw_TraceBackup=enable

##Globaly forcing return code for scripts
#export gvsqw_ForcedReturnCodeScript_sqwdb2_DumpDatabase=0

#PK for indicators, if DB2INSTANCE not unique, put for example gvsqw_DbAlias='$lvsqw_InstanceParam:$(hostname|cut -d '.' -f1)'
export gvsqw_DbAlias='$lvsqw_InstanceParam'


Explication de variables:

#General variables
gvsqw_SqwVersion => SQWare Production version
gvsqw_ConnectDb => if connection to db evalable then Enable else Disable
gvsqw_Hostname => Hostname for prompt and trace
gvsqw_GlobalMsgMail => Begining of email subject
gvsqw_GlobalMail => email adress, put NoNail in gvsqw_GlobalMail if you don't want to send mail on error
gvsqw_SendmailHtmlFormat => Html format for email, put disable in gvsqw_SendmailHtmlFormat if you don't want to send mail in html format
gvsqw_PreFormatHtlml => enable if file is already formated
gvsqw_Colors => enable, put disable in gvsqw_Colors if you don't want to print in color
gvsqw_TraceJobDb => enable, put disable in gvsqw_TraceJobDb if you don't want to trace job execution in SQWareRepository
gvsqw_EgrepIvFs => for 'egrep -v' on 'df' command
gvsqw_SuppLogsHisto => number of days to delete log files
gvsqw_GzipLogsHisto => number of days to compress log files
gvsqw_RootAdmin => admin directory
gvsqw_RootCfg => configuration directory
gvsqw_RootDbf => datafiles directory
gvsqw_InitInstanceSourceCommand => Init profile instance command
gvsqw_NbThread => default number of thread for parallelism
gvsqw_Db2ErrorMsg => format of MySQL errors
gvsqw_SshOptions => ssh default options
gvsqw_ScpOptions => scp default options

#Html tags
gvsqw_CHtmlError => font tag for error
gvsqw_CHtmlOk => font tag for OK
gvsqw_CHtmlInfo => font tag for info
gvsqw_CHtmlEnd => end font tag
gvsqw_THtmlBegin => table tag
gvsqw_THtmlEnd => end table tag
gvsqw_THtmlThBegin => th tag
gvsqw_THtmlThEnd => end th tag
gvsqw_THtmlThInter => inter th tag
gvsqw_THtmlTdBegin1 => td tag sqwnc
gvsqw_THtmlTdBegin2 => td tag sqwc_
gvsqw_THtmlTdEnd => end td tag
gvsqw_THtmlTdInter => inter td tag
gvsqw_THtmlPre => tag for pre formated text
gvsqw_THtmlPreEnd => end tag for pre formated text
gvsqw_HtmlCss => CSS style

#for Dump scripts
gvsqw_NbThreadBackup => default number of thread for parallelism for backup
gvsqw_RootBackup => default backup directory
#Put disable in gvsqw_TraceBackup if you don't want to trace backup execution in SQWareRepository
gvsqw_TraceBackup => to trace backup execution in SQWare repository
gvsqw_BackupRetention => backup retention in days
gvsqw_ToolCommand => Support backup 'USE TSM' 'TO DISK' 'USE XBSA'
gvsqw_Compress => for backup compression

#for reorg scripts
gvsqw_NbThreadReorganize => default number of thread for parallelism for reorg
gvsqw_ReorgStat => for reorgchk CURRENT or UPDATE
gvsqw_ReorgTypeTable => type of table to reorg USER ALL SYSTEM
gvsqw_ReorgRunStatsOption => RUNSTAT option after reorg (Put off to desactivate)

#for analyse scripts
gvsqw_NbThreadRunStats => default number of thread for parallelism for runStatistics
gvsqw_RunStatsOption => RUNSTAT option

##Globaly forcing return code for scripts
gvsqw_ForcedReturnCodeScript_sqwdb2_BackupDatabase => To force return code of sqwdb2_BackupDatabase.ksh
...

#for SQWare Web
gvsqw_WebDbaURL => SQWare Web URL
Information.png
Information:
Vous pouvez surcharger les variables contenues dans $gvsqw_D2db2Bin/../etc/sqwdb2_GlobalVar.cfg

en mettant les memes noms de variables dans $gvsqw_D2db2Bin/../etc_cust/sqwdb2_GlobalVar.cfg pour tous vos environnements
ou dans $HOME/sqwConfig/sqwdb2_GlobalVar.cfg pour cet utilisateur specialement.