SQWareCentral:sybase

From Wiki_dbSQWare
Jump to: navigation, search

auto

sqwsyb_AdddbSQWareProfile.ksh

Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_AdddbSQWareProfile.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_AdddbSQWareProfile.ksh.
Add dbSQWare profile

Action:

lfsqw_Action()
{
while read lvsqw_HostName lvsqw_UserName lvsqw_Instance
do
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName $lvsqw_Instance${c_normal}"
lvsqw_Instance=$(echo "$lvsqw_Instance"|cut -d':' -f1)
ssh $gvsqw_SshOptions $lvsqw_UserName@$lvsqw_HostName <<EOFSSH
if [ -r ~/.profile ]
then
	if [ \$(grep -c 'gvsqw_SybBin' ~/.profile) -eq 0 ]
	then
		cat <<EOFCAT >>~/.profile

#dbSQWare
export gvsqw_Env=''
export gvsqw_SybBin=\\\$HOME/SQWareProduction/sybase/bin
lvsqw_IsTerminal=\\\$(tty 2>&1 >/dev/null;echo \\\$?)
if [ "\\\$lvsqw_IsTerminal" = "0" ] && [ -r \\\$gvsqw_SybBin/../etc/.profile_confort ]
then
	. \\\$gvsqw_SybBin/../etc/.profile_confort
fi

EOFCAT
	fi
elif [ -r ~/.bash_profile ]
then
	if [ \$(grep -c 'gvsqw_SybBin' ~/.bash_profile) -eq 0 ]
	then
		cat <<EOFCAT >>~/.bash_profile

#dbSQWare
export gvsqw_Env=''
export gvsqw_SybBin=\\\$HOME/SQWareProduction/sybase/bin
lvsqw_IsTerminal=\\\$(tty 2>&1 >/dev/null;echo \\\$?)
if [ "\\\$lvsqw_IsTerminal" = "0" ] && [ -r \\\$gvsqw_SybBin/../etc/.profile_confort ]
then
	. \\\$gvsqw_SybBin/../etc/.profile_confort
fi

EOFCAT
	fi
fi
EOFSSH
done <$gvsqw_TmpFile.lst

}


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 $gvsqw_SshOptions $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_GatherDistFsSize.ksh

Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_GatherDistFsSize.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_GatherDistFsSize.ksh.
Gather FS size

Action:

lfsqw_Action()
{
while read lvsqw_HostName lvsqw_UserName lvsqw_Instance
do
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName $lvsqw_Instance${c_normal}"
ssh $gvsqw_SshOptions $gvsqw_DistSQWareProdUser_sybase <<EOFSSH &
\$gvsqw_SybBin/sqwsyb_GatherDistantFsSize.ksh -S "$lvsqw_Instance" -U "$lvsqw_UserName" -H "$lvsqw_HostName"
EOFSSH
sleep 3
done <$gvsqw_TmpFile.lst
jobs
wait
}


sqwsyb_GatherIndicatorsDist.ksh

Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_GatherIndicatorsDist.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_GatherIndicatorsDist.ksh.
Sybase indicators collection in distant mode

Action:

lfsqw_Action()
{
while read lvsqw_HostName lvsqw_UserName lvsqw_Instance
do
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName $lvsqw_Instance${c_normal}"
ssh $gvsqw_SshOptions $gvsqw_DistSQWareProdUser_sybase <<EOFSSH &
\$gvsqw_SybBin/sqwsyb_GatherIndicators.ksh -S "$lvsqw_Instance" -Dist
EOFSSH
sleep 1
done <$gvsqw_TmpFile.lst
jobs
wait
}


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
lvsqw_Instance=$(echo "$lvsqw_Instance"|cut -d':' -f1)
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName $lvsqw_Instance${c_normal}"
ssh $gvsqw_SshOptions $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
}


sqwsyb_Gen_dbSQWare.ksh

Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_Gen_dbSQWare.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_Gen_dbSQWare.ksh.
generate dbSQWare files

Action:

lfsqw_Action()
{
while read lvsqw_HostName lvsqw_UserName lvsqw_Instance
do
lvsqw_Instance=$(echo "$lvsqw_Instance"|cut -d':' -f1)
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName $lvsqw_Instance${c_normal}"
ssh $gvsqw_SshOptions $lvsqw_UserName@$lvsqw_HostName <<EOFSSH
. \$gvsqw_SybBin/../tools/sqwsyb_SetEnv.ksh $lvsqw_Instance
if [ "\$DSQUERY" != "$lvsqw_Instance" ]
then
	export DSQUERY="$lvsqw_Instance"
fi
\$gvsqw_SybBin/../tools/sqwsyb_GenerateCreateDataserver.ksh -dbsOnly <<EOF
y
EOF
EOFSSH
done <$gvsqw_TmpFile.lst
}


