CDBCOPY

Summary

This command copies CDBS catalogs and calibration reference file images and tables from a remote system to a local disk. The command can be run exclusively with command line parameters, or parameters can be read from a disk file. The command can also be run as a pipeline process, CDBCPY.
 

Description

The remote directory (REMOTE_FILESPEC) on the remote machine (REMOTE_MACHINE) is searched for one or more catalog files (ending in "*.cat").  Any that are found are retrieved to the local directory (LOCAL_FILESPEC) using FTP controlled by parameters REMOTE_LOGIN and a user-supplied password.  Each catalog is read and files matching each rootname entry in the catalog are searched for in REMOTE_FILESPEC. If there is sufficient disk space on LOCAL_FILESPEC to hold all the files plus the DISK_SLOP_PERC, they are copied back to LOCAL_FILESPEC. If any catalog entry does not match files in REMOTE_FILESPEC, then the catalog copy is said to have failed, and will be left on the remote machine. If DELETE_AFTER_COPY was selected, then all successfully copied catalogs and calibration files will be deleted from REMOTE_FILESPEC, after they have been confirmed to exist in LOCAL_FILESPEC.

A trailer file is created for each catalog copied from the remote machine. This file will serve as a processing log for the rest of the CDB pipeline processing.

When run in pipeline mode, the name of the catalog to search for on the remote system is obtained from an OSF.  Only this single catalog and the files the catalog contains are retrieved from the remote system in pipeline mode.

Usage

cdbcopy -pa pathfile -cat catalog_name -pw encrypted_passwd | The flags can be specified in any order by any number of unique characters (e.g. -de, -del, and -delete are treated equally).
 

Inputs

Outputs

        CDBS catalog and reference files copied from remote machine to local disk. A trailer file (.trl) is created for each catalog copied from the remote machine.
 

Constraints

Resource File

The following parameters appear in the CDBCPY resource file. Their values can be specified directly in the resource file itself, or setting values to names from the path file, can be pulled through from the path file.

FIREWALL

REMOTE_MACHINE REMOTE_FILESPEC LOCAL_FILESPEC REMOTE_LOGIN (optional) REMOTE_TYPE DISK_SLOP_PERC DELETE_AFTER_COPY ROLLBACK_PARTIAL_COPY TEMP_DIR FILE_TYPE PUT_OR_GET PASSWORD_PROMPT

        Supplies the password prompt for the PMG to use (reminds the user which password is being request of them).
 
 

Command Line Arguments

-cat[alog_name]

        Name of a particular catalog to process.  Used in pipeline mode with a catalog name from the OSF.

-pw[passwd]

        Encrypted password used for FTP login

-pr[ocess_name]

        Used to locate the process resource file in pipeline mode (default=CDBCPY)

-pa[thfile]

-fil[ename] -rm[achine] -rt[ype] -rf[ilespec] -lf[ilespec] -rl[ogin] -ds[lop_percentage] -de[lete_after_copy] -ro[llback_partial_copy] -fir[ewall] -t[emp_directory]
Examples


$ cdbcopy -pa opus_definitions_dir:blue.path -cat opus_10345_u.cat -pw w2e3r4t5r4e3w2

Uses values from the process resource file (opus_definitions_dir:cdbcpy.resource) to determine which remote machine and directories should be searched for the catalog "opus_10345_u.cat" and its files.  The encrypted password supplied is decrypted and used to access the FTP account defined by resource entry REMOTE_LOGIN.

$ cdbcopy -rm ajuga -rt UNIX -rf /home/mswam/data -lf disk$lyra:[mswam.dest] -ds 5 -de

Searches for catalogs on the UNIX machine "ajuga" in the directory "/home/mswam/data". If found, they are copied back to "disk$lyra:[mswam.dest]" if enough disk space plus 5% slop is available. If the files are copied successfully, they are deleted afterwards from the remote host "ajuga".