MCSE Boot Camp Notes :

Networking Guide
Chapter 18, Distributing files remotely over TCP/IP

Writing a distfile

Writing a distfile

The distfile contains a sequence of entries that specify the files to be copied, the destination hosts, and what operations to perform to do the updating. Each entry has one of the following formats:

variable_name = name_list
Used for defining variables.

[label: ] source_list -> destination_list command_list
Used for distributing files to other hosts. source_list specifies a list of files and/or directories on the local host that are to be used as the master copy for distribution. Each file in the source_list is added to a list of changes if the file is out of date on the host that is being updated.

[ label: ] source_list :: time_stamp_file command_list
Used for making lists of files that have been changed since some given date. Each file in the source_list is added to a list of changes if the file is newer than the timestamp file.
The source and destination lists have one of these two formats:

name
( zero_or_more_names_separated_by_white_space )

If additional modifications are needed (for example, ``all servers and client machines except for the OSF/1 machines''), then the list will have to be explicitly constructed in steps using ``temporary'' variables.

The shell meta-characters ``['', ``]'', ``{'', ``}'', ``'', and ``?'' are recognized and expanded (on the local host only) in the same way as csh(C). They can be escaped with a backslash. The ``~'' character is also expanded in the same way as csh but is expanded separately on the local and destination hosts. When the -owhole option is used with a filename that begins with ``~'', everything except the home directory is appended to the destination name. File names that do not begin with ``/'' or ``~'' use the destination user's home directory as the root directory for the rest of the file name.

The command list consists of zero or more commands with the following formats:

install options opt_dest_name
The install command is used to copy out-of-date files and/or directories. Each source file is copied to each host in the destination list. Directories are recursively copied in the same way. opt_dest_name is an optional parameter to rename files. If no install command appears in the command list or the destination name is not specified, the source filename is used. Directories in the pathname will be created if they do not exist on the remote host. The -odistopts option has the same semantics as on the command line except they only apply to the files in the source list. The login name used on the destination host is the same as the local host unless the destination name is of the format ``login@host''.

notify name_list
The notify command is used to mail the list of updated files (and any errors that may have occurred) to the listed names. If no ``@'' appears in the name, the destination host is appended to the name (for example, name1@host, name2@host, ...).

except name_list
The except command is used to update all of the files in the source list except for the files listed in name_list. This is usually used to copy everything in a directory except certain files. 

except_pat pattern_list
The except_pat command is like the except command except that pattern_list is a list of regular expressions (see the ed(C) manual page for details). If one of the patterns matches some string within a filename, that file will be ignored. Note that since ``\'' is a quote character, it must be doubled to become part of the regular expression. Variables are expanded in pattern_list but not shell file pattern matching characters. To include a ``$'', it must be preceded by the escape character ``\''.

special name_list string
The special command is used to specify sh(C) commands that are to be executed on the remote host after the file in name_list is updated or installed. If the name_list is omitted, then the shell commands will be executed for every file updated or installed. string starts and ends with ``"'' and can cross multiple lines in distfile. Multiple commands to the shell should be separated with ``;''. Commands are executed in the user's home directory on the host being updated. The special command can be used to rebuild private databases, and so forth, after a program has been updated. The following environment variables are set for each special command:

FILE
the full pathname of the local file that was just updated

REMFILE
the full pathname of the remote file that was just updated

cmdspecial name_list string
The cmdspecial command is similar to the special command, except it is executed only when the entire command is completed instead of after each file is updated. The list of files is placed in the environment variable $FILES. Each filename in $FILES is separated by a ``;'' (semicolon).
If a hostname ends in a ``+'', rdist strips it off and disables NFS checking. This is equivalent to disabling the -ochknfs option for this host.

Here is a small example:

A sample distfile

   HOSTS = ( yukon root@arpa)
   

