CDO$HELP.HLB  —  CDO Commands, DEFINE  REPOSITORY
    Format

      DEFINE REPOSITORY  anchor-name   [ ALTERNATE_ROOT dir-name ] .

1  –  Parameters

1.1  –  anchor-name

    Specifies the OpenVMS directory in which you are creating the
    repository. The directory must be empty. If you specify a
    directory that does not exist, CDO creates one for you in your
    default directory and places the repository files there. Do not
    modify or delete the files created by Oracle CDD/Repository;
    otherwise, you will corrupt your repository.

    If you plan to provide remote access to your repository with
    the ALTERNATE_ROOT parameter, the device associated with the
    anchor name cannot be mounted through the VAX Distributed File
    Service (DFS). Using the ALTERNATE_ROOT parameter lets you move
    binary files to a top-level directory, which reduces the depth of
    directories created. It also allows you to move binary files to
    another disk, reducing I/O contention on the anchor disk.

1.2  –  dir-name

    Specifies your top OpenVMS file directory. (Use a logical name,
    instead of a full node name.) The device associated with the
    directory can be mounted through DFS.

2  –  Description

    The DEFINE REPOSITORY command creates a physical CDO repository.

    Specify the OpenVMS directory where you want the repository to
    reside.

    You can charge disk resources for your repository to a resource
    identifier by setting this identifier as the owner of the files
    DEFINE REPOSITORY creates. First, issue the DEFINE REPOSITORY
    command, which sets the creator as the file owner. Then,
    issue the CHANGE PROTECTION command. This operation requires
    privileges.

    OpenVMS utilities, including the OpenVMS BACKUP utility, cannot
    directly access repository files unless you invoke them from an
    account with system privileges.

                               RESTRICTION

       Do not store any files in the OpenVMS directory that
       contains the repository, except the files created by Oracle
       CDD/Repository. Otherwise, if you decide to delete the
       repository later, Oracle CDD/Repository deletes all files
       in this directory.

       Do not create a repository in your top level directory
       [000000].

       Once a repository is defined using the ALTERNATE_ROOT
       parameter, the alternate root cannot be changed or moved.

       Changing the alternate root means that your binary files
       are no longer under the repository anchor. When you back up
       the repository, you must synchronize the backup of all the
       repository files.

3  –  Remote Access

    You can issue DEFINE REPOSITORY on a local (host) machine, but
    not on a remote (client) machine.

    To make your repository available to remote users, perform the
    following steps:

    1. Ask your system manager to make the ALTERNATE_ROOT directory
       a DFS access point. This action makes the directory and
       subdirectories known to a DFS server.

    2. Issue the DEFINE REPOSITORY command, including an ALTERNATE_
       ROOT parameter. This action permanently associates the
       file directories with the anchor directory. You should not
       explicitly refer to the file directories again. For example:

       DEFINE REPOSITORY DEV1:[PROJECT.CDD]
         ALTERNATE_ROOT DEV2:[PROJECT.FILES]

       For backup purposes, you can choose to move your anchor
       directory to the DFS disk where you store your file
       directories. In this case, you specify the same logical name
       for both anchor and ALTERNATE_ROOT directories. For example:

       DEFINE REPOSITORY DEV1:[PROJECT.CDD]
         ALTERNATE_ROOT DEV1:[PROJECT.FILES]

    To access a repository from a host machine, perform the following
    steps:

    1. Ask your system manager to make the DFS access point available
       on your system. During the DFS mount, the manager identifies
       the access point by the ALTERNATE_ROOT logical name. For
       example, if the DEFINE REPOSITORY command issued at the host
       machine referred to ALTERNATE_ROOT DEV1:[PROJECT.FILES], the
       manager refers to DEV1.

    2. Issue a SET DEFAULT command that includes the full node name
       of the anchor directory. For example:

       SET DEFAULT A_NODE::DEV1:[PROJECT.CDD]

    3. Review the default protection you receive on file directories.
       DFS does not support remote specification of file ACLs. You
       must make any modifications on the host system.

4  –  Repository Templates

    When you install Oracle CDD/Repository on your system,
    the installation procedure creates a template repository
    (CDD$TEMPLATE) and a repository database directory
    (CDD$TEMPLATEDB). CDD$TEMPLATE contains the CDD$PROTOCOL
    directory, which stores all the type definitions Oracle
    CDD/Repository uses to create metadata.

    The DEFINE REPOSITORY command creates several files in the
    specified OpenVMS anchor directory. Oracle CDD/Repository keeps
    directory information in these files in the anchor directory;
    Oracle CDD/Repository does not store directory information with
    the CDO definitions in the Oracle Rdb database.

    Oracle CDD/Repository creates all new CDO repositories from
    CDD$TEMPLATE and CDD$TEMPLATEDB. If, after defining customized
    types in a repository, you want to include these types in all
    subsequent repositories that you create, you must make them part
    of the template.

    To do this, execute the following command procedure:

    $ @SYS$LIBRARY:CDD_BUILD_TEMPLATE.COM -
    _$ repository-anchor-dir  repository-db-anchor-dir

    Use the repository-anchor-dir parameter to specify the repository
    that contains definitions of your customized types. Use the
    repository-db-anchor-dir parameter to specify the empty directory
    that will hold database files.

    Then, rename the CDD$TEMPLATE and CDD$TEMPLATEDB logicals to the
    parameter names you specified.

    After you have assigned the logical name CDD$TEMPLATE to a
    repository, the protocols in that repository's CDD$PROTOCOLS
    directory will be distributed to any new CDO repository you
    create. If you have extended the types supplied by Oracle
    CDD/Repository or if you have created your own types in a
    repository, you may want to assign the logical name CDD$TEMPLATE
    to that repository so that these types will be copied into
    the CDD$PROTOCOLS directory of any subsequent repositories you
    create. If CDD$TEMPLATE is not defined, each new repository you
    create will contain only types supplied by Oracle CDD/Repository.

    If you no longer want to use the templates supplied by Oracle
    CDD/Repository and want to use only the customized template
    that you created, delete the original CDD$TEMPLATE and
    CDD$TEMPLATEDB directories. Modify the following lines the
    SYS$STARTUP:CDDSTRTUP.COM command procedure to point to the new
    location of the template:

    $ DEFINE/NOLOG/SYSTEM/EXEC CDD$TEMPLATE device:[CDD$TEMPLATE]
    $ DEFINE/NOLOG/SYSTEM/EXEC CDD$TEMPLATEDB device:[CDD$TEMPLATEDB]

5  –  Examples

  CDO>  DEFINE REPOSITORY DISK1:[BOB.DICT].

      In this example, the DEFINE REPOSITORY command creates a CDO
      repository in a subdirectory called [BOB.DICT]:
Close Help