Several volumes are available to software developers and maintainers for their software - source, dest, common, and object. By default, each volume has five megabytes of quota. Archive volumes are created only for software that is of a critical nature to the operation of the system(e.g. OS source, file system source).
This volume appears as the mountpoint common within the dest volume. For example:
Before deciding to use a common volume, please read Section 6.1, How Depot Organizes Software.
AFS object space may be requested if there are compelling reasons to do so. Such reasons may include the need to retain unstripped binaries for debugging purposes, or because the application is so large and complex that it would be difficult and time-consuming to recreate all objects to test small changes.
/afs/andrew/system/obj/pmax_42/local/gnu-emacs/001
1.2.5 Archive Volumes
The archive tree provides an online reference of unaltered vendor software. Archive volumes are created if the software is of a critical nature to the system and the reading of tapes would be time consuming (e.g. OS source, File system source).A read-only archive tree is rooted at:
/afs/andrew.cmu.edu/system/archive
Currently the vendor's name is used as the top level under archive. For example, a "dec" directory could contain "ultrix.v.2.2." It would be located in:
/afs/andrew.cmu.edu/system/archive/dec/ultrix2_2
In cases where the name of the vendor does not provide an intuitive understanding of the software archived there, other naming conventions may be used. Archive volumes are intended to provide an area where vendor tapes can be unloaded, stored, and easily referenced.
Access to each of these development areas is controlled through pts groups. A pts group is used to assign access privileges to several users at once. For more information on pts groups, see the online help for pts.
1.3.1 The Commanders group
This group contains the userIDs of all of the people who will be part of the development team for a particular application. Each collection is automatically given a pts group named:
sysmaint:<collection>.commanders
For example:
sysmaint:gnu-emacs.commanders
Members of the commanders group can add or delete userIDs from the commander's list.
1.3.2 The Visitors group
In cases where the source files should not be publicly available, a visitors group should be created.This group contains the userIDs of all the people who have been given access to read the source files.
The visitors group is named:
For example:
systmaint:gnu-emacs.visitors
1.3.3 Checking the members of a pts group
To display which users are within a protection group, at the system prompt, type:
For example:
Environment Maintenance Tool, or EMT, is an application used to manage the
collections on AFS automatically. Any operation to create, delete, or release software is processed by EMT. This ensures that everything conforms to the software management structure and that the volumes and symbolic links are constructed properly.
The Gatekeeper (who can be one or more individuals employed by Computing Services), has access to EMT's full functionality within a given tree. Through the carpe program, requests are sent to the Gatekeeper to assign and set up collections, delete collections, or release software to Beta or Gamma. All of these requests are posted to a set of electronic bboards. When requests have been received and processed, they will be posted to the following appropriate bboards.
org.acs.asg.request.<tree>.complete
org.acs.asg.request.<tree>.create.pending
org.acs.asg.request.<tree>.release.beta.pending
org.acs.asg.request.<tree>.release.gamma.pending
org.acs.asg.request.<tree>.delete.pending
For example,
Carpe is an automated way to send requests to the Gatekeeper to create, delete, or release collections.
Carpe is a command line program. All of the necessary information may be included in the first line, or carpe will prompt the user until it has all the information it needs. All carpe commands use the same syntax. To use carpe, at the system prompt, type:
carpe <command> <flags>
To request that the Gatekeeper create a collection, the following information must be provided:
- The name of the tree the software belongs in, for example, host, local or
contributed
- The unique and permanent name of the application collection, for example, gnu-emacs
- The version number needed. Version numbers start at 001 and are
incremented consecutively for each new version
- The system or systems for which the software will be compiled, for example, Sun 4413
- The amount of disk space needed
- The users who should be in the commanders group
- The types of volumes that are needed (source, AFS object, and/or common volumes)
- Whether or not the sources for the new version should be cloned from the sources of an earlier version
The local tree maintainer can create a collection with EMT and may also set the quota of the collection.
For information on how to use EMT, see the online help file for EMT.
2.2.1 Using the carpe interface
To create a volume, at the system prompt type:
Carpe will prompt the user with a series of questions about their collection. To use the default answer, simply press <return> after the question.
Example 1 Using carpe to create a collection
% carpe create
Tree name (default is local):<return>
--------------
Collection name: test
--------------
Enter a list of systems separated by spaces
(default is sun4413 pmax_42):sun4413 <return>
--------------
What version would you like to create (default is 001):<return>
--------------
Would you like source volumes created (default is yes)?<return>
--------------
Would you like AFS object volumes created (default is no)?<return>
--------------
Would you like a common volume created (default is no)?<return>
--------------
This is the first version of a collection
No clone can be made
--------------
How much quota would you like for the source volume (default is 5000)? <return>
How much quota would you like for the dest volumes (default is 5000)? <return>
--------------
What users should be added to the commanders list (default is the user)? kb3t sk4i ez00 mf3s mw5e <return>
--------------
Please enter any additional comments about this request.
End your input with a ^D
this is a test
^D
Carpe will then send the information to the Gatekeeper. The Gatekeeper will use EMT to create the collection and will notify the user when the set-up is complete. For collections in the local tree, it usually takes a day or two. For contributed collections, it takes about a week. If the release of a program is to be coordinated with another event such as an announcement, the Gatekeeper should be contacted directly. To contact the gatekeeper, post a message on org.acs.asg.request.gatekeeper.
2.2.2 Using the carpe command line flags
All of the relevant information to create a collection may be included in the command line as flags.
To do this, at the system prompt type:
% carpe create <flags>
Table 1 Command Line Flags for the Create Command
Flag |
Use |
-tree <tree > |
Designates the tree where the collection will reside. |
-collection <collection > |
Designates the name of the collection. |
-version <version> |
Designates the version number of the request. Version numbers start at 001 and are incremented by one for each new version. |
-systems <systems> |
Specifies the systems the collection can be used under. Separate the system names by spaces. |
-C <version > |
Specifies which existing version number to clone, or copy the source files from, to create the new version. |
-nC |
Specifies that a version should not be cloned. Instead, you will create the source files from scratch. |
-ns |
Specifies that a source volume should not be created. |
-mkcom |
Creates a common volume for a collection. |
-obj <AFS or local> |
Specifies where the object volume will be created, either on AFS or your local disk. |
-Qsrc <quota> |
Requests a new quota for the source volume. |
-Qdest <quota> |
Requests a new quota for the dest volume. |
-Qcomm <quota> |
Requests a new quota for the common volume. |
-Qobj <quota> |
Requests a new quota for the object volume. |
-users <users> |
Creates a list of users with access to the volumes. |
-U |
Specifies that the request is urgent. You must list the reason in the comments section. This option is only available as a command line flag. |
For example:
% carpe create -tree local -collections gnu-emacs -version 002
-system pmax_42 -C 001
Carpe will prompt the user for any information that was not specified with a flag.
To delete a volume, at the system prompt type:
Carpe will ask for the version numbers and the system types that are to be deleted and then ask to confirm each deletion. More than one version type may be deleted with one request.
The appropriate command line flags may also be used.
Table 2 Command Line Flags for the Delete Command
Flag |
Use |
-tree <tree> |
Designates the tree where the collection will reside. |
-collection<collection > |
Designates the name of the collection. |
-version <version> |
Designates the version number of the request. Version numbers start at 001 and are incremented by one for each new version. |
-systems <systems> |
Specifies the systems the collection can be used under. Separate the system names by spaces. |
2.4 Releasing a Collection
For information on releasing a collection with carpe, see Chapter 5, Releasing Software
All releases must include some kind of documentation, which can consist of help files, man pages, or both. When the software is released, this documentation will become a part of the system documentation database, accessible from the help command.
- If the software is for the local tree, Computing Services must review the help files before they are released. A software release will be delayed if the documentation has not been reviewed. Before writing a help file, read several existing help files to get an idea of what they should look like. A first draft containing all the technical information should be reviewed by the technical writing staff, then he or she can help complete the process.
- If the software is for the contributed tree, Computing Services reserves the right to review the documentation. If it is unsatisfactory, release will be delayed until it has been revised. Two examples of well written help files are in /usr/contributed/lib/maintainer. Every help file and man page in contributed must have two /usr/contributed caveats (one at the beginning and one at the end) and must include the name of the maintainer.
All help files should be written in EZ using the.help template provided. To access this template, create a file named <file name>.help and open it in EZ.
Man pages should be in troff format. This is sometimes referred to as man format.
Any changes made in subsequent releases of the application that affect the behavior of the application must be reflected in the help documents.
Tips for writing Help Files
- Avoid jargon and negative words. Assume the reader knows nothing about Andrew. Organize the information so that the expert readers can skip the information they already know.
- Instruct users to type commands "at the system prompt" instead of "in your typescript window."
- Never use the phrase "hit return." Use "press ENTER" instead.
- Include examples whenever possible.
- Test the information. Make sure the directories exist, the files that are supposed to be there are indeed there, and that the names are
consistent with what is written.
- Don't use rasters, insets, tables, etc., as many people will not be reading these files through the same system.
- Keep as much text as possible in plain text. Use italics for pointers to other help files.
- If necessary, write two help files - an introduction and a more detailed file.
- Always, always, always spell check and proofread help files.
The Makefile is a file which controls the process of compiling, linking, and installing software packages. The MakeFile also controls the creation of appropriate subdirectories in the destination volume and the subsequent vms allocation of appropriate files. Man pages go into the appropriate man subdirectory, help files into a help subdirectory, libraries into lib, and the executable image into bin. For any other file, create an appropriate directory in the dest area and install it there.
In order for the software to install correctly in the destination volumes, the variable DESTDIR should be used to point to the destination volume.
A Makefile excerpt follows:
Example 2 A sample Makefile excerpt
install: myprogram myprogram.man libmy.a myprogram.help
-mkdir $(DESTDIR)
-mkdir $(DESTDIR)/man
-mkdir $(DESTDIR)/man/man1
-mkdir $(DESTDIR)/bin
-mkdir $(DESTDIR)/lib
-mkdir $(DESTDIR)/help
install -s myprogram $(DESTDIR)/bin
install <lib>.a $(DESTDIR)/lib
install -m 644 myprogram.man $(DESTDIR/man/man1/ myprogram.1
install -m 644 myprogram.help (DESTDIR)/help
4.1.1 Installing Binaries
When installing binaries, the -s switch should be used with install. See the Makefile excerpt above for an example of this switch. This strips the files as they are installed and saves space on the system. If a debugger is to be used on the program as part of testing, do not use this switch.
4.1.2 Installing Non-executable files
When installing non-executable files such as text, help, or man files, the -m 644 switch sets the protection bits appropriately during the installation. See the Makefile excerpt on the previous page for an example of this switch.
4.1.3 Defining DESTDIR explicitly
DESTDIR must be defined explicitly if the sources are not located in the top level of the source volume.
DESTDIR may be defined explicitly in the Makefile, or a top-level Makefile may be created to define DESTDIR, that looks like this:
Example 3 A top-level Makefile to define DESTDIR
SUBDIRS= src docs
all install clean:
for i in $(SUBDIRS); do (cd $$i;$(MAKE)$(MFLAGS)
DESTDIR=$(DESTDIR) $@); done
This Makefile would pass the correct value for DESTDIR to the Makefiles in the lower-level directories, and they in turn would be able to use DESTDIR to install files in the correct location.
For more information, see the online help files for install.
4.2.1 Build
Build is a tool that is available to developers for compiling their programs. Build must be run on a machine which is running the system type for which the software is being compiled.Washing machines are provided and maintainted by Computing Services for the purpose of building software. Please see the following section for more information about washing machines.
To run build, at the system prompt type:
Build should be run on the Makefile instead of make.Build does precisely the same things as make with two exceptions. First, it causes the compile to take place in the object area. Second, build automatically sets several variables that can be used in the Makefile, such as the DESTDIR variable. Standard Makefiles can be converted to files which build can use in a distributed environment.
Before the software is compiled, make sure that all the pathnames referenced in the software are the pathnames to the files as they will be released and not the pathnames to the development areas.
Please study the online help on build before installing files
4.2.2 Washing Machines
Washing machines are provided and maintained by Computing Services for the purpose of compiling software. There is one washing machine for each supported system type. Access to the washing machines is restricted via / etc/user.permits. If a software maintainer cannot access these machines, then the washing machine maintainer should be notified. A post on org.acs.asg.request.washconfig will notify the maintainer. By default, washing machines are linked to the beta versions of /usr/local and /usr/contributed. If custom linkage to a washing machine is needed, a post with an explanation should be sent to org.acs.asg.request.washconfig.
If vendor supplied Makefiles are nested and complex it can be difficult to render the conversion from make to build. A technique that is used to resolve this is to run a program called mklink. The mklink program is installed in /usr/local/bin and is used to create masses of symbolic links from the system-specific object directories to a common source tree. Standard make can then be run in the object tree.
To use mklink, telnet to a washing machine and make a directory for the application to be built under /usr/obj. Then, cd to that directory on the washing machine and run mklink with the long pathname to the source volume as the only argument along with an appropriate set of flags. Typically, mklink is run with the -RrvF flags. Mklink does not have to be rn on a washing machine. It will work on any machine given sufficient disk space, or in AFS. Running /usr/local/bin/mklink -x will output the usage message.
Software that is to be installed to a beta or gamma environment needs to be tested before it is released. Local disk depot (LDD) provides an environment for testing software. LDD allows a software developer to recreate an environment on the local disk of a workstation that is, with the exception of the component to be tested, identical to the environment to which the component is to be released.
In order to set up LDD, one must have root access to a workstation. After root access has been obtained, follow the instructions below:
- Edit the /etc/package.proto such that the following lines are at the top of the file.
%define usesdepot
%define localdepotdir
%define local/usr/local
%Define localoverride
- Reboot the machine. When the Machine comes back up, /usr/local will be a directory on the local machine.
To test new software, edit /usr/local/depot/custom.depot.proto so that there is a path command that points to the location of the software to be tested. For example, to test wsadmin 040 on a pmax, the following line would be added to custom.depot.proto.
wsadmin.path:/afs/andrew.cmu.edu/system/dest/pmax_u14/local/wsadmin/040
More information on depot and local disk depot can be found in the technical paper on depot. To retrieve the technical paper, anonymously FTP to export.acs.cmu.edu.The file is in /pub/depot.
Once the software has been compiled and tested, it may be released to a release environment. There are two such environments on Andrew.
- Beta, which allows a pool of Computing Services employees or any other interested parties, to test the software and report any bugs.
- Gamma, which releases the software to the general environment available on most machines. Software must be stable before it can be released to Gamma.
To release a version of software, a request must be sent to the Gatekeeper through carpe. The following information must be provided to the Gatekeeper:
- the name of the collection
- the version number
- the system types the software runs on
- whether it should be released to the Gamma or Beta environment.
To request the release of a collection, type:
Carpe will then prompt the user for all of the necessary information. This information will include details of any bug fixes and changes to the program. Lack of detail will be considered sufficient reason to reject the request.
Command line flags may also be used with the release command.
Table 3 Command Line Flags for the Release Command
Flag |
Use |
-tree <tree name> |
Designates the tree where the collection will reside. |
-collection <collection name> |
Designates the name of the collection. |
-version <version number> |
Designates the version number of the request. Version numbers start at 001 and are incremented by one for each new version. |
-systems <systems> |
Specifies the systems the collection can be used under. Separate the system names by spaces. |
-environment <environment> |
Specifies which environment a collection should be released to. |
-U |
Specifies that the request is urgent. You must list the reason in the comments section. |
The Gatekeeper will process requests with EMT as soon as possible. For local software, Beta releases usually take one work day, Gamma releases usually take three work days. Local software must be in Beta for at least three days before it can be released to Gamma. For contributed software, releases can take several days. User Services reserves the right to defer the release of any software beyond the original release date. Any information about a delay will be posted on:
To coordinate a release with another activity such as an announcement, contact the gatekeeper directly. To contact the gatekeeper post a message on org.acs.asg.request.gatekeeper.
Releases which are defined as routine system maintenance releases are not subject to the review process. Routine system maintenance releases are defined as such by agreement between the System Manager, the Gatekeeper, and the User Services Release Coordinator. An example of a routine system maintenance release would be the release of the help file indices.
Sometimes, particularly in the Beta environment, The most recently released version software must be removed in order to correct serious bugs. To do this, request the release of an earlier version of the software.
However, unless the currently-released version is unusable or damaged, a new version should be requested, the software fixed, and the new version released.
When EMT releases software to an environment, it:
- Mounts the volume in the appropriate environment.
- Changes the protections so that the files can no longer be written to and system:anyuser can read the files.
- Runs a program called Depot to create a series of symbolic links.
- Releases the program so that the campus community can use it.
The following sections describe how Depot makes the symbolic links to the software, and how to tell Depot how to find the software.
Depot controls the mapping of software so that all of the parts that make up a collection appear in a single target location.
On workstations, /usr/contributed program binaries are found under the directory
/usr/contributed/bin. Similarly, libraries are in /usr/contributed/lib, man pages in
/usr/contributed/man, and so on.
However, no real files exist in these directories. Instead, these directories contain symbolic links to the appropriate files underneath
/usr/contributed/depot/<collection>. This special subdirectory contains the
bin, lib, man, and help directories for that specific collection.
For example, the contributed program myprog will actually sit in the directory:
but users will find it in:
For more information, read the online help files on depot and the technical paper on depot. To retrieve the technical paper, anonymously FTP to export.acs.cmu.edu. The file is in /pub/depot.
Files and directories will be linked to the /usr/contributed area as they appear at the top level of the destination volume. This linking is done by Depot. For example, if the top level of a destination volume contained:
Depot would link the files beneath bin into /usr/contributed/bin, the files beneath lib into /usr/contributed/lib, and the man subdirectories into
/usr/contributed/man.
However there may be a common volume that contains all of the help files for an application. In this case, the default depot links will not work.
To link a common volume to the system:
- Create a file in the top level of your destination directory and name it depot.conf
- Type the following lines in this file:
/ /
common /
~afsmountpoint common
For more information, read the online help for depot.conf.