Agriculture and Agri-Food Canada
Symbol of the Government of Canada

The NSDB archiving system

The NSDB archive strikes a balance between the conflicting needs of ease of user access to the data, while ensuring the security and integrity of the datasets. The principal features and operations are as follows:
  • The NSDB is on-line and directly accessible by all users of all CanSIS computers.  Full backups to tape of the entire NSDB are done on a monthly basis, and are supplemented by weekly incremental backups.
  • NSDB GIS datasets are sorted and stored in a logical hierarchy of directories and file names:
    1. The NSDB home directory is mounted on all CanSIS computers as $NSDB
    2. The first level subdirectories are named according to the first two letters of the  NSDB-ID (i.e. ca for Canada)
    3. the second level subdirectories are named according to the entire NSDB-ID (i.e. ca/cac003 for SLCs of Canada)
    4. the third level subdirectories are named according to the entire NSDB-ID concatenated with the date of archiving (i.e. ca/cac003/cac003.19950828)
    5. When an NSDB-ID becomes obsolete, that archive is migrated to the superseded directory that exists within each first level subdirectory, using the "supersede" script.
  • Non-spatial Attribute files are stored somewhat differently in the NSDB:
    • Three special directories (smuf, snf and slf exist within each first level subdirectory (e.g. on/snf for Ontario)
    • WIthin these directories, a combination of the file name and date is used to create a unique subdirectory for each version of the attribute file (e.g. on/smuf/waterloo/19940315/ )  The filename iteself and the date on the file are identical to the file as it was received from the author.
  • All files and directories are completely write protected from normal users.
    • all files are owned by root:archive
    • first and second level directories are rwxrwxr-x and owned by root:archive
    • third and lower level directories are r-xr-xr-x, and files are r--r--r--
  • To place a dataset in the archive, the user runs "archive", which transfers the directory to the $nsdb/temp directory, write protects all files, and changes ownerships to a specified archiver, and the group ownership to archive.  After the archiver verifies the dataset, they run the "archive.ok" script, which creates a new date-stamped directory in the NSDB. The names of both the production officer and the archiver are appended to the ARC/INFO log file.
  • Retrievals from the NSDB are done with the "restore" or "arccopy" scripts