Setting up the pin_virtual_time utility
1. Go to the BRM_home/sys/test directory.
2. Run this command to create a file that pin_virtual_time requires, called pin_virtual_time_file:
pin_virtual_time -m 0 -f BRM_home/bin/pin_virtual_time_file
Note BRM_home/lib/pin_virtual_time_file is the standard path and file name, but you can change it.
3. Add the following entry to the configuration file in the BRM_home/sys/test directory:
– – pin_virtual_time pin_virtual_time_file
Replace pin_virtual_time_file with the path and name of the mapped file created in the previous step.
Adding the entry to the configuration file in sys/test enables you to run pin_virtual_time from that directory. The directory from which you run pin_virtual_time must contain a configuration file with the pin_virtual_time entry.
4. Add the entry in step 3 to the configuration file for each program you want to respond to an altered time.
To test your price list, edit the configuration files for at least these applications:
Application
Configuration file location
CM
sys/cm/
Oracle DM
sys/dm_oracle/
Billing and invoice utilities
apps/pin_billd/
sample_act utility
source/apps/sample
To ensure that all applications respond to pin_virtual_time changes, add the entry to all the configuration files in your test BRM system.
Entry example:
– – pin_virtual_time BRM_home/bin/pin_virtual_time_file
For more information on the pin_virtual_time utility, see pin_virtual_time. For more information on configuration files, see About configuration and properties files.
Running pin_virtual_time
After you set up the pin_virtual_time utility, run pin_virtual_time to advance the BRM date and time.
Syntax for pin_virtual_time:
pin_virtual_time -m 2 MMDDHHMM[CC]YY.[SS]
For the string MMDDHHMM[CC]YY.[SS], enter the date and time you want BRM to use in this format: month, date, hour, minute, year, and seconds. You must enter at least two digits for the year, but you can enter four. Seconds are optional.
For example, to set the date and time to 9/3/99 and 11:30, respectively:
example% pin_virtual_time -m 2 090311301999.00
The command displays this message at the command prompt:
filename BRM_home/lib/pin_virtual_time_file, mode 2, time: Fri Sept 03 11:30:00 1999
The time then advances normally from the new reset time.