4 # Installing the First AFS Machine
6 This chapter describes how to install the first AFS machine in your cell, configuring it as both a file server machine and a client machine. After completing all procedures in this chapter, you can remove the client functionality if you wish, as described in Removing Client Functionality.
8 To install additional file server machines after completing this chapter, see Installing Additional Server Machines.
10 To install additional client machines after completing this chapter, see Installing Additional Client Machines. Requirements and Configuration Decisions
12 The instructions in this chapter assume that you meet the following requirements.
14 - You are logged onto the machine's console as the local superuser root
16 - A standard version of one of the operating systems supported by the current version of AFS is running on the machine
18 - You can access the data on the AFS CD-ROMs, either through a local CD drive or via an NFS mount of a CD drive attached to a machine that is accessible by network
20 You must make the following configuration decisions while installing the first AFS machine. To speed the installation itself, it is best to make the decisions before beginning. See the chapter in the IBM AFS Administration Guide about issues in cell administration and configuration for detailed guidelines.
22 - Select the first AFS machine
24 - Select the cell name
26 - Decide which partitions or logical volumes to configure as AFS server partitions, and choose the directory names on which to mount them
28 - Decide whether to use the standard AFS authentication and authorization software or Kerberos as obtained from another source. On several system types, the decision determines how you incorporate AFS into the machine's authentication system. If you wish to use Kerberos, contact the AFS Product Support group now to learn about how you must modify the installation procedure.
30 - Decide how big to make the client cache
32 - Decide how to configure the top levels of your cell's AFS filespace
34 This chapter is divided into three large sections corresponding to the three parts of installing the first AFS machine. Perform all of the steps in the order they appear. Each functional section begins with a summary of the procedures to perform. The sections are as follows:
36 - Installing server functionality (begins in Overview: Installing Server Functionality)
38 - Installing client functionality (begins in Overview: Installing Client Functionality)
40 - Configuring your cell's filespace, establishing further security mechanisms, and enabling access to foreign cells (begins in Overview: Completing the Installation of the First AFS Machine)
42 # Overview: Installing Server Functionality
44 In the first phase of installing your cell's first AFS machine, you install file server and database server functionality by performing the following procedures:
46 1. Choose which machine to install as the first AFS machine
48 1. Create AFS-related directories on the local disk
50 1. Incorporate AFS modifications into the machine's kernel
52 1. Configure partitions or logical volumes for storing AFS volumes
54 1. On some system types, install and configure an AFS-modified version of the fsck program
56 1. If the machine is to remain a client machine, incorporate AFS into its authentication system
58 1. Start the Basic [[OverSeer]] (BOS) Server
60 1. Define the cell name and the machine's cell membership
62 1. Start the database server processes: Authentication Server, Backup Server, Protection Server, and Volume Location (VL) Server
64 10. Configure initial security mechanisms
66 11. Start the fs process, which incorporates three component processes: the File Server, Volume Server, and Salvager
68 12. Start the server portion of the Update Server
70 13. Start the controller process (called runntp) for the Network Time Protocol Daemon, which synchronizes machine clocks
72 # Choosing the First AFS Machine
74 The first AFS machine you install must have sufficient disk space to store AFS volumes. To take best advantage of AFS's capabilities, store client-side binaries as well as user files in volumes. When you later install additional file server machines in your cell, you can distribute these volumes among the different machines as you see fit.
76 These instructions configure the first AFS machine as a database server machine, the binary distribution machine for its system type, and the cell's system control machine. For a description of these roles, see the IBM AFS Administration Guide.
78 Installation of additional machines is simplest if the first machine has the lowest IP address of any database server machine you currently plan to install. If you later install database server functionality on a machine with a lower IP address, you must first update the /usr/vice/etc/CellServDB file on all of your cell's client machines. For more details, see Installing Database Server Functionality. Creating AFS Directories
80 Create the /usr/afs and /usr/vice/etc directories on the local disk, to house server and client files respectively. Subsequent instructions copy files from the AFS CD-ROM into them. Create the /cdrom directory as a mount point for CD-ROMs, if it does not already exist.
84 # mkdir -p /usr/vice/etc
88 # Performing Platform-Specific Procedures
90 Several of the initial procedures for installing a file server machine differ for each system type. For convenience, the following sections group them together for each system type:
92 - Incorporate AFS modifications into the kernel.
94 The kernel on every AFS file server and client machine must incorporate AFS extensions. On machines that use a dynamic kernel module loader, it is conventional to alter the machine's initialization script to load the AFS extensions at each reboot.
96 - Configure server partitions or logical volumes to house AFS volumes.
98 Every AFS file server machine must have at least one partition or logical volume dedicated to storing AFS volumes (for convenience, the documentation hereafter refers to partitions only). Each server partition is mounted at a directory named /vicepxx, where xx is one or two lowercase letters. By convention, the first 26 partitions are mounted on the directories called /vicepa through /vicepz, the 27th one is mounted on the /vicepaa directory, and so on through /vicepaz and /vicepba, continuing up to the index corresponding to the maximum number of server partitions supported in the current version of AFS (which is specified in the IBM AFS Release Notes).
100 The /vicepxx directories must reside in the file server machine's root directory, not in one of its subdirectories (for example, /usr/vicepa is not an acceptable directory location).
102 You can also add or remove server partitions on an existing file server machine. For instructions, see the chapter in the IBM AFS Administration Guide about maintaining server machines.
108 <dd> Not all file system types supported by an operating system are necessarily supported as AFS server partitions. For possible restrictions, see the IBM AFS Release Notes. </dd>
113 - On some system types, install and configure a modified fsck program which recognizes the structures that the File Server uses to organize volume data on AFS server partitions. The fsck program provided with the operating system does not understand the AFS data structures, and so removes them to the lost+found directory.
115 - If the machine is to remain an AFS client machine, modify the machine's authentication system so that users obtain an AFS token as they log into the local file system. Using AFS is simpler and more convenient for your users if you make the modifications on all client machines. Otherwise, users must perform a two-step login procedure (login to the local file system and then issue the klog command). For further discussion of AFS authentication, see the chapter in the IBM AFS Administration Guide about cell configuration and administration issues.
117 # Getting Started on AIX Systems
119 Begin by running the AFS initialization script to call the AIX kernel extension facility, which dynamically loads AFS modifications into the kernel. Then use the SMIT program to configure partitions for storing AFS volumes, and replace the AIX fsck program helper with a version that correctly handles AFS volumes. If the machine is to remain an AFS client machine, incorporate AFS into the AIX secondary authentication system.
121 ## Loading AFS into the AIX Kernel
123 [[Loading AFS into the AIX Kernel|LoadingAFSIntoTheAIXKernel]]
125 ## Replacing the fsck Program Helper on AIX Systems
127 Never run the standard fsck program on AFS server partitions. It discards AFS volumes.
129 [[Replacing the fsck Program Helper on AIX Systems|ReplacingTheFsckProgramHelperOnAIXSystems]]
131 ## Configuring Server Volumes on AIX Systems
133 If this system is going to be used as a file server to share some of its disk space, create a directory called /vicepxx for each AFS server partition you are configuring (there must be at least one). If it is not going to be a file server you can skip this step.
135 [[Configuring Server Volumes on AIX|ConfiguringServerVolumesOnAIX]]
137 If you plan to retain client functionality on this machine after completing the installation, proceed to [[Enabling AFS Login on AIX Systems|EnablingAFSLoginOnAIXSystems]]. Otherwise, proceed to Starting the BOS Server.
139 # <a name="Getting Started on Digital UNIX "></a> Getting Started on Digital UNIX Systems
141 Begin by either building AFS modifications into a new static kernel or by setting up to dynamically load the AFS kernel module. Then create partitions for storing AFS volumes, and replace the Digital UNIX fsck program with a version that correctly handles AFS volumes. If the machine is to remain an AFS client machine, incorporate AFS into the machine's Security Integration Architecture (SIA) matrix.
143 ## Loading AFS into the Digital UNIX Kernel
145 [[Building AFS into the Digital UNIX Kernel|BuildingAFSIntoTheDigitalUNIXKernel]]
147 ## Replacing the fsck Program on Digital UNIX Systems
149 Never run the standard fsck program on AFS server partitions. It discards AFS volumes.
151 [[Replacing the fsck Program on Digital UNIX Systems|ReplacingTheFsckProgramOnDigitalUNIXSystems]]
153 ## Configuring Server Volumes on Digital UNIX Systems
155 If this system is going to be used as a file server to share some of its disk space, create a directory called /vicepxx for each AFS server partition you are configuring (there must be at least one). If it is not going to be a file server you can skip this step.
157 [[Configuring Server Volumes on Digital UNIX|ConfiguringServerVolumesOnDigitalUNIX]]
159 If you plan to retain client functionality on this machine after completing the installation, proceed to [[Enabling AFS Login on Digital UNIX Systems|EnablingAFSLoginOnDigitalUNIXSystems]]. Otherwise, proceed to Starting the BOS Server.
161 # Getting Started on HP-UX Systems
163 Begin by building AFS modifications into a new kernel; HP-UX does not support dynamic loading. Then create partitions for storing AFS volumes, and install and configure the AFS-modified fsck program to run on AFS server partitions. If the machine is to remain an AFS client machine, incorporate AFS into the machine's Pluggable Authentication Module (PAM) scheme.
165 ## Building AFS into the HP-UX Kernel
167 [[Building AFS into the HP-UX Kernel|BuildingAFSIntoTheHP-UXKernel]]
169 ## Configuring the AFS-modified fsck Program on HP-UX Systems
171 Never run the standard fsck program on AFS server partitions. It discards AFS volumes.
173 [[Configuring the AFS-modified fsck Program on HP-UX Systems|ConfiguringTheAFS-modifiedFsckProgramOnHP-UXSystems]]
175 ## Configuring Server Volumes on HP-UX Systems
177 If this system is going to be used as a file server to share some of its disk space, create a directory called /vicepxx for each AFS server partition you are configuring (there must be at least one). If it is not going to be a file server you can skip this step.
179 [[Configuring Server Volumes on HP-UX|ConfiguringServerVolumesOnHP-UX]]
181 If you plan to retain client functionality on this machine after completing the installation, proceed to [[Enabling AFS Login on HP-UX Systems|EnablingAFSLoginOnHP-UXSystems]]. Otherwise, proceed to Starting the BOS Server.
183 # Getting Started on IRIX Systems
185 Begin by incorporating AFS modifications into the kernel. Either use the ml dynamic loader program, or build a static kernel. Then configure partitions to house AFS volumes. AFS supports use of both EFS and XFS partitions for housing AFS volumes. SGI encourages use of XFS partitions.
187 You do not need to replace IRIX fsck program, because the version that SGI distributes handles AFS volumes properly.
189 ## Loading AFS into the IRIX Kernel
191 [[Loading AFS into the IRIX Kernel|LoadingAFSIntoTheIRIXKernel]]
193 Proceed to Configuring Server Partitions on IRIX Systems.
195 ## Configuring Server Volumes on IRIX Systems
197 If this system is going to be used as a file server to share some of its disk space, create a directory called /vicepxx for each AFS server partition you are configuring (there must be at least one). If it is not going to be a file server you can skip this step.
199 [[Configuring Server Volumes on IRIX|ConfiguringServerVolumesOnIRIX]]
201 If you plan to retain client functionality on this machine after completing the installation, proceed to [[Enabling AFS Login on IRIX Systems|EnablingAFSLoginOnIRIXSystems]]. Otherwise, proceed to Starting the BOS Server.
203 # Getting Started on Linux Systems
205 Begin by running the AFS initialization script to call the insmod program, which dynamically loads AFS modifications into the kernel. Then create partitions for storing AFS volumes. You do not need to replace the Linux fsck program. If the machine is to remain an AFS client machine, incorporate AFS into the machine's Pluggable Authentication Module (PAM) scheme.
207 ## Loading AFS into the Linux Kernel
209 [[Loading AFS into the Linux Kernel|LoadingAFSIntoTheLinuxKernel]]
211 ## Configuring Server Volumes on Linux Systems
213 If this system is going to be used as a file server to share some of its disk space, create a directory called /vicepxx for each AFS server partition you are configuring (there must be at least one). If it is not going to be a file server you can skip this step.
215 [[Configuring Server Volumes On Linux|ConfiguringServerVolumesOnLinux]]
217 If you plan to retain client functionality on this machine after completing the installation, proceed to [[Enabling AFS Login on Linux Systems|EnablingAFSLoginOnLinuxSystems]]. Otherwise, proceed to Starting the BOS Server.
219 # Getting Started on Solaris Systems
221 Begin by running the AFS initialization script to call the modload program distributed by Sun Microsystems, which dynamically loads AFS modifications into the kernel. Then create partitions for storing AFS volumes, and install and configure the AFS-modified fsck program to run on AFS server partitions. If the machine is to remain an AFS client machine, incorporate AFS into the machine's Pluggable Authentication Module (PAM) scheme.
223 ## Loading AFS into the Solaris Kernel
225 [[Loading AFS into the Solaris Kernel|LoadingAFSIntoTheSolarisKernel]]
227 ## Configuring the AFS-modified fsck Program on Solaris Systems
229 Never run the standard fsck program on AFS server partitions. It discards AFS volumes.
231 [[Configuring the AFS-modified fsck Program on Solaris Systems|ConfiguringTheAFS-modifiedFsckProgramOnSolarisSystems]]
233 ## Configuring Server Partitions on Solaris Systems
235 If this system is going to be used as a file server to share some of its disk space, create a directory called /vicepxx for each AFS server partition you are configuring (there must be at least one). If it is not going to be a file server you can skip this step.
237 [[Configuring Server Volumes On Solaris|ConfiguringServerVolumesOnSolaris]]
239 If you plan to retain client functionality on this machine after completing the installation, proceed to Enabling AFS Login on Solaris Systems. Otherwise, proceed to Starting the BOS Server.
241 ## Enabling AFS Login on Solaris Systems
243 Note: If you plan to remove client functionality from this machine after completing the installation, skip this section and proceed to Starting the BOS Server.
245 [[Enabling AFS Login on Solaris Systems|EnablingAFSLoginOnSolarisSystems]]
247 Proceed to Starting the BOS Server (or if referring to these instructions while installing an additional file server machine, return to Starting Server Programs).
249 # Starting the BOS Server
251 You are now ready to start the AFS server processes on this machine. Begin by copying the AFS server binaries from the CD-ROM to the conventional local disk location, the /usr/afs/bin directory. The following instructions also create files in other subdirectories of the /usr/afs directory.
253 Then issue the bosserver command to initialize the Basic [[OverSeer]] (BOS) Server, which monitors and controls other AFS server processes on its server machine. Include the -noauth flag to disable authorization checking. Because you have not yet configured your cell's AFS authentication and authorization mechanisms, the BOS Server cannot perform authorization checking as it does during normal operation. In no-authorization mode, it does not verify the identity or privilege of the issuer of a bos command, and so performs any operation for anyone.
255 Disabling authorization checking gravely compromises cell security. You must complete all subsequent steps in one uninterrupted pass and must not leave the machine unattended until you restart the BOS Server with authorization checking enabled, in Verifying the AFS Initialization Script.
257 As it initializes for the first time, the BOS Server creates the following directories and files, setting the owner to the local superuser root and the mode bits to limit the ability to write (and in some cases, read) them. For a description of the contents and function of these directories and files, see the chapter in the IBM AFS Administration Guide about administering server machines. For further discussion of the mode bit settings, see Protecting Sensitive AFS Directories.
261 - /usr/afs/etc/CellServDB
263 - /usr/afs/etc/ThisCell
269 The BOS Server also creates symbolic links called /usr/vice/etc/ThisCell and /usr/vice/etc/CellServDB to the corresponding files in the /usr/afs/etc directory. The AFS command interpreters consult the [[CellServDB]] and [[ThisCell]] files in the /usr/vice/etc directory because they generally run on client machines. On machines that are AFS servers only (as this machine currently is), the files reside only in the /usr/afs/etc directory; the links enable the command interpreters to retrieve the information they need. Later instructions for installing the client functionality replace the links with actual files.
271 1. On the local /cdrom directory, mount the AFS CD-ROM for this machine's system type, if it is not already. For instructions on mounting CD-ROMs (either locally or remotely via NFS), consult the operating system documentation.
273 1. Copy files from the CD-ROM to the local /usr/afs directory.
275 # cd /cdrom/sysname/root.server/usr/afs
279 1. Issue the bosserver command. Include the -noauth flag to disable authorization checking.
281 # /usr/afs/bin/bosserver -noauth &
283 1. Verify that the BOS Server created /usr/vice/etc/ThisCell and /usr/vice/etc/CellServDB as symbolic links to the corresponding files in the /usr/afs/etc directory.
285 # ls -l /usr/vice/etc
287 If either or both of /usr/vice/etc/ThisCell and /usr/vice/etc/CellServDB do not exist, or are not links, issue the following commands.
291 # ln -s /usr/afs/etc/ThisCell
293 # ln -s /usr/afs/etc/CellServDB
295 # Defining Cell Name and Membership for Server Processes
297 Now assign your cell's name. The chapter in the IBM AFS Administration Guide about cell configuration and administration issues discusses the important considerations, explains why changing the name is difficult, and outlines the restrictions on name format. Two of the most important restrictions are that the name cannot include uppercase letters or more than 64 characters.
299 Use the bos setcellname command to assign the cell name. It creates two files:
301 - /usr/afs/etc/ThisCell, which defines this machine's cell membership
303 - /usr/afs/etc/CellServDB, which lists the cell's database server machines; the machine named on the command line is placed on the list automatically
305 Note: In the following and every instruction in this guide, for the machine name argument substitute the fully-qualified hostname (such as fs1.abc.com) of the machine you are installing. For the cell name argument substitute your cell's complete name (such as abc.com).
307 1. Issue the bos setcellname command to set the cell name.
311 # ./bos setcellname <machine name> <cell name> -noauth
313 Because you are not authenticated and authorization checking is disabled, the bos command interpreter possibly produces error messages about being unable to obtain tickets and running unauthenticated. You can safely ignore the messages.
315 1. Issue the bos listhosts command to verify that the machine you are installing is now registered as the cell's first database server machine.
317 # ./bos listhosts <machine name> -noauth
318 Cell name is cell_name
319 Host 1 is machine_name
321 # Starting the Database Server Processes
323 Next use the bos create command to create entries for the four database server processes in the /usr/afs/local/BosConfig file and start them running. The four processes run on database server machines only:
325 - The Authentication Server (the kaserver process) maintains the Authentication Database
327 - The Backup Server (the buserver process) maintains the Backup Database
329 - The Protection Server (the ptserver process) maintains the Protection Database
331 - The Volume Location (VL) Server (the vlserver process) maintains the Volume Location Database (VLDB)
333 Note: AFS's authentication and authorization software is based on algorithms and other procedures known as Kerberos, as originally developed by Project Athena at the Massachusetts Institute of Technology. Some cells choose to replace the AFS Authentication Server and other security-related protocols with Kerberos as obtained directly from Project Athena or other sources. If you wish to do this, contact the AFS Product Support group now to learn about necessary modifications to the installation.
335 The remaining instructions in this chapter include the -cell argument on all applicable commands. Provide the cell name you assigned in Defining Cell Name and Membership for Server Processes. If a command appears on multiple lines, it is only for legibility.
337 1. Issue the bos create command to start the Authentication Server. The current working directory is still /usr/afs/bin.
339 # ./bos create <machine name> kaserver simple /usr/afs/bin/kaserver \
340 -cell <cell name> -noauth
342 You can safely ignore the messages that tell you to add Kerberos to the /etc/services file; AFS uses a default value that makes the addition unnecessary. You can also ignore messages about the failure of authentication.
344 1. Issue the bos create command to start the Backup Server.
346 # ./bos create <machine name> buserver simple /usr/afs/bin/buserver \
347 -cell <cell name> -noauth
349 1. Issue the bos create command to start the Protection Server.
351 # ./bos create <machine name> ptserver simple /usr/afs/bin/ptserver \
352 -cell <cell name> -noauth
354 1. Issue the bos create command to start the VL Server.
356 # ./bos create <machine name> vlserver simple /usr/afs/bin/vlserver \
357 -cell <cell name> -noauth
359 # Initializing Cell Security
361 Now initialize the cell's security mechanisms. Begin by creating the following two initial entries in the Authentication Database:
363 - A generic administrative account, called admin by convention. If you choose to assign a different name, substitute it throughout the remainder of this document.
365 After you complete the installation of the first machine, you can continue to have all administrators use the admin account, or you can create a separate administrative account for each of them. The latter scheme implies somewhat more overhead, but provides a more informative audit trail for administrative operations.
367 - The entry for AFS server processes, called afs. No user logs in under this identity, but the Authentication Server's Ticket Granting Service (TGS) module uses the associated key to encrypt the server tickets that it grants to AFS clients for presentation to server processes during mutual authentication. (The chapter in the IBM AFS Administration Guide about cell configuration and administration describes the role of server encryption keys in mutual authentication.)
369 In Step 7, you also place the initial AFS server encryption key into the /usr/afs/etc/KeyFile file. The AFS server processes refer to this file to learn the server encryption key when they need to decrypt server tickets.
371 You also issue several commands that enable the new admin user to issue privileged commands in all of the AFS suites.
373 The following instructions do not configure all of the security mechanisms related to the AFS Backup System. See the chapter in the IBM AFS Administration Guide about configuring the Backup System.
375 1. Enter kas interactive mode. Because the machine is in no-authorization checking mode, include the -noauth flag to suppress the Authentication Server's usual prompt for a password.
377 # kas -cell <cell name> -noauth
380 1. Issue the kas create command to create Authentication Database entries called admin and afs.
382 Do not provide passwords on the command line. Instead provide them as afs\_passwd and admin\_passwd in response to the kas command interpreter's prompts as shown, so that they do not appear on the standard output stream.
384 You need to enter the afs\_passwd string only in this step and in Step 7, so provide a value that is as long and complex as possible, preferably including numerals, punctuation characters, and both uppercase and lowercase letters. Also make the admin\_passwd as long and complex as possible, but keep in mind that administrators need to enter it often. Both passwords must be at least six characters long.
387 initial_password: afs_passwd
388 Verifying, please re-enter initial_password: afs_passwd
391 initial_password: admin_passwd
392 Verifying, please re-enter initial_password: admin_passwd
394 1. Issue the kas examine command to display the afs entry. The output includes a checksum generated by encrypting a constant with the server encryption key derived from the afs\_passwd string. In Step 8 you issue the bos listkeys command to verify that the checksum in its output matches the checksum in this output.
398 key (0) cksum is checksum . . .
400 1. Issue the kas setfields command to turn on the ADMIN flag in the admin entry. This enables the admin user to issue privileged kas commands. Then issue the kas examine command to verify that the ADMIN flag appears in parentheses on the first line of the output, as shown in the example.
402 ka> setfields admin -flags admin
405 User data for admin (ADMIN) . . .
407 1. Issue the kas quit command to leave kas interactive mode.
411 1. Issue the bos adduser command to add the admin user to the /usr/afs/etc/UserList file. This enables the admin user to issue privileged bos and vos commands.
413 # ./bos adduser <machine name> admin -cell <cell name> -noauth
415 1. Issue the bos addkey command to define the AFS server encryption key in the /usr/afs/etc/KeyFile file.
417 Do not provide the password on the command line. Instead provide it as afs\_passwd in response to the bos command interpreter's prompts, as shown. Provide the same string as in Step 2.
419 # ./bos addkey <machine name> -kvno 0 -cell <cell name> -noauth
420 Input key: afs_passwd
421 Retype input key: afs_passwd
423 1. Issue the bos listkeys command to verify that the checksum for the new key in the [[KeyFile]] file is the same as the checksum for the key in the Authentication Database's afs entry, which you displayed in Step 3.
425 # ./bos listkeys <machine name> -cell <cell name> -noauth
426 key 0 has cksum checksum
428 You can safely ignore any error messages indicating that bos failed to get tickets or that authentication failed.
430 If the keys are different, issue the following commands, making sure that the afs\_passwd string is the same in each case. The checksum strings reported by the kas examine and bos listkeys commands must match; if they do not, repeat these instructions until they do, using the -kvno argument to increment the key version number each time.
432 # ./kas -cell <cell name> -noauth
434 ka> setpassword afs -kvno 1
435 new_password: afs_passwd
436 Verifying, please re-enter initial_password: afs_passwd
440 key (1) cksum is checksum . . .
444 # ./bos addkey <machine name> -kvno 1 -cell <cell name> -noauth
445 Input key: afs_passwd
446 Retype input key: afs_passwd
448 # ./bos listkeys <machine name> -cell <cell name> -noauth
449 key 1 has cksum checksum
451 1. Issue the pts createuser command to create a Protection Database entry for the admin user.
453 By default, the Protection Server assigns AFS UID 1 (one) to the admin user, because it is the first user entry you are creating. If the local password file (/etc/passwd or equivalent) already has an entry for admin that assigns it a UNIX UID other than 1, it is best to use the -id argument to the pts createuser command to make the new AFS UID match the existing UNIX UID. Otherwise, it is best to accept the default.
455 # ./pts createuser -name admin -cell <cell name> [-id <AFS UID>] -noauth
456 User admin has id AFS UID
458 10. Issue the pts adduser command to make the admin user a member of the
459 system:administrators group, and the pts membership command to verify the new
460 membership. Membership in the group enables the admin user to issue privileged
461 pts commands and some privileged fs commands.
464 # ./pts adduser admin system:administrators -cell <cell name> -noauth
465 # ./pts membership admin -cell <cell name> -noauth
466 Groups admin (id: 1) is a member of:
467 system:administrators
470 11. Issue the bos restart command with the -all flag to restart the database
471 server processes, so that they start using the new server encryption key.
474 # ./bos restart <machine name> -all -cell <cell name> -noauth
477 # Starting the File Server, Volume Server, and Salvager
479 Start the fs process, which consists of the File Server, Volume Server, and Salvager (fileserver, volserver and salvager processes).
481 1. Issue the bos create command to start the fs process. The command appears here on multiple lines only for legibility.
483 # ./bos create <machine name> fs fs /usr/afs/bin/fileserver \
484 /usr/afs/bin/volserver /usr/afs/bin/salvager \
485 -cell <cell name> -noauth
487 Sometimes a message about Volume Location Database (VLDB) initialization appears, along with one or more instances of an error message similar to the following:
489 FSYNC_clientInit temporary failure (will retry)
491 This message appears when the volserver process tries to start before the fileserver process has completed its initialization. Wait a few minutes after the last such message before continuing, to guarantee that both processes have started successfully.
493 You can verify that the fs process has started successfully by issuing the bos status command. Its output mentions two proc starts.
495 # ./bos status <machine name> fs -long -noauth
497 1. Your next action depends on whether you have ever run AFS file server machines in the cell:
499 \* If you are installing the first AFS server machine ever in the cell (that is, you are not upgrading the AFS software from a previous version), create the first AFS volume, root.afs.
501 For the partition name argument, substitute the name of one of the machine's AFS server partitions (such as /vicepa).
503 # ./vos create <machine name> <partition name> root.afs \
504 -cell <cell name> -noauth
506 The Volume Server produces a message confirming that it created the volume on the specified partition. You can ignore error messages indicating that tokens are missing, or that authentication failed.
508 \* If there are existing AFS file server machines and volumes in the cell, issue the vos syncvldb and vos syncserv commands to synchronize the VLDB with the actual state of volumes on the local machine. To follow the progress of the synchronization operation, which can take several minutes, use the -verbose flag.
510 # ./vos syncvldb <machine name> -cell <cell name> -verbose -noauth
512 # ./vos syncserv <machine name> -cell <cell name> -verbose -noauth
514 You can ignore error messages indicating that tokens are missing, or that authentication failed.
516 # Starting the Server Portion of the Update Server
518 Start the server portion of the Update Server (the upserver process), to distribute the contents of directories on this machine to other server machines in the cell. It becomes active when you configure the client portion of the Update Server on additional server machines.
520 Distributing the contents of its /usr/afs/etc directory makes this machine the cell's system control machine. The other server machines in the cell run the upclientetc process (an instance of the client portion of the Update Server) to retrieve the configuration files. Use the -crypt argument to the upserver initialization command to specify that the Update Server distributes the contents of the /usr/afs/etc directory only in encrypted form, as shown in the following instruction. Several of the files in the directory, particularly the [[KeyFile]] file, are crucial to cell security and so must never cross the network unencrypted.
522 (You can choose not to configure a system control machine, in which case you must update the configuration files in each server machine's /usr/afs/etc directory individually. The bos commands used for this purpose also encrypt data before sending it across the network.)
524 Distributing the contents of its /usr/afs/bin directory to other server machines of its system type makes this machine a binary distribution machine. The other server machines of its system type run the upclientbin process (an instance of the client portion of the Update Server) to retrieve the binaries.
526 The binaries in the /usr/afs/bin directory are not sensitive, so it is not necessary to encrypt them before transfer across the network. Include the -clear argument to the upserver initialization command to specify that the Update Server distributes the contents of the /usr/afs/bin directory in unencrypted form unless an upclientbin process requests encrypted transfer.
528 Note that the server and client portions of the Update Server always mutually authenticate with one another, regardless of whether you use the -clear or -crypt arguments. This protects their communications from eavesdropping to some degree.
530 For more information on the upclient and upserver processes, see their reference pages in the IBM AFS Administration Reference. The commands appear on multiple lines here only for legibility.
532 1. Issue the bos create command to start the upserver process.
534 # ./bos create <machine name> upserver simple \
535 "/usr/afs/bin/upserver -crypt /usr/afs/etc \
536 -clear /usr/afs/bin" -cell <cell name> -noauth
538 # Starting the Controller for NTPD
540 Keeping the clocks on all server and client machines in your cell synchronized is crucial to several functions, and in particular to the correct operation of AFS's distributed database technology, Ubik. The chapter in the IBM AFS Administration Guide about administering server machines explains how time skew can disturb Ubik's performance and cause service outages in your cell.
542 The AFS distribution includes a version of the Network Time Protocol Daemon (NTPD) for synchronizing the clocks on server machines. If a time synchronization program is not already running on the machine, then in this section you start the runntp process to configure NTPD for use with AFS. Note: Do not run the runntp process if NTPD or another time synchronization protocol is already running on the machine. Some versions of some operating systems run a time synchronization program by default, as detailed in the IBM AFS Release Notes.
544 Attempting to run multiple instances of the NTPD causes an error. Running NTPD together with another time synchronization protocol is unnecessary and can cause instability in the clock setting.
546 If you run the runntp process and your cell has reliable network connectivity to machines outside your cell, then it is conventional to configure the first AFS machine to refer to a time source outside the cell. When you later install the runntp program on other server machines in the cell, it configures NTPD to choose a time source at random from among the database server machines listed in the /usr/afs/etc/CellServDB file. Time synchronization therefore works in a chained manner: this database server machine refers to a time source outside the cell, the database server machines refer to the machine among them that has access to the most accurate time (NTPD itself includes code for determining this), and each non-database server machine refers to a local database server machine chosen at random from the /usr/afs/etc/CellServDB file. If you ever decide to remove database server functionality from this machine, it is best to transfer responsibility for consulting an external time source to a remaining database server machine.
548 If your cell does not have network connectivity to external machines, or if the connectivity is not reliable, include the -localclock flag to the runntp command as indicated in the following instructions. The flag tells NTPD to rely on the machine's internal clock when all external time sources are inaccessible. The runntp command has other arguments that are possibly useful given your cell configuration; see the IBM AFS Administration Reference.
550 Choosing an appropriate external time source is important, but involves more considerations than can be discussed here. If you need help in selecting a source, contact the AFS Product Support group.
552 As the runntp process initializes NTPD, trace messages sometimes appear on the standard output stream. You can ignore them, but they can be informative if you understand how NTPD works.
554 1. Issue the bos create command to start the runntp process. For the host argument, substitute the fully-qualified hostname or IP address of one or more machines outside the cell that are to serve as time sources. Separate each name with a space.
556 \* If your cell usually has reliable network connectivity to an external time source, use the following command:
558 # ./bos create <machine name> runntp simple \
559 "/usr/afs/bin/runntp <host>+" -cell <cell name> -noauth
561 \* If your cell does not have network connectivity to an external time source, use the following command:
563 # ./bos create <machine name> runntp simple \
564 "/usr/afs/bin/runntp -localclock" -cell <cell name> -noauth
566 \* If your cell has network connectivity to an external time source, but the network connection is frequently interrupted, use the following command:
568 # ./bos create <machine name> runntp simple \
569 "/usr/afs/bin/runntp -localclock <host>+" \
570 -cell <cell name> -noauth
572 # Overview: Installing Client Functionality
574 The machine you are installing is now an AFS file server machine, database server machine, system control machine, and binary distribution machine. Now make it a client machine by completing the following tasks:
576 1. Define the machine's cell membership for client processes
578 1. Create the client version of the [[CellServDB]] file
580 1. Define cache location and size
582 1. Create the /afs directory and start the Cache Manager
584 ## Copying Client Files to the Local Disk
586 Before installing and configuring the AFS client, copy the necessary files from the AFS CD-ROM to the local /usr/vice/etc directory.
588 1. On the local /cdrom directory, mount the AFS CD-ROM for this machine's system type, if it is not already. For instructions on mounting CD-ROMs (either locally or remotely via NFS), consult the operating system documentation.
590 1. Copy files to the local /usr/vice/etc directory.
592 This step places a copy of the AFS initialization script (and related files, if applicable) into the /usr/vice/etc directory. In the preceding instructions for incorporating AFS into the kernel, you copied the script directly to the operating system's conventional location for initialization files. When you incorporate AFS into the machine's startup sequence in a later step, you can choose to link the two files.
594 On some system types that use a dynamic kernel loader program, you previously copied AFS library files into a subdirectory of the /usr/vice/etc directory. On other system types, you copied the appropriate AFS library file directly to the directory where the operating system accesses it. The following commands do not copy or recopy the AFS library files into the /usr/vice/etc directory, because on some system types the library files consume a large amount of space. If you want to copy them, add the -r flag to the first cp command and skip the second cp command.
596 # cd /cdrom/sun4x_59/dest/root.client/usr/vice/etc
598 # cp -p * /usr/vice/etc
600 # cp -rp C /usr/vice/etc
602 ## Defining Cell Membership for Client Processes
604 Every AFS client machine has a copy of the /usr/vice/etc/ThisCell file on its local disk to define the machine's cell membership for the AFS client programs that run on it. The [[ThisCell]] file you created in the /usr/afs/etc directory (in Defining Cell Name and Membership for Server Processes) is used only by server processes.
606 Among other functions, the [[ThisCell]] file on a client machine determines the following:
608 \* The cell in which users authenticate when they log onto the machine, assuming it is using an AFS-modified login utility
610 \* The cell in which users authenticate by default when they issue the klog command
612 \* The cell membership of the AFS server processes that the AFS command interpreters on this machine contact by default
614 1. Change to the /usr/vice/etc directory and remove the symbolic link created in Starting the BOS Server.
620 1. Create the [[ThisCell]] file as a copy of the /usr/afs/etc/ThisCell file. Defining the same local cell for both server and client processes leads to the most consistent AFS performance.
622 # cp /usr/afs/etc/ThisCell ThisCell
624 ## <a name="Creating the Client _CellServDB "></a> Creating the Client [[CellServDB]] File
626 [[Creating the Client CellServDB File|CreatingTheClientCellServDBFile]]
628 ## Configuring the Cache
630 [[Configuring the Cache|ConfiguringTheCache]]
632 ## Configuring the Cache Manager
634 [[Configuring the Cache Manager|ConfiguringTheCacheManager]]
636 # Overview: Completing the Installation of the First AFS Machine
638 The machine is now configured as an AFS file server and client machine. In this final phase of the installation, you initialize the Cache Manager and then create the upper levels of your AFS filespace, among other procedures. The procedures are:
640 1. Verify that the initialization script works correctly, and incorporate it into the operating system's startup and shutdown sequence
642 1. Create and mount top-level volumes
644 1. Create and mount volumes to store system binaries in AFS
646 1. Enable access to foreign cells
648 1. Institute additional security measures
650 1. Remove client functionality if desired
652 ## Verifying the AFS Initialization Script
654 At this point you run the AFS initialization script to verify that it correctly invokes all of the necessary programs and AFS processes, and that they start correctly. The following are the relevant commands:
656 \* The command that dynamically loads AFS modifications into the kernel, on some system types (not applicable if the kernel has AFS modifications built in)
658 \* The bosserver command, which starts the BOS Server; it in turn starts the server processes for which you created entries in the /usr/afs/local/BosConfig file
660 \* The afsd command, which initializes the Cache Manager
662 On system types that use a dynamic loader program, you must reboot the machine before running the initialization script, so that it can freshly load AFS modifications into the kernel.
664 If there are problems during the initialization, attempt to resolve them. The AFS Product Support group can provide assistance if necessary.
666 1. Issue the bos shutdown command to shut down the AFS server processes other than the BOS Server. Include the -wait flag to delay return of the command shell prompt until all processes shut down completely.
668 # /usr/afs/bin/bos shutdown <machine name> -wait
670 1. Issue the ps command to learn the bosserver process's process ID number (PID), and then the kill command to stop it.
672 # ps appropriate_ps_options | grep bosserver
676 1. Issue the appropriate commands to run the AFS initialization script for this system type.
680 [[Initialization Script on AIX|InitializationScriptOnAIX]]
684 ## On Digital UNIX systems:
686 [[Initialization Script on Digital UNIX|InitializationScriptOnDigitalUNIX]]
692 [[Initialization Script on HP-UX|InitializationScriptOnHP-UX]]
698 [[Initialization Script on IRIX|InitializationScriptOnIRIX]]
704 [[Initialization Script on Linux|InitializationScriptOnLinux]]
708 ## On Solaris systems:
710 [[Initialization Script on Solaris|InitializationScriptOnSolaris]]
712 Step 4. Verify that /usr/afs and its subdirectories on the new file server machine meet the ownership and mode bit requirements outlined in Protecting Sensitive AFS Directories. If necessary, use the chmod command to correct the mode bits.
714 Proceed to Configuring the Top Levels of the AFS Filespace.
716 # Configuring the Top Levels of the AFS Filespace
718 If you have not previously run AFS in your cell, you now configure the top levels of your cell's AFS filespace. If you have run a previous version of AFS, the filespace is already configured. Proceed to Storing AFS Binaries in AFS.
720 You created the root.afs volume in Starting the File Server, Volume Server, and Salvager, and the Cache Manager mounted it automatically on the local /afs directory when you ran the AFS initialization script in Verifying the AFS Initialization Script. You now set the access control list (ACL) on the /afs directory; creating, mounting, and setting the ACL are the three steps required when creating any volume.
722 After setting the ACL on the root.afs volume, you create your cell's root.cell volume, mount it as a subdirectory of the /afs directory, and set the ACL. Create both a read/write and a regular mount point for the root.cell volume. The read/write mount point enables you to access the read/write version of replicated volumes when necessary. Creating both mount points essentially creates separate read-only and read-write copies of your filespace, and enables the Cache Manager to traverse the filespace on a read-only path or read/write path as appropriate. For further discussion of these concepts, see the chapter in the IBM AFS Administration Guide about administering volumes.
724 Then replicate both the root.afs and root.cell volumes. This is required if you want to replicate any other volumes in your cell, because all volumes mounted above a replicated volume must themselves be replicated in order for the Cache Manager to access the replica.
726 When the root.afs volume is replicated, the Cache Manager is programmed to access its read-only version (root.afs.readonly) whenever possible. To make changes to the contents of the root.afs volume (when, for example, you mount another cell's root.cell volume at the second level in your filespace), you must mount the root.afs volume temporarily, make the changes, release the volume and remove the temporary mount point. For instructions, see Enabling Access to Foreign Cells.
728 1. Issue the fs setacl command to edit the ACL on the /afs directory. Add an entry that grants the l (lookup) and r (read) permissions to the system:anyuser group, to enable all AFS users who can reach your cell to traverse through the directory. If you prefer to enable access only to locally authenticated users, substitute the system:authuser group.
730 Note that there is already an ACL entry that grants all seven access rights to the system:administrators group. It is a default entry that AFS places on every new volume's root directory.
732 # /usr/afs/bin/fs setacl /afs system:anyuser rl
734 1. Issue the vos create command to create the root.cell volume. Then issue the fs mkmount command to mount it as a subdirectory of the /afs directory, where it serves as the root of your cell's local AFS filespace. Finally, issue the fs setacl command to create an ACL entry for the system:anyuser group (or system:authuser group).
736 For the partition name argument, substitute the name of one of the machine's AFS server partitions (such as /vicepa). For the cellname argument, substitute your cell's fully-qualified Internet domain name (such as abc.com).
738 # /usr/afs/bin/vos create <machine name> <partition name> root.cell
740 # /usr/afs/bin/fs mkmount /afs/cellname root.cell
742 # /usr/afs/bin/fs setacl /afs/cellname system:anyuser rl
744 1. (Optional) Create a symbolic link to a shortened cell name, to reduce the length of pathnames for users in the local cell. For example, in the abc.com cell, /afs/abc is a link to /afs/abc.com.
748 # ln -s full_cellname short_cellname
750 1. Issue the fs mkmount command to create a read/write mount point for the root.cell volume (you created a regular mount point in Step 2).
752 By convention, the name of a read/write mount point begins with a period, both to distinguish it from the regular mount point and to make it visible only when the -a flag is used on the ls command.
754 Change directory to /usr/afs/bin to make it easier to access the command binaries.
758 # ./fs mkmount /afs/.cellname root.cell -rw
760 1. Issue the vos addsite command to define a replication site for both the root.afs and root.cell volumes. In each case, substitute for the partition name argument the partition where the volume's read/write version resides. When you install additional file server machines, it is a good idea to create replication sites on them as well.
762 # ./vos addsite <machine name> <partition name> root.afs
764 # ./vos addsite <machine name> <partition name> root.cell
766 1. Issue the fs examine command to verify that the Cache Manager can access both the root.afs and root.cell volumes, before you attempt to replicate them. The output lists each volume's name, volumeID number, quota, size, and the size of the partition that houses them. If you get an error message instead, do not continue before taking corrective action.
770 # ./fs examine /afs/cellname
772 1. Issue the vos release command to release a replica of the root.afs and root.cell volumes to the sites you defined in Step 5.
774 # ./vos release root.afs
776 # ./vos release root.cell
778 1. Issue the fs checkvolumes to force the Cache Manager to notice that you have released read-only versions of the volumes, then issue the fs examine command again. This time its output mentions the read-only version of the volumes (root.afs.readonly and root.cell.readonly) instead of the read/write versions, because of the Cache Manager's bias to access the read-only version of the root.afs volume if it exists.
784 # ./fs examine /afs/cellname
786 # Storing AFS Binaries in AFS
788 In the conventional configuration, you make AFS client binaries and configuration files available in the subdirectories of the /usr/afsws directory on client machines (afsws is an acronym for AFS workstation). You can conserve local disk space by creating /usr/afsws as a link to an AFS volume that houses the AFS client binaries and configuration files for this system type.
790 In this section you create the necessary volumes. The conventional location to which to link /usr/afsws is /afs/cellname/sysname/usr/afsws, where sysname is the appropriate system type name as specified in the IBM AFS Release Notes. The instructions in Installing Additional Client Machines assume that you have followed the instructions in this section.
792 If you have previously run AFS in the cell, the volumes possibly already exist. If so, you need to perform Step 8 only.
794 The current working directory is still /usr/afs/bin, which houses the fs and vos command suite binaries. In the following commands, it is possible you still need to specify the pathname to the commands, depending on how your PATH environment variable is set.
796 1. Issue the vos create command to create volumes for storing the AFS client binaries for this system type. The following example instruction creates volumes called sysname, sysname.usr, and sysname.usr.afsws. Refer to the IBM AFS Release Notes to learn the proper value of sysname for this system type.
798 # vos create <machine name> <partition name> sysname
800 # vos create <machine name> <partition name> sysname.usr
802 # vos create <machine name> <partition name> sysname.usr.afsws
804 1. Issue the fs mkmount command to mount the newly created volumes. Because the root.cell volume is replicated, you must precede the cellname part of the pathname with a period to specify the read/write mount point, as shown. Then issue the vos release command to release a new replica of the root.cell volume, and the fs checkvolumes command to force the local Cache Manager to access them.
806 # fs mkmount -dir /afs/.cellname/sysname -vol sysname
808 # fs mkmount -dir /afs/.cellname/sysname/usr -vol sysname.usr
810 # fs mkmount -dir /afs/.cellname/sysname/usr/afsws -vol sysname.usr.afsws
812 # vos release root.cell
816 1. Issue the fs setacl command to grant the l (lookup) and r (read) permissions to the system:anyuser group on each new directory's ACL.
818 # cd /afs/.cellname/sysname
820 # fs setacl -dir . usr usr/afsws -acl system:anyuser rl
822 1. Issue the fs setquota command to set an unlimited quota on the volume mounted at the /afs/cellname/sysname/usr/afsws directory. This enables you to copy all of the appropriate files from the CD-ROM into the volume without exceeding the volume's quota.
824 If you wish, you can set the volume's quota to a finite value after you complete the copying operation. At that point, use the vos examine command to determine how much space the volume is occupying. Then issue the fs setquota command to set a quota that is slightly larger.
826 # fs setquota /afs/.cellname/sysname/usr/afsws 0
828 1. Mount the AFS CD-ROM for this machine's system type on the local /cdrom directory, if it is not already. For instructions on mounting CD-ROMs (either locally or remotely via NFS), consult the operating system documentation.
830 1. Copy the contents of the indicated directories from the CD-ROM into the /afs/cellname/sysname/usr/afsws directory.
832 # cd /afs/.cellname/sysname/usr/afsws
834 # cp -rp /cdrom/sysname/bin .
836 # cp -rp /cdrom/sysname/etc .
838 # cp -rp /cdrom/sysname/include .
840 # cp -rp /cdrom/sysname/lib .
842 1. Issue the fs setacl command to set the ACL on each directory appropriately. To comply with the terms of your AFS License agreement, you must prevent unauthorized users from accessing AFS software. To enable access for locally authenticated users only, set the ACL on the etc, include, and lib subdirectories to grant the l and r permissions to the system:authuser group rather than the system:anyuser group. The system:anyuser group must retain the l and r permissions on the bin subdirectory to enable unauthenticated users to access the klog binary. To ensure that unauthorized users are not accessing AFS software, check periodically that the ACLs on these directories are set properly.
844 # cd /afs/.cellname/sysname/usr/afsws
846 # fs setacl -dir etc include lib -acl system:authuser rl \
849 1. Create /usr/afsws on the local disk as a symbolic link to the directory /afs/cellname/@sys/usr/afsws. You can specify the actual system name instead of @sys if you wish, but the advantage of using @sys is that it remains valid if you upgrade this machine to a different system type.
851 # ln -s /afs/cellname/@sys/usr/afsws /usr/afsws
853 1. (Optional) To enable users to issue commands from the AFS suites (such as fs) without having to specify a pathname to their binaries, include the /usr/afsws/bin and /usr/afsws/etc directories in the PATH environment variable you define in each user's shell initialization file (such as .cshrc).
855 Storing AFS Documents in AFS
857 # The AFS distribution includes the following documents:
859 - IBM AFS Release Notes
861 - IBM AFS Quick Beginnings
865 - IBM AFS Administration Reference
867 - IBM AFS Administration Guide
869 The AFS CD-ROM for each system type has a top-level Documentation directory, with a subdirectory for each document format provided. The different formats are suitable for online viewing, printing, or both.
871 This section explains how to create and mount a volume to house the documents, making them available to your users. The recommended mount point for the volume is /afs/cellname/afsdoc. If you wish, you can create a link to the mount point on each client machine's local disk, called /usr/afsdoc. Alternatively, you can create a link to the mount point in each user's home directory. You can also choose to permit users to access only certain documents (most probably, the IBM AFS User Guide) by creating different mount points or setting different ACLs on different document directories.
873 The current working directory is still /usr/afs/bin, which houses the fs and vos command suite binaries you use to create and mount volumes. In the following commands, it is possible you still need to specify the pathname to the commands, depending on how your PATH environment variable is set.
875 1. Issue the vos create command to create a volume for storing the AFS documentation. Include the -maxquota argument to set an unlimited quota on the volume. This enables you to copy all of the appropriate files from the CD-ROM into the volume without exceeding the volume's quota.
877 If you wish, you can set the volume's quota to a finite value after you complete the copying operations. At that point, use the vos examine command to determine how much space the volume is occupying. Then issue the fs setquota command to set a quota that is slightly larger.
879 # vos create <machine name> <partition name> afsdoc -maxquota 0
881 1. Issue the fs mkmount command to mount the new volume. Because the root.cell volume is replicated, you must precede the cellname with a period to specify the read/write mount point, as shown. Then issue the vos release command to release a new replica of the root.cell volume, and the fs checkvolumes command to force the local Cache Manager to access them.
883 # fs mkmount -dir /afs/.cellname/afsdoc -vol afsdoc
885 # vos release root.cell
889 1. Issue the fs setacl command to grant the rl permissions to the system:anyuser group on the new directory's ACL.
891 # cd /afs/.cellname/afsdoc
893 # fs setacl . system:anyuser rl
895 1. Mount the AFS CD-ROM for any system type on the local /cdrom directory, if one is not already. For instructions on mounting CD-ROMs (either locally or remotely via NFS), consult the operating system documentation.
897 1. Copy the AFS documents in one or more formats from the CD-ROM into subdirectories of the /afs/cellname/afsdoc directory. Repeat the commands for each format.
903 # cp -rp /cdrom/Documentation/format .
905 If you choose to store the HTML version of the documents in AFS, note that in addition to a subdirectory for each document there are several files with a .gif extension, which enable readers to move easily between sections of a document. The file called index.htm is an introductory HTML page that contains a hyperlink to each of the documents. For online viewing to work properly, these files must remain in the top-level HTML directory (the one named, for example, /afs/cellname/afsdoc/html).
907 1. (Optional) If you believe it is helpful to your users to access the AFS documents in a certain format via a local disk directory, create /usr/afsdoc on the local disk as a symbolic link to the documentation directory in AFS (/afs/cellname/afsdoc/format\_name).
909 # ln -s /afs/cellname/afsdoc/format_name /usr/afsdoc
911 An alternative is to create a link in each user's home directory to the /afs/cellname/afsdoc/format\_name directory.
913 # Storing System Binaries in AFS
915 You can also choose to store other system binaries in AFS volumes, such as the standard UNIX programs conventionally located in local disk directories such as /etc, /bin, and /lib. Storing such binaries in an AFS volume not only frees local disk space, but makes it easier to update binaries on all client machines.
917 The following is a suggested scheme for storing system binaries in AFS. It does not include instructions, but you can use the instructions in Storing AFS Binaries in AFS (which are for AFS-specific binaries) as a template.
919 Some files must remain on the local disk for use when AFS is inaccessible (during bootup and file server or network outages). The required binaries include the following:
921 - A text editor, network commands, and so on
923 - Files used during the boot sequence before the afsd program runs, such as initialization and configuration files, and binaries for commands that mount file systems
925 - Files used by dynamic kernel loader programs
927 In most cases, it is more secure to enable only locally authenticated users to access system binaries, by granting the l (lookup) and r (read) permissions to the system:authuser group on the ACLs of directories that contain the binaries. If users need to access a binary while unauthenticated, however, the ACL on its directory must grant those permissions to the system:anyuser group.
929 The following chart summarizes the suggested volume and mount point names for storing system binaries. It uses a separate volume for each directory. You already created a volume called sysname for this machine's system type when you followed the instructions in Storing AFS Binaries in AFS.
931 You can name volumes in any way you wish, and mount them at other locations than those suggested here. However, this scheme has several advantages:
933 - Volume names clearly identify volume contents
935 - Using the sysname prefix on every volume makes it is easy to back up all of the volumes together, because the AFS Backup System enables you to define sets of volumes based on a string included in all of their names
937 - It makes it easy to track related volumes, keeping them together on the same file server machine if desired
939 - There is a clear relationship between volume name and mount point name
941 Volume Name Mount Point
942 sysname /afs/cellname/sysname
943 sysname.bin /afs/cellname/sysname/bin
944 sysname.etc /afs/cellname/sysname/etc
945 sysname.usr /afs/cellname/sysname/usr
946 sysname.usr.afsws /afs/cellname/sysname/usr/afsws
947 sysname.usr.bin /afs/cellname/sysname/usr/bin
948 sysname.usr.etc /afs/cellname/sysname/usr/etc
949 sysname.usr.inc /afs/cellname/sysname/usr/include
950 sysname.usr.lib /afs/cellname/sysname/usr/lib
951 sysname.usr.loc /afs/cellname/sysname/usr/local
952 sysname.usr.man /afs/cellname/sysname/usr/man
953 sysname.usr.sys /afs/cellname/sysname/usr/sys
955 # Enabling Access to Foreign Cells
957 In this section you create a mount point in your AFS filespace for the root.cell volume of each foreign cell that you want to enable your users to access. For users working on a client machine to access the cell, there must in addition be an entry for it in the client machine's local /usr/vice/etc/CellServDB file. (The instructions in Creating the Client [[CellServDB]] File suggest that you use the [[CellServDB]].sample file included in the AFS distribution as the basis for your cell's client [[CellServDB]] file. The sample file lists all of the cells that had agreed to participate in the AFS global namespace at the time your AFS CD-ROM was created. As mentioned in that section, the AFS Product Support group also maintains a copy of the file, updating it as necessary.)
959 The chapter in the IBM AFS Administration Guide about cell administration and configuration issues discusses the implications of participating in the global AFS namespace. The chapter about administering client machines explains how to maintain knowledge of foreign cells on client machines, and includes suggestions for maintaining a central version of the file in AFS.
961 1. Issue the fs mkmount command to mount each foreign cell's root.cell volume on a directory called /afs/foreign\_cell. Because the root.afs volume is replicated, you must create a temporary mount point for its read/write version in a directory to which you have write access (such as your cell's /afs/.cellname directory). Create the mount points, issue the vos release command to release new replicas to the read-only sites for the root.afs volume, and issue the fs checkvolumes command to force the local Cache Manager to access the new replica. <dl>
963 <dd> You need to issue the fs mkmount command only once for each foreign cell's root.cell volume. You do not need to repeat the command on each client machine. </dd>
966 Substitute your cell's name for cellname.
970 # /usr/afs/bin/fs mkmount temp root.afs
972 Repeat the fs mkmount command for each foreign cell you wish to mount at this time.
974 # /usr/afs/bin/fs mkmount temp/foreign_cell root.cell -c foreign_cell
976 Issue the following commands only once.
978 # /usr/afs/bin/fs rmmount temp
980 # /usr/afs/bin/vos release root.afs
982 # /usr/afs/bin/fs checkvolumes
984 If this machine is going to remain an AFS client after you complete the
985 installation, verify that the local /usr/vice/etc/CellServDB file includes an
986 entry for each foreign cell.
988 For each cell that does not already have an entry, complete the following instructions:
990 Create an entry in the [[CellServDB]] file. Be sure to comply with the
991 formatting instructions in Creating the Client [[CellServDB]] File.
993 Issue the fs newcell command to add an entry for the cell directly to
994 the list that the Cache Manager maintains in kernel memory. Provide each
995 database server machine's fully qualified hostname.
998 # /usr/afs/bin/fs newcell <foreign_cell> <dbserver1> [<dbserver2>] [<dbserver3>]
1001 If you plan to maintain a central version of the [[CellServDB]] file
1002 (the conventional location is /afs/cellname/common/etc/CellServDB), create it
1003 now as a copy of the local /usr/vice/etc/CellServDB file. Verify that it
1004 includes an entry for each foreign cell you want your users to be able to
1011 # cp /usr/vice/etc/CellServDB common/etc
1013 # /usr/afs/bin/vos release root.cell
1015 Issue the ls command to verify that the new cell's mount point is visible in your filespace. The output lists the directories at the top level of the new cell's AFS filespace.
1017 # ls /afs/foreign_cell
1019 Please register your cell with the AFS Product Support group at this time. If you do not want to participate in the global AFS namespace, they list your cell in a private [[CellServDB]] file that is not available to other AFS cells.
1021 # Improving Cell Security
1023 This section discusses ways to improve the security of AFS data in your cell. Also see the chapter in the IBM AFS Administration Guide about configuration and administration issues.
1025 # Controlling root Access
1027 As on any machine, it is important to prevent unauthorized users from logging onto an AFS server or client machine as the local superuser root. Take care to keep the root password secret.
1029 The local root superuser does not have special access to AFS data through the Cache Manager (as members of the system:administrators group do), but it does have the following privileges:
1031 - On client machines, the ability to issue commands from the fs suite that affect AFS performance
1033 - On server machines, the ability to disable authorization checking, or to install rogue process binaries
1035 ## Controlling System Administrator Access
1037 Following are suggestions for managing AFS administrative privilege:
1039 - Create an administrative account for each administrator named something like username.admin. Administrators authenticate under these identities only when performing administrative tasks, and destroy the administrative tokens immediately after finishing the task (either by issuing the unlog command, or the klog command to adopt their regular identity).
1041 - Set a short ticket lifetime for administrator accounts (for example, 20 minutes) by using the -lifetime argument to the kas setfields command, which is described in the IBM AFS Administration Reference. Do not however, use a short lifetime for users who issue long-running backup commands.
1043 - Limit the number of system administrators in your cell, especially those who belong to the system:administrators group. By default they have all ACL rights on all directories in the local AFS filespace, and therefore must be trusted not to examine private files.
1045 - Limit the use of system administrator accounts on machines in public areas. It is especially important not to leave such machines unattended without first destroying the administrative tokens.
1047 - Limit the use by administrators of standard UNIX commands that make connections to remote machines (such as the telnet utility). Many of these programs send passwords across the network without encrypting them.
1049 ## Protecting Sensitive AFS Directories
1051 Some subdirectories of the /usr/afs directory contain files crucial to cell security. Unauthorized users must not read or write to these files because of the potential for misuse of the information they contain.
1053 As the BOS Server initializes for the first time on a server machine, it creates several files and directories (as mentioned in Starting the BOS Server). It sets their owner to the local superuser root and sets their mode bits to enable writing by the owner only; in some cases, it also restricts reading.
1055 At each subsequent restart, the BOS Server checks that the owner and mode bits on these files are still set appropriately. If they are not, it write the following message to the /usr/afs/logs/BosLog file:
1057 Bosserver reports inappropriate access on server directories
1059 The BOS Server does not reset the mode bits, which enables you to set alternate values if you wish.
1061 The following charts lists the expected mode bit settings. A question mark indicates that the BOS Server does not check that mode bit.
1064 /usr/afs/backup drwx???---
1065 /usr/afs/bin drwxr?xr-x
1066 /usr/afs/db drwx???---
1067 /usr/afs/etc drwxr?xr-x
1068 /usr/afs/etc/KeyFile -rw????---
1069 /usr/afs/etc/UserList -rw?????--
1070 /usr/afs/local drwx???---
1071 /usr/afs/logs drwxr?xr-x
1073 # Removing Client Functionality
1075 Follow the instructions in this section only if you do not wish this machine to remain an AFS client. Removing client functionality means that you cannot use this machine to access AFS files.
1077 1. Remove the files from the /usr/vice/etc directory. The command does not remove the directory for files used by the dynamic kernel loader program, if it exists on this system type. Those files are still needed on a server-only machine.
1085 1. Create symbolic links to the [[ThisCell]] and [[CellServDB]] files in the /usr/afs/etc directory. This makes it possible to issue commands from the AFS command suites (such as bos and fs) on this machine.
1087 # ln -s /usr/afs/etc/ThisCell ThisCell
1089 # ln -s /usr/afs/etc/CellServDB CellServDB
1091 1. On IRIX systems, issue the chkconfig command to deactivate the afsclient configuration variable.
1093 # /etc/chkconfig -f afsclient off
1095 1. Reboot the machine. Most system types use the shutdown command, but the appropriate options vary.
1099 # shutdown appropriate_options