Template:SQWareProduction sqwcas RollingRestart.ksh example: Difference between revisions
Jump to navigation
Jump to search
m Updated by BatchUser |
No edit summary |
||
(37 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<pre> | <pre> | ||
Sourcing sqwcas_Global.lib | Sourcing sqwcas_Global.lib v2025.06 SQWareProduction for Cassandra (dbSQWare) ... | ||
#Standard help for script sqwcas_RollingRestart.ksh: | #Standard help for script sqwcas_RollingRestart.ksh: | ||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -h | |||
#Display online help for this script | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -Locale en -h | |||
#Display online help for this script with forcing of the 'en' locale (by default locale managed by $gvsqw_Locale) | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -s | |||
#Display usage examples for this script | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -A <Action> -S <scope> | |||
#Display generated commands without execute them ! | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -A <Action> -S <scope> -Exec | |||
#Execute action <Action> (start, stop, restart is default) on the instance $CAS_SID and for the <scope> selected : All, AllDC (by default is locale) or -Dynamic | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I CAS_01 -A 'stop' -Dynamic -Wait 42 -Exec | |||
#Execute stop on the instance CAS_01, for dynamic discovery of nodes and wait 42 secondes between each retart | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -S <scope> -Timeout 1500 -Exec | |||
#Timeout in seconds for kill inactive ssh session (by default is 7200, manage by $gvsqw_TimeOutStop) | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -AddMail 'mymail1@mydomaine.com,mymail2@mydomaine.com' -Exec | |||
#Add the mail list to the default address managed by $gvsqw_GlobalMail (only this time), if needed separate by commas | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -SendReport -Exec | |||
#Send the log by email at the end of the treatment even if there is no error | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -NoMail -Exec | |||
#Disables sending an email on error to $gvsqw_GlobalMail (by default, send on error) | |||
$gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -FRT <NumericValue> -Exec | |||
#Force return code to '<NumericValue>' on error (if no error, "exit 0!") | |||
#You can also force return code of this script on all your | |||
#environnement if you set the variable: $gvsqw_ForcedReturnCodeScript_sqwcas_RollingRestart=<NumericValue> | |||
#in configuration file $gvsqw_CasBin/../etc_cust/sqwcas_GlobalVar.cfg | |||
</pre> | </pre> |
Latest revision as of 18:51, 1 July 2025
Sourcing sqwcas_Global.lib v2025.06 SQWareProduction for Cassandra (dbSQWare) ... #Standard help for script sqwcas_RollingRestart.ksh: $gvsqw_CasBin/sqwcas_RollingRestart.ksh -h #Display online help for this script $gvsqw_CasBin/sqwcas_RollingRestart.ksh -Locale en -h #Display online help for this script with forcing of the 'en' locale (by default locale managed by $gvsqw_Locale) $gvsqw_CasBin/sqwcas_RollingRestart.ksh -s #Display usage examples for this script $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -A <Action> -S <scope> #Display generated commands without execute them ! $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -A <Action> -S <scope> -Exec #Execute action <Action> (start, stop, restart is default) on the instance $CAS_SID and for the <scope> selected : All, AllDC (by default is locale) or -Dynamic $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I CAS_01 -A 'stop' -Dynamic -Wait 42 -Exec #Execute stop on the instance CAS_01, for dynamic discovery of nodes and wait 42 secondes between each retart $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -S <scope> -Timeout 1500 -Exec #Timeout in seconds for kill inactive ssh session (by default is 7200, manage by $gvsqw_TimeOutStop) $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -AddMail 'mymail1@mydomaine.com,mymail2@mydomaine.com' -Exec #Add the mail list to the default address managed by $gvsqw_GlobalMail (only this time), if needed separate by commas $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -SendReport -Exec #Send the log by email at the end of the treatment even if there is no error $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -NoMail -Exec #Disables sending an email on error to $gvsqw_GlobalMail (by default, send on error) $gvsqw_CasBin/sqwcas_RollingRestart.ksh -I $CAS_SID -FRT <NumericValue> -Exec #Force return code to '<NumericValue>' on error (if no error, "exit 0!") #You can also force return code of this script on all your #environnement if you set the variable: $gvsqw_ForcedReturnCodeScript_sqwcas_RollingRestart=<NumericValue> #in configuration file $gvsqw_CasBin/../etc_cust/sqwcas_GlobalVar.cfg