sqwsyb_GenSshKeysInstance.ksh

Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_GenSshKeysInstance.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_GenSshKeysInstance.ksh.
ssh keys deployment for Sybase

Action:

lfsqw_Action()
{

echo "#########################################################################"
echo "#Create/Retrieve key for SQWareCentral"
mkdir -p $HOME/tmp
if [ -r $HOME/.ssh/id_dsa.pub ]
then
	echo "Id DSA found:"
	ls -l $HOME/.ssh/id_dsa.pub
	lvsqw_CentralKey=$(cat $HOME/.ssh/id_dsa.pub)
elif [ -r $HOME/.ssh/id_rsa.pub ]
then
	echo "Id RSA found:"
	ls -l $HOME/.ssh/id_rsa.pub
	lvsqw_CentralKey=$(cat $HOME/.ssh/id_rsa.pub)
else
	ssh-keygen -t rsa -N '' -f $HOME/.ssh/id_rsa
	lvsqw_CentralKey=$(cat $HOME/.ssh/id_rsa.pub)
fi
#Retrieve additionnal keys if found (your windows key for exemple)
if [ -r $HOME/.ssh/id_dbSQWare.pub ]
then
	echo "Id dbSQWare found:"
	ls -l $HOME/.ssh/id_dbSQWare.pub
	lvsqw_AdditionnalKey=$(cat $HOME/.ssh/id_dbSQWare.pub)
else
	lvsqw_AdditionnalKey=""
fi
chmod go-w $HOME
touch $HOME/.ssh/authorized_keys
chmod 700 $HOME/.ssh
chmod 600 $HOME/.ssh/authorized_keys
echo "${c_menu}#########################################################################"
echo "#create key if not found and put SQWareCentral key for distant users"
echo "Enter password when necessary${c_normal}"
while read lvsqw_HostName lvsqw_UserName lvsqw_Instance
do
echo ""
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName${c_normal}"
ssh -o StrictHostKeyChecking=no $lvsqw_UserName@$lvsqw_HostName <<EOFSSH
mkdir -p \$HOME/tmp
if [ -r \$HOME/.ssh/id_dsa.pub ]
then
	echo "Id DSA found:"
	ls -l \$HOME/.ssh/id_dsa.pub
	cat \$HOME/.ssh/id_dsa.pub
elif [ -r \$HOME/.ssh/id_rsa.pub ]
then
	echo "Id RSA found:"
	ls -l \$HOME/.ssh/id_rsa.pub
	cat \$HOME/.ssh/id_rsa.pub
else
	ssh-keygen -t rsa -N '' -f \$HOME/.ssh/id_rsa
	cat \$HOME/.ssh/id_rsa.pub
fi
chmod go-w \$HOME
echo "$lvsqw_CentralKey" >>\$HOME/.ssh/authorized_keys
echo "$lvsqw_AdditionnalKey" >>\$HOME/.ssh/authorized_keys
chmod 700 \$HOME/.ssh
chmod 600 \$HOME/.ssh/authorized_keys
EOFSSH

done <$gvsqw_TmpFile.lst
}


sqwsyb_GenSshKeys.ksh

Action script $gvsqw_RootexpdbCentral/action/sybase/auto/sqwsyb_GenSshKeys.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/auto_cust/sqwsyb_GenSshKeys.ksh.
ssh keys deployment for Sybase

Action:

