annotate
apropos
catcr
catcs
cc.icon
cc.magic
cd
chactivity
chbl
checkin
checkout
checkvob
chevent
chflevel
chfolder
chmaster
chpool
chproject
chstream
chtype
chview
clearaudit
clearbug
cleardescribe
cleardiffbl
cleardiff
clearexport_ccase
clearexport_cvs
clearexport_pvcs
clearexport_rcs
clearexport_sccs
clearexport_ssafe
clearfsimport
cleargetlog
clearhistory
clearimport
clearjoinproj
clearlicense
clearmake
clearmake.options
clearmrgman
clearprojexp
clearprompt
cleartool
clearviewupdate
clearvobadmin
comments
config_ccase
config_spec
cptype
credmap
creds
deliver
describe
diffbl
diffcr
diff
dospace
edcs
endview
env_ccase
events_ccase
export_mvfs
exports_ccase
file
find
findmerge
fmt_ccase
getcache
get
getlog
help
hostinfo
init_ccase
ln
lock
lsactivity
lsbl
lscheckout
lsclients
lscomp
lsdo
lsfolder
lshistory
ls
lslock
lsmaster
lspool
lsprivate
lsproject
lsregion
lsreplica
lssite
lsstgloc
lsstream
lstype
lsview
lsvob
lsvtree
makefile_aix
makefile_ccase
makefile_gnu
makefile_pmake
makefile_smake
makefile_sun
man
merge
mkactivity
mkattr
mkattype
mkbl
mkbranch
mkbrtype
mkcomp
mkdir
mkelem
mkeltype
mkfolder
mkhlink
mkhltype
mklabel
mklbtype
mkpool
mkproject
mkregion
mkstgloc
mkstream
mktag
mktrigger
mktrtype
mkview
mkvob
mount_ccase
mount
msdostext_mode
mvfslog
mvfsstorage
mvfstime
mvfsversion
mv
omake
pathnames_ccase
permissions
profile_ccase
promote_server
protect
protectvob
pwd
pwv
query_language
quit
rebase
recoverview
reformatview
reformatvob
register
relocate
rename
reqmaster
reserve
rgy_backup
rgy_check
rgy_passwd
rgy_switchover
rmactivity
rmattr
rmbl
rmbranch
rmcomp
rmdo
rmelem
rmfolder
rmhlink
rmlabel
rmmerge
rmname
rmpool
rmproject
rmregion
rmstgloc
rmstream
rmtag
rmtrigger
rmtype
rmver
rmview
rmvob
schedule
schemes
scrubber
setactivity
setcache
setcs
setplevel
setsite
setview
shell
snapshot.conf
softbench_ccase
space
startview
type_manager
umount
uncheckout
unlock
unregister
unreserve
update
version_selector
view_scrubber
vob_restore
vob_scrubber
vob_sidwalk
vob_snapshot
vob_snapshot_setup
wildcards_ccase
winkin
xclearcase
xcleardiff
xmldiffmrg
DESCRIPTION
Note: clearaudit is applicable to dynamic views only.
The clearaudit command runs an audited shell with the same view and working directory as the current process. MVFS files created within an audited shell (or any of its children) are derived objects (DOs). When it exits, an audited shell creates a configuration record (CR) and associates it with each of the newly created DOs.
The CR and DOs produced by clearaudit are similar to those created by clearmake. They can be listed, compared, and deleted with the same cleartool commands used for other DOs (see below). They can be shared with other views through explicit winkin commands, but they cannot be winked in by clearmake. They can be checked in as DO versions. For more information about configuration records, see Building Software.
clearaudit itself is not a shell. It starts an audit and then executes an underlying shell. clearaudit determines which shell to run as follows:
- First choice: the value of environment variable CLEARAUDIT_SHELL, which must be the full pathname of a program.
- Second choice: the value of the UNIX environment variable SHELL,or the Windows environment variable COMSPEC. These environment variables must be set to the full pathname of a program.
- If no EV is set: the Bourne shell, /bin/sh (UNIX) or cmd.exe (Windows).
View Context
On UNIX systems, the process from which you invoke clearaudit must have a view context: set view or working directory view. In either case, the audited process is set to that view. An error occurs if the invoking process has no view context or if its working directory view differs from its set view. (See the pwv reference page.)
On Windows systems as well, the process from which you invoke clearaudit must have a view context for the audited process. An error occurs if the invoking process has no view context.
Location of Temporary Build Files
clearaudit creates temporary build files in the directory specified by the CCASE_AUDIT_TMPDIR environment variable. If this EV is not set or is set to an empty value, clearaudit creates temporary files in the directory specified as follows:
- On UNIX systems, by the TMPDIR environment variable. If neither EV is set, clearaudit creates temporary files in the /tmp directory.
- On Windows systems, by the TMP environment variable.
All temporary files are deleted when clearaudit exits. If the value of CCASE_AUDIT_TMPDIR is a directory under a VOB tag, clearaudit prints an error message and exits.
Auditing Any Process
clearaudit can be used to document the work performed by any process. For example, you can use clearaudit to audit the creation of a UNIX tar(1) file or a Windows backup operation, producing a configuration record that describes exactly which files and/or versions were archived.
Auditing a Non-ClearCase make
You can also use clearaudit to produce derived objects and configuration records for software builds performed with another make program, such as UNIX make(1) or Windows nmake. Follow these guidelines:
- On
UNIX systems:
- Set the value of SHELL to /opt/rational/bin/clearaudit in the makefile.
- Set your process's CLEARAUDIT_SHELL environment variable to your normal shell, for example, /bin/sh. This prevents recursive invocation of clearaudit: if CLEARAUDIT_SHELL is not set, clearaudit attempts to start the shell specified in SHELL, which was set to clearaudit.
- If you want to produce a single CR for each target's build script, structure your makefiles so that each build script is a single shell command. Use continuation lines (\) as necessary.
- On
Windows systems:
- Set the value of COMSPEC to ccase-home-dir\bin\clearaudit in the makefile.
- Set your process's CLEARAUDIT_SHELL environment variable to your normal shell, for example,%SYSTEMROOT%\system32\cmd.exe. This prevents recursive invocation of clearaudit: if CLEARAUDIT_SHELL is not set, clearaudit attempts to start the shell specified in COMSPEC, which was set to clearaudit.
- If you want to produce a single CR for each target's build script, structure your makefiles so that each build script is a single shell command. Use continuation lines (^) as necessary.
OPTIONS AND ARGUMENTS
- –c (UNIX) or /c (Windows)
- Most UNIX shells (including sh, csh, tcsh,
and ksh) and some Windows shells (including cmd.exe),
require the use of this option, which tells the shell what command to execute.
This option must precede any shell_cmd arguments.
- shell_cmd
- One or more words, which are passed as
arguments to $CLEARAUDIT_SHELL, $SHELL,
or /bin/sh (UNIX); or to %CLEARAUDIT_SHELL%, %COMSPEC%, or cmd.exe (Windows).
EXAMPLES
- Run program myscr in an audited C shell.
- Run program validation_suite in an audited third-party shell tool.
- This
example shows a typical CR produced by clearaudit. It describes
all files produced by a software build with UNIX make.
View-private files are marked with time stamps.
Target ClearAudit_Shell built by block.user
Host "starfield" running IRIX 4.0.1 (IP6)
Reference Time 16-May-99.10:24:08, this audit started
16-May-99.10:24:08
View was starfield:/usr/people/block/cc_views/view.bl62
Initial working directory was /vobs/doc/reference_man/test
----------------------------
MVFS objects:
----------------------------
/vobs/doc/reference_man/test/hello@@16-May.10:25.16742
/vobs/doc/reference_man/test/hello.c <16-May-99.10:11:34>
/vobs/doc/reference_man/test/hello.o@@16-May.10:25.16740
/vobs/doc/reference_man/test/makefile <16-May-99.10:23:57> - Run a batch file that performs a backup in an audited shell; create an empty derived object (bkup_do) whose CR lists all of the backed-up objects.