Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ bkexcept(1a) — NEWS-os 5.0.1

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

backup(1M)

cpio(1)

ed(1)

incfile(1M)

intro(2)

sh(1)



bkexcept(1M)     SYSTEM ADMINISTRATION COMMANDS      bkexcept(1M)



NAME
     bkexcept - change or display an exception list for incremen-
     tal backups

SYNOPSIS
     bkexcept [-t file] [-d patterns]
     bkexcept [-t file_name] -a|-rpatterns
     bkexcept -C [files]

DESCRIPTION
     The bkexcept command displays a list of patterns  describing
     files  that  are to be excluded when backup operations occur
     using incfile.  The list is known as the  "exception  list".
     bkexcept  may  only  be  executed  by  a user with superuser
     privilege.  bkexcept -a adds patterns to the list.  bkexcept
     -d  displays  patterns  from  the list.  bkexcept -r removes
     patterns from the list.

  Patterns
     Patterns describe individual paths or sets of  paths.   Pat-
     terns  must conform to pathname naming conventions specified
     in intro.  A pattern is taken as a file name and  is  inter-
     preted  in  the  manner  of cpio.  A pattern can include the
     shell special characters *, ?, and  [].   Asterisk  (*)  and
     question  mark  (?)  will  match  period  (.)  and slash(/).
     Because these are shell special  characters,  they  must  be
     escaped on the command line.

     There are three general methods of specifying entries to the
     exception list:
     To specify all files under a particular  directory,  specify
     the directory name (and any desired subdirectories) followed
     by an asterisk:
               /directory/subdirectories/*
     To specify all instances of a  filename  regardless  of  its
     location, specify the filename preceded by an asterisk:
               */filename
     To specify one instance of a particular  file,  specify  the
     entire pathname to the file:
               /directory/subdirectories/filename

     If pattern is a dash (-), standard input is read for a  list
     of patterns (one per line until EOF) to be added or deleted.

  Compatibility
     Prior versions of the backup service created exception lists
     using  ed syntax.  bkexcept -C provides a translation facil-
     ity for exception lists created by ed.  The  translation  is
     not  perfect;  not all ed patterns have equivalents in cpio.
     For those patterns that have no  automatic  translation,  an
     attempt  at  translation is made, and the translated version
     is flagged with the word QUESTIONABLE.  The  exception  list



                                                                1





bkexcept(1M)     SYSTEM ADMINISTRATION COMMANDS      bkexcept(1M)



     translation  is  directed  to standard output.  Redirect the
     standard output to a translation file, review  the  contents
     of  the  translation  file (correcting entries that were not
     translated properly and deleting  the  QUESTIONABLE  flags),
     and  then  use  the  resulting file as input to a subsequent
     bkexcept -a.  For example, if the translated file was  named
     checkfile the -a option would appear as follows:
             bkexcept -a - < checkfile

  Options
     -t file
          The filename used in place of  the  default  file.   -a
          pattern...   Adds  pattern to the exception list.  pat-
          tern is one or a list of patterns  (comma-separated  or
          blank-separated and enclosed in quotes) describing sets
          of paths.

     -d pattern...
          Displays entries in the  exception  list.   If  pattern
          begins  with a slash (/), -d displays all entries whose
          names begin with pattern.  If pattern  does  not  begin
          with a slash, -d displays all entries that include pat-
          tern anywhere in the entry.  If pattern is a dash  (-),
          input  is  taken from standard input.  pattern is not a
          pattern -- it matches patterns.   pattern  a*b  matches
          /a*b  but  does not match /adb.  For files containing a
          carriage return, a null  exception  list  is  returned.
          For  files  of zero length (no characters), an error is
          returned (search of table failed).

            The entries are displayed in ASCII collating sequence
            order (special characters, numbers, then alphabetical
            order).

     -r pattern...
            Removes pattern from the exception list.  pattern  is
            one  or a list of patterns (comma-separated or blank-
            separated and enclosed in quotes) describing sets  of
            paths.  pattern must be an exact match of an entry in
            the exception list for pattern to be  removed.   Pat-
            terns that are removed are echoed to standard output,
            stdout.

     -C[files]
            Displays on standard output the translation  of  each
            file  (a  prior  version's exception list) to the new
            syntax.  file contains ed patterns, one per line.

            If file is omitted, the default UNIX exception  list,
            /etc/save.d/except  is translated.  If file is a dash
            (-), input is taken  from  standard  input,  one  per
            line.



                                                                2





bkexcept(1M)     SYSTEM ADMINISTRATION COMMANDS      bkexcept(1M)



DIAGNOSTICS
     The exit codes for the bkexcept command are the following:

     0 = the task completed successfully
     1 = one or more parameters to bkexcept are invalid
     2 = an error has occurred, causing bkexcept to fail to
           complete all portions of its task

EXAMPLES
     Example 1:

          bkexcept                                             -a
          /tmp/\(*,/var/tmp/\(*,/usr/rje/\(*,\(*/trash,

     adds the four sets of files  to  the  exception  list,  (all
     files  under /tmp, all files under /var/tmp, all files under
     /usr/rje, and any file on the system named "trash").

     Example 2:

          bkexcept -d /tmp

     displays the following patterns  from  those  added  to  the
     exception list in example 1.

          /tmp/*

          bkexcept -d tmp

     displays the following patterns  from  those  added  to  the
     exception list in example 1.

          /tmp/*, /var/tmp/*

     displays one per line, with a heading.

     Example 3:

          bkexcept -r /var/tmp/\(**,/usr/rje/\(**

     removes the two patterns from the exception list.

     Example 4:

          bkexcept -C /save.d/old.except > trans.except

     translates the file /save.d/old.except from its ed format to
     cpio   format   and  sends  the  translations  to  the  file
     trans.except. The translations of /save.d/old.except may  be
     added  to the current exception list by using bkexcept -a as
     follows:
             bkexcept -a - < trans.except



                                                                3





bkexcept(1M)     SYSTEM ADMINISTRATION COMMANDS      bkexcept(1M)



FILES
     /etc/bkup/bkexcept.tab - the default exception list for UNIX
     SVR4.0.
     /etc/save.d/except - the default  exception  list  for  UNIX
     pre-SVR4.0.

SEE ALSO
     backup(1M), cpio(1), ed(1), incfile(1M), intro(2), sh(1)















































                                                                4



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026