IPnom Home • Manuals • ClearCase

 Rational ClearCase Commands Reference

ClearCase Stuff:ClearCase LinksClearCase BooksClearCase Commands ReferenceClearCase ForumsClearCase News
Keyword Live Search (10 results max):
 Type in part of a ClearCase command in the search box.
 
Commands Index:
  intro
  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

mkpool

Creates a VOB storage pool or modifies its scrubbing parameters

APPLICABILITY

ProductCommand type
ClearCasecleartool subcommand

Platform
UNIX
Windows

SYNOPSIS

  • UNIX only—Create source pool:
    mkpool –sou·rce [ –ln pname ]
    [ –c·omment comment | –cfi·le comment-file-pname | –cq·uery
    | –cqe·ach | –nc·omment ] pool-selector ...

  • UNIX only—Create derived object pool or cleartext pool:
    mkpool { –der·ived | –cle·artext } [ –ln pname ]
    [ –siz·e max-kbytes reclaim-kbytes [ –age hours ]
    [ –ale·rt command ] ]
    [ –c·omment comment | –cfi·le comment-file-pname | –cq·uery
    | –cqe·ach | –nc·omment ] pool-selector ...

  • Windows only—Create source pool:
    mkpool –sou·rce
    [ –c·omment comment | –cfi·le comment-file-pname | –cq·uery
    | –cqe·ach | –nc·omment ] pool-selector ...

  • Windows only—Create derived object pool or cleartext pool:
    mkpool { –der·ived | –cle·artext }
    [ –siz·e max-kbytes reclaim-kbytes [ –age hours ]
    [ –ale·rt command ] ]
    [ –c·omment comment | –cfi·le comment-file-pname | –cq·uery
    | –cqe·ach | –nc·omment ] pool-selector ...

  • Update pool parameters:
    mkpool –upd·ate [ –siz·e max-kbytes reclaim-kbytes ] [ –age hours ]
    [ –ale·rt command ]
    [ –c·omment comment | –cfi·le comment-file-pname | –cq·uery
    | –cqe·ach | –nc·omment ] pool-selector ...

DESCRIPTION

The mkpool command creates a source storage pool, derived object storage pool, or cleartext storage pool, and initializes the pool's scrubbing parameters. You can also use this command to update the scrubbing parameters of an existing storage pool.

Storage pools are directories used as physical storage areas for different kinds of data:

  • A source storage pool stores the data containers that contain versions of elements.
  • A derived object storage pool stores shared derived objects—those that are referenced by more than one view.
  • A cleartext storage pool is a cache of text files. If an element's versions are stored in a compressed format, accessing a particular version involves some processing overhead; a type manager program is invoked to extract the cleartext of that version from the data container. As a performance optimization, the extracted version is cached as a file in a cleartext storage pool. The next access to that same version uses the cached copy, saving the cost of extracting the version from the data container again.

Creating a new VOB with the mkvob command creates one default pool of each kind: sdft (source pool), ddft (derived object pool), and cdft (cleartext pool).

mkpool creates a storage pool as a directory within the VOB storage area. Source pools are always created within subdirectory s of the VOB storage directory; derived object pools are created within subdirectory d; cleartext pools are created within subdirectory c. The –ln option allows you to create pools elsewhere, to be accessed at the standard locations through symbolic links.

Pool Allocation and Inheritance

Each file element is assigned to one source pool and one cleartext pool. The source pool provides permanent storage, in one or more data container files, for all of the element's versions. If the element's versions are stored in a compressed format, the cleartext pool is used to cache extracted versions of that element, as described earlier. (If each version is stored uncompressed in a separate data container, the cleartext pool is not used.)

Each directory element is also assigned to one source pool and one cleartext pool. But directory versions themselves are not stored in these pools. (They are stored directly in the VOB database.) Rather, a directory's pool assignments are used solely for pool inheritance: each element created within the directory inherits its source and cleartext pool assignments.

Each directory element is also assigned to one derived object pool. All shared derived objects with pathnames in that directory are stored in that pool. A new directory element inherits the derived object pool of its parent, along with the source and cleartext pools.

