Initializing TotalView
When TotalView begins executing, it reads initialization and startup information from a number of files. The two most common are initialization files that you create and preference files that TotalView creates.
*It is sometimes desirable to bypass defaults that have been set in either a global or a private initialization file. To bypass the default execution of startup scripts, you can specify -no_startup_scripts on the TotalView startup command line.
An initialization file stores CLI functions, set variables, and execute actions that TotalView interprets when it begins executing. This file, which you must name tvdrc, resides in the .totalview subdirectory contained in your home directory. TotalView creates this directory for you the first time it executes.
TotalView can read more than one initialization file. You can place these files in your installation directory, the .totalview subdirectory, the directory in which you invoke TotalView, or the directory in which the program resides. If an initialization file is present in one or all of these places, TotalView reads and executes each. Only the initialization file in your .totalview directory has the name tvdrc. The other initialization files have the name .tvdrc. That is, a dot precedes the file name.
*Before Version 6.0, you placed your personal .tvdrc file in your home directory. If you do not move this file to the .totalview directory, TotalView will still find it. However, if you also have a tvdrc file in the .totalview directory, TotalView ignores the .tvdrc file in your home directory.
TotalView automatically writes your preferences file to your .totalview subdirectory. Its name is preferences6.tvd. Do not modify this file as TotalView overwrites it when it saves your preferences.
If you add the -s filename option to either the totalview or totalviewcli shell command, TotalView executes the CLI commands contained in filename. This start­up file executes after a tvdrc file executes. The -s option lets you, for example, initialize the debugging state of your program, run the program you’re debugging until it reaches some point where you’re ready to begin debugging, and even create a shell command that starts the CLI.
Figure 25 shows the order in which TotalView executes initialization and startup files.
Figure 25: Startup and Initialization Sequence
The .Xdefaults file, which is actually read by the server when you start X Windows, is only used by the GUI. The CLI ignores it.
The tvdinit.tvd file resides in the TotalView lib directory. It contains startup macros that TotalView requires. Do not edit this file. Instead, if you want to globally set a variable or define or run a CLI macro, create a file named .tvdrc and place it in the TotalView lib directory.
As part of the initialization process, TotalView exports three environment variables into your environment: LM_LICENSE_FILE, TVROOT, and either SHLIB_PATH or LD_LIBRARY_PATH.
If you have saved an action point file to the same subdirectory as your program, TotalView automatically reads the information in this file when it loads your program.
You can also invoke scripts by naming them in the TV::process_load_callbacks list. For information on using this variable, see the “Variables” chapter of the TotalView Reference Guide.
If you are debugging multi-process programs that run on more than one computer, TotalView caches library information in the .totalview subdirectory. If you want to move this cache to another location, set TV::library_cache_directory to this location. TotalView can share the files in this cache directory among users.
 
RELATED TOPICS 
 
The TV::process_load_callbacks variable
"TotalView Variables" in the TotalView Reference Guide
Saving action points