IBM Support

Creating a snapshot view from the command line in ClearCase LT

Question & Answer


Question

How do I create base and UCM snapshot views from the command line interface (CLI) using IBM® Rational® ClearCase LT®?

Answer

Overview

The ClearCase LT server provides storage and access control for all VOBs and views used by a ClearCase LT community.

The server storage location (stgloc) is automatically created on the ClearCase LT server with a special parameter called ngpath (no global path), which allows access to ClearCase LT views and VOBs without using a UNC share.

Note: Additional storage locations can be created manually on the ClearCase LT server; refer to technote 1120024 for more details.

The VOBs must be created directly on the server, refer to technote 1238976 for more details about working in a ClearCase LT interop environment.


Create a Snapshot View from CLI

Snapshot views are created from the clients regardless of what platform is running on the ClearCase LT server.

Note: MultiVersion File System (MVFS) for using dynamic views is not supported by ClearCase LT.

A snapshot view can be created from a Windows client when the view server storage location is on UNIX or Linux, or from UNIX and Linux when the stgloc is on Windows.

This cross-platform functionality for creating snapshot views is limited to ClearCase LT as it is specially designed to work in homogeneous and heterogeneous environments.

Note: When working in a Rational ClearCase heterogeneous environment, snapshot views must be created from a host running the same operating system; refer to technote 1123321 for more details.

Below are the directions for creating base ClearCase and ClearCase UCM snapshot views from CLI.

The command line syntax to create a base ClearCase snapshot view is:


    cleartool mkview -snapshot -tag <tag name> -stgloc <stgloc name>  <local snapshot view path name>

Example:
  • On UNIX and Linux: cleartool mkview -snapshot -tag snap_test -stgloc views /view_store/views/snap_test

  • On Windows: C:\>cleartool mkview -snapshot -tag snap_test -stgloc Views c:\Rational\Storage\views\snap_test

The command line syntax to create a ClearCase UCM snapshot view requires the -stream option:


    cleartool mkview -snapshot -tag <tag name> -stgloc <stgloc name>  -stream <stream-selector> <local snapshot view path name>

Example:
  • On UNIX and Linux: cleartool mkview -snapshot -tag ucm_view -stgloc views -stream prj1_dev@/vobs/pvob1 /view_store/views/ucm_snap

  • On Windows: C:\>cleartool mkview -snapshot -tag ucm_snap -stgloc Views -stream prj1_dev@\PVOB1 c:\Rational\Storage\views\ucm_snap

Review IBM Rational ClearCase Command Reference on the topic of mkview (cleartool man cleartool mkview) for more information.


Add Load Rules

Once the new view has been created, load rules need to be added to the view's config spec to identify the VOB elements that will be loaded into the view:

  1. Change to the view root directory

  2. Run a cleartool edcs command

  3. Edit the config spec from the editor window that is opened

  4. Add the load rules

    Example:
    load \myvob
    load \yourvob


  5. Close the editor window

  6. Respond "y" to the following question to load the view.
    Set config spec and load snapshot view “view-tag”? [yes]

    Note: If you forgot to add all the load rules in the steps above, re-run through those steps again to add additional load rules.

    Review the ClearCase Developing Software manual on the topic of About changing which elements are loaded in a snapshot view for more information.

Refer to the To remove, modify or add load rules when editing the config spec section of the IBM Rational ClearCase Developing Software manual for further information about adding load rules to a snapshot view.

[{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"View: Snapshot","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF010","label":"HP-UX"},{"code":"PF015","label":"IRIX"},{"code":"PF016","label":"Linux"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"7.0.1.1;7.0.1;7.0.0.2;7.0.0.1;7.0;2003.06.16;2003.06.00","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}},{"Product":{"code":"SSSH27","label":"Rational ClearCase"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Interop: CCFS","Platform":[{"code":"","label":""}],"Version":"","Edition":"","Line of Business":{"code":"LOB45","label":"Automation"}}]

Document Information

Modified date:
29 September 2018

UID

swg21121208