The pool inheritance scheme begins at the VOB root directory (top-level directory element) created by mkvob, which is automatically assigned to the default pools.

You can change any of an element's pool assignments with the chpool command.

Scrubbing

Scrubbing is the process of reclaiming space in a derived object pool or cleartext pool. (Source pools are not subject to scrubbing.) This process is performed by the scrubber utility. mkpool initializes or updates these scrubbing parameters:

maximum size (max-kbytes) Maximum pool size
reclaim size(reclaim-kbytes) Size to which scrubber attempts to reduce the pool
age(hours) Threshold to prevent premature scrubbing of recently referenced objects

The default settings for the scrubbing parameters are max-kbytes = 0, reclaim-kbytes = 0, hours = 96. See the scrubber reference page for details on how these parameters are interpreted.

By default, the scheduler runs scrubber periodically. See the schedule reference page for information on describing and changing scheduled jobs.

Getting Information on Storage Pools

The lspool command lists a VOB's storage pools. If you include the –long option, the current settings of the scrubbing parameters are listed, as well. (The describe –pool command displays the same information as lspool –long.)

RESTRICTIONS

Identities

You must have one of the following identities:

  • VOB owner
  • root (UNIX)
  • Member of the ClearCase administrators group (Windows)

Locks

An error occurs if one or more of these objects are locked: VOB, pool (for -update only).

Mastership

(Replicated VOBs only) No mastership restrictions.

OPTIONS AND ARGUMENTS

Specifying the Kind of Storage Pool / Specifying an Update

Default
You must specify the kind of pool, unless you use –update and name an existing pool. The following options are mutually exclusive.

–sou·rce
Creates a source pool.

–der·ived
Creates a derived object pool.

–cle·artext
Creates a cleartext pool.

–upd·ate
Asserts that the parameters of an existing pool are to be updated. You must also use a –size and/or –age option.

Local vs. Remote Storage

Default
Creates a storage pool as a subdirectory under the VOB storage directory.

–ln pname
Creates a storage pool directory at pname, and creates pool-name in the VOB storage directory as a symbolic link to pname. You can create only one pool when using this option.

Restriction: pname must be a full pathname, starting with a slash (/). It must also be a global pathname, valid on every host from which users will access the VOB. mkpool attempts to verify that this pathname is truly global, using a simple heuristic. (For example, a pathname that begins with /net is likely to be global.) If it suspects that pname is not global, mkpool proceeds anyway, but displays a warning message:

Warning: Linktext for pool does not appear to be a global path.

This mechanism is independent of the network storage registry facility. Thus, the pathname to a remote storage pool directory must be truly global, not global within a particular network region.

Caution: We recommend that you keep source pools local, within the VOB storage directory. This strategy optimizes data integrity: a single disk partition contains all of the VOB's essential data. It also simplifies backup/restore procedures.

Specifying New Parameters

Default
For a new derived object or cleartext pool: the maximum size and reclaim size parameters are set to 0, which enables a special scrubbing procedure. (See the scrubber reference page.) The age parameter is set to 96 (hours). These parameters are meaningless for a source pool.

When updating an existing pool, you must use at least one of –size and –age.

–siz·e max-kbytes reclaim-kbytes
Specifies that the pool is scrubbed if its size exceeds max-kbytes KB; scrubbing will continues until the pool reaches the goal size of reclaim-kbytes KB.

–age hours
Prevents scrubbing of derived objects or cleartext files that have been referenced within the specified number of hours. Specifying –age 0 restores the default age setting (96 hours).

Scrubber Failure Processing

Default
If scrubber fails to scrub a pool below its max-kbytes level, it logs a warning message in /var/adm/rational/clearcase/log/scrubber_log (UNIX) or the Windows event log, but takes no other action.

–ale·rt command
Causes scrubber to run the specified command (typically, a shell script or batch file) whenever it fails to scrub a pool below its max-kbytes level.

Windows: If you invoke a command built in to the Windows shell (for example, cd, del, dir, or copy) instead of a batch file, you must invoke the shell with cmd /c. For example:

–alert 'cmd /c cd \tmp & del *.*' 

Event Records and Comments

Default
Creates one or more event records, with commenting controlled by your .clearcase_profile file (default: –cqe). See the comments reference page. Comments can be edited with chevent.

–c·omment comment | –cfi·le comment-file-pname |–cq·uery | –cqe·ach | –nc·omment
Overrides the default with the option you specify. See the comments reference page.

Specifying the Pool

Default
Creates or updates a pool in the VOB containing the current working directory unless you specify another VOB with the @vob-selector suffix.

pool-selector ...
One or more names for the storage pools to be created. Specify pool-selector in the form [pool:]pool-name[@vob-selector]
pool-name Name of the storage pool

See the cleartool reference page for rules about composing names.

vob-selector VOB specifier

Specify vob-selector in the form [vob:]pname-in-vob

 pname-in-vob Pathname of the VOB tag (whether or not the VOB is mounted) or of any file system object within the VOB (if the VOB is mounted)

EXAMPLES

The UNIX examples in this section are written for use in csh. If you use another shell, you may need to use different quoting and escaping conventions.

The Windows examples that include wildcards or quoting are written for use in cleartool interactive mode. If you use cleartool single-command mode, you may need to change the wildcards and quoting to make your command interpreter process the command appropriately.

In cleartool single-command mode, cmd-context represents the UNIX shell or Windows command interpreter prompt, followed by the cleartool command. In cleartool interactive mode, cmd-context represents the interactive cleartool prompt.

  • Create a source pool that uses the default pool parameters.

    cmd-context mkpool –source –c "pool for c source files" c_pool 
    Created pool "c_pool".

  • Create a derived object pool with a maximum size of 10,000 KB (10 MB) and a reclaim size of 8,000 KB (8 MB). Allow the age parameter to assume its default value.

    cmd-context mkpool –derived –nc –size 10000 8000 do1 
    Created pool "do1".

  • Update the derived object pool created in the previous example, so that any derived object referenced within the last week (168 hours) is not scrubbed.

    cmd-context mkpool –nc –update –age 168 do1
    Updated pool "do1". 

  • On a UNIX system, create a nonlocal cleartext storage pool at the globally accessible location /usr/vobstore/ccase_pools/c2, to be accessed as pool cltxt2.

    cmd-context mkpool –nc –cleartext –ln /usr/vobstore/ccase_pools/c2 cltxt2 
    Created pool "cltxt2".

    This command creates this symbolic link:

    vob-storage-dir-pname/c/cltxt –> /usr/vobstore/ccase_pools/c2

  • Create a cleartext pool named my_ctpool that uses the default pool parameters. Then, change all elements using pool cdft (the default cleartext pool) to use my_ctpool instead.

    cmd-context mkpool -cleartext -c "alternate cleartext pool" my_ctpool 
    Created pool "my_ctpool".
    cmd-context find . -all -element 'pool(cdft)' -exec 'cleartool chpool ^ 
    -force my_ctpool $CLEARCASE_PN'
     
    Changed pool for "\users_hw" to "my_ctpool".
    Changed pool for "\users_hw\bin" to "my_ctpool".
    Changed pool for "\users_hw\bin\hello" to "my_ctpool".
    Changed pool for "\users_hw\bugs" to "my_ctpool".
    Changed pool for "\users_hw\bugs\bug.report.21" to "my_ctpool".
    Changed pool for "\users_hw\doc" to "my_ctpool".
    Changed pool for "\users_hw\doc\util.doc" to "my_ctpool".
    Changed pool for "\users_hw\include" to "my_ctpool".
    Changed pool for "\users_hw\libs" to "my_ctpool".
    Changed pool for "\users_hw\libs\libntx.a" to "my_ctpool".
    Changed pool for "\users_hw\libs\libpvt.a" to "my_ctpool"
    .
    .
    .

SPONSORED LINKS



 

ClearCase Links • ClearCase Books • ClearCase Commands Reference • ClearCase Forums • ClearCase News