Difference between revisions of "Template:SQWareProduction sqwora ExpdpAllSchemas.ksh example"
m (Updated by BatchUser) |
m (Updated by BatchUser) |
||
Line 1: | Line 1: | ||
<pre> | <pre> | ||
− | Sourcing sqwora_Global.lib v2024. | + | Sourcing sqwora_Global.lib v2024.02 SQWareProduction for Oracle (dbSQWare) ... |
#Standard help for script sqwora_ExpdpAllSchemas.ksh: | #Standard help for script sqwora_ExpdpAllSchemas.ksh: | ||
− | + | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -h | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -h | ||
Line 17: | Line 11: | ||
$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -Locale en -h | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -Locale en -h | ||
− | #Display online help for this script with forcing of the 'en' locale (default locale managed by | + | #Display online help for this script with forcing of the 'en' locale (by default locale managed by $gvsqw_Locale) |
$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -s | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -s | ||
#Display usage examples for this script | #Display usage examples for this script | ||
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh - | + | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID |
− | # | + | #Generate commands but don't execute them ! |
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -Exec | ||
+ | #Export Oracle schemas and structure | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -IS 'thisone,thatone' -Exec | ||
+ | #List of schemas to include in the copy : thisone and thatone (by default all). | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -ES 'thisotherone,thatotherone' -Exec | ||
+ | #List of schemas to exclude in the copy : thisotherone and thatotherone | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -IL '%_PROD' -Exec | ||
+ | #Clause like to generate dynamic schemas list to include (example: 'sch%'). | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -EL '%_TESTS' -Exec | ||
+ | #Clause like to generate dynamic schemas list to exclude (example: 'nosch%')." | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -WCD '<condition>' -Exec | ||
+ | #Clause where to generate dynamic schemas list to include (example: 'OPEN_MODE=MOUNTED') | ||
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh - | + | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -DIR <DirExport> -ZIP <ZipExtension> -Exec |
− | # | + | #Execute generated commands and export data to directory <DirExport> and compress them (gz,bz2,Z,none) |
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID - | + | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -PutInf <user@host:path> -Exec |
− | # | + | #Export all schema and copy dump files to path <host:path> |
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID - | + | $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -Pdb <pdb_name> -Exec |
− | # | + | #Specify pugable database name <pdb_name> for multitenant environnements |
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID - | + | $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -HI <NbGeneration> -Exec |
− | # | + | #define the number of expdp version of data to keep for this job |
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID - | + | $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -AGR 20 -Exec |
− | # | + | #Set the waiting time in seconds between two command run, 20s here (by default is 0 manage by $lvsqw_AggressivenessRun) |
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID - | + | $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -AGE 40 -Exec |
− | # | + | #Set the waiting time in seconds between two end checks, 40s here (by default is 5 manage by $lvsqw_AggressivenessCheckEnd) |
− | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID - | + | $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -PS <NumericValue> -Exec |
− | # | + | #Number of PDB to process in parallel, work only with Oracle Enterprise |
− | |||
− | |||
− | |||
$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -P <NumericValue> -Exec | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -P <NumericValue> -Exec | ||
Line 53: | Line 62: | ||
#Use by default the variable gvsqw_NbThreadXXX in $gvsqw_OraBin/../etc/sqwora_GlobalVar.cfg | #Use by default the variable gvsqw_NbThreadXXX in $gvsqw_OraBin/../etc/sqwora_GlobalVar.cfg | ||
#You can change this default on all your environnement if you set this variable | #You can change this default on all your environnement if you set this variable | ||
+ | #in configuration file $gvsqw_OraBin/../etc_cust/sqwora_GlobalVar.cfg | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -OPT '<options>' -Exec | ||
+ | #Add the option(s) <options> to the expdp job | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -sysdba -Exec | ||
+ | #Set the user as '/ as sysdba' for the expdp job | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -NoConsistent -Exec | ||
+ | #Remove 'flashback_time=systimestamp' option (set by default) | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -AddMail 'mymail1@mydomaine.com,mymail2@mydomaine.com' -Exec | ||
+ | #Add the mail list to the default address managed by the variable gvsqw_GlobalMail | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -SendReport -Exec | ||
+ | #Send the log by email at the end of the treatment even if there is no error | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -NoMail -Exec | ||
+ | #Disables sending an email on error to $gvsqw_GlobalMail (by default, send on error) | ||
+ | |||
+ | $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_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_sqwora_ExpdpAllSchemas=<NumericValue> | ||
#in configuration file $gvsqw_OraBin/../etc_cust/sqwora_GlobalVar.cfg | #in configuration file $gvsqw_OraBin/../etc_cust/sqwora_GlobalVar.cfg | ||
</pre> | </pre> |
Revision as of 16:10, 7 April 2024
Sourcing sqwora_Global.lib v2024.02 SQWareProduction for Oracle (dbSQWare) ... #Standard help for script sqwora_ExpdpAllSchemas.ksh: $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -h #Display online help for this script $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -Locale en -h #Display online help for this script with forcing of the 'en' locale (by default locale managed by $gvsqw_Locale) $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -s #Display usage examples for this script $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID #Generate commands but don't execute them ! $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -Exec #Export Oracle schemas and structure $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -IS 'thisone,thatone' -Exec #List of schemas to include in the copy : thisone and thatone (by default all). $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -ES 'thisotherone,thatotherone' -Exec #List of schemas to exclude in the copy : thisotherone and thatotherone $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -IL '%_PROD' -Exec #Clause like to generate dynamic schemas list to include (example: 'sch%'). $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -EL '%_TESTS' -Exec #Clause like to generate dynamic schemas list to exclude (example: 'nosch%')." $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -WCD '<condition>' -Exec #Clause where to generate dynamic schemas list to include (example: 'OPEN_MODE=MOUNTED') $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -DIR <DirExport> -ZIP <ZipExtension> -Exec #Execute generated commands and export data to directory <DirExport> and compress them (gz,bz2,Z,none) $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -PutInf <user@host:path> -Exec #Export all schema and copy dump files to path <host:path> $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -Pdb <pdb_name> -Exec #Specify pugable database name <pdb_name> for multitenant environnements $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -HI <NbGeneration> -Exec #define the number of expdp version of data to keep for this job $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -AGR 20 -Exec #Set the waiting time in seconds between two command run, 20s here (by default is 0 manage by $lvsqw_AggressivenessRun) $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -AGE 40 -Exec #Set the waiting time in seconds between two end checks, 40s here (by default is 5 manage by $lvsqw_AggressivenessCheckEnd) $$gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -PS <NumericValue> -Exec #Number of PDB to process in parallel, work only with Oracle Enterprise $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -P <NumericValue> -Exec #Run sqwora_ExpdpAllSchemas.ksh script with a parallel degree of '<NumericValue>' #Use by default the variable gvsqw_NbThreadXXX in $gvsqw_OraBin/../etc/sqwora_GlobalVar.cfg #You can change this default on all your environnement if you set this variable #in configuration file $gvsqw_OraBin/../etc_cust/sqwora_GlobalVar.cfg $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -OPT '<options>' -Exec #Add the option(s) <options> to the expdp job $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -sysdba -Exec #Set the user as '/ as sysdba' for the expdp job $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -NoConsistent -Exec #Remove 'flashback_time=systimestamp' option (set by default) $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -AddMail 'mymail1@mydomaine.com,mymail2@mydomaine.com' -Exec #Add the mail list to the default address managed by the variable gvsqw_GlobalMail $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -SendReport -Exec #Send the log by email at the end of the treatment even if there is no error $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_SID -NoMail -Exec #Disables sending an email on error to $gvsqw_GlobalMail (by default, send on error) $gvsqw_OraBin/sqwora_ExpdpAllSchemas.ksh -I $ORACLE_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_sqwora_ExpdpAllSchemas=<NumericValue> #in configuration file $gvsqw_OraBin/../etc_cust/sqwora_GlobalVar.cfg