lfsqw_Action()
{

echo "#########################################################################"
echo "#Create/Retrieve key for SQWareCentral"
mkdir -p $HOME/tmp
if [ -r $HOME/.ssh/id_dsa.pub ]
then
	echo "Id DSA found:"
	ls -l $HOME/.ssh/id_dsa.pub
	lvsqw_CentralKey=$(cat $HOME/.ssh/id_dsa.pub)
elif [ -r $HOME/.ssh/id_rsa.pub ]
then
	echo "Id RSA found:"
	ls -l $HOME/.ssh/id_rsa.pub
	lvsqw_CentralKey=$(cat $HOME/.ssh/id_rsa.pub)
else
	ssh-keygen -t rsa -N '' -f $HOME/.ssh/id_rsa
	lvsqw_CentralKey=$(cat $HOME/.ssh/id_rsa.pub)
fi
#Retrieve additionnal keys if found (your windows key for exemple)
if [ -r $HOME/.ssh/id_dbSQWare.pub ]
then
	echo "Id dbSQWare found:"
	ls -l $HOME/.ssh/id_dbSQWare.pub
	lvsqw_AdditionnalKey=$(cat $HOME/.ssh/id_dbSQWare.pub)
else
	lvsqw_AdditionnalKey=""
fi
chmod go-w $HOME
touch $HOME/.ssh/authorized_keys
chmod 700 $HOME/.ssh
chmod 600 $HOME/.ssh/authorized_keys
echo "${c_menu}#########################################################################"
echo "#create key if not found and put SQWareCentral key for distant users"
echo "Enter password when necessary${c_normal}"
while read lvsqw_HostName lvsqw_UserName
do
echo ""
echo "${c_info}$lvsqw_UserName@$lvsqw_HostName${c_normal}"
ssh -o StrictHostKeyChecking=no $lvsqw_UserName@$lvsqw_HostName <<EOFSSH
mkdir -p \$HOME/tmp
if [ -r \$HOME/.ssh/id_dsa.pub ]
then
	echo "Id DSA found:"
	ls -l \$HOME/.ssh/id_dsa.pub
	cat \$HOME/.ssh/id_dsa.pub
elif [ -r \$HOME/.ssh/id_rsa.pub ]
then
	echo "Id RSA found:"
	ls -l \$HOME/.ssh/id_rsa.pub
	cat \$HOME/.ssh/id_rsa.pub
else
	ssh-keygen -t rsa -N '' -f \$HOME/.ssh/id_rsa
	cat \$HOME/.ssh/id_rsa.pub
fi
chmod go-w \$HOME
echo "$lvsqw_CentralKey" >>\$HOME/.ssh/authorized_keys
echo "$lvsqw_AdditionnalKey" >>\$HOME/.ssh/authorized_keys
chmod 700 \$HOME/.ssh
chmod 600 \$HOME/.ssh/authorized_keys
EOFSSH

done <$gvsqw_TmpFile.lst
}




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).

File content:




Variable explanation:



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 => 
gvsqw_DbRefInstance_sybase => 
gvsqw_DbRefPass_sybase => 
gvsqw_DbRefPort_sybase => 
gvsqw_DbRefType_sybase => 
gvsqw_DbRefUser_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_RootexpdbExpSybase="~$gvsqw_UserUniqueSybase/SQWareProduction/sybase"
export gvsqw_VersexpdbExpSybase='prod'
export gvsqw_VersDeplexpdbExpSybase='v3.1'
export gvsqw_Mail_sybase='dba'
export gvsqw_MailMsg_sybase='TrtSybAuto'



Variable explanation:

gvsqw_MailMsg_sybase => 
gvsqw_Mail_sybase => 
gvsqw_RootexpdbExpSybase => 
gvsqw_VersDeplexpdbExpSybase => 
gvsqw_VersexpdbExpSybase => 


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_Mail_sybase='default@dbsqware.com'
export gvsqw_MailMsg_sybase='TrtSybAuto'
export gvsqw_UserUniqueSybase='dbsqware'
export gvsqw_RootSQWareProductionSybase="~$gvsqw_UserUniqueSybase/SQWareProduction/sybase"
export gvsqw_VersSQWareProductionSybase='prod'
export gvsqw_VersDeplSQWareProductionSybase='v3.1'
export gvsqw_DistSQWareProdUser_sybase="$gvsqw_UserUniqueSybase@$gvsqw_Hostname"



Variable explanation:

gvsqw_DistSQWareProdUser_sybase => 
gvsqw_MailMsg_sybase => 
gvsqw_Mail_sybase => 
gvsqw_RootSQWareProductionSybase => 
gvsqw_UserUniqueSybase => 
gvsqw_VersDeplSQWareProductionSybase => 
gvsqw_VersSQWareProductionSybase => 