FILES = ( /bin /lib /usr/bin /usr/games /usr/include/{*.h,{stand,sys,vax*,pascal,machine}/*.h} /usr/lib /usr/man/man? /usr/ucb /usr/local/rdist )

EXLIB = ( Mail.rc aliases aliases.dir aliases.pag crontab dshrc sendmail.cf sendmail.fc sendmail.hf sendmail.st uucp vfont )

${FILES} -> ${HOSTS} install -oremove,chknfs ; except /usr/lib/${EXLIB} ; except /usr/games/lib ; special /usr/lib/sendmail "/usr/lib/sendmail -bz" ;

srcs: /usr/src/bin -> arpa except_pat ( \\.o\$ /SCCS\$ ) ;

IMAGEN = (ips dviimp catdvi)

 imagen: /usr/local/${IMAGEN} -> arpa install /usr/local/lib ; notify ralph ;

${FILES} :: stamp.cory notify root@cory ;

Networking guide
Call : 800-519- 2267

MCSE CCNA Certification boot camp
Testimonials
 Join MCSE Boot Camp & CCNA Boot Camp Back to Back Certification Today.
MCSE Boot Camp links  MCSE Boot Camp 270  MCSE Boot Camp  290  MCSE Boot Camp  291  MCSE Boot Camp 293  MCSE Boot Camp  294  MCSE Boot Camp 298  MCSE Boot Camp 299  MCSE Boot Camp Security  MCSE Boot Camp 640-801  MCSE Boot Camp routing MCSE Boot Camp 811  MCSE Boot Camp 821  MCSE Boot Camp 831  MCSE Boot Camp Resources MCSE Boot Camp MCSE + CCNA  MCSE Boot Camp Training  MCSE Boot Camp Card pay  MCSE Boot Camp Papal  MCSE Boot Camp MCSE Notes  MCSE Boot Camp CCNA Notes    MCSE Boot Camp index MCSE Boot Camp main  MCSE Boot Camp root MCSE Boot Camp link  MCSE Boot Camp resources MCSE Boot Camp home    Ref1 Ref2
Microsoft MCSE Boot Camp
MCSE Boot Camp, MCSE Certification boot camp, MCSE Training boot camps, MCSE certification  boot camp training at California and Maryland USA. Also CCNA, CCNP, CISSP, Red Hat Linux Certification notes.

Vibrant boot camp offers MCSE, CCNA, CCNP Certification back to back

Vibrant offers MCSE certification training boot camp for $5400 all inclusive, instructor led at California and Baltimore.

Vibrant Bootcamp Participants come from All Around the World. Vibrant has trained students from more than 15 countries like USA, UK, (Scotland, Ireland, Wales), Switzerland, Germany, Australia, Canada, France, Holland, Japan, Belgium, Bahrain, New Zealand, Tanzania, Turkey, Kenya and more.

Access List Commands, Access Lists, Application Laye - OSI layer, CCNA Bootcamp Notes, CCNA certification bootcamps, CCNA T1 Connections, CDP Setup, Cisco Bootcamp, TCP/IP Info, Cisco Hierarchical Model, Cisco Notes, TCP Ports,  Configure Router Register, Configuring IPX, Configuring VLAN, Data Link Layer, DOD Model, Ethernet Frames, Ethernet Networking, Frame Relay information, HDLC WAN Notes, Host to Host Layer, IP Communication ports, IP Ports,  ISDN settings, LAN Protocols, LAN Segmentation, Lan Switiching, LAPB CCNA Notes, Layer 2 Protocol, Network Access Layer, Network Laye, Cisco Boot camps, Novell Cisco Routing, OSI Layer, OSI Model, CCNP Bootcamps, Physical Layer, OSI Layer, Point to Point Protocol, PPP, PPP Link, Presentation Layer, OSI Layer, Process Application Layer,  Rip Routing Setting, Router Images, Router Information,  Router Interfaces,  Router IOS Backup, Router IOS,  Router Management, Router Password Setup, Router Recover Password, , San Francisco, Router Setup, , California, Router troubleshoot,  Routing Protocol RIP, Session Layer, Subnet Masking, Supported RFCs, Switch Images,  Switching Configuration, Switching Simulation,  TCP/IP Ports,  VLAN Communication,  WAN Communication,