Housekeeping (Tmp, Log and Trace File Maintenance)

Temp Files

Dbvisit Standby produces temporary files in the TMPDIR directory (can be specified in the DDC file) every time Dbvisit Standby executes. 

The default location for the TMPDIR variable is in the DBVISIT_BASE/standby/tmp

Default TMPDIR location on Linux: 

/usr/dbvisit/standby/tmp

 

Default TMPDIR location on Windows:

C:\Program Files\dbvisit\standby\tmp

 

The temporary files are automatically deleted when Dbvisit Standby finishes execution.

Do not set REMOVE_TEMP_FILE=N in the Dbvisit Configuration File (DDC) unless instructed by Dbvisit support. If this value is set all temporary files will be NOT be deleted when Dbvisit Standby has completed processing, which can interfere with the next scheduled run.

 

This setting does not apply to Dbvisit Standby trace files. 

Dbvisit Standby Trace Files

Dbvisit Standby trace files are files that are created every time Dbvisit Standby executes, these trace files contain a large amount of information about the execution of Dbvisit Standby and can be sent to Dbvisit support for fast issue resolution.

Trace files are created in the TRCDIR (trace) directory (can be specified in the DDC file). 

The default location for the TRCDIR variable is in the DBVISIT_BASE/standby/trace

Default TRCDIR location on Linux: 

/usr/dbvisit/standby/trace

 

Default TRCDIR location on Windows:

C:\Program Files\dbvisit\standby\trace

 

Dbvisit Standby trace files have the following format:  <pid>_dbvisit_<DDC>_<yyyymmddhhmi>.trc

The trace file start with a number also know as the process number of the process that generated the trace file, it is followed by the name dbvisit, then the DDC name and then the timestamp with extension .trc.

Example:  3118_dbvisit_PROD_200901091322.trc

Dbvisit Standby trace files are automatically deleted according to settings:

 

The following settings (located in the DDC file) can be used to manage the maintenance of the trace files

Variable: NUM_TRACE_TO_KEEP
Default value: 100

Description: Number of Dbvisit trace files to keep, and Dbvisit Standby will delete trace files greater than this number.  Deletes oldest trace file first.

Variable: DAYS_TO_KEEP_TRACE
Default value: 10 (in days)

Description: Number of days to keep Dbvisit trace files, Dbvisit Standby will delete trace files that are older than the value specified for this variable.

Least restrictive setting applies between DAYS_TO_KEEP_TRACE and NUM_TRACE_TO_KEEP.  

To turn off these maintenance settings, set to 0.

 

Dbvisit Standby log files

Dbvisit Standby produces two log dbvisit.hist and the Dbvisit Standby Archivelog Management Module (AMM) log file in the format <DDC>_arch_management.logfiles  

The default location for the LOGDIR variable is in the DBVISIT_BASE/standby/log

Default TMPDIR location on Linux: 

/usr/dbvisit/standby/log

 

Default TMPDIR location on Windows:

C:\Program Files\dbvisit\standby\log
 

These logfiles will automatically be kept at a specific size based on the following settings specified in the Dbvisit Database Configuration File (DDC).

  • LOG_FILE_ROTATE_MAX
  • LOG_FILE_SIZE_MAX_MB

 

Variable:LOG_FILE_ROTATE_MAX

Default Value: 5

Indicates how many backups are made of the log files before it is overwritten.

The first backup will be: dbvisit_hist.log.1
The second backup will be: dbvisit_hist.log.2
etc.

 

Variable: LOG_FILE_SIZE_MAX_MB

Default Value: 5

Indicates the size of the log file before the log file is rotated as above. 

 

The default value of 5, ensures the maximum size of the Dbvisit Standby log file will be 5MB. If the log file is greater than 5MB, it will be copied to a backup log file. 
There will be 5 backup versions of the Dbvisit Standby log file before backup versions of the log file will be overwritten.

 

LOG, TRACE and TMP Directory Locations

 

 

In some cases it might be required to move the default LOG, TRACE and TMP locations for the Dbvisit Standby log, trace and temp files.  

The default location should be sufficient for most environments, but if you do want to move these directories to a different location, you can use the LOGDIR, TRCDIR and TMPDIR directory parameters in the DDC file.  There are also standby equivalent parameters with the _DR at the end (LOGDIR_DR, TRCDIR_DR and TMPDIR_DR).

 

The following parameters can be set in the DDC file to overwrite the default locations of these directories inside DBVISIT_BASE/standby:

LOGDIR=/your_primary_log_dir_location
TRCDIR=/your_primary_trace_dir_location
TMPDIR=/your_primary_temp_dir_location

LOGDIR_DR=/your_standby_server_log_location
TRCDIR_DR=/your_standby_server_trace_location
TMPDIR_DR=/your_standby_server_temp_location

 

How to identify a trace file for a particular process

 

When you execute a Dbvisit Standby process, example the sending and applying of logs.  You will notice the header "banner" being displayed, which contains a process id see example below where it is (pid 10632) 

oracle@dbvlin501[/usr/dbvisit/standby]: ./dbvisit proddb
=============================================================
Dbvisit Standby Database Technology (7.0.01.11254) (pid 10632)
dbvisit started on dbvlin501: Thu Aug 22 23:12:11 2013 ()
=============================================================
...
...
...

 

Now to identify the trace file for this process, review the trace directory under DBVISIT_BASE/standby/trace and search for the file that starts with this process id number - 10632 which will be in the format of <pid>_dbvisit_<ddc>_<timestamp>.trc