.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'
	  etc_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/etc;ls -al'
	  lst_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/lst;ls -al'
	  auto_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/auto;ls -al'
	  cetc_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/etc_cust;ls -al'
	  clst_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/lst_cust;ls -al'
	  cauto_syb => 'cd $gvsqw_RootexpdbCentral/action/sybase/auto_cust;ls -al'
	  depl_syb => '$gvsqw_RootexpdbCentral/menu/sqwc_MenuAction.ksh sybase sqwsyb_DeplScripts.ksh sqwsyb_GenLstUnique.ksh'
	  repind_syb => '$gvsqw_RootexpdbCentral/bin/sqwc_TrtAuto.ksh sybase sqwsyb_GatherIndicators.ksh sqwsyb_GenLstRepind.ksh NOLOG'
	  repind_syb_dist => '$gvsqw_RootexpdbCentral/bin/sqwc_TrtAuto.ksh sybase sqwsyb_GatherIndicatorsDist.ksh sqwsyb_GenLstRepindDist.ksh NOLOG'
	  gen_syb => '$gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_GenRefSybase.ksh'
	  gen_int => '$gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_GenInterfaces.ksh'
	  menu_syb => '$gvsqw_RootexpdbCentral/menu/sqwc_MenuAction.ksh sybase'




lst

sqwc_Extract_CMDB_Sybase.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_Extract_CMDB_Sybase.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwc_Extract_CMDB_Sybase.ksh.


Query used:

select 'SYB;' || ref.DataServer || ';' || isnull(lic.Hostname,ref.Hostname)|| ';' || ref.Env || ';' || ref.Status || ';' ||
from tsqw_Repository ref 
        on (ref.DataServer = hist.DataServer and hist.Month=convert(smalldatetime,'01'+substring(convert(char(10),getdate(),103),3,8),103))
        on (hist.DataServer = inf.DataServer and hist.Gather_date = inf.Gather_date)
order by 1


sqwc_GenInterfaces.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwc_GenInterfaces.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwc_GenInterfaces.ksh.


Query used:

echo "# interfaces file generated by SQWareCentral (module of dbSQWare) from SQWareRepository" > $lvsqw_FicRef
select '#'+Env+', '+Client+', '+Contact+', '+Comments+char(10)
from tsqw_Repository
where Status!='OFF'
order by DataServer


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_GenLstDataserverDist.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstDataserverDist.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstDataserverDist.ksh.
Generation of the list of Sybase dataservers for distant connection (tsqw_Repository)

Query used:

select convert(varchar(70),Virt_Hostname+' '+Username+' '+DataServer)
from tsqw_Repository
where Status in ('DIST','MIX')
order by Virt_Hostname, Username


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 in ('ON','MIX')
order by Virt_Hostname, Username


sqwsyb_GenLstDataserverSsh.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstDataserverSsh.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstDataserverSsh.ksh.
Generation of the list of Sybase dataservers for ssh connection

Query used:

select convert(varchar(70),ref.Virt_Hostname+' '+cust.Username+' '+ref.DataServer)
from tsqw_Repository ref, tsqw_UserSsh cust
where ref.Status != 'OFF'
and cust.Status = 'ON'
and ref.DataServer = cust.DataServer
order by ref.Virt_Hostname, cust.Username


sqwsyb_GenLstDataserverSshNew.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstDataserverSshNew.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstDataserverSshNew.ksh.
Generation of the list of Sybase dataservers for ssh connection

Query used:

select convert(varchar(70),ref.Virt_Hostname+' '+cust.Username+' '+ref.DataServer)
from tsqw_Repository ref, tsqw_UserSsh cust
where ref.Status != 'OFF'
and cust.Status = 'NEW'
and ref.DataServer = cust.DataServer
order by ref.Virt_Hostname, cust.Username


sqwsyb_GenLstNewDataserver.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstNewDataserver.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstNewDataserver.ksh.
Generation of the list of Sybase new dataservers (tsqw_Repository)

Query used:

select convert(varchar(70),Virt_Hostname+' '+Username+' '+DataServer)
from tsqw_Repository
where Status = 'NEW'
order by Virt_Hostname, Username


sqwsyb_GenLstNewUnique.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstNewUnique.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstNewUnique.ksh.
Generation of the new user unique list (tsqw_Repository)

Query used:

select distinct Hostname||' $gvsqw_UserUniqueSybase'
from tsqw_Repository
where Status = 'NEW'


sqwsyb_GenLstRepindDist.ksh

List generator $gvsqw_RootexpdbCentral/action/sybase/lst/sqwsyb_GenLstRepindDist.ksh:
Can be replaced by $gvsqw_RootexpdbCentral/action/sybase/lst_cust/sqwsyb_GenLstRepindDist.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 in ('DIST','MIX')
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_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 in ('ON','MIX')
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 in ('ON','MIX')
select distinct Hostname||' $gvsqw_UserUniqueSybase'
from tsqw_RepositoryOther
order by 1