1 <?xml version="1.0" encoding="UTF-8"?>
3 <title>Installing the First AFS Machine</title>
7 <primary>file server machine</primary>
9 <seealso>first AFS machine</seealso>
11 <seealso>file server machine, additional</seealso>
15 <primary>instructions</primary>
17 <secondary>first AFS machine</secondary>
21 <primary>installing</primary>
23 <secondary>first AFS machine</secondary>
26 This chapter describes how to install the first AFS machine in your cell, configuring it as both a file server machine and a
27 client machine. After completing all procedures in this chapter, you can remove the client functionality if you wish, as described
28 in <link linkend="HDRWQ98">Removing Client Functionality</link>.</para>
30 <para>To install additional file server machines after completing this chapter, see <link linkend="HDRWQ99">Installing Additional
31 Server Machines</link>.</para>
33 <para>To install additional client machines after completing this chapter, see <link linkend="HDRWQ133">Installing Additional
34 Client Machines</link>. <indexterm>
35 <primary>requirements</primary>
37 <secondary>first AFS machine</secondary>
40 <sect1 id="Header_29">
41 <title>Requirements and Configuration Decisions</title>
43 <para>The instructions in this chapter assume that you meet the following requirements.
46 <para>You are logged onto the machine's console as the local superuser <emphasis role="bold">root</emphasis></para>
50 <para>A standard version of one of the operating systems supported by the current version of AFS is running on the
55 <para>You have either installed the provided OpenAFS packages for
56 your system, have access to a binary distribution tarball, or have
57 successfully built OpenAFS from source</para>
61 <para>You have a Kerberos v5 realm running for your site. If you are
62 working with an existing cell which uses
63 <emphasis role="bold">kaserver</emphasis> or Kerberos v4 for
64 authentication, please see
65 <link linkend="KAS001">kaserver and Legacy Kerberos v4 Authentication</link>
66 for the modifications required to this installation procedure.</para>
70 <para>You have NTP or a similar time service deployed to ensure
71 rough clock syncronistation between your clients and servers.</para>
73 </itemizedlist></para>
75 <para>You must make the following configuration decisions while installing the first AFS machine. To speed the installation
76 itself, it is best to make the decisions before beginning. See the chapter in the <emphasis>OpenAFS Administration
77 Guide</emphasis> about issues in cell administration and configuration for detailed guidelines. <indexterm>
78 <primary>cell name</primary>
80 <secondary>choosing</secondary>
81 </indexterm> <indexterm>
82 <primary>AFS filespace</primary>
84 <secondary>deciding how to configure</secondary>
85 </indexterm> <indexterm>
86 <primary>filespace</primary>
88 <see>AFS filespace</see>
89 </indexterm> <itemizedlist>
91 <para>Select the first AFS machine</para>
95 <para>Select the cell name</para>
99 <para>Decide which partitions or logical volumes to configure as AFS server partitions, and choose the directory names on
100 which to mount them</para>
104 <para>Decide how big to make the client cache</para>
108 <para>Decide how to configure the top levels of your cell's AFS filespace</para>
110 </itemizedlist></para>
112 <para>This chapter is divided into three large sections corresponding to the three parts of installing the first AFS machine.
113 Perform all of the steps in the order they appear. Each functional section begins with a summary of the procedures to perform.
114 The sections are as follows: <itemizedlist>
116 <para>Installing server functionality (begins in <link linkend="HDRWQ18">Overview: Installing Server
117 Functionality</link>)</para>
121 <para>Installing client functionality (begins in <link linkend="HDRWQ63">Overview: Installing Client
122 Functionality</link>)</para>
126 <para>Configuring your cell's filespace, establishing further security mechanisms, and enabling access to foreign cells
127 (begins in <link linkend="HDRWQ71">Overview: Completing the Installation of the First AFS Machine</link>)</para>
129 </itemizedlist></para>
132 <primary>overview</primary>
134 <secondary>installing server functionality on first AFS machine</secondary>
138 <primary>first AFS machine</primary>
140 <secondary>server functionality</secondary>
144 <primary>installing</primary>
146 <secondary>server functionality</secondary>
148 <tertiary>first AFS machine</tertiary>
153 <title>Overview: Installing Server Functionality</title>
155 <para>In the first phase of installing your cell's first AFS machine, you install file server and database server functionality
156 by performing the following procedures:
159 <para>Choose which machine to install as the first AFS machine</para>
163 <para>Create AFS-related directories on the local disk</para>
167 <para>Incorporate AFS modifications into the machine's kernel</para>
171 <para>Configure partitions or logical volumes for storing AFS volumes</para>
175 <para>On some system types, install and configure an AFS-modified version of the <emphasis role="bold">fsck</emphasis>
180 <para>If the machine is to remain a client machine, incorporate AFS into its authentication system</para>
184 <para>Start the Basic OverSeer (BOS) Server</para>
188 <para>Define the cell name and the machine's cell membership</para>
192 <para>Start the database server processes: Backup Server, Protection Server, and Volume Location
197 <para>Configure initial security mechanisms</para>
201 <para>Start the <emphasis role="bold">fs</emphasis> process, which incorporates three component processes: the File
202 Server, Volume Server, and Salvager</para>
206 <para>Optionally, start the server portion of the Update Server</para>
209 </orderedlist></para>
213 <title>Choosing the First AFS Machine</title>
215 <para>The first AFS machine you install must have sufficient disk space to store AFS volumes. To take best advantage of AFS's
216 capabilities, store client-side binaries as well as user files in volumes. When you later install additional file server
217 machines in your cell, you can distribute these volumes among the different machines as you see fit.</para>
219 <para>These instructions configure the first AFS machine as a <emphasis>database server machine</emphasis>, the <emphasis>binary
220 distribution machine</emphasis> for its system type, and the cell's <emphasis>system control machine</emphasis>. For a
221 description of these roles, see the <emphasis>OpenAFS Administration Guide</emphasis>.</para>
223 <para>Installation of additional machines is simplest if the first machine has the lowest IP address of any database server
224 machine you currently plan to install. If you later install database server functionality on a machine with a lower IP address,
225 you must first update the <emphasis role="bold">/usr/vice/etc/CellServDB</emphasis> file on all of your cell's client machines.
226 For more details, see <link linkend="HDRWQ114">Installing Database Server Functionality</link>.</para>
229 <sect1 id="Header_32">
230 <title>Creating AFS Directories</title>
233 <primary>usr/afs directory</primary>
235 <secondary>first AFS machine</secondary>
239 <primary>first AFS machine</primary>
241 <secondary>/usr/afs directory</secondary>
245 <primary>creating</primary>
247 <secondary>/usr/afs directory</secondary>
249 <tertiary>first AFS machine</tertiary>
253 <primary>usr/vice/etc directory</primary>
255 <secondary>first AFS machine</secondary>
259 <primary>first AFS machine</primary>
261 <secondary>/usr/vice/etc directory</secondary>
265 <primary>creating</primary>
267 <secondary>/usr/vice/etc directory</secondary>
269 <tertiary>first AFS machine</tertiary>
273 <primary>/ as start to file and directory names</primary>
275 <secondary>see alphabetized entries without initial slash</secondary>
278 <para>If you are installing from packages (such as Debian .deb or
279 Fedora/SuSe .rpm files), you should now install all of the available
280 OpenAFS packages for your system type. Typically, these will include
281 packages for client and server functionality, and a seperate package
282 containing a suitable kernel module for your running kernel. Consult
283 the package lists on the OpenAFS website to determine the packages
284 appropriate for your system.</para>
286 <para>If you are installing from a tarfile, or from a locally compiled
287 source tree you should create the <emphasis role="bold">/usr/afs</emphasis>
288 and <emphasis role="bold">/usr/vice/etc</emphasis> directories on the
289 local disk, to house server and client files respectively. Subsequent
290 instructions copy files from the distribution tarfile into them. </para>
292 # <emphasis role="bold">mkdir /usr/afs</emphasis>
293 # <emphasis role="bold">mkdir /usr/vice</emphasis>
294 # <emphasis role="bold">mkdir /usr/vice/etc</emphasis>
299 <title>Performing Platform-Specific Procedures</title>
301 <para>Several of the initial procedures for installing a file server machine differ for each system type. For convenience, the
302 following sections group them together for each system type: <itemizedlist>
304 <primary>kernel extensions</primary>
306 <see>AFS kernel extensions</see>
310 <primary>loading AFS kernel extensions</primary>
312 <see>incorporating</see>
316 <primary>building</primary>
318 <secondary>AFS extensions into kernel</secondary>
320 <see>incorporating AFS kernel extensions</see>
324 <para>Incorporate AFS modifications into the kernel.</para>
326 <para>The kernel on every AFS client machine and, on some systems,
327 the AFS fileservers, must incorporate AFS extensions. On machines
328 that use a dynamic kernel module loader, it is conventional to
329 alter the machine's initialization script to load the AFS extensions
330 at each reboot. <indexterm>
331 <primary>AFS server partition</primary>
333 <secondary>mounted on /vicep directory</secondary>
334 </indexterm> <indexterm>
335 <primary>partition</primary>
337 <see>AFS server partition</see>
338 </indexterm> <indexterm>
339 <primary>logical volume</primary>
341 <see>AFS server partition</see>
342 </indexterm> <indexterm>
343 <primary>requirements</primary>
345 <secondary>AFS server partition name and location</secondary>
346 </indexterm> <indexterm>
347 <primary>naming conventions for AFS server partition</primary>
348 </indexterm> <indexterm>
349 <primary>vicep<emphasis>xx</emphasis> directory</primary>
351 <see>AFS server partition</see>
352 </indexterm> <indexterm>
353 <primary>directories</primary>
355 <secondary>/vicep<emphasis>xx</emphasis></secondary>
357 <see>AFS server partition</see>
362 <para>Configure server partitions or logical volumes to house AFS volumes.</para>
364 <para>Every AFS file server machine must have at least one partition or logical volume dedicated to storing AFS volumes
365 (for convenience, the documentation hereafter refers to partitions only). Each server partition is mounted at a directory
366 named <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable>, where <replaceable>xx</replaceable> is one or
367 two lowercase letters. By convention, the first 26 partitions are mounted on the directories called <emphasis
368 role="bold">/vicepa</emphasis> through <emphasis role="bold">/vicepz</emphasis>, the 27th one is mounted on the <emphasis
369 role="bold">/vicepaa</emphasis> directory, and so on through <emphasis role="bold">/vicepaz</emphasis> and <emphasis
370 role="bold">/vicepba</emphasis>, continuing up to the index corresponding to the maximum number of server partitions
371 supported in the current version of AFS (which is specified in the <emphasis>OpenAFS Release Notes</emphasis>).</para>
373 <para>The <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable> directories must reside in the file server
374 machine's root directory, not in one of its subdirectories (for example, <emphasis role="bold">/usr/vicepa</emphasis> is
375 not an acceptable directory location).
377 The <emphasis role="bold">fileserver</emphasis> will refuse to
379 any <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable>
380 folders that are not separate partitions. </para>
383 <para>The separate partition requirement may be overridden by
384 creating a file named
385 <emphasis role="bold">/vicep<replaceable>xx</replaceable>/AlwaysAttach</emphasis>;
386 however, mixed-use partitions, whether cache or fileserver,
387 have the risk that a non-AFS use will fill the partition and
388 not leave enough free space for AFS. Even though it is
389 allowed, be wary of configuring a mixed-use partition
390 without understanding the ramifications of doing so with the
391 workload on your filesystem.
393 <primary>AFS server partition</primary>
394 <secondary>AlwaysAttach</secondary>
399 <para>You can also add or remove server partitions on an existing file server machine. For instructions, see the chapter
400 in the <emphasis>OpenAFS Administration Guide</emphasis> about maintaining server machines.</para>
403 <para>Not all file system types supported by an operating system are necessarily supported as AFS server partitions. For
404 possible restrictions, see the <emphasis>OpenAFS Release Notes</emphasis>.</para>
409 <para>On system types using the <emphasis role="bold">inode</emphasis> storage format, install and configure a modified <emphasis role="bold">fsck</emphasis> program which
410 recognizes the structures that the File Server uses to organize volume data on AFS server partitions. The <emphasis
411 role="bold">fsck</emphasis> program provided with the operating system does not understand the AFS data structures, and so
412 removes them to the <emphasis role="bold">lost+found</emphasis> directory.</para>
416 <para>If the machine is to remain an AFS client machine, modify the machine's authentication system so that users obtain
417 an AFS token as they log into the local file system. Using AFS is simpler and more convenient for your users if you make
418 the modifications on all client machines. Otherwise, users must perform a two or three step login procedure (login to the local
419 system, then obtain Kerberos credentials, and then issue the <emphasis role="bold">aklog</emphasis> command). For further discussion of AFS
420 authentication, see the chapter in the <emphasis>OpenAFS Administration Guide</emphasis> about cell configuration and
421 administration issues.</para>
423 </itemizedlist></para>
425 <para>To continue, proceed to the appropriate section: <itemizedlist>
427 <para><link linkend="HDRWQ41">Getting Started on Linux Systems</link></para>
431 <para><link linkend="HDRWQ45">Getting Started on Solaris Systems</link></para>
435 <para><link linkend="HDRWQ21">Getting Started on AIX Systems</link></para>
437 </itemizedlist></para>
441 <title>Getting Started on Linux Systems</title>
444 <primary>replacing fsck program</primary>
446 <secondary>not necessary on Linux</secondary>
450 <primary>fsck program</primary>
452 <secondary>on first AFS machine</secondary>
454 <tertiary>Linux</tertiary>
458 <primary>first AFS machine</primary>
460 <secondary>fsck program</secondary>
462 <tertiary>on Linux</tertiary>
466 <primary>Linux</primary>
468 <secondary>fsck program replacement not necessary</secondary>
471 <para>Since this guide was originally written, the procedure for starting
472 OpenAFS has diverged significantly between different Linux distributions.
473 The instructions that follow are appropriate for both the Fedora and
474 RedHat Enterprise Linux packages distributed by OpenAFS. Additional
475 instructions are provided for those building from source.</para>
477 <para>Begin by running the AFS client startup scripts, which call the
478 <emphasis role="bold">modprobe</emphasis> program to dynamically
479 load the AFS modifications into the kernel. Then create partitions for
480 storing AFS volumes. You do not need to replace the Linux <emphasis
481 role="bold">fsck</emphasis> program. If the machine is to remain an
482 AFS client machine, incorporate AFS into the machine's Pluggable
483 Authentication Module (PAM) scheme. <indexterm>
484 <primary>incorporating AFS kernel extensions</primary>
486 <secondary>first AFS machine</secondary>
488 <tertiary>Linux</tertiary>
489 </indexterm> <indexterm>
490 <primary>AFS kernel extensions</primary>
492 <secondary>on first AFS machine</secondary>
494 <tertiary>Linux</tertiary>
495 </indexterm> <indexterm>
496 <primary>first AFS machine</primary>
498 <secondary>AFS kernel extensions</secondary>
500 <tertiary>on Linux</tertiary>
501 </indexterm> <indexterm>
502 <primary>Linux</primary>
504 <secondary>AFS kernel extensions</secondary>
506 <tertiary>on first AFS machine</tertiary>
510 <title>Loading AFS into the Linux Kernel</title>
512 <para>The <emphasis role="bold">modprobe</emphasis> program is the dynamic kernel loader for Linux. Linux does not support
513 incorporation of AFS modifications during a kernel build.</para>
515 <para>For AFS to function correctly, the <emphasis role="bold">modprobe</emphasis> program must run each time the machine
516 reboots, so your distribution's AFS initialization script invokes it automatically. The script also includes
517 commands that select the appropriate AFS library file automatically. In this section you run the script.</para>
519 <para>In later sections you verify that the script correctly initializes all AFS components, then activate a configuration
520 variable, which results in the script being incorporated into the Linux startup and shutdown sequence.</para>
522 <para>The procedure for starting up OpenAFS depends upon your distribution</para>
524 <title>Fedora and RedHat Enterprise Linux</title>
525 <para>OpenAFS provides RPMS for all current Fedora and RedHat Enterprise Linux (RHEL) releases on the OpenAFS web site and the OpenAFS yum repository.
529 http://dl.openafs.org/dl/openafs/<replaceable>VERSION</replaceable>,
530 where VERSION is the latest stable release of
531 OpenAFS. Download the
532 openafs-repository-<replaceable>VERSION</replaceable>.noarch.rpm
533 file for Fedora systems or the
534 openafs-repository-rhel-<replaceable>VERSION</replaceable>.noarch.rpm
535 file for RedHat-based systems.
539 <para>Install the downloaded RPM file using the following command:
541 # rpm -U openafs-repository*.rpm
546 <para>Install the RPM set for your operating system using the yum command as follows:
548 # yum -y install openafs-client openafs-server openafs-krb5 kmod-openafs
552 <para>Alternatively, you may use dynamically-compiled kernel
553 modules if you have the kernel headers, a compiler, and the
555 <ulink url="http://fedoraproject.org/wiki/EPEL"><citetitle>EPEL</citetitle></ulink> installed.
558 <para>To use dynamically-compiled kernel modules instead of statically compiled modules, use the following command instead of the kmod-openafs as shown above:
560 # yum install openafs-client openafs-server openafs-krb5 dkms-openafs
564 <!-- If you do this with current RHEL and Fedora releases you end up with
565 a dynroot'd client running - this breaks setting up the root.afs volume
566 as described later in this guide
568 <para>Run the AFS initialization script to load AFS extensions into
569 the kernel. You can ignore any error messages about the inability
570 to start the BOS Server or the Cache Manager or AFS client.</para>
572 # <emphasis role="bold">/etc/rc.d/init.d/openafs-client start</emphasis>
580 <title>Systems packaged as tar files</title>
581 <para>If you are running a system where the OpenAFS Binary Distribution
582 is provided as a tar file, or where you have built the system from
583 source yourself, you need to install the relevant components by hand
588 <para>Unpack the distribution tarball. The examples below assume
589 that you have unpacked the files into the
590 <emphasis role="bold">/tmp/afsdist</emphasis> directory. If you
591 pick a different location, substitute this in all of the following
592 examples. Once you have unpacked the distribution,
593 change directory as indicated.
595 # <emphasis role="bold">cd /tmp/afsdist/linux/dest/root.client/usr/vice/etc</emphasis>
596 </programlisting></para>
600 <para>Copy the AFS kernel library files to the local <emphasis role="bold">/usr/vice/etc/modload</emphasis> directory.
601 The filenames for the libraries have the format <emphasis
602 role="bold">libafs-</emphasis><replaceable>version</replaceable><emphasis role="bold">.o</emphasis>, where
603 <replaceable>version</replaceable> indicates the kernel build level. The string <emphasis role="bold">.mp</emphasis> in
604 the <replaceable>version</replaceable> indicates that the file is appropriate for machines running a multiprocessor
605 kernel. <programlisting>
606 # <emphasis role="bold">cp -rp modload /usr/vice/etc</emphasis>
607 </programlisting></para>
611 <para>Copy the AFS initialization script to the local directory for initialization files (by convention, <emphasis
612 role="bold">/etc/rc.d/init.d</emphasis> on Linux machines). Note the removal of the <emphasis role="bold">.rc</emphasis>
613 extension as you copy the script. <programlisting>
614 # <emphasis role="bold">cp -p afs.rc /etc/rc.d/init.d/afs</emphasis>
615 </programlisting></para>
618 <!-- I don't think we need to do this for Linux, and it complicates things if
619 dynroot is enabled ...
621 <para>Run the AFS initialization script to load AFS extensions into the kernel. You can ignore any error messages about
622 the inability to start the BOS Server or the Cache Manager or AFS client.</para>
624 # <emphasis role="bold">/etc/rc.d/init.d/afs start</emphasis>
631 <primary>configuring</primary>
633 <secondary>AFS server partition on first AFS machine</secondary>
635 <tertiary>Linux</tertiary>
639 <primary>AFS server partition</primary>
641 <secondary>configuring on first AFS machine</secondary>
643 <tertiary>Linux</tertiary>
647 <primary>first AFS machine</primary>
649 <secondary>AFS server partition</secondary>
651 <tertiary>on Linux</tertiary>
655 <primary>Linux</primary>
657 <secondary>AFS server partition</secondary>
659 <tertiary>on first AFS machine</tertiary>
665 <title>Configuring Server Partitions on Linux Systems</title>
667 <para>Every AFS file server machine must have at least one partition or logical volume dedicated to storing AFS volumes. Each
668 server partition is mounted at a directory named <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable>, where
669 <replaceable>xx</replaceable> is one or two lowercase letters. The <emphasis
670 role="bold">/vicep</emphasis><replaceable>xx</replaceable> directories must reside in the file server machine's root
671 directory, not in one of its subdirectories (for example, <emphasis role="bold">/usr/vicepa</emphasis> is not an acceptable
672 directory location). For additional information, see <link linkend="HDRWQ20">Performing Platform-Specific Procedures</link>.
675 <para>Create a directory called <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable> for each AFS server
676 partition you are configuring (there must be at least one). Repeat the command for each partition. <programlisting>
677 # <emphasis role="bold">mkdir /vicep</emphasis><replaceable>xx</replaceable>
678 </programlisting></para>
682 <para>Add a line with the following format to the file systems registry file, <emphasis
683 role="bold">/etc/fstab</emphasis>, for each directory just created. The entry maps the directory name to the disk
684 partition to be mounted on it. <programlisting>
685 /dev/<replaceable>disk</replaceable> /vicep<replaceable>xx</replaceable> ext2 defaults 0 2
686 </programlisting></para>
688 <para>The following is an example for the first partition being configured.</para>
691 /dev/sda8 /vicepa ext2 defaults 0 2
696 <para>Create a file system on each partition that is to be mounted at a <emphasis
697 role="bold">/vicep</emphasis><replaceable>xx</replaceable> directory. The following command is probably appropriate, but
698 consult the Linux documentation for more information. <programlisting>
699 # <emphasis role="bold">mkfs -v /dev/</emphasis><replaceable>disk</replaceable>
700 </programlisting></para>
704 <para>Mount each partition by issuing either the <emphasis role="bold">mount -a</emphasis> command to mount all
705 partitions at once or the <emphasis role="bold">mount</emphasis> command to mount each partition in turn.</para>
709 <para>If you plan to retain client functionality on this machine after completing the installation, proceed to <link
710 linkend="HDRWQ44">Enabling AFS Login on Linux Systems</link>. Otherwise, proceed to <link linkend="HDRWQ50">Starting the
711 BOS Server</link>.</para>
713 </orderedlist></para>
716 <primary>enabling AFS login</primary>
718 <secondary>file server machine</secondary>
720 <tertiary>Linux</tertiary>
724 <primary>AFS login</primary>
726 <secondary>on file server machine</secondary>
728 <tertiary>Linux</tertiary>
732 <primary>first AFS machine</primary>
734 <secondary>AFS login</secondary>
736 <tertiary>on Linux</tertiary>
740 <primary>Linux</primary>
742 <secondary>AFS login</secondary>
744 <tertiary>on file server machine</tertiary>
748 <primary>PAM</primary>
750 <secondary>on Linux</secondary>
752 <tertiary>file server machine</tertiary>
757 <title>Enabling AFS Login on Linux Systems</title>
760 <para>If you plan to remove client functionality from this machine
761 after completing the installation, skip this section and proceed
762 to <link linkend="HDRWQ50">Starting the BOS Server</link>.</para>
765 <para>At this point you incorporate AFS into the operating system's
766 Pluggable Authentication Module (PAM) scheme. PAM integrates all
767 authentication mechanisms on the machine, including login, to provide
768 the security infrastructure for authenticated access to and from the
771 <para>You should first configure your system to obtain Kerberos v5
772 tickets as part of the authentication process, and then run an AFS PAM
773 module to obtain tokens from those tickets after authentication. Many
774 Linux distributions come with a Kerberos v5 PAM module (usually called
775 pam-krb5 or pam_krb5), or you can download and install <ulink
776 url="http://www.eyrie.org/~eagle/software/pam-krb5">Russ Allbery's
777 Kerberos v5 PAM module</ulink>, which is tested regularly with AFS.
778 See the instructions of whatever PAM module you use for how to
781 <para>Some Kerberos v5 PAM modules do come with native AFS support
782 (usually requiring the Heimdal Kerberos implementation rather than the
783 MIT Kerberos implementation). If you are using one of those PAM
784 modules, you can configure it to obtain AFS tokens. It's more common,
785 however, to separate the AFS token acquisition into a separate PAM
788 <para>The recommended AFS PAM module is <ulink
789 url="http://www.eyrie.org/~eagle/software/pam-afs-session/">Russ
790 Allbery's pam-afs-session module</ulink>. It should work with any of
791 the Kerberos v5 PAM modules. To add it to the PAM configuration, you
792 often only need to add configuration to the session group:</para>
795 <title>Linux PAM session example</title>
796 <literallayout>session required pam_afs_session.so</literallayout>
799 <para>If you also want to obtain AFS tokens for <command>scp</command>
800 and similar commands that don't open a session, you will also need to
801 add the AFS PAM module to the auth group so that the PAM
802 <function>setcred</function> call will obtain tokens. The
803 <literal>pam_afs_session</literal> module will always return success
804 for authentication so that it can be added to the auth group only for
805 <function>setcred</function>, so make sure that it's not marked as
806 <literal>sufficient</literal>.</para>
809 <title>Linux PAM auth example</title>
810 <literallayout>auth [success=ok default=1] pam_krb5.so
811 auth [default=done] pam_afs_session.so
812 auth required pam_unix.so try_first_pass</literallayout>
815 <para>This example will work if you want to try Kerberos v5 first and
816 then fall back to regular Unix authentication.
817 <literal>success=ok</literal> for the Kerberos PAM module followed by
818 <literal>default=done</literal> for the AFS PAM module will cause a
819 successful Kerberos login to run the AFS PAM module and then skip the
820 Unix authentication module. <literal>default=1</literal> on the
821 Kerberos PAM module causes failure of that module to skip the next
822 module (the AFS PAM module) and fall back to the Unix module. If you
823 want to try Unix authentication first and rearrange the order, be sure
824 to use <literal>default=die</literal> instead.</para>
826 <para>The PAM configuration is stored in different places in different
827 Linux distributions. On Red Hat, look in
828 <filename>/etc/pam.d/system-auth</filename>. On Debian and
829 derivatives, look in <filename>/etc/pam.d/common-session</filename>
830 and <filename>/etc/pam.d/common-auth</filename>.</para>
832 <para>For additional configuration examples and the configuration
833 options of the AFS PAM module, see its documentation. For more
834 details on the available options for the PAM configuration, see the
835 Linux PAM documentation.</para>
837 <para>Sites which still require <command>kaserver</command> or
838 external Kerberos v4 authentication should consult <link
839 linkend="KAS015">Enabling kaserver based AFS Login on Linux
840 Systems</link> for details of how to enable AFS login on Linux.</para>
842 <para>Proceed to <link linkend="HDRWQ50">Starting the BOS
843 Server</link> (or if referring to these instructions while installing
844 an additional file server machine, return to <link
845 linkend="HDRWQ108">Starting Server Programs</link>).</para>
850 <title>Getting Started on Solaris Systems</title>
852 <para>Begin by running the AFS initialization script to call the <emphasis role="bold">modload</emphasis> program distributed by
853 Sun Microsystems, which dynamically loads AFS modifications into the kernel. Then create partitions for storing AFS volumes, and
854 install and configure the AFS-modified <emphasis role="bold">fsck</emphasis> program to run on AFS server partitions. If the
855 machine is to remain an AFS client machine, incorporate AFS into the machine's Pluggable Authentication Module (PAM) scheme.
857 <primary>incorporating AFS kernel extensions</primary>
859 <secondary>first AFS machine</secondary>
861 <tertiary>Solaris</tertiary>
862 </indexterm> <indexterm>
863 <primary>AFS kernel extensions</primary>
865 <secondary>on first AFS machine</secondary>
867 <tertiary>Solaris</tertiary>
868 </indexterm> <indexterm>
869 <primary>first AFS machine</primary>
871 <secondary>AFS kernel extensions</secondary>
873 <tertiary>on Solaris</tertiary>
874 </indexterm> <indexterm>
875 <primary>Solaris</primary>
877 <secondary>AFS kernel extensions</secondary>
879 <tertiary>on first AFS machine</tertiary>
883 <title>Loading AFS into the Solaris Kernel</title>
885 <para>The <emphasis role="bold">modload</emphasis> program is the dynamic kernel loader provided by Sun Microsystems for
886 Solaris systems. Solaris does not support incorporation of AFS modifications during a kernel build.</para>
888 <para>For AFS to function correctly, the <emphasis role="bold">modload</emphasis> program must run each time the machine
889 reboots, so the AFS initialization script (included on the AFS CD-ROM) invokes it automatically. In this section you copy the
890 appropriate AFS library file to the location where the <emphasis role="bold">modload</emphasis> program accesses it and then
891 run the script.</para>
893 <para>In later sections you verify that the script correctly initializes all AFS components, then create the links that
894 incorporate AFS into the Solaris startup and shutdown sequence. <orderedlist>
896 <para>Unpack the OpenAFS Solaris distribution tarball. The examples
897 below assume that you have unpacked the files into the
898 <emphasis role="bold">/tmp/afsdist</emphasis> directory. If you
899 pick a diferent location, substitute this in all of the following
900 exmaples. Once you have unpacked the distribution, change directory
903 # <emphasis role="bold">cd /tmp/afsdist/sun4x_56/dest/root.client/usr/vice/etc</emphasis>
904 </programlisting></para>
908 <para>Copy the AFS initialization script to the local directory for initialization files (by convention, <emphasis
909 role="bold">/etc/init.d</emphasis> on Solaris machines). Note the removal of the <emphasis role="bold">.rc</emphasis>
910 extension as you copy the script. <programlisting>
911 # <emphasis role="bold">cp -p afs.rc /etc/init.d/afs</emphasis>
912 </programlisting></para>
916 <para>Copy the appropriate AFS kernel library file to the local file <emphasis
917 role="bold">/kernel/fs/afs</emphasis>.</para>
919 <para>If the machine is running Solaris 11 on the x86_64 platform:</para>
922 # <emphasis role="bold">cp -p modload/libafs64.o /kernel/drv/amd64/afs</emphasis>
925 <para>If the machine is running Solaris 10 on the x86_64 platform:</para>
928 # <emphasis role="bold">cp -p modload/libafs64.o /kernel/fs/amd64/afs</emphasis>
931 <para>If the machine is running Solaris 2.6 or the 32-bit version of Solaris 7, its kernel supports NFS server
932 functionality, and the <emphasis role="bold">nfsd</emphasis> process is running:</para>
935 # <emphasis role="bold">cp -p modload/libafs.o /kernel/fs/afs</emphasis>
938 <para>If the machine is running Solaris 2.6 or the 32-bit version of Solaris 7, and its kernel does not support NFS
939 server functionality or the <emphasis role="bold">nfsd</emphasis> process is not running:</para>
942 # <emphasis role="bold">cp -p modload/libafs.nonfs.o /kernel/fs/afs</emphasis>
945 <para>If the machine is running the 64-bit version of Solaris 7, its kernel supports NFS server functionality, and the
946 <emphasis role="bold">nfsd</emphasis> process is running:</para>
949 # <emphasis role="bold">cp -p modload/libafs64.o /kernel/fs/sparcv9/afs</emphasis>
952 <para>If the machine is running the 64-bit version of Solaris 7, and its kernel does not support NFS server
953 functionality or the <emphasis role="bold">nfsd</emphasis> process is not running:</para>
956 # <emphasis role="bold">cp -p modload/libafs64.nonfs.o /kernel/fs/sparcv9/afs</emphasis>
961 <para>Run the AFS initialization script to load AFS modifications into the kernel. You can ignore any error messages
962 about the inability to start the BOS Server or the Cache Manager or AFS client. <programlisting>
963 # <emphasis role="bold">/etc/init.d/afs start</emphasis>
964 </programlisting></para>
966 <para>When an entry called <computeroutput>afs</computeroutput> does not already exist in the local <emphasis
967 role="bold">/etc/name_to_sysnum</emphasis> file, the script automatically creates it and reboots the machine to start
968 using the new version of the file. If this happens, log in again as the superuser <emphasis role="bold">root</emphasis>
969 after the reboot and run the initialization script again. This time the required entry exists in the <emphasis
970 role="bold">/etc/name_to_sysnum</emphasis> file, and the <emphasis role="bold">modload</emphasis> program runs.</para>
973 login: <emphasis role="bold">root</emphasis>
974 Password: <replaceable>root_password</replaceable>
975 # <emphasis role="bold">/etc/init.d/afs start</emphasis>
978 </orderedlist></para>
981 <primary>replacing fsck program</primary>
983 <secondary>first AFS machine</secondary>
985 <tertiary>Solaris</tertiary>
989 <primary>fsck program</primary>
991 <secondary>on first AFS machine</secondary>
993 <tertiary>Solaris</tertiary>
997 <primary>first AFS machine</primary>
999 <secondary>fsck program</secondary>
1001 <tertiary>on Solaris</tertiary>
1005 <primary>Solaris</primary>
1007 <secondary>fsck program</secondary>
1009 <tertiary>on first AFS machine</tertiary>
1013 <sect2 id="HDRWQ47">
1014 <title>Configuring the AFS-modified fsck Program on Solaris Systems</title>
1016 <para>In this section, you make modifications to guarantee that the appropriate <emphasis role="bold">fsck</emphasis> program
1017 runs on AFS server partitions. The <emphasis role="bold">fsck</emphasis> program provided with the operating system must never
1018 run on AFS server partitions. Because it does not recognize the structures that the File Server uses to organize volume data,
1019 it removes all of the data. To repeat:</para>
1021 <para><emphasis role="bold">Never run the standard fsck program on AFS server partitions. It discards AFS volumes.</emphasis>
1024 <para>Create the <emphasis role="bold">/usr/lib/fs/afs</emphasis> directory to house the AFS-modified <emphasis
1025 role="bold">fsck</emphasis> program and related files. <programlisting>
1026 # <emphasis role="bold">mkdir /usr/lib/fs/afs</emphasis>
1027 # <emphasis role="bold">cd /usr/lib/fs/afs</emphasis>
1028 </programlisting></para>
1032 <para>Copy the <emphasis role="bold">vfsck</emphasis> binary to the newly created directory, changing the name as you do
1033 so. <programlisting>
1034 # <emphasis role="bold">cp /tmp/afsdist/sun4x_56/dest/root.server/etc/vfsck fsck</emphasis>
1035 </programlisting></para>
1039 <para>Working in the <emphasis role="bold">/usr/lib/fs/afs</emphasis> directory, create the following links to Solaris
1040 libraries: <programlisting>
1041 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/clri</emphasis>
1042 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/df</emphasis>
1043 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/edquota</emphasis>
1044 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/ff</emphasis>
1045 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/fsdb</emphasis>
1046 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/fsirand</emphasis>
1047 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/fstyp</emphasis>
1048 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/labelit</emphasis>
1049 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/lockfs</emphasis>
1050 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/mkfs</emphasis>
1051 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/mount</emphasis>
1052 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/ncheck</emphasis>
1053 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/newfs</emphasis>
1054 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/quot</emphasis>
1055 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/quota</emphasis>
1056 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/quotaoff</emphasis>
1057 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/quotaon</emphasis>
1058 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/repquota</emphasis>
1059 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/tunefs</emphasis>
1060 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/ufsdump</emphasis>
1061 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/ufsrestore</emphasis>
1062 # <emphasis role="bold">ln -s /usr/lib/fs/ufs/volcopy</emphasis>
1063 </programlisting></para>
1067 <para>Append the following line to the end of the file <emphasis role="bold">/etc/dfs/fstypes</emphasis>.
1070 </programlisting></para>
1074 <para>Edit the <emphasis role="bold">/sbin/mountall</emphasis> file, making two changes. <itemizedlist>
1076 <para>Add an entry for AFS to the <computeroutput>case</computeroutput> statement for option 2, so that it reads
1077 as follows: <programlisting>
1079 ufs) foptions="-o p"
1081 afs) foptions="-o p"
1083 s5) foptions="-y -t /var/tmp/tmp$$ -D"
1087 </programlisting></para>
1091 <para>Edit the file so that all AFS and UFS partitions are checked in parallel. Replace the following section of
1092 code: <programlisting>
1093 # For fsck purposes, we make a distinction between ufs and
1094 # other file systems
1096 if [ "$fstype" = "ufs" ]; then
1097 ufs_fscklist="$ufs_fscklist $fsckdev"
1098 saveentry $fstype "$OPTIONS" $special $mountp
1101 </programlisting></para>
1103 <para>with the following section of code:</para>
1106 # For fsck purposes, we make a distinction between ufs/afs
1107 # and other file systems.
1109 if [ "$fstype" = "ufs" -o "$fstype" = "afs" ]; then
1110 ufs_fscklist="$ufs_fscklist $fsckdev"
1111 saveentry $fstype "$OPTIONS" $special $mountp
1116 </itemizedlist></para>
1118 </orderedlist></para>
1121 <primary>configuring</primary>
1123 <secondary>AFS server partition on first AFS machine</secondary>
1125 <tertiary>Solaris</tertiary>
1129 <primary>AFS server partition</primary>
1131 <secondary>configuring on first AFS machine</secondary>
1133 <tertiary>Solaris</tertiary>
1137 <primary>first AFS machine</primary>
1139 <secondary>AFS server partition</secondary>
1141 <tertiary>on Solaris</tertiary>
1145 <primary>Solaris</primary>
1147 <secondary>AFS server partition</secondary>
1149 <tertiary>on first AFS machine</tertiary>
1153 <sect2 id="HDRWQ48">
1154 <title>Configuring Server Partitions on Solaris Systems</title>
1156 <para>Every AFS file server machine must have at least one partition or logical volume dedicated to storing AFS volumes. Each
1157 server partition is mounted at a directory named <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable>, where
1158 <replaceable>xx</replaceable> is one or two lowercase letters. The <emphasis
1159 role="bold">/vicep</emphasis><replaceable>xx</replaceable> directories must reside in the file server machine's root
1160 directory, not in one of its subdirectories (for example, <emphasis role="bold">/usr/vicepa</emphasis> is not an acceptable
1161 directory location). For additional information, see <link linkend="HDRWQ20">Performing Platform-Specific Procedures</link>.
1164 <para>Create a directory called <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable> for each AFS server
1165 partition you are configuring (there must be at least one). Repeat the command for each partition. <programlisting>
1166 # <emphasis role="bold">mkdir /vicep</emphasis><replaceable>xx</replaceable>
1167 </programlisting></para>
1171 <para>Add a line with the following format to the file systems registry file, <emphasis
1172 role="bold">/etc/vfstab</emphasis>, for each partition to be mounted on a directory created in the previous step. Note
1173 the value <computeroutput>afs</computeroutput> in the fourth field, which tells Solaris to use the AFS-modified
1174 <emphasis role="bold">fsck</emphasis> program on this partition. <programlisting>
1175 /dev/dsk/<replaceable>disk</replaceable> /dev/rdsk/<replaceable>disk</replaceable> /vicep<replaceable>xx</replaceable> afs <replaceable>boot_order</replaceable> yes
1176 </programlisting></para>
1178 <para>The following is an example for the first partition being configured.</para>
1181 /dev/dsk/c0t6d0s1 /dev/rdsk/c0t6d0s1 /vicepa afs 3 yes
1186 <para>Create a file system on each partition that is to be mounted at a <emphasis
1187 role="bold">/vicep</emphasis><replaceable>xx</replaceable> directory. The following command is probably appropriate, but
1188 consult the Solaris documentation for more information. <programlisting>
1189 # <emphasis role="bold">newfs -v /dev/rdsk/</emphasis><replaceable>disk</replaceable>
1190 </programlisting></para>
1194 <para>Issue the <emphasis role="bold">mountall</emphasis> command to mount all partitions at once.</para>
1198 <para>If you plan to retain client functionality on this machine after completing the installation, proceed to <link
1199 linkend="HDRWQ49">Enabling AFS Login and Editing the File Systems Clean-up Script on Solaris Systems</link>. Otherwise,
1200 proceed to <link linkend="HDRWQ50">Starting the BOS Server</link>.</para>
1202 </orderedlist></para>
1205 <sect2 id="HDRWQ49">
1206 <title>Enabling AFS Login on Solaris Systems</title>
1208 <primary>enabling AFS login</primary>
1210 <secondary>file server machine</secondary>
1212 <tertiary>Solaris</tertiary>
1216 <primary>AFS login</primary>
1218 <secondary>on file server machine</secondary>
1220 <tertiary>Solaris</tertiary>
1224 <primary>first AFS machine</primary>
1226 <secondary>AFS login</secondary>
1228 <tertiary>on Solaris</tertiary>
1232 <primary>Solaris</primary>
1234 <secondary>AFS login</secondary>
1236 <tertiary>on file server machine</tertiary>
1240 <primary>PAM</primary>
1242 <secondary>on Solaris</secondary>
1244 <tertiary>file server machine</tertiary>
1248 <para>If you plan to remove client functionality from this machine after completing the installation, skip this section and
1249 proceed to <link linkend="HDRWQ50">Starting the BOS Server</link>.</para>
1252 <para>At this point you incorporate AFS into the operating system's
1253 Pluggable Authentication Module (PAM) scheme. PAM integrates all
1254 authentication mechanisms on the machine, including login, to provide
1255 the security infrastructure for authenticated access to and from the
1258 <para>Explaining PAM is beyond the scope of this document. It is
1259 assumed that you understand the syntax and meanings of settings in the
1260 PAM configuration file (for example, how the
1261 <computeroutput>other</computeroutput> entry works, the effect of
1262 marking an entry as <computeroutput>required</computeroutput>,
1263 <computeroutput>optional</computeroutput>, or
1264 <computeroutput>sufficient</computeroutput>, and so on).</para>
1266 <para>You should first configure your system to obtain Kerberos v5
1267 tickets as part of the authentication process, and then run an AFS PAM
1268 module to obtain tokens from those tickets after authentication.
1269 Current versions of Solaris come with a Kerberos v5 PAM module that
1270 will work, or you can download and install <ulink
1271 url="http://www.eyrie.org/~eagle/software/pam-krb5">Russ Allbery's
1272 Kerberos v5 PAM module</ulink>, which is tested regularly with AFS.
1273 See the instructions of whatever PAM module you use for how to
1274 configure it.</para>
1276 <para>Some Kerberos v5 PAM modules do come with native AFS support
1277 (usually requiring the Heimdal Kerberos implementation rather than the
1278 MIT Kerberos implementation). If you are using one of those PAM
1279 modules, you can configure it to obtain AFS tokens. It's more common,
1280 however, to separate the AFS token acquisition into a separate PAM
1283 <para>The recommended AFS PAM module is <ulink
1284 url="http://www.eyrie.org/~eagle/software/pam-afs-session/">Russ
1285 Allbery's pam-afs-session module</ulink>. It should work with any of
1286 the Kerberos v5 PAM modules. To add it to the PAM configuration, you
1287 often only need to add configuration to the session group in
1288 <filename>pam.conf</filename>:</para>
1291 <title>Solaris PAM session example</title>
1292 <literallayout>login session required pam_afs_session.so</literallayout>
1295 <para>This example enables PAM authentication only for console login.
1296 You may want to add a similar line for the ssh service and for any
1297 other login service that you use, including possibly the
1298 <literal>other</literal> service (which serves as a catch-all). You
1299 may also want to add options to the AFS PAM session module
1300 (particularly <literal>retain_after_close</literal>, which is
1301 necessary for some versions of Solaris.</para>
1303 <para>For additional configuration examples and the configuration
1304 options of the AFS PAM module, see its documentation. For more
1305 details on the available options for the PAM configuration, see the
1306 <filename>pam.conf</filename> manual page.</para>
1308 <para>Sites which still require <emphasis
1309 role="bold">kaserver</emphasis> or external Kerberos v4 authentication
1310 should consult <link linkend="KAS016">"Enabling kaserver based AFS
1311 Login on Solaris Systems"</link> for details of how to enable AFS
1312 login on Solaris.</para>
1314 <para>Proceed to <link linkend="HDRWQ49a">Editing the File Systems
1315 Clean-up Script on Solaris Systems</link></para>
1317 <sect2 id="HDRWQ49a">
1318 <title>Editing the File Systems Clean-up Script on Solaris Systems</title>
1320 <primary>Solaris</primary>
1322 <secondary>file systems clean-up script</secondary>
1324 <tertiary>on file server machine</tertiary>
1328 <primary>file systems clean-up script (Solaris)</primary>
1330 <secondary>file server machine</secondary>
1334 <primary>scripts</primary>
1336 <secondary>file systems clean-up (Solaris)</secondary>
1338 <tertiary>file server machine</tertiary>
1344 <para>Some Solaris distributions include a script that locates and removes unneeded files from various file systems. Its
1345 conventional location is <emphasis role="bold">/usr/lib/fs/nfs/nfsfind</emphasis>. The script generally uses an argument
1346 to the <emphasis role="bold">find</emphasis> command to define which file systems to search. In this step you modify the
1347 command to exclude the <emphasis role="bold">/afs</emphasis> directory. Otherwise, the command traverses the AFS
1348 filespace of every cell that is accessible from the machine, which can take many hours. The following alterations are
1349 possibilities, but you must verify that they are appropriate for your cell.</para>
1351 <para>The first possible alteration is to add the <emphasis role="bold">-local</emphasis> flag to the existing command,
1352 so that it looks like the following:</para>
1355 find $dir -local -name .nfs\* -mtime +7 -mount -exec rm -f {} \;
1358 <para>Another alternative is to exclude any directories whose names begin with the lowercase letter <emphasis
1359 role="bold">a</emphasis> or a non-alphabetic character.</para>
1362 find /[A-Zb-z]* <replaceable>remainder of existing command</replaceable>
1365 <para>Do not use the following command, which still searches under the <emphasis role="bold">/afs</emphasis> directory,
1366 looking for a subdirectory of type <emphasis role="bold">4.2</emphasis>.</para>
1369 find / -fstype 4.2 /* <replaceable>do not use</replaceable> */
1374 <para>Proceed to <link linkend="HDRWQ50">Starting the BOS Server</link> (or if referring to these instructions while
1375 installing an additional file server machine, return to <link linkend="HDRWQ108">Starting Server
1376 Programs</link>).</para>
1381 <primary>Basic OverSeer Server</primary>
1383 <see>BOS Server</see>
1387 <primary>BOS Server</primary>
1389 <secondary>starting</secondary>
1391 <tertiary>first AFS machine</tertiary>
1395 <primary>starting</primary>
1397 <secondary>BOS Server</secondary>
1399 <tertiary>first AFS machine</tertiary>
1403 <primary>first AFS machine</primary>
1405 <secondary>BOS Server</secondary>
1409 <primary>authorization checking (disabling)</primary>
1411 <secondary>first AFS machine</secondary>
1415 <primary>disabling authorization checking</primary>
1417 <secondary>first AFS machine</secondary>
1421 <primary>first AFS machine</primary>
1423 <secondary>authorization checking (disabling)</secondary>
1428 <sect1 id="HDRWQ21">
1429 <title>Getting Started on AIX Systems</title>
1431 <para>Begin by running the AFS initialization script to call the AIX kernel extension facility, which dynamically loads AFS
1432 modifications into the kernel. Then use the <emphasis role="bold">SMIT</emphasis> program to configure partitions for storing
1433 AFS volumes, and replace the AIX <emphasis role="bold">fsck</emphasis> program helper with a version that correctly handles AFS
1434 volumes. If the machine is to remain an AFS client machine, incorporate AFS into the AIX secondary authentication system.
1436 <primary>incorporating AFS kernel extensions</primary>
1438 <secondary>first AFS machine</secondary>
1440 <tertiary>AIX</tertiary>
1441 </indexterm> <indexterm>
1442 <primary>AFS kernel extensions</primary>
1444 <secondary>on first AFS machine</secondary>
1446 <tertiary>AIX</tertiary>
1447 </indexterm> <indexterm>
1448 <primary>first AFS machine</primary>
1450 <secondary>AFS kernel extensions</secondary>
1452 <tertiary>on AIX</tertiary>
1453 </indexterm> <indexterm>
1454 <primary>AIX</primary>
1456 <secondary>AFS kernel extensions</secondary>
1458 <tertiary>on first AFS machine</tertiary>
1461 <sect2 id="HDRWQ22">
1462 <title>Loading AFS into the AIX Kernel</title>
1464 <para>The AIX kernel extension facility is the dynamic kernel loader
1465 provided by IBM Corporation. AIX does not support incorporation of
1466 AFS modifications during a kernel build.</para>
1468 <para>For AFS to function correctly, the kernel extension facility must run each time the machine reboots, so the AFS
1469 initialization script (included in the AFS distribution) invokes it automatically. In this section you copy the script to the
1470 conventional location and edit it to select the appropriate options depending on whether NFS is also to run.</para>
1472 <para>After editing the script, you run it to incorporate AFS into the kernel. In later sections you verify that the script
1473 correctly initializes all AFS components, then configure the AIX <emphasis role="bold">inittab</emphasis> file so that the
1474 script runs automatically at reboot. <orderedlist>
1476 <para>Unpack the distribution tarball. The examples below assume
1477 that you have unpacked the files into the
1478 <emphasis role="bold">/tmp/afsdist</emphasis> directory. If you
1479 pick a different location, substitute this in all of the following
1480 examples. Once you have unpacked the distribution,
1481 change directory as indicated.
1483 # <emphasis role="bold">cd /tmp/afsdist/rs_aix42/dest/root.client/usr/vice/etc</emphasis>
1484 </programlisting></para>
1488 <para>Copy the AFS kernel library files to the local <emphasis role="bold">/usr/vice/etc/dkload</emphasis> directory,
1489 and the AFS initialization script to the <emphasis role="bold">/etc</emphasis> directory. <programlisting>
1490 # <emphasis role="bold">cp -rp dkload /usr/vice/etc</emphasis>
1491 # <emphasis role="bold">cp -p rc.afs /etc/rc.afs</emphasis>
1492 </programlisting></para>
1496 <para>Edit the <emphasis role="bold">/etc/rc.afs</emphasis> script, setting the <computeroutput>NFS</computeroutput>
1497 variable as indicated.</para>
1499 <para>If the machine is not to function as an NFS/AFS Translator, set the <computeroutput>NFS</computeroutput> variable
1506 <para>If the machine is to function as an NFS/AFS Translator and is running AIX 4.2.1 or higher, set the
1507 <computeroutput>NFS</computeroutput> variable as follows. Note that NFS must already be loaded into the kernel, which
1508 happens automatically on systems running AIX 4.1.1 and later, as long as the file <emphasis
1509 role="bold">/etc/exports</emphasis> exists.</para>
1517 <para>Invoke the <emphasis role="bold">/etc/rc.afs</emphasis> script to load AFS modifications into the kernel. You can
1518 ignore any error messages about the inability to start the BOS Server or the Cache Manager or AFS client.
1520 # <emphasis role="bold">/etc/rc.afs</emphasis>
1521 </programlisting></para>
1523 </orderedlist></para>
1526 <primary>configuring</primary>
1528 <secondary>AFS server partition on first AFS machine</secondary>
1530 <tertiary>AIX</tertiary>
1534 <primary>AFS server partition</primary>
1536 <secondary>configuring on first AFS machine</secondary>
1538 <tertiary>AIX</tertiary>
1542 <primary>first AFS machine</primary>
1544 <secondary>AFS server partition</secondary>
1546 <tertiary>on AIX</tertiary>
1550 <primary>AIX</primary>
1552 <secondary>AFS server partition</secondary>
1554 <tertiary>on first AFS machine</tertiary>
1558 <sect2 id="HDRWQ23">
1559 <title>Configuring Server Partitions on AIX Systems</title>
1561 <para>Every AFS file server machine must have at least one partition or logical volume dedicated to storing AFS volumes. Each
1562 server partition is mounted at a directory named <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable>, where
1563 <replaceable>xx</replaceable> is one or two lowercase letters. The <emphasis
1564 role="bold">/vicep</emphasis><replaceable>xx</replaceable> directories must reside in the file server machine's root
1565 directory, not in one of its subdirectories (for example, <emphasis role="bold">/usr/vicepa</emphasis> is not an acceptable
1566 directory location). For additional information, see <link linkend="HDRWQ20">Performing Platform-Specific
1567 Procedures</link>.</para>
1569 <para>To configure server partitions on an AIX system, perform the following procedures: <orderedlist>
1571 <para>Create a directory called <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable> for each AFS server
1572 partition you are configuring (there must be at least one). Repeat the command for each partition. <programlisting>
1573 # <emphasis role="bold">mkdir /vicep</emphasis><replaceable>xx</replaceable>
1574 </programlisting></para>
1578 <para>Use the <emphasis role="bold">SMIT</emphasis> program to create a journaling file system on each partition to be
1579 configured as an AFS server partition.</para>
1583 <para>Mount each partition at one of the <emphasis role="bold">/vicep</emphasis><replaceable>xx</replaceable>
1584 directories. Choose one of the following three methods: <itemizedlist>
1586 <para>Use the <emphasis role="bold">SMIT</emphasis> program</para>
1590 <para>Use the <emphasis role="bold">mount -a</emphasis> command to mount all partitions at once</para>
1594 <para>Use the <emphasis role="bold">mount</emphasis> command on each partition in turn</para>
1596 </itemizedlist></para>
1598 <para>Also configure the partitions so that they are mounted automatically at each reboot. For more information, refer
1599 to the AIX documentation.</para>
1601 </orderedlist></para>
1604 <primary>replacing fsck program</primary>
1606 <secondary>first AFS machine</secondary>
1608 <tertiary>AIX</tertiary>
1612 <primary>fsck program</primary>
1614 <secondary>on first AFS machine</secondary>
1616 <tertiary>AIX</tertiary>
1620 <primary>first AFS machine</primary>
1622 <secondary>fsck program</secondary>
1624 <tertiary>on AIX</tertiary>
1628 <primary>AIX</primary>
1630 <secondary>fsck program</secondary>
1632 <tertiary>on first AFS machine</tertiary>
1636 <sect2 id="HDRWQ24">
1637 <title>Replacing the fsck Program Helper on AIX Systems</title>
1639 <note><para>The AFS modified fsck program is not required on AIX 5.1
1640 systems, and the <emphasis role="bold">v3fshelper</emphasis> program
1641 refered to below is not shipped for these systems.</para></note>
1643 <para>In this section, you make modifications to guarantee that the appropriate <emphasis role="bold">fsck</emphasis> program
1644 runs on AFS server partitions. The <emphasis role="bold">fsck</emphasis> program provided with the operating system must never
1645 run on AFS server partitions. Because it does not recognize the structures that the File Server uses to organize volume data,
1646 it removes all of the data. To repeat:</para>
1648 <para><emphasis role="bold">Never run the standard fsck program on AFS server partitions. It discards AFS
1649 volumes.</emphasis></para>
1651 <para>On AIX systems, you do not replace the <emphasis role="bold">fsck</emphasis> binary itself, but rather the
1652 <emphasis>program helper</emphasis> file included in the AIX distribution as <emphasis
1653 role="bold">/sbin/helpers/v3fshelper</emphasis>. <orderedlist>
1655 <para>Move the AIX <emphasis role="bold">fsck</emphasis> program helper to a safe location and install the version from
1656 the AFS distribution in its place.
1658 # <emphasis role="bold">cd /sbin/helpers</emphasis>
1659 # <emphasis role="bold">mv v3fshelper v3fshelper.noafs</emphasis>
1660 # <emphasis role="bold">cp -p /tmp/afsdist/rs_aix42/dest/root.server/etc/v3fshelper v3fshelper</emphasis>
1661 </programlisting></para>
1665 <para>If you plan to retain client functionality on this machine after completing the installation, proceed to <link
1666 linkend="HDRWQ25">Enabling AFS Login on AIX Systems</link>. Otherwise, proceed to <link linkend="HDRWQ50">Starting the
1667 BOS Server</link>.</para>
1669 </orderedlist></para>
1672 <primary>enabling AFS login</primary>
1674 <secondary>file server machine</secondary>
1676 <tertiary>AIX</tertiary>
1680 <primary>AFS login</primary>
1682 <secondary>on file server machine</secondary>
1684 <tertiary>AIX</tertiary>
1688 <primary>first AFS machine</primary>
1690 <secondary>AFS login</secondary>
1692 <tertiary>on AIX</tertiary>
1696 <primary>AIX</primary>
1698 <secondary>AFS login</secondary>
1700 <tertiary>on file server machine</tertiary>
1704 <primary>secondary authentication system (AIX)</primary>
1706 <secondary>server machine</secondary>
1710 <sect2 id="HDRWQ25">
1711 <title>Enabling AFS Login on AIX Systems</title>
1714 <para>If you plan to remove client functionality from this machine after completing the installation, skip this section and
1715 proceed to <link linkend="HDRWQ50">Starting the BOS Server</link>.</para>
1718 <para>In modern AFS installations, you should be using Kerberos v5
1719 for user login, and obtaining AFS tokens following this authentication
1722 <para>There are currently no instructions available on configuring AIX to
1723 automatically obtain AFS tokens at login. Following login, users can
1724 obtain tokens by running the <emphasis role="bold">aklog</emphasis>
1727 <para>Sites which still require <emphasis role="bold">kaserver</emphasis>
1728 or external Kerberos v4 authentication should consult
1729 <link linkend="KAS012">Enabling kaserver based AFS login on AIX systems</link>
1730 for details of how to enable AIX login.</para>
1732 <para>Proceed to <link linkend="HDRWQ50">Starting the BOS Server</link>
1733 (or if referring to these instructions while installing an additional
1734 file server machine, return to <link linkend="HDRWQ108">Starting Server
1735 Programs</link>).</para>
1738 <sect1 id="HDRWQ50">
1739 <title>Starting the BOS Server</title>
1741 <para>You are now ready to start the AFS server processes on this machine.
1742 If you are not working from a packaged distribution, begin by copying the
1743 AFS server binaries from the distribution to the conventional local disk
1744 location, the <emphasis role="bold">/usr/afs/bin</emphasis> directory. The
1745 following instructions also create files in other subdirectories of the
1746 <emphasis role="bold">/usr/afs</emphasis> directory.</para>
1748 <para>Then issue the <emphasis role="bold">bosserver</emphasis> command to initialize the Basic OverSeer (BOS) Server, which
1749 monitors and controls other AFS server processes on its server machine. Include the <emphasis role="bold">-noauth</emphasis>
1750 flag to disable authorization checking. Because you have not yet configured your cell's AFS authentication and authorization
1751 mechanisms, the BOS Server cannot perform authorization checking as it does during normal operation. In no-authorization mode,
1752 it does not verify the identity or privilege of the issuer of a <emphasis role="bold">bos</emphasis> command, and so performs
1753 any operation for anyone.</para>
1755 <para>Disabling authorization checking gravely compromises cell security. You must complete all subsequent steps in one
1756 uninterrupted pass and must not leave the machine unattended until you restart the BOS Server with authorization checking
1757 enabled, in <link linkend="HDRWQ72">Verifying the AFS Initialization Script</link>.</para>
1759 <para>As it initializes for the first time, the BOS Server creates the following directories and files, setting the owner to the
1760 local superuser <emphasis role="bold">root</emphasis> and the mode bits to limit the ability to write (and in some cases, read)
1761 them. For a description of the contents and function of these directories and files, see the chapter in the <emphasis>OpenAFS
1762 Administration Guide</emphasis> about administering server machines. For further discussion of the mode bit settings, see <link
1763 linkend="HDRWQ96">Protecting Sensitive AFS Directories</link>. <indexterm>
1764 <primary>Binary Distribution</primary>
1766 <secondary>copying server files from</secondary>
1768 <tertiary>first AFS machine</tertiary>
1769 </indexterm> <indexterm>
1770 <primary>first AFS machine</primary>
1772 <secondary>subdirectories of /usr/afs</secondary>
1773 </indexterm> <indexterm>
1774 <primary>creating</primary>
1776 <secondary>/usr/afs/bin directory</secondary>
1778 <tertiary>first AFS machine</tertiary>
1779 </indexterm> <indexterm>
1780 <primary>creating</primary>
1782 <secondary>/usr/afs/etc directory</secondary>
1784 <tertiary>first AFS machine</tertiary>
1785 </indexterm> <indexterm>
1786 <primary>copying</primary>
1788 <secondary>server files to local disk</secondary>
1790 <tertiary>first AFS machine</tertiary>
1791 </indexterm> <indexterm>
1792 <primary>first AFS machine</primary>
1794 <secondary>copying</secondary>
1796 <tertiary>server files to local disk</tertiary>
1797 </indexterm> <indexterm>
1798 <primary>usr/afs/bin directory</primary>
1800 <secondary>first AFS machine</secondary>
1801 </indexterm> <indexterm>
1802 <primary>usr/afs/etc directory</primary>
1804 <secondary>first AFS machine</secondary>
1805 </indexterm> <indexterm>
1806 <primary>usr/afs/db directory</primary>
1807 </indexterm> <indexterm>
1808 <primary>usr/afs/local directory</primary>
1809 </indexterm> <indexterm>
1810 <primary>usr/afs/logs directory</primary>
1811 </indexterm> <itemizedlist>
1813 <para><emphasis role="bold">/usr/afs/db</emphasis></para>
1817 <para><emphasis role="bold">/usr/afs/etc/CellServDB</emphasis></para>
1821 <para><emphasis role="bold">/usr/afs/etc/ThisCell</emphasis></para>
1825 <para><emphasis role="bold">/usr/afs/local</emphasis></para>
1829 <para><emphasis role="bold">/usr/afs/logs</emphasis></para>
1831 </itemizedlist></para>
1833 <para>The BOS Server also creates symbolic links called <emphasis role="bold">/usr/vice/etc/ThisCell</emphasis> and <emphasis
1834 role="bold">/usr/vice/etc/CellServDB</emphasis> to the corresponding files in the <emphasis role="bold">/usr/afs/etc</emphasis>
1835 directory. The AFS command interpreters consult the <emphasis role="bold">CellServDB</emphasis> and <emphasis
1836 role="bold">ThisCell</emphasis> files in the <emphasis role="bold">/usr/vice/etc</emphasis> directory because they generally run
1837 on client machines. On machines that are AFS servers only (as this machine currently is), the files reside only in the <emphasis
1838 role="bold">/usr/afs/etc</emphasis> directory; the links enable the command interpreters to retrieve the information they need.
1839 Later instructions for installing the client functionality replace the links with actual files. <orderedlist>
1841 <para>If you are not working from a packaged distribution, you may need to copy files from the distribution media to the local <emphasis role="bold">/usr/afs</emphasis> directory.
1843 # <emphasis role="bold">cd /tmp/afsdist/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/root.server/usr/afs</emphasis>
1844 # <emphasis role="bold">cp -rp * /usr/afs</emphasis>
1845 </programlisting> <indexterm>
1846 <primary>commands</primary>
1848 <secondary>bosserver</secondary>
1849 </indexterm> <indexterm>
1850 <primary>bosserver command</primary>
1855 <para>Issue the <emphasis role="bold">bosserver</emphasis> command. Include the <emphasis role="bold">-noauth</emphasis>
1856 flag to disable authorization checking. <programlisting>
1857 # <emphasis role="bold">/usr/afs/bin/bosserver -noauth &</emphasis>
1858 </programlisting></para>
1862 <para>Verify that the BOS Server created <emphasis role="bold">/usr/vice/etc/ThisCell</emphasis> and <emphasis
1863 role="bold">/usr/vice/etc/CellServDB</emphasis> as symbolic links to the corresponding files in the <emphasis
1864 role="bold">/usr/afs/etc</emphasis> directory. <programlisting>
1865 # <emphasis role="bold">ls -l /usr/vice/etc</emphasis>
1866 </programlisting></para>
1868 <para>If either or both of <emphasis role="bold">/usr/vice/etc/ThisCell</emphasis> and <emphasis
1869 role="bold">/usr/vice/etc/CellServDB</emphasis> do not exist, or are not links, issue the following commands.</para>
1872 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
1873 # <emphasis role="bold">ln -s /usr/afs/etc/ThisCell</emphasis>
1874 # <emphasis role="bold">ln -s /usr/afs/etc/CellServDB</emphasis>
1877 </orderedlist></para>
1880 <primary>cell name</primary>
1882 <secondary>defining during installation of first machine</secondary>
1886 <primary>defining</primary>
1888 <secondary>cell name during installation of first machine</secondary>
1892 <primary>cell name</primary>
1894 <secondary>setting in server ThisCell file</secondary>
1896 <tertiary>first AFS machine</tertiary>
1900 <primary>setting</primary>
1902 <secondary>cell name in server ThisCell file</secondary>
1904 <tertiary>first AFS machine</tertiary>
1908 <primary>first AFS machine</primary>
1910 <secondary>ThisCell file (server)</secondary>
1914 <primary>usr/afs/etc/ThisCell</primary>
1916 <see>ThisCell file (server)</see>
1920 <primary>ThisCell file (server)</primary>
1922 <secondary>first AFS machine</secondary>
1926 <primary>files</primary>
1928 <secondary>ThisCell (server)</secondary>
1932 <primary>database server machine</primary>
1934 <secondary>entry in server CellServDB file</secondary>
1936 <tertiary>on first AFS machine</tertiary>
1940 <primary>first AFS machine</primary>
1942 <secondary>cell membership, defining</secondary>
1944 <tertiary>for server processes</tertiary>
1948 <primary>usr/afs/etc/CellServDB file</primary>
1950 <see>CellServDB file (server)</see>
1954 <primary>CellServDB file (server)</primary>
1956 <secondary>creating</secondary>
1958 <tertiary>on first AFS machine</tertiary>
1962 <primary>creating</primary>
1964 <secondary>CellServDB file (server)</secondary>
1966 <tertiary>first AFS machine</tertiary>
1970 <primary>files</primary>
1972 <secondary>CellServDB (server)</secondary>
1976 <primary>first AFS machine</primary>
1978 <secondary>CellServDB file (server)</secondary>
1982 <primary>first AFS machine</primary>
1984 <secondary>defining</secondary>
1986 <tertiary>as database server</tertiary>
1990 <primary>defining</primary>
1992 <secondary>first AFS machine as database server</secondary>
1996 <sect1 id="HDRWQ51">
1997 <title>Defining Cell Name and Membership for Server Processes</title>
1999 <para>Now assign your cell's name. The chapter in the <emphasis>OpenAFS Administration Guide</emphasis> about cell configuration
2000 and administration issues discusses the important considerations, explains why changing the name is difficult, and outlines the
2001 restrictions on name format. Two of the most important restrictions are that the name cannot include uppercase letters or more
2002 than 64 characters.</para>
2004 <para>Use the <emphasis role="bold">bos setcellname</emphasis> command to assign the cell name. It creates two files:
2007 <para><emphasis role="bold">/usr/afs/etc/ThisCell</emphasis>, which defines this machine's cell membership</para>
2011 <para><emphasis role="bold">/usr/afs/etc/CellServDB</emphasis>, which lists the cell's database server machines; the
2012 machine named on the command line is placed on the list automatically</para>
2014 </itemizedlist> <note>
2015 <para>In the following and every instruction in this guide, for the <replaceable>machine name</replaceable> argument
2016 substitute the fully-qualified hostname (such as <emphasis role="bold">fs1.example.com</emphasis>) of the machine you are
2017 installing. For the <replaceable>cell name</replaceable> argument substitute your cell's complete name (such as <emphasis
2018 role="bold">example.com</emphasis>).</para>
2022 <primary>commands</primary>
2024 <secondary>bos setcellname</secondary>
2028 <primary>bos commands</primary>
2030 <secondary>setcellname</secondary>
2035 <para>If necessary, add the directory containing the <emphasis role="bold">bos</emphasis> command to your path.
2037 # <emphasis role="bold">export PATH=$PATH:/usr/afs/bin</emphasis>
2043 <para>Issue the <emphasis role="bold">bos setcellname</emphasis> command to set the cell name. <programlisting>
2044 # <emphasis role="bold">bos setcellname</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>cell name</replaceable>> <emphasis
2045 role="bold">-noauth</emphasis>
2046 </programlisting></para>
2048 <para>Because you are not authenticated and authorization checking is disabled, the <emphasis role="bold">bos</emphasis>
2049 command interpreter possibly produces error messages about being unable to obtain tickets and running unauthenticated. You
2050 can safely ignore the messages. <indexterm>
2051 <primary>commands</primary>
2053 <secondary>bos listhosts</secondary>
2054 </indexterm> <indexterm>
2055 <primary>bos commands</primary>
2057 <secondary>listhosts</secondary>
2058 </indexterm> <indexterm>
2059 <primary>CellServDB file (server)</primary>
2061 <secondary>displaying entries</secondary>
2062 </indexterm> <indexterm>
2063 <primary>displaying</primary>
2065 <secondary>CellServDB file (server) entries</secondary>
2070 <para>Issue the <emphasis role="bold">bos listhosts</emphasis> command to verify that the machine you are installing is now
2071 registered as the cell's first database server machine. <programlisting>
2072 # <emphasis role="bold">bos listhosts</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">-noauth</emphasis>
2073 Cell name is <replaceable>cell_name</replaceable>
2074 Host 1 is <replaceable>machine_name</replaceable>
2075 </programlisting></para>
2080 <primary>database server machine</primary>
2082 <secondary>installing</secondary>
2084 <tertiary>first</tertiary>
2088 <primary>instructions</primary>
2090 <secondary>database server machine, installing first</secondary>
2094 <primary>installing</primary>
2096 <secondary>database server machine</secondary>
2098 <tertiary>first</tertiary>
2102 <primary>Backup Server</primary>
2104 <secondary>starting</secondary>
2106 <tertiary>first AFS machine</tertiary>
2110 <primary>buserver process</primary>
2112 <see>Backup Server</see>
2116 <primary>starting</primary>
2118 <secondary>Backup Server</secondary>
2120 <tertiary>first AFS machine</tertiary>
2124 <primary>first AFS machine</primary>
2126 <secondary>Backup Server</secondary>
2130 <primary>Protection Server</primary>
2132 <secondary>starting</secondary>
2134 <tertiary>first AFS machine</tertiary>
2138 <primary>ptserver process</primary>
2140 <see>Protection Server</see>
2144 <primary>starting</primary>
2146 <secondary>Protection Server</secondary>
2148 <tertiary>first AFS machine</tertiary>
2152 <primary>first AFS machine</primary>
2154 <secondary>Protection Server</secondary>
2158 <primary>VL Server (vlserver process)</primary>
2160 <secondary>starting</secondary>
2162 <tertiary>first AFS machine</tertiary>
2166 <primary>Volume Location Server</primary>
2168 <see>VL Server</see>
2172 <primary>starting</primary>
2174 <secondary>VL Server</secondary>
2176 <tertiary>first AFS machine</tertiary>
2180 <primary>first AFS machine</primary>
2182 <secondary>VL Server</secondary>
2186 <primary>usr/afs/local/BosConfig</primary>
2188 <see>BosConfig file</see>
2192 <primary>BosConfig file</primary>
2194 <secondary>adding entries</secondary>
2196 <tertiary>first AFS machine</tertiary>
2200 <primary>adding</primary>
2202 <secondary>entries to BosConfig file</secondary>
2204 <tertiary>first AFS machine</tertiary>
2208 <primary>files</primary>
2210 <secondary>BosConfig</secondary>
2214 <primary>initializing</primary>
2216 <secondary>server process</secondary>
2222 <primary>server process</primary>
2224 <secondary>see also entry for each server's name</secondary>
2228 <sect1 id="HDRWQ52">
2229 <title>Starting the Database Server Processes</title>
2231 <para>Next use the <emphasis role="bold">bos create</emphasis> command to create entries for the three database server processes
2232 in the <emphasis role="bold">/usr/afs/local/BosConfig</emphasis> file and start them running. The three processes run on database
2233 server machines only: <itemizedlist>
2236 <para>The Backup Server (the <emphasis role="bold">buserver</emphasis> process) maintains the Backup Database</para>
2240 <para>The Protection Server (the <emphasis role="bold">ptserver</emphasis> process) maintains the Protection
2245 <para>The Volume Location (VL) Server (the <emphasis role="bold">vlserver</emphasis> process) maintains the Volume
2246 Location Database (VLDB)</para>
2248 </itemizedlist></para>
2251 <primary>Kerberos</primary>
2255 <para>AFS ships with an additional database server named 'kaserver', which
2256 was historically used to provide authentication services to AFS cells.
2257 kaserver was based on <emphasis>Kerberos v4</emphasis>, as such, it is
2258 not recommended for new cells. This guide assumes you have already
2259 configured a Kerberos v5 realm for your site, and details the procedures
2260 required to use AFS with this realm. If you do wish to use
2261 <emphasis role="bold">kaserver</emphasis>, please see the modifications
2262 to these instructions detailed in
2263 <link linkend="KAS006">Starting the kaserver Database Server Process</link>
2267 <para>The remaining instructions in this chapter include the <emphasis role="bold">-cell</emphasis> argument on all applicable
2268 commands. Provide the cell name you assigned in <link linkend="HDRWQ51">Defining Cell Name and Membership for Server
2269 Processes</link>. If a command appears on multiple lines, it is only for legibility. <indexterm>
2270 <primary>commands</primary>
2272 <secondary>bos create</secondary>
2273 </indexterm> <indexterm>
2274 <primary>bos commands</primary>
2276 <secondary>create</secondary>
2277 </indexterm> <orderedlist>
2279 <para>Issue the <emphasis role="bold">bos create</emphasis> command to start the Backup Server. <programlisting>
2280 # <emphasis role="bold">./bos create</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">buserver simple /usr/afs/bin/buserver</emphasis> <emphasis role="bold">-noauth</emphasis>
2281 </programlisting></para>
2285 <para>Issue the <emphasis role="bold">bos create</emphasis> command to start the Protection Server. <programlisting>
2286 # <emphasis role="bold">./bos create</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">ptserver simple /usr/afs/bin/ptserver</emphasis> <emphasis role="bold">-noauth</emphasis>
2287 </programlisting></para>
2291 <para>Issue the <emphasis role="bold">bos create</emphasis> command to start the VL Server. <programlisting>
2292 # <emphasis role="bold">./bos create</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">vlserver simple /usr/afs/bin/vlserver</emphasis> <emphasis role="bold">-noauth</emphasis>
2293 </programlisting></para>
2295 </orderedlist></para>
2298 <primary>admin account</primary>
2300 <secondary>creating</secondary>
2304 <primary>afs entry in Kerberos Database</primary>
2308 <primary>Kerberos Database</primary>
2312 <primary>creating</primary>
2314 <secondary>afs entry in Kerberos Database</secondary>
2318 <primary>creating</primary>
2320 <secondary>admin account in Kerberos Database</secondary>
2324 <primary>security</primary>
2326 <secondary>initializing cell-wide</secondary>
2330 <primary>cell</primary>
2332 <secondary>initializing security mechanisms</secondary>
2336 <primary>initializing</primary>
2338 <secondary>cell security mechanisms</secondary>
2342 <primary>usr/afs/etc/KeyFile</primary>
2344 <see>KeyFile file</see>
2348 <primary>KeyFile file</primary>
2350 <secondary>first AFS machine</secondary>
2354 <primary>files</primary>
2356 <secondary>KeyFile</secondary>
2360 <primary>key</primary>
2362 <see>server encryption key</see>
2366 <primary>encryption key</primary>
2368 <see>server encryption key</see>
2372 <sect1 id="HDRWQ53">
2373 <title>Initializing Cell Security </title>
2375 <para>If you are working with an existing cell which uses
2376 <emphasis role="bold">kaserver</emphasis> or Kerberos v4 for authentication,
2378 <link linkend="HDRWQ53">Initializing Cell Security with kaserver</link>
2379 for installation instructions which replace this section.</para>
2381 <para>Now initialize the cell's security mechanisms. Begin by creating the following two entires in your site's Kerberos database: <itemizedlist>
2383 <para>A generic administrative account, called <emphasis role="bold">admin</emphasis> by convention. If you choose to
2384 assign a different name, substitute it throughout the remainder of this document.</para>
2386 <para>After you complete the installation of the first machine, you can continue to have all administrators use the
2387 <emphasis role="bold">admin</emphasis> account, or you can create a separate administrative account for each of them. The
2388 latter scheme implies somewhat more overhead, but provides a more informative audit trail for administrative
2393 <para>The entry for AFS server processes, called either
2394 <emphasis role="bold">afs</emphasis> or
2395 <emphasis role="bold">afs/<replaceable>cell</replaceable></emphasis>.
2396 The latter form is preferred since it works regardless of whether
2397 your cell name matches your Kerberos realm name and allows multiple
2398 AFS cells to be served from a single Kerberos realm.
2399 No user logs in under this identity, but it is used to encrypt the
2400 server tickets that granted to AFS clients for presentation to
2401 server processes during mutual authentication. (The
2402 chapter in the <emphasis>OpenAFS Administration Guide</emphasis> about cell configuration and administration describes the
2403 role of server encryption keys in mutual authentication.)</para>
2405 <para>In Step <link linkend="LIWQ58">7</link>, you also place the initial AFS server encryption key into the <emphasis
2406 role="bold">/usr/afs/etc/KeyFile</emphasis> file. The AFS server processes refer to this file to learn the server
2407 encryption key when they need to decrypt server tickets.</para>
2409 </itemizedlist></para>
2411 <para>You also issue several commands that enable the new <emphasis role="bold">admin</emphasis> user to issue privileged
2412 commands in all of the AFS suites.</para>
2414 <para>The following instructions do not configure all of the security mechanisms related to the AFS Backup System. See the
2415 chapter in the <emphasis>OpenAFS Administration Guide</emphasis> about configuring the Backup System.</para>
2417 <para>The examples below assume you are using MIT Kerberos. Please refer
2418 to the documentation for your KDC's administrative interface if you are
2419 using a different vendor</para>
2423 <para>Enter <emphasis role="bold">kadmin</emphasis> interactive mode.
2425 # <emphasis role="bold">kadmin</emphasis>
2426 Authenticating as principal <replaceable>you</replaceable>/admin@<replaceable>YOUR REALM</replaceable> with password
2427 Password for <replaceable>you/admin@REALM</replaceable>: <replaceable>your_password</replaceable>
2428 </programlisting> <indexterm>
2429 <primary>server encryption key</primary>
2431 <secondary>in Kerberos Database</secondary>
2432 </indexterm> <indexterm>
2433 <primary>creating</primary>
2435 <secondary>server encryption key</secondary>
2437 <tertiary>Kerberos Database</tertiary>
2441 <listitem id="LIWQ54">
2443 <emphasis role="bold">add_principal</emphasis> command to create
2444 Kerberos Database entries called
2445 <emphasis role="bold">admin</emphasis> and
2446 <emphasis role="bold">afs/<<replaceable>cell name</replaceable>></emphasis>.</para>
2448 <para>You should make the <replaceable>admin_passwd</replaceable> as
2449 long and complex as possible, but keep in mind that administrators
2450 need to enter it often. It must be at least six characters long.</para>
2451 <para>Note that when creating the
2452 <emphasis role="bold">afs/<<replaceable>cell name</replaceable>></emphasis>
2453 entry, the encryption types should be restricted to des-cbc-crc:v4.
2454 For more details regarding encryption types, see the documentation
2455 for your Kerberos installation.
2458 kadmin: <emphasis role="bold">add_principal -randkey -e des-cbc-crc:v4 afs/</emphasis><<replaceable>cell name</replaceable>>
2459 Principal "afs/<replaceable>cell name</replaceable>@<replaceable>REALM</replaceable>" created.
2460 kadmin: <emphasis role="bold">add_principal admin</emphasis>
2461 Enter password for principal "admin@<replaceable>REALM</replaceable>": <emphasis role="bold"><replaceable>admin_password</replaceable></emphasis>
2462 Principal "admin@<replaceable>REALM</replaceable>" created.
2467 <primary>commands</primary>
2469 <secondary>kas examine</secondary>
2473 <primary>kas commands</primary>
2475 <secondary>examine</secondary>
2479 <primary>displaying</primary>
2481 <secondary>server encryption key</secondary>
2483 <tertiary>Authentication Database</tertiary>
2487 <listitem id="LIWQ55">
2488 <para>Issue the <emphasis role="bold">kadmin
2489 get_principal</emphasis> command to display the <emphasis
2490 role="bold">afs/</emphasis><<replaceable>cell name</replaceable>> entry.
2492 kadmin: <emphasis role="bold">get_principal afs/<<replaceable>cell name</replaceable>></emphasis>
2493 Principal: afs/<replaceable>cell</replaceable>
2495 Key: vno 2, DES cbc mode with CRC-32, no salt
2501 <para>Extract the newly created key for <emphasis role="bold">afs/<replaceable>cell</replaceable></emphasis> to a keytab on the local machine. We will use <emphasis role="bold">/etc/afs.keytab</emphasis> as the location for this keytab.</para>
2503 <para>The keytab contains the key material that ensures the security of your AFS cell. You should ensure that it is kept in a secure location at all times.</para>
2506 kadmin: <emphasis role="bold">ktadd -k /etc/afs.keytab -e des-cbc-crc:v4 afs/<<replaceable>cell name</replaceable>></emphasis>
2507 Entry for principal afs/<<replaceable>cell name</replaceable>> with kvno 3, encryption type DES cbc mode with CRC-32 added to keytab WRFILE:/etc/afs.keytab
2509 <para>Make a note of the key version number (kvno) given in the
2510 response, as you will need it to load the key into bos in a later
2513 <note><para>Note that each time you run
2514 <emphasis role="bold">ktadd</emphasis> a new key is generated
2515 for the item being extracted. This means that you cannot run ktadd
2516 multiple times and end up with the same key material each time.
2521 <para>Issue the <emphasis role="bold">quit</emphasis> command to leave <emphasis role="bold">kadmin</emphasis>
2522 interactive mode. <programlisting>
2523 kadmin: <emphasis role="bold">quit</emphasis>
2524 </programlisting> <indexterm>
2525 <primary>commands</primary>
2527 <secondary>bos adduser</secondary>
2528 </indexterm> <indexterm>
2529 <primary>bos commands</primary>
2531 <secondary>adduser</secondary>
2532 </indexterm> <indexterm>
2533 <primary>usr/afs/etc/UserList</primary>
2535 <see>UserList file</see>
2536 </indexterm> <indexterm>
2537 <primary>UserList file</primary>
2539 <secondary>first AFS machine</secondary>
2540 </indexterm> <indexterm>
2541 <primary>files</primary>
2543 <secondary>UserList</secondary>
2544 </indexterm> <indexterm>
2545 <primary>creating</primary>
2547 <secondary>UserList file entry</secondary>
2548 </indexterm> <indexterm>
2549 <primary>admin account</primary>
2551 <secondary>adding</secondary>
2553 <tertiary>to UserList file</tertiary>
2557 <listitem id="LIWQ57">
2558 <para>Issue the <emphasis role="bold">bos adduser</emphasis> command to add the <emphasis
2559 role="bold">admin</emphasis> user to the <emphasis role="bold">/usr/afs/etc/UserList</emphasis> file. This enables the
2560 <emphasis role="bold">admin</emphasis> user to issue privileged <emphasis role="bold">bos</emphasis> and <emphasis
2561 role="bold">vos</emphasis> commands. <programlisting>
2562 # <emphasis role="bold">./bos adduser</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">admin -noauth</emphasis>
2565 <primary>commands</primary>
2566 <secondary>asetkey</secondary>
2569 <primary>creating</primary>
2570 <secondary>server encryption key</secondary>
2571 <tertiary>KeyFile file</tertiary>
2574 <primary>server encryption key</primary>
2575 <secondary>in KeyFile file</secondary>
2579 <listitem id="LIWQ58">
2581 <emphasis role="bold">asetkey</emphasis> command to set the AFS
2582 server encryption key in the
2583 <emphasis role="bold">/usr/afs/etc/KeyFile</emphasis> file. This key
2584 is created from the <emphasis role="bold">/etc/afs.keytab</emphasis>
2585 file created earlier.</para>
2587 <para>asetkey requires the key version number (or kvno) of the
2588 <emphasis role="bold">afs/</emphasis><replaceable>cell</replaceable>
2589 key. You should have made note of the kvno when creating the key
2590 earlier. The key version number can also be found by running the
2591 <emphasis role="bold">kvno</emphasis> command</para>
2593 # <emphasis role="bold">kvno -k /etc/afs.keytab afs/</emphasis><<replaceable>cell name</replaceable>>
2596 <para>Once the kvno is known, the key can then be extracted using
2599 # <emphasis role="bold">asetkey add</emphasis> <<replaceable>kvno</replaceable>> <emphasis role="bold">/etc/afs.keytab afs/</emphasis><<replaceable>cell name</replaceable>>
2603 <primary>commands</primary>
2604 <secondary>bos listkeys</secondary>
2608 <primary>bos commands</primary>
2609 <secondary>listkeys</secondary>
2613 <primary>displaying</primary>
2614 <secondary>server encryption key</secondary>
2615 <tertiary>KeyFile file</tertiary>
2619 <listitem id="LIWQ59">
2621 <emphasis role="bold">bos listkeys</emphasis> command to verify that
2622 the key version number for the new key in the
2623 <emphasis role="bold">KeyFile</emphasis> file is the same as the key
2624 version number in the Authentication Database's
2625 <emphasis role="bold">afs/<replaceable>cell name</replaceable></emphasis>
2626 entry, which you displayed in Step <link linkend="LIWQ55">3</link>.
2628 # <emphasis role="bold">./bos listkeys</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">-noauth</emphasis>
2629 key 0 has cksum <replaceable>checksum</replaceable>
2630 </programlisting></para>
2632 <para>You can safely ignore any error messages indicating that <emphasis role="bold">bos</emphasis> failed to get tickets
2633 or that authentication failed.</para>
2637 <sect1 id="HDRWQ53a">
2638 <title>Initializing the Protection Database</title>
2640 <para>Now continue to configure your cell's security systems by
2641 populating the Protection Database with the newly created
2642 <emphasis role="bold">admin</emphasis> user, and permitting it
2643 to issue priviledged commands on the AFS filesystem.</para>
2648 <primary>commands</primary>
2649 <secondary>pts createuser</secondary>
2653 <primary>pts commands</primary>
2654 <secondary>createuser</secondary>
2658 <primary>Protection Database</primary>
2660 <para>Issue the <emphasis role="bold">pts createuser</emphasis> command to create a Protection Database entry for the
2661 <emphasis role="bold">admin</emphasis> user.</para>
2663 <para>By default, the Protection Server assigns AFS UID 1 (one) to the <emphasis role="bold">admin</emphasis> user,
2664 because it is the first user entry you are creating. If the local password file (<emphasis
2665 role="bold">/etc/passwd</emphasis> or equivalent) already has an entry for <emphasis role="bold">admin</emphasis> that
2666 assigns it a UNIX UID other than 1, it is best to use the <emphasis role="bold">-id</emphasis> argument to the <emphasis
2667 role="bold">pts createuser</emphasis> command to make the new AFS UID match the existing UNIX UID. Otherwise, it is best
2668 to accept the default.</para>
2671 # <emphasis role="bold">pts createuser -name admin</emphasis> [<emphasis
2672 role="bold">-id</emphasis> <<replaceable>AFS UID</replaceable>>] <emphasis role="bold">-noauth</emphasis>
2673 User admin has id <replaceable>AFS UID</replaceable>
2677 <primary>commands</primary>
2678 <secondary>pts adduser</secondary>
2682 <primary>pts commands</primary>
2683 <secondary>adduser</secondary>
2687 <primary>system:administrators group</primary>
2691 <primary>admin account</primary>
2692 <secondary>adding</secondary>
2693 <tertiary>to system:administrators group</tertiary>
2698 <para>Issue the <emphasis role="bold">pts adduser</emphasis> command to make the <emphasis role="bold">admin</emphasis>
2699 user a member of the <emphasis role="bold">system:administrators</emphasis> group, and the <emphasis role="bold">pts
2700 membership</emphasis> command to verify the new membership. Membership in the group enables the <emphasis
2701 role="bold">admin</emphasis> user to issue privileged <emphasis role="bold">pts</emphasis> commands and some privileged
2702 <emphasis role="bold">fs</emphasis> commands. <programlisting>
2703 # <emphasis role="bold">./pts adduser admin system:administrators</emphasis> <emphasis role="bold">-noauth</emphasis>
2704 # <emphasis role="bold">./pts membership admin</emphasis> <emphasis role="bold">-noauth</emphasis>
2705 Groups admin (id: 1) is a member of:
2706 system:administrators
2707 </programlisting> <indexterm>
2708 <primary>commands</primary>
2709 <secondary>bos restart</secondary>
2710 <tertiary>on first AFS machine</tertiary>
2711 </indexterm> <indexterm>
2712 <primary>bos commands</primary>
2713 <secondary>restart</secondary>
2714 <tertiary>on first AFS machine</tertiary>
2715 </indexterm> <indexterm>
2716 <primary>restarting server process</primary>
2717 <secondary>on first AFS machine</secondary>
2718 </indexterm> <indexterm>
2719 <primary>server process</primary>
2720 <secondary>restarting</secondary>
2721 <tertiary>on first AFS machine</tertiary>
2726 <para>Issue the <emphasis role="bold">bos restart</emphasis> command with the <emphasis role="bold">-all</emphasis> flag
2727 to restart the database server processes, so that they start using the new server encryption key. <programlisting>
2728 # <emphasis role="bold">./bos restart</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">-all</emphasis>
2729 <emphasis role="bold">-noauth</emphasis>
2730 </programlisting></para>
2735 <primary>File Server</primary>
2737 <secondary>first AFS machine</secondary>
2741 <primary>fileserver process</primary>
2743 <see>File Server</see>
2747 <primary>starting</primary>
2749 <secondary>File Server</secondary>
2751 <tertiary>first AFS machine</tertiary>
2755 <primary>first AFS machine</primary>
2757 <secondary>File Server, fs process</secondary>
2761 <primary>Volume Server</primary>
2763 <secondary>first AFS machine</secondary>
2767 <primary>volserver process</primary>
2769 <see>Volume Server</see>
2773 <primary>starting</primary>
2775 <secondary>Volume Server</secondary>
2777 <tertiary>first AFS machine</tertiary>
2781 <primary>first AFS machine</primary>
2783 <secondary>Volume Server</secondary>
2787 <primary>Salvager (salvager process)</primary>
2789 <secondary>first AFS machine</secondary>
2793 <primary>fs process</primary>
2795 <secondary>first AFS machine</secondary>
2799 <primary>starting</primary>
2801 <secondary>fs process</secondary>
2803 <tertiary>first AFS machine</tertiary>
2807 <primary>first AFS machine</primary>
2809 <secondary>Salvager</secondary>
2813 <sect1 id="HDRWQ60">
2814 <title>Starting the File Server processes</title>
2816 <para>Start either the <emphasis role="bold">fs</emphasis> process or, if you want to run the Demand-Attach File Server, the
2817 <emphasis role="bold">dafs</emphasis> process. The <emphasis role="bold">fs</emphasis> process consists of the File Server,
2818 Volume Server, and Salvager (<emphasis role="bold">fileserver</emphasis>, <emphasis role="bold">volserver</emphasis> and
2819 <emphasis role="bold">salvager</emphasis> processes). The <emphasis role="bold">dafs</emphasis> process consists of the
2820 Demand-Attach File Server, Volume Server, Salvage Server, and Salvager (<emphasis role="bold">dafileserver</emphasis>,
2821 <emphasis role="bold"> davolserver</emphasis>, <emphasis role="bold">salvageserver</emphasis>, and <emphasis
2822 role="bold">dasalvager</emphasis> processes). For information about the Demand-Attach File Server and to see whether or not
2823 you should run it, see <link linkend="DAFS">Appendix C, The Demand-Attach File Server</link>.
2826 <para>Issue the <emphasis role="bold">bos create</emphasis> command to start the <emphasis role="bold">fs</emphasis>
2827 process or the <emphasis role="bold">dafs</emphasis> process. The commands appear here on multiple lines only for legibility.
2831 <para>If you are not planning on running the Demand-Attach File Server, create the <emphasis role="bold">fs</emphasis>
2834 # <emphasis role="bold">./bos create</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">fs fs /usr/afs/bin/fileserver</emphasis> \
2835 <emphasis role="bold">/usr/afs/bin/volserver /usr/afs/bin/salvager</emphasis> \
2836 <emphasis role="bold">-noauth</emphasis>
2837 </programlisting></para>
2840 <para>If you are planning on running the Demand-Attach File Server, create the <emphasis
2841 role="bold">dafs</emphasis> process:
2843 # <emphasis role="bold">./bos create</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">dafs dafs /usr/afs/bin/dafileserver</emphasis> \
2844 <emphasis role="bold">/usr/afs/bin/davolserver /usr/afs/bin/salvageserver</emphasis> \
2845 <emphasis role="bold">/usr/afs/bin/dasalvager</emphasis> <emphasis role="bold">-noauth</emphasis>
2846 </programlisting></para>
2851 <para>Sometimes a message about Volume Location Database (VLDB) initialization appears, along with one or more instances
2852 of an error message similar to the following:</para>
2855 FSYNC_clientInit temporary failure (will retry)
2858 <para>This message appears when the <emphasis role="bold">volserver</emphasis> process tries to start before the <emphasis
2859 role="bold">fileserver</emphasis> process has completed its initialization. Wait a few minutes after the last such message
2860 before continuing, to guarantee that both processes have started successfully. <indexterm>
2861 <primary>commands</primary>
2863 <secondary>bos status</secondary>
2864 </indexterm> <indexterm>
2865 <primary>bos commands</primary>
2867 <secondary>status</secondary>
2870 <para>You can verify that the <emphasis role="bold">fs</emphasis> or <emphasis role="bold">dafs</emphasis> process has started
2871 successfully by issuing the <emphasis role="bold">bos status</emphasis> command. Its output mentions two <computeroutput>proc
2872 starts</computeroutput>.</para>
2876 <para>If you are not running the Demand-Attach File Server:
2879 # <emphasis role="bold">./bos status</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">fs -long -noauth</emphasis>
2880 </programlisting></para></listitem>
2883 <para>If you are running the Demand-Attach File Server:
2885 # <emphasis role="bold">./bos status</emphasis> <<replaceable>machine name</replaceable>> <emphasis role="bold">dafs -long -noauth</emphasis>
2886 </programlisting></para></listitem>
2892 <para>Your next action depends on whether you have ever run AFS file server machines in the cell: <itemizedlist>
2894 <primary>commands</primary>
2896 <secondary>vos create</secondary>
2898 <tertiary>root.afs volume</tertiary>
2902 <primary>vos commands</primary>
2904 <secondary>create</secondary>
2906 <tertiary>root.afs volume</tertiary>
2910 <primary>root.afs volume</primary>
2912 <secondary>creating</secondary>
2916 <primary>volume</primary>
2918 <secondary>creating</secondary>
2920 <tertiary>root.afs</tertiary>
2924 <primary>creating</primary>
2926 <secondary>root.afs volume</secondary>
2930 <para>If you are installing the first AFS server machine ever in the cell (that is, you are not upgrading the AFS
2931 software from a previous version), create the first AFS volume, <emphasis role="bold">root.afs</emphasis>.</para>
2933 <para>For the <replaceable>partition name</replaceable> argument, substitute the name of one of the machine's AFS
2934 server partitions (such as <emphasis role="bold">/vicepa</emphasis>).</para>
2937 # <emphasis role="bold">./vos create</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <emphasis
2938 role="bold">root.afs</emphasis> \
2939 <emphasis role="bold">-noauth</emphasis>
2942 <para>The Volume Server produces a message confirming that it created the volume on the specified partition. You can
2943 ignore error messages indicating that tokens are missing, or that authentication failed. <indexterm>
2944 <primary>commands</primary>
2946 <secondary>vos syncvldb</secondary>
2947 </indexterm> <indexterm>
2948 <primary>vos commands</primary>
2950 <secondary>syncvldb</secondary>
2951 </indexterm> <indexterm>
2952 <primary>commands</primary>
2954 <secondary>vos syncserv</secondary>
2955 </indexterm> <indexterm>
2956 <primary>vos commands</primary>
2958 <secondary>syncserv</secondary>
2963 <para>If there are existing AFS file server machines and volumes in the cell, issue the <emphasis role="bold">vos
2964 syncvldb</emphasis> and <emphasis role="bold">vos syncserv</emphasis> commands to synchronize the VLDB with the
2965 actual state of volumes on the local machine. To follow the progress of the synchronization operation, which can
2966 take several minutes, use the <emphasis role="bold">-verbose</emphasis> flag. <programlisting>
2967 # <emphasis role="bold">./vos syncvldb</emphasis> <<replaceable>machine name</replaceable>> <emphasis
2968 role="bold">-verbose -noauth</emphasis>
2969 # <emphasis role="bold">./vos syncserv</emphasis> <<replaceable>machine name</replaceable>> <emphasis
2970 role="bold">-verbose -noauth</emphasis>
2971 </programlisting></para>
2973 <para>You can ignore error messages indicating that tokens are missing, or that authentication failed.</para>
2975 </itemizedlist></para>
2977 </orderedlist></para>
2980 <primary>Update Server</primary>
2982 <secondary>starting server portion</secondary>
2984 <tertiary>first AFS machine</tertiary>
2988 <primary>upserver process</primary>
2990 <see>Update Server</see>
2994 <primary>starting</primary>
2996 <secondary>Update Server server portion</secondary>
2998 <tertiary>first AFS machine</tertiary>
3002 <primary>first AFS machine</primary>
3004 <secondary>Update Server server portion</secondary>
3008 <primary>first AFS machine</primary>
3010 <secondary>defining</secondary>
3012 <tertiary>as binary distribution machine</tertiary>
3016 <primary>first AFS machine</primary>
3018 <secondary>defining</secondary>
3020 <tertiary>as system control machine</tertiary>
3024 <primary>system control machine</primary>
3028 <primary>binary distribution machine</primary>
3032 <sect1 id="HDRWQ61">
3033 <title>Starting the Server Portion of the Update Server</title>
3035 <para>Start the server portion of the Update Server (the <emphasis role="bold">upserver</emphasis> process), to distribute the
3036 contents of directories on this machine to other server machines in the cell. It becomes active when you configure the client
3037 portion of the Update Server on additional server machines.</para>
3039 <para>Distributing the contents of its <emphasis role="bold">/usr/afs/etc</emphasis> directory makes this machine the cell's
3040 <emphasis>system control machine</emphasis>. The other server machines in the cell run the <emphasis
3041 role="bold">upclientetc</emphasis> process (an instance of the client portion of the Update Server) to retrieve the
3042 configuration files. Use the <emphasis role="bold">-crypt</emphasis> argument to the <emphasis role="bold">upserver</emphasis>
3043 initialization command to specify that the Update Server distributes the contents of the <emphasis
3044 role="bold">/usr/afs/etc</emphasis> directory only in encrypted form, as shown in the following instruction. Several of the
3045 files in the directory, particularly the <emphasis role="bold">KeyFile</emphasis> file, are crucial to cell security and so must
3046 never cross the network unencrypted.</para>
3048 <para>(You can choose not to configure a system control machine, in which case you must update the configuration files in each
3049 server machine's <emphasis role="bold">/usr/afs/etc</emphasis> directory individually. The <emphasis role="bold">bos</emphasis>
3050 commands used for this purpose also encrypt data before sending it across the network.)</para>
3052 <para>Distributing the contents of its <emphasis role="bold">/usr/afs/bin</emphasis> directory to other server machines of its
3053 system type makes this machine a <emphasis>binary distribution machine</emphasis>. The other server machines of its system type
3054 run the <emphasis role="bold">upclientbin</emphasis> process (an instance of the client portion of the Update Server) to
3055 retrieve the binaries. If your platform has a package management system,
3056 such as 'rpm' or 'apt', running the Update Server to distribute binaries
3057 may interfere with this system.</para>
3059 <para>The binaries in the <emphasis role="bold">/usr/afs/bin</emphasis> directory are not sensitive, so it is not necessary to
3060 encrypt them before transfer across the network. Include the <emphasis role="bold">-clear</emphasis> argument to the <emphasis
3061 role="bold">upserver</emphasis> initialization command to specify that the Update Server distributes the contents of the
3062 <emphasis role="bold">/usr/afs/bin</emphasis> directory in unencrypted form unless an <emphasis
3063 role="bold">upclientbin</emphasis> process requests encrypted transfer.</para>
3065 <para>Note that the server and client portions of the Update Server always mutually authenticate with one another, regardless of
3066 whether you use the <emphasis role="bold">-clear</emphasis> or <emphasis role="bold">-crypt</emphasis> arguments. This protects
3067 their communications from eavesdropping to some degree.</para>
3069 <para>For more information on the <emphasis role="bold">upclient</emphasis> and <emphasis role="bold">upserver</emphasis>
3070 processes, see their reference pages in the <emphasis>OpenAFS Administration Reference</emphasis>. The commands appear on
3071 multiple lines here only for legibility. <orderedlist>
3073 <para>Issue the <emphasis role="bold">bos create</emphasis> command to start the <emphasis role="bold">upserver</emphasis>
3074 process. <programlisting>
3075 # <emphasis role="bold">./bos create</emphasis> <<replaceable>machine name></replaceable> <emphasis role="bold">upserver simple</emphasis> \
3076 <emphasis role="bold">"/usr/afs/bin/upserver -crypt /usr/afs/etc</emphasis> \
3077 <emphasis role="bold">-clear /usr/afs/bin"</emphasis> <emphasis role="bold">-noauth</emphasis>
3078 </programlisting></para>
3080 </orderedlist></para>
3083 <sect1 id="HDRWQ62">
3084 <title>Clock Sync Considerations</title>
3086 <para>Keeping the clocks on all server and client machines in your cell synchronized is crucial to several functions, and in
3087 particular to the correct operation of AFS's distributed database technology, Ubik. The chapter in the <emphasis>OpenAFS
3088 Administration Guide</emphasis> about administering server machines explains how time skew can disturb Ubik's performance and
3089 cause service outages in your cell.</para>
3091 <para>You should install and configure your time service independently of
3092 AFS. Your Kerberos realm will also require a reliable time source, so your site
3093 may already have one available.</para>
3096 <primary>overview</primary>
3098 <secondary>installing client functionality on first machine</secondary>
3102 <primary>first AFS machine</primary>
3104 <secondary>client functionality</secondary>
3106 <tertiary>installing</tertiary>
3110 <primary>installing</primary>
3112 <secondary>client functionality</secondary>
3114 <tertiary>first AFS machine</tertiary>
3118 <sect1 id="HDRWQ63">
3119 <title>Overview: Installing Client Functionality</title>
3121 <para>The machine you are installing is now an AFS file server machine,
3122 database server machine, system control machine, and binary distribution
3123 machine. Now make it a client machine by completing the following tasks:
3126 <para>Define the machine's cell membership for client processes</para>
3130 <para>Create the client version of the <emphasis role="bold">CellServDB</emphasis> file</para>
3134 <para>Define cache location and size</para>
3138 <para>Create the <emphasis role="bold">/afs</emphasis> directory and start the Cache Manager</para>
3140 </orderedlist></para>
3143 <primary>Distribution</primary>
3145 <secondary>copying client files from</secondary>
3147 <tertiary>first AFS machine</tertiary>
3151 <primary>first AFS machine</primary>
3153 <secondary>copying</secondary>
3155 <tertiary>client files to local disk</tertiary>
3159 <primary>copying</primary>
3161 <secondary>client files to local disk</secondary>
3163 <tertiary>first AFS machine</tertiary>
3167 <sect1 id="HDRWQ64">
3168 <title>Copying Client Files to the Local Disk</title>
3170 <para>You need only undertake the steps in this section, if you are using
3171 a tar file distribution, or one built from scratch. Packaged distributions,
3172 such as RPMs or DEBs will already have installed the necessary files in
3173 the correct locations.</para>
3175 <para>Before installing and configuring the AFS client, copy the necessary files from the tarball to the local <emphasis
3176 role="bold">/usr/vice/etc</emphasis> directory. <orderedlist>
3178 <para>If you have not already done so, unpack the distribution
3179 tarball for this machine's system type into a suitable location on
3180 the filesystem, such as <emphasis role="bold">/tmp/afsdist</emphasis>.
3181 If you use a different location, substitue that in the examples that
3186 <para>Copy files to the local <emphasis role="bold">/usr/vice/etc</emphasis> directory.</para>
3188 <para>This step places a copy of the AFS initialization script (and related files, if applicable) into the <emphasis
3189 role="bold">/usr/vice/etc</emphasis> directory. In the preceding instructions for incorporating AFS into the kernel, you
3190 copied the script directly to the operating system's conventional location for initialization files. When you incorporate
3191 AFS into the machine's startup sequence in a later step, you can choose to link the two files.</para>
3193 <para>On some system types that use a dynamic kernel loader program, you previously copied AFS library files into a
3194 subdirectory of the <emphasis role="bold">/usr/vice/etc</emphasis> directory. On other system types, you copied the
3195 appropriate AFS library file directly to the directory where the operating system accesses it. The following commands do
3196 not copy or recopy the AFS library files into the <emphasis role="bold">/usr/vice/etc</emphasis> directory, because on
3197 some system types the library files consume a large amount of space. If you want to copy them, add the <emphasis
3198 role="bold">-r</emphasis> flag to the first <emphasis role="bold">cp</emphasis> command and skip the second <emphasis
3199 role="bold">cp</emphasis> command.</para>
3202 # <emphasis role="bold">cd /tmp/afsdist/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/root.client/usr/vice/etc</emphasis>
3203 # <emphasis role="bold">cp -p * /usr/vice/etc</emphasis>
3204 # <emphasis role="bold">cp -rp C /usr/vice/etc</emphasis>
3207 </orderedlist></para>
3210 <primary>cell name</primary>
3212 <secondary>setting in client ThisCell file</secondary>
3214 <tertiary>first AFS machine</tertiary>
3218 <primary>setting</primary>
3220 <secondary>cell name in client ThisCell file</secondary>
3222 <tertiary>first AFS machine</tertiary>
3226 <primary>first AFS machine</primary>
3228 <secondary>ThisCell file (client)</secondary>
3232 <primary>first AFS machine</primary>
3234 <secondary>cell membership, defining</secondary>
3236 <tertiary>for client processes</tertiary>
3240 <primary>usr/vice/etc/ThisCell</primary>
3242 <see>ThisCell file (client)</see>
3246 <primary>ThisCell file (client)</primary>
3248 <secondary>first AFS machine</secondary>
3252 <primary>files</primary>
3254 <secondary>ThisCell (client)</secondary>
3258 <sect1 id="HDRWQ65">
3259 <title>Defining Cell Membership for Client Processes</title>
3261 <para>Every AFS client machine has a copy of the <emphasis role="bold">/usr/vice/etc/ThisCell</emphasis> file on its local disk
3262 to define the machine's cell membership for the AFS client programs that run on it. The <emphasis
3263 role="bold">ThisCell</emphasis> file you created in the <emphasis role="bold">/usr/afs/etc</emphasis> directory (in <link
3264 linkend="HDRWQ51">Defining Cell Name and Membership for Server Processes</link>) is used only by server processes.</para>
3266 <para>Among other functions, the <emphasis role="bold">ThisCell</emphasis> file on a client machine determines the following:
3269 <para>The cell in which users gain tokens when they log onto the
3270 machine, assuming it is using an AFS-modified login utility</para>
3274 <para>The cell in which users gain tokens by default when they issue
3275 the <emphasis role="bold">aklog</emphasis> command</para>
3279 <para>The cell membership of the AFS server processes that the AFS
3280 command interpreters on this machine contact by default</para>
3285 <para>Change to the <emphasis role="bold">/usr/vice/etc</emphasis> directory and remove the symbolic link created in <link
3286 linkend="HDRWQ50">Starting the BOS Server</link>. <programlisting>
3287 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
3288 # <emphasis role="bold">rm ThisCell</emphasis>
3289 </programlisting></para>
3293 <para>Create the <emphasis role="bold">ThisCell</emphasis> file as a copy of the <emphasis
3294 role="bold">/usr/afs/etc/ThisCell</emphasis> file. Defining the same local cell for both server and client processes leads
3295 to the most consistent AFS performance. <programlisting>
3296 # <emphasis role="bold">cp /usr/afs/etc/ThisCell ThisCell</emphasis>
3297 </programlisting></para>
3299 </orderedlist></para>
3302 <primary>database server machine</primary>
3304 <secondary>entry in client CellServDB file</secondary>
3306 <tertiary>on first AFS machine</tertiary>
3310 <primary>usr/vice/etc/CellServDB</primary>
3312 <see>CellServDB file (client)</see>
3316 <primary>CellServDB file (client)</primary>
3318 <secondary>creating</secondary>
3320 <tertiary>on first AFS machine</tertiary>
3324 <primary>creating</primary>
3326 <secondary>CellServDB file (client)</secondary>
3328 <tertiary>first AFS machine</tertiary>
3332 <primary>CellServDB file (client)</primary>
3334 <secondary>required format</secondary>
3338 <primary>requirements</primary>
3340 <secondary>CellServDB file format (client version)</secondary>
3344 <primary>files</primary>
3346 <secondary>CellServDB (client)</secondary>
3350 <primary>first AFS machine</primary>
3352 <secondary>CellServDB file (client)</secondary>
3356 <sect1 id="HDRWQ66">
3357 <title>Creating the Client CellServDB File</title>
3359 <para>The <emphasis role="bold">/usr/vice/etc/CellServDB</emphasis> file on a client machine's local disk lists the database
3360 server machines for each cell that the local Cache Manager can contact. If there is no entry in the file for a cell, or if the
3361 list of database server machines is wrong, then users working on this machine cannot access the cell. The chapter in the
3362 <emphasis>OpenAFS Administration Guide</emphasis> about administering client machines explains how to maintain the file after
3365 <para>As the <emphasis role="bold">afsd</emphasis> program initializes the Cache Manager, it copies the contents of the
3366 <emphasis role="bold">CellServDB</emphasis> file into kernel memory. The Cache Manager always consults the list in kernel memory
3367 rather than the <emphasis role="bold">CellServDB</emphasis> file itself. Between reboots of the machine, you can use the
3368 <emphasis role="bold">fs newcell</emphasis> command to update the list in kernel memory directly; see the chapter in the
3369 <emphasis>OpenAFS Administration Guide</emphasis> about administering client machines.</para>
3371 <para>The AFS distribution includes the file
3372 <emphasis role="bold">CellServDB.dist</emphasis>. It includes an entry for
3373 all AFS cells that agreed to share their database server machine
3374 information at the time the distribution was
3375 created. The definitive copy of this file is maintained at
3376 grand.central.org, and updates may be obtained from
3377 /afs/grand.central.org/service/CellServDB or
3378 <ulink url="http://grand.central.org/dl/cellservdb/CellServDB">
3379 http://grand.central.org/dl/cellservdb/CellServDB</ulink></para>
3381 <para>The <emphasis role="bold">CellServDB.dist</emphasis> file can be a
3382 good basis for the client <emphasis role="bold">CellServDB</emphasis> file,
3383 because all of the entries in it use the correct format. You can add or
3384 remove cell entries as you see fit. Depending on your cache manager
3385 configuration, additional steps (as detailed in
3386 <link linkend="HDRWQ91">Enabling Access to Foreign Cells</link>) may be
3387 required to enable the Cache Manager to actually reach the cells.</para>
3389 <para>In this section, you add an entry for the local cell to the local <emphasis role="bold">CellServDB</emphasis> file. The
3390 current working directory is still <emphasis role="bold">/usr/vice/etc</emphasis>. <orderedlist>
3392 <para>Remove the symbolic link created in <link linkend="HDRWQ50">Starting the BOS Server</link> and rename the <emphasis
3393 role="bold">CellServDB.sample</emphasis> file to <emphasis role="bold">CellServDB</emphasis>. <programlisting>
3394 # <emphasis role="bold">rm CellServDB</emphasis>
3395 # <emphasis role="bold">mv CellServDB.sample CellServDB</emphasis>
3396 </programlisting></para>
3400 <para>Add an entry for the local cell to the <emphasis role="bold">CellServDB</emphasis> file. One easy method is to use
3401 the <emphasis role="bold">cat</emphasis> command to append the contents of the server <emphasis
3402 role="bold">/usr/afs/etc/CellServDB</emphasis> file to the client version. <programlisting>
3403 # <emphasis role="bold">cat /usr/afs/etc/CellServDB >> CellServDB</emphasis>
3404 </programlisting></para>
3406 <para>Then open the file in a text editor to verify that there are no blank lines, and that all entries have the required
3407 format, which is described just following. The ordering of cells is not significant, but it can be convenient to have the
3408 client machine's home cell at the top; move it there now if you wish. <itemizedlist>
3410 <para>The first line of a cell's entry has the following format: <programlisting>
3411 ><replaceable>cell_name</replaceable> #<replaceable>organization</replaceable>
3412 </programlisting></para>
3414 <para>where <replaceable>cell_name</replaceable> is the cell's complete Internet domain name (for example, <emphasis
3415 role="bold">example.com</emphasis>) and <replaceable>organization</replaceable> is an optional field that follows any
3416 number of spaces and the number sign (<computeroutput>#</computeroutput>). By convention it names the organization
3417 to which the cell corresponds (for example, the Example Corporation).</para>
3421 <para>After the first line comes a separate line for each database server machine. Each line has the following
3422 format: <programlisting>
3423 <replaceable>IP_address</replaceable> #<replaceable>machine_name</replaceable>
3424 </programlisting></para>
3426 <para>where <replaceable>IP_address</replaceable> is the machine's IP address in dotted decimal format (for example,
3427 192.12.105.3). Following any number of spaces and the number sign (<computeroutput>#</computeroutput>) is
3428 <replaceable>machine_name</replaceable>, the machine's fully-qualified hostname (for example, <emphasis
3429 role="bold">db1.example.com</emphasis>). In this case, the number sign does not indicate a comment;
3430 <replaceable>machine_name</replaceable> is a required field.</para>
3432 </itemizedlist></para>
3436 <para>If the file includes cells that you do not wish users of this machine to access, remove their entries.</para>
3438 </orderedlist></para>
3440 <para>The following example shows entries for two cells, each of which has three database server machines:</para>
3443 >example.com #Example Corporation (home cell)
3444 192.12.105.3 #db1.example.com
3445 192.12.105.4 #db2.example.com
3446 192.12.105.55 #db3.example.com
3447 >example.org #Example Organization cell
3448 138.255.68.93 #serverA.example.org
3449 138.255.68.72 #serverB.example.org
3450 138.255.33.154 #serverC.example.org
3454 <primary>cache</primary>
3456 <secondary>configuring</secondary>
3458 <tertiary>first AFS machine</tertiary>
3462 <primary>configuring</primary>
3464 <secondary>cache</secondary>
3466 <tertiary>first AFS machine</tertiary>
3470 <primary>setting</primary>
3472 <secondary>cache size and location</secondary>
3474 <tertiary>first AFS machine</tertiary>
3478 <primary>first AFS machine</primary>
3480 <secondary>cache size and location</secondary>
3484 <sect1 id="HDRWQ67">
3485 <title>Configuring the Cache</title>
3487 <para>The Cache Manager uses a cache on the local disk or in machine memory to store local copies of files fetched from file
3488 server machines. As the <emphasis role="bold">afsd</emphasis> program initializes the Cache Manager, it sets basic cache
3489 configuration parameters according to definitions in the local <emphasis role="bold">/usr/vice/etc/cacheinfo</emphasis> file.
3490 The file has three fields: <orderedlist>
3492 <para>The first field names the local directory on which to mount the AFS filespace. The conventional location is the
3493 <emphasis role="bold">/afs</emphasis> directory.</para>
3497 <para>The second field defines the local disk directory to use for the disk cache. The conventional location is the
3498 <emphasis role="bold">/usr/vice/cache</emphasis> directory, but you can specify an alternate directory if another
3499 partition has more space available. There must always be a value in this field, but the Cache Manager ignores it if the
3500 machine uses a memory cache.</para>
3504 <para>The third field specifies the number of kilobyte (1024 byte) blocks to allocate for the cache.</para>
3506 </orderedlist></para>
3508 <para>The values you define must meet the following requirements. <itemizedlist>
3510 <para>On a machine using a disk cache, the Cache Manager expects always to be able to use the amount of space specified in
3511 the third field. Failure to meet this requirement can cause serious problems, some of which can be repaired only by
3512 rebooting. You must prevent non-AFS processes from filling up the cache partition. The simplest way is to devote a
3513 partition to the cache exclusively.</para>
3517 <para>The amount of space available in memory or on the partition housing the disk cache directory imposes an absolute
3518 limit on cache size.</para>
3522 <para>The maximum supported cache size can vary in each AFS release; see the <emphasis>OpenAFS Release Notes</emphasis>
3523 for the current version.</para>
3527 <para>For a disk cache, you cannot specify a value in the third field that exceeds 95% of the space available on the
3528 partition mounted at the directory named in the second field. If you violate this restriction, the <emphasis
3529 role="bold">afsd</emphasis> program exits without starting the Cache Manager and prints an appropriate message on the
3530 standard output stream. A value of 90% is more appropriate on most machines. Some operating systems (such as AIX) do not
3531 automatically reserve some space to prevent the partition from filling completely; for them, a smaller value (say, 80% to
3532 85% of the space available) is more appropriate.</para>
3536 <para>For a memory cache, you must leave enough memory for other processes and applications to run. If you try to allocate
3537 more memory than is actually available, the <emphasis role="bold">afsd</emphasis> program exits without initializing the
3538 Cache Manager and produces the following message on the standard output stream. <programlisting>
3539 afsd: memCache allocation failure at <replaceable>number</replaceable> KB
3540 </programlisting></para>
3542 <para>The <replaceable>number</replaceable> value is how many kilobytes were allocated just before the failure, and so
3543 indicates the approximate amount of memory available.</para>
3545 </itemizedlist></para>
3547 <para>Within these hard limits, the factors that determine appropriate cache size include the number of users working on the
3548 machine, the size of the files with which they work, and (for a memory cache) the number of processes that run on the machine.
3549 The higher the demand from these factors, the larger the cache needs to be to maintain good performance.</para>
3551 <para>Disk caches smaller than 10 MB do not generally perform well. Machines serving multiple users usually perform better with
3552 a cache of at least 60 to 70 MB. The point at which enlarging the cache further does not really improve performance depends on
3553 the factors mentioned previously and is difficult to predict.</para>
3555 <para>Memory caches smaller than 1 MB are nonfunctional, and the performance of caches smaller than 5 MB is usually
3556 unsatisfactory. Suitable upper limits are similar to those for disk caches but are probably determined more by the demands on
3557 memory from other sources on the machine (number of users and processes). Machines running only a few processes possibly can use
3558 a smaller memory cache.</para>
3560 <sect2 id="HDRWQ68">
3561 <title>Configuring a Disk Cache</title>
3564 <para>Not all file system types that an operating system supports are necessarily supported for use as the cache partition.
3565 For possible restrictions, see the <emphasis>OpenAFS Release Notes</emphasis>.</para>
3568 <para>To configure the disk cache, perform the following procedures: <orderedlist>
3570 <para>Create the local directory to use for caching. The following instruction shows the conventional location,
3571 <emphasis role="bold">/usr/vice/cache</emphasis>. If you are devoting a partition exclusively to caching, as
3572 recommended, you must also configure it, make a file system on it, and mount it at the directory created in this step.
3574 # <emphasis role="bold">mkdir /usr/vice/cache</emphasis>
3575 </programlisting></para>
3579 <para>Create the <emphasis role="bold">cacheinfo</emphasis> file to define the configuration parameters discussed
3580 previously. The following instruction shows the standard mount location, <emphasis role="bold">/afs</emphasis>, and the
3581 standard cache location, <emphasis role="bold">/usr/vice/cache</emphasis>. <programlisting>
3582 # <emphasis role="bold">echo "/afs:/usr/vice/cache:</emphasis><replaceable>#blocks</replaceable><emphasis role="bold">" > /usr/vice/etc/cacheinfo</emphasis>
3583 </programlisting></para>
3585 <para>The following example defines the disk cache size as 50,000 KB:</para>
3588 # <emphasis role="bold">echo "/afs:/usr/vice/cache:50000" > /usr/vice/etc/cacheinfo</emphasis>
3591 </orderedlist></para>
3594 <sect2 id="HDRWQ69">
3595 <title>Configuring a Memory Cache</title>
3597 <para>To configure a memory cache, create the <emphasis role="bold">cacheinfo</emphasis> file to define the configuration
3598 parameters discussed previously. The following instruction shows the standard mount location, <emphasis
3599 role="bold">/afs</emphasis>, and the standard cache location, <emphasis role="bold">/usr/vice/cache</emphasis> (though the
3600 exact value of the latter is irrelevant for a memory cache).</para>
3603 # <emphasis role="bold">echo "/afs:/usr/vice/cache:</emphasis><replaceable>#blocks</replaceable><emphasis role="bold">" > /usr/vice/etc/cacheinfo</emphasis>
3606 <para>The following example allocates 25,000 KB of memory for the cache.</para>
3609 # <emphasis role="bold">echo "/afs:/usr/vice/cache:25000" > /usr/vice/etc/cacheinfo</emphasis>
3613 <primary>Cache Manager</primary>
3615 <secondary>first AFS machine</secondary>
3619 <primary>configuring</primary>
3621 <secondary>Cache Manager</secondary>
3623 <tertiary>first AFS machine</tertiary>
3627 <primary>first AFS machine</primary>
3629 <secondary>Cache Manager</secondary>
3633 <primary>afs (/afs) directory</primary>
3635 <secondary>creating</secondary>
3637 <tertiary>first AFS machine</tertiary>
3641 <primary>AFS initialization script</primary>
3643 <secondary>setting afsd parameters</secondary>
3645 <tertiary>first AFS machine</tertiary>
3649 <primary>first AFS machine</primary>
3651 <secondary>afsd command parameters</secondary>
3656 <sect1 id="HDRWQ70">
3657 <title>Configuring the Cache Manager</title>
3659 <para>By convention, the Cache Manager mounts the AFS filespace on the local <emphasis role="bold">/afs</emphasis> directory. In
3660 this section you create that directory.</para>
3662 <para>The <emphasis role="bold">afsd</emphasis> program sets several cache configuration parameters as it initializes the Cache
3663 Manager, and starts daemons that improve performance. You can use the <emphasis role="bold">afsd</emphasis> command's arguments
3664 to override the parameters' default values and to change the number of some of the daemons. Depending on the machine's cache
3665 size, its amount of RAM, and how many people work on it, you can sometimes improve Cache Manager performance by overriding the
3666 default values. For a discussion of all of the <emphasis role="bold">afsd</emphasis> command's arguments, see its reference page
3667 in the <emphasis>OpenAFS Administration Reference</emphasis>.</para>
3669 <para>On platforms using the standard 'afs' initialisation script (this does not apply to Fedora or RHEL based distributions), the <emphasis role="bold">afsd</emphasis> command line in the AFS initialization script on each system type includes an
3670 <computeroutput>OPTIONS</computeroutput> variable. You can use it to set nondefault values for the command's arguments, in one
3671 of the following ways: <itemizedlist>
3673 <para>You can create an <emphasis role="bold">afsd</emphasis> <emphasis>options file</emphasis> that sets values for
3674 arguments to the <emphasis role="bold">afsd</emphasis> command. If the file exists, its contents are automatically
3675 substituted for the <computeroutput>OPTIONS</computeroutput> variable in the AFS initialization script. The AFS
3676 distribution for some system types includes an options file; on other system types, you must create it.</para>
3678 <para>You use two variables in the AFS initialization script to specify the path to the options file:
3679 <computeroutput>CONFIG</computeroutput> and <computeroutput>AFSDOPT</computeroutput>. On system types that define a
3680 conventional directory for configuration files, the <computeroutput>CONFIG</computeroutput> variable indicates it by
3681 default; otherwise, the variable indicates an appropriate location.</para>
3683 <para>List the desired <emphasis role="bold">afsd</emphasis> options on a single line in the options file, separating each
3684 option with one or more spaces. The following example sets the <emphasis role="bold">-stat</emphasis> argument to 2500,
3685 the <emphasis role="bold">-daemons</emphasis> argument to 4, and the <emphasis role="bold">-volumes</emphasis> argument to
3689 -stat 2500 -daemons 4 -volumes 100
3694 <para>On a machine that uses a disk cache, you can set the <computeroutput>OPTIONS</computeroutput> variable in the AFS
3695 initialization script to one of <computeroutput>$SMALL</computeroutput>, <computeroutput>$MEDIUM</computeroutput>, or
3696 <computeroutput>$LARGE</computeroutput>. The AFS initialization script uses one of these settings if the <emphasis
3697 role="bold">afsd</emphasis> options file named by the <computeroutput>AFSDOPT</computeroutput> variable does not exist. In
3698 the script as distributed, the <computeroutput>OPTIONS</computeroutput> variable is set to the value
3699 <computeroutput>$MEDIUM</computeroutput>.</para>
3702 <para>Do not set the <computeroutput>OPTIONS</computeroutput> variable to <computeroutput>$SMALL</computeroutput>,
3703 <computeroutput>$MEDIUM</computeroutput>, or <computeroutput>$LARGE</computeroutput> on a machine that uses a memory
3704 cache. The arguments it sets are appropriate only on a machine that uses a disk cache.</para>
3707 <para>The script (or on some system types the <emphasis role="bold">afsd</emphasis> options file named by the
3708 <computeroutput>AFSDOPT</computeroutput> variable) defines a value for each of <computeroutput>SMALL</computeroutput>,
3709 <computeroutput>MEDIUM</computeroutput>, and <computeroutput>LARGE</computeroutput> that sets <emphasis
3710 role="bold">afsd</emphasis> command arguments appropriately for client machines of different sizes: <itemizedlist>
3712 <para><computeroutput>SMALL</computeroutput> is suitable for a small machine that serves one or two users and has
3713 approximately 8 MB of RAM and a 20-MB cache</para>
3717 <para><computeroutput>MEDIUM</computeroutput> is suitable for a medium-sized machine that serves two to six users
3718 and has 16 MB of RAM and a 40-MB cache</para>
3722 <para><computeroutput>LARGE</computeroutput> is suitable for a large machine that serves five to ten users and has
3723 32 MB of RAM and a 100-MB cache</para>
3725 </itemizedlist></para>
3729 <para>You can choose not to create an <emphasis role="bold">afsd</emphasis> options file and to set the
3730 <computeroutput>OPTIONS</computeroutput> variable in the initialization script to a null value rather than to the default
3731 <computeroutput>$MEDIUM</computeroutput> value. You can then either set arguments directly on the <emphasis
3732 role="bold">afsd</emphasis> command line in the script, or set no arguments (and so accept default values for all Cache
3733 Manager parameters).</para>
3738 <para>If you are running on a Fedora or RHEL based system, the
3739 openafs-client initialization script behaves differently from that
3740 described above. It sources /etc/sysconfig/openafs, in which the
3741 AFSD_ARGS variable may be set to contain any, or all, of the afsd options
3742 detailed. Note that this script does not support setting an OPTIONS
3743 variable, or the SMALL, MEDIUM and LARGE methods of defining cache size
3749 <para>Create the local directory on which to mount the AFS filespace, by convention <emphasis role="bold">/afs</emphasis>.
3750 If the directory already exists, verify that it is empty. <programlisting>
3751 # <emphasis role="bold">mkdir /afs</emphasis>
3752 </programlisting></para>
3756 <para>On AIX systems, add the following line to the <emphasis role="bold">/etc/vfs</emphasis> file. It enables AIX to
3757 unmount AFS correctly during shutdown. <programlisting>
3759 </programlisting></para>
3763 <para>On non-package based Linux systems, copy the <emphasis role="bold">afsd</emphasis> options file from the <emphasis
3764 role="bold">/usr/vice/etc</emphasis> directory to the <emphasis role="bold">/etc/sysconfig</emphasis> directory, removing
3765 the <emphasis role="bold">.conf</emphasis> extension as you do so. <programlisting>
3766 # <emphasis role="bold">cp /usr/vice/etc/afs.conf /etc/sysconfig/afs</emphasis>
3767 </programlisting></para>
3771 <para>Edit the machine's AFS initialization script or <emphasis role="bold">afsd</emphasis> options file to set
3772 appropriate values for <emphasis role="bold">afsd</emphasis> command parameters. The script resides in the indicated
3773 location on each system type: <itemizedlist>
3775 <para>On AIX systems, <emphasis role="bold">/etc/rc.afs</emphasis></para>
3779 <para>On HP-UX systems, <emphasis role="bold">/sbin/init.d/afs</emphasis></para>
3783 <para>On IRIX systems, <emphasis role="bold">/etc/init.d/afs</emphasis></para>
3787 <para>On Fedora and RHEL systems, <emphasis role="bold">/etc/sysconfg/openafs</emphasis></para>
3791 <para>On non-package based Linux systems, <emphasis role="bold">/etc/sysconfig/afs</emphasis> (the <emphasis
3792 role="bold">afsd</emphasis> options file)</para>
3796 <para>On Solaris systems, <emphasis role="bold">/etc/init.d/afs</emphasis></para>
3798 </itemizedlist></para>
3800 <para>Use one of the methods described in the introduction to this section to add the following flags to the <emphasis
3801 role="bold">afsd</emphasis> command line. If you intend for the machine to remain an AFS client, also set any
3802 performance-related arguments you wish. <itemizedlist>
3804 <para>Add the <emphasis role="bold">-memcache</emphasis> flag if the machine is to use a memory cache.</para>
3808 <para>Add the <emphasis role="bold">-verbose</emphasis> flag to display a trace of the Cache Manager's
3809 initialization on the standard output stream.</para>
3811 </itemizedlist></para>
3814 <note><para>In order to successfully complete the instructions in the
3815 remainder of this guide, it is important that the machine does not have
3816 a synthetic root (as discussed in <link linkend="HDRWQ91">Enabling Access
3817 to Foreign Cells</link>). As some distributions ship with this enabled, it
3818 may be necessary to remove any occurences of the
3819 <emphasis role="bold">-dynroot</emphasis> and
3820 <emphasis role="bold">-afsdb</emphasis> options from both the AFS
3821 initialisation script and options file. If this functionality is
3822 required it may be renabled as detailed in
3823 <link linkend="HDRWQ91">Enabling Access to Foreign Cells</link>.
3828 <primary>overview</primary>
3830 <secondary>completing installation of first machine</secondary>
3834 <primary>first AFS machine</primary>
3836 <secondary>completion of installation</secondary>
3840 <sect1 id="HDRWQ71">
3841 <title>Overview: Completing the Installation of the First AFS Machine</title>
3843 <para>The machine is now configured as an AFS file server and client machine. In this final phase of the installation, you
3844 initialize the Cache Manager and then create the upper levels of your AFS filespace, among other procedures. The procedures are:
3847 <para>Verify that the initialization script works correctly, and incorporate it into the operating system's startup and
3848 shutdown sequence</para>
3852 <para>Create and mount top-level volumes</para>
3856 <para>Create and mount volumes to store system binaries in AFS</para>
3860 <para>Enable access to foreign cells</para>
3864 <para>Institute additional security measures</para>
3868 <para>Remove client functionality if desired</para>
3870 </orderedlist></para>
3873 <primary>AFS initialization script</primary>
3875 <secondary>verifying on first AFS machine</secondary>
3879 <primary>AFS initialization script</primary>
3881 <secondary>running</secondary>
3883 <tertiary>first AFS machine</tertiary>
3887 <primary>first AFS machine</primary>
3889 <secondary>AFS initialization script</secondary>
3891 <tertiary>running/verifying</tertiary>
3895 <primary>running AFS init. script</primary>
3897 <secondary>first AFS machine</secondary>
3901 <primary>invoking AFS init. script</primary>
3907 <sect1 id="HDRWQ72">
3908 <title>Verifying the AFS Initialization Script</title>
3910 <para>At this point you run the AFS initialization script to verify that it correctly invokes all of the necessary programs and
3911 AFS processes, and that they start correctly. The following are the relevant commands: <itemizedlist>
3913 <para>The command that dynamically loads AFS modifications into the kernel, on some system types (not applicable if the
3914 kernel has AFS modifications built in)</para>
3918 <para>The <emphasis role="bold">bosserver</emphasis> command, which starts the BOS Server; it in turn starts the server
3919 processes for which you created entries in the <emphasis role="bold">/usr/afs/local/BosConfig</emphasis> file</para>
3923 <para>The <emphasis role="bold">afsd</emphasis> command, which initializes the Cache Manager</para>
3925 </itemizedlist></para>
3927 <para>On system types that use a dynamic loader program, you must reboot the machine before running the initialization script,
3928 so that it can freshly load AFS modifications into the kernel.</para>
3930 <para>If there are problems during the initialization, attempt to resolve them. The OpenAFS mailing lists can provide assistance if necessary.
3934 <primary>commands</primary>
3936 <secondary>bos shutdown</secondary>
3940 <primary>bos commands</primary>
3942 <secondary>shutdown</secondary>
3946 <para>Issue the <emphasis role="bold">bos shutdown</emphasis> command to shut down the AFS server processes other than the
3947 BOS Server. Include the <emphasis role="bold">-wait</emphasis> flag to delay return of the command shell prompt until all
3948 processes shut down completely. <programlisting>
3949 # <emphasis role="bold">/usr/afs/bin/bos shutdown</emphasis> <<replaceable>machine name</replaceable>> <emphasis
3950 role="bold">-wait</emphasis>
3951 </programlisting></para>
3955 <para>Issue the <emphasis role="bold">ps</emphasis> command to learn the <emphasis role="bold">bosserver</emphasis>
3956 process's process ID number (PID), and then the <emphasis role="bold">kill</emphasis> command to stop it. <programlisting>
3957 # <emphasis role="bold">ps</emphasis> <replaceable>appropriate_ps_options</replaceable> <emphasis role="bold">| grep bosserver</emphasis>
3958 # <emphasis role="bold">kill</emphasis> <replaceable>bosserver_PID</replaceable>
3959 </programlisting></para>
3963 <para>Issue the appropriate commands to run the AFS initialization script for this system type.</para>
3966 <primary>AIX</primary>
3968 <secondary>AFS initialization script</secondary>
3970 <tertiary>on first AFS machine</tertiary>
3973 <para><emphasis role="bold">On AIX systems:</emphasis> <orderedlist>
3975 <para>Reboot the machine and log in again as the local superuser <emphasis role="bold">root</emphasis>.
3977 # <emphasis role="bold">cd /</emphasis>
3978 # <emphasis role="bold">shutdown -r now</emphasis>
3979 login: <emphasis role="bold">root</emphasis>
3980 Password: <replaceable>root_password</replaceable>
3981 </programlisting></para>
3985 <para>Run the AFS initialization script. <programlisting>
3986 # <emphasis role="bold">/etc/rc.afs</emphasis>
3987 </programlisting></para>
3989 </orderedlist></para>
3992 <primary>HP-UX</primary>
3994 <secondary>AFS initialization script</secondary>
3996 <tertiary>on first AFS machine</tertiary>
3999 <para><emphasis role="bold">On HP-UX systems:</emphasis> <orderedlist>
4001 <para>Run the AFS initialization script. <programlisting>
4002 # <emphasis role="bold">/sbin/init.d/afs start</emphasis>
4003 </programlisting></para>
4005 </orderedlist></para>
4008 <primary>IRIX</primary>
4010 <secondary>AFS initialization script</secondary>
4012 <tertiary>on first AFS machine</tertiary>
4016 <primary>afsclient variable (IRIX)</primary>
4018 <secondary>first AFS machine</secondary>
4022 <primary>variables</primary>
4024 <secondary>afsclient (IRIX)</secondary>
4026 <tertiary>first AFS machine</tertiary>
4030 <primary>IRIX</primary>
4032 <secondary>afsclient variable</secondary>
4034 <tertiary>first AFS machine</tertiary>
4038 <primary>afsserver variable (IRIX)</primary>
4040 <secondary>first AFS machine</secondary>
4044 <primary>variables</primary>
4046 <secondary>afsserver (IRIX)</secondary>
4048 <tertiary>first AFS machine</tertiary>
4052 <primary>IRIX</primary>
4054 <secondary>afsserver variable</secondary>
4056 <tertiary>first AFS machine</tertiary>
4059 <para><emphasis role="bold">On IRIX systems:</emphasis> <orderedlist>
4061 <para>If you have configured the machine to use the <emphasis role="bold">ml</emphasis> dynamic loader program,
4062 reboot the machine and log in again as the local superuser <emphasis role="bold">root</emphasis>. <programlisting>
4063 # <emphasis role="bold">cd /</emphasis>
4064 # <emphasis role="bold">shutdown -i6 -g0 -y</emphasis>
4065 login: <emphasis role="bold">root</emphasis>
4066 Password: <replaceable>root_password</replaceable>
4067 </programlisting></para>
4071 <para>Issue the <emphasis role="bold">chkconfig</emphasis> command to activate the <emphasis
4072 role="bold">afsserver</emphasis> and <emphasis role="bold">afsclient</emphasis> configuration variables.
4074 # <emphasis role="bold">/etc/chkconfig -f afsserver on</emphasis>
4075 # <emphasis role="bold">/etc/chkconfig -f afsclient on</emphasis>
4076 </programlisting></para>
4080 <para>Run the AFS initialization script. <programlisting>
4081 # <emphasis role="bold">/etc/init.d/afs start</emphasis>
4082 </programlisting></para>
4084 </orderedlist></para>
4087 <primary>Linux</primary>
4089 <secondary>AFS initialization script</secondary>
4091 <tertiary>on first AFS machine</tertiary>
4094 <para><emphasis role="bold">On Linux systems:</emphasis> <orderedlist>
4096 <para>Reboot the machine and log in again as the local superuser <emphasis role="bold">root</emphasis>.
4098 # <emphasis role="bold">cd /</emphasis>
4099 # <emphasis role="bold">shutdown -r now</emphasis>
4100 login: <emphasis role="bold">root</emphasis>
4101 Password: <replaceable>root_password</replaceable>
4102 </programlisting></para>
4106 <para>Run the AFS initialization scripts.
4108 # <emphasis role="bold">/etc/rc.d/init.d/openafs-client start</emphasis>
4109 # <emphasis role="bold">/etc/rc.d/init.d/openafs-server start</emphasis>
4110 </programlisting></para>
4112 </orderedlist></para>
4115 <primary>Solaris</primary>
4117 <secondary>AFS initialization script</secondary>
4119 <tertiary>on first AFS machine</tertiary>
4122 <para><emphasis role="bold">On Solaris systems:</emphasis> <orderedlist>
4124 <para>Reboot the machine and log in again as the local superuser <emphasis role="bold">root</emphasis>.
4126 # <emphasis role="bold">cd /</emphasis>
4127 # <emphasis role="bold">shutdown -i6 -g0 -y</emphasis>
4128 login: <emphasis role="bold">root</emphasis>
4129 Password: <replaceable>root_password</replaceable>
4130 </programlisting></para>
4134 <para>Run the AFS initialization script. <programlisting>
4135 # <emphasis role="bold">/etc/init.d/afs start</emphasis>
4136 </programlisting></para>
4138 </orderedlist></para>
4142 <para>Wait for the message that confirms that Cache Manager initialization is complete.</para>
4144 <para>On machines that use a disk cache, it can take a while to initialize the Cache Manager for the first time, because
4145 the <emphasis role="bold">afsd</emphasis> program must create all of the <emphasis
4146 role="bold">V</emphasis><replaceable>n</replaceable> files in the cache directory. Subsequent Cache Manager
4147 initializations do not take nearly as long, because the <emphasis role="bold">V</emphasis><replaceable>n</replaceable>
4148 files already exist.</para>
4153 <primary>commands</primary>
4154 <secondary>aklog</secondary>
4158 <primary>aklog command</primary>
4161 <para>If you are working with an existing cell which uses
4162 <emphasis role="bold">kaserver</emphasis> for authentication,
4163 please recall the note in
4164 <link linkend="KAS003">Using this Appendix</link> detailing the
4165 substitution of <emphasis role="bold">kinit</emphasis> and
4166 <emphasis role="bold">aklog</emphasis> with
4167 <emphasis role="bold">klog</emphasis>.</para>
4169 <para>As a basic test of correct AFS functioning, issue the
4170 <emphasis role="bold">kinit</emphasis> and
4171 <emphasis role="bold">aklog</emphasis> commands to authenticate
4172 as the <emphasis role="bold">admin</emphasis> user.
4173 Provide the password (<replaceable>admin_passwd</replaceable>) you
4174 defined in <link linkend="HDRWQ53">Initializing Cell Security</link>.</para>
4177 # <emphasis role="bold">kinit admin</emphasis>
4178 Password: <replaceable>admin_passwd</replaceable>
4179 # <emphasis role="bold">aklog</emphasis>
4183 <primary>commands</primary>
4185 <secondary>tokens</secondary>
4189 <primary>tokens command</primary>
4194 <para>Issue the <emphasis role="bold">tokens</emphasis> command to
4195 verify that the <emphasis role="bold">aklog</emphasis>
4196 command worked correctly. If it did, the output looks similar to the following example for the <emphasis
4197 role="bold">example.com</emphasis> cell, where <emphasis role="bold">admin</emphasis>'s AFS UID is 1. If the output does not
4198 seem correct, resolve the problem. Changes to the AFS initialization script are possibly necessary. The OpenAFS mailing lists can provide assistance as necessary. <programlisting>
4199 # <emphasis role="bold">tokens</emphasis>
4200 Tokens held by the Cache Manager:
4201 User's (AFS ID 1) tokens for afs@example.com [Expires May 22 11:52]
4203 </programlisting></para>
4207 <para>Issue the <emphasis role="bold">bos status</emphasis> command to verify that the output for each process reads
4208 <computeroutput>Currently running normally</computeroutput>. <programlisting>
4209 # <emphasis role="bold">/usr/afs/bin/bos status</emphasis> <<replaceable>machine name</replaceable>>
4210 </programlisting> <indexterm>
4211 <primary>fs commands</primary>
4213 <secondary>checkvolumes</secondary>
4214 </indexterm> <indexterm>
4215 <primary>commands</primary>
4217 <secondary>fs checkvolumes</secondary>
4222 <para>Change directory to the local file system root (<emphasis role="bold">/</emphasis>) and issue the <emphasis
4223 role="bold">fs checkvolumes</emphasis> command. <programlisting>
4224 # <emphasis role="bold">cd /</emphasis>
4225 # <emphasis role="bold">/usr/afs/bin/fs checkvolumes</emphasis>
4226 </programlisting></para>
4228 </orderedlist></para>
4231 <primary>AFS initialization script</primary>
4233 <secondary>adding to machine startup sequence</secondary>
4235 <tertiary>first AFS machine</tertiary>
4239 <primary>installing</primary>
4241 <secondary>AFS initialization script</secondary>
4243 <tertiary>first AFS machine</tertiary>
4247 <primary>first AFS machine</primary>
4249 <secondary>AFS initialization script</secondary>
4251 <tertiary>activating</tertiary>
4255 <primary>activating AFS init. script</primary>
4257 <see>installing</see>
4261 <sect1 id="HDRWQ73">
4262 <title>Activating the AFS Initialization Script</title>
4264 <para>Now that you have confirmed that the AFS initialization script works correctly, take the action necessary to have it run
4265 automatically at each reboot. Proceed to the instructions for your system type: <itemizedlist>
4267 <para><link linkend="HDRWQ74">Activating the Script on AIX Systems</link></para>
4271 <para><link linkend="HDRWQ76">Activating the Script on HP-UX Systems</link></para>
4275 <para><link linkend="HDRWQ77">Activating the Script on IRIX Systems</link></para>
4279 <para><link linkend="HDRWQ78">Activating the Script on Linux Systems</link></para>
4283 <para><link linkend="HDRWQ79">Activating the Script on Solaris Systems</link></para>
4285 </itemizedlist></para>
4288 <primary>AIX</primary>
4290 <secondary>AFS initialization script</secondary>
4292 <tertiary>on first AFS machine</tertiary>
4295 <sect2 id="HDRWQ74">
4296 <title>Activating the Script on AIX Systems</title>
4300 <para>Edit the AIX initialization file, <emphasis role="bold">/etc/inittab</emphasis>, adding the following line to invoke
4301 the AFS initialization script. Place it just after the line that starts NFS daemons. <programlisting>
4302 rcafs:2:wait:/etc/rc.afs > /dev/console 2>&1 # Start AFS services
4303 </programlisting></para>
4307 <para><emphasis role="bold">(Optional)</emphasis> There are now copies of the AFS initialization file in both the
4308 <emphasis role="bold">/usr/vice/etc</emphasis> and <emphasis role="bold">/etc</emphasis> directories. If you want to avoid
4309 potential confusion by guaranteeing that they are always the same, create a link between them. You can always retrieve the
4310 original script from the AFS CD-ROM if necessary. <programlisting>
4311 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
4312 # <emphasis role="bold">rm rc.afs</emphasis>
4313 # <emphasis role="bold">ln -s /etc/rc.afs</emphasis>
4314 </programlisting></para>
4318 <para>Proceed to <link linkend="HDRWQ80">Configuring the Top Levels of the AFS Filespace</link>.</para>
4323 <primary>HP-UX</primary>
4325 <secondary>AFS initialization script</secondary>
4327 <tertiary>on first AFS machine</tertiary>
4331 <sect2 id="HDRWQ76">
4332 <title>Activating the Script on HP-UX Systems</title>
4336 <para>Change to the <emphasis role="bold">/sbin/init.d</emphasis> directory and issue the <emphasis role="bold">ln
4337 -s</emphasis> command to create symbolic links that incorporate the AFS initialization script into the HP-UX startup and
4338 shutdown sequence. <programlisting>
4339 # <emphasis role="bold">cd /sbin/init.d</emphasis>
4340 # <emphasis role="bold">ln -s ../init.d/afs /sbin/rc2.d/S460afs</emphasis>
4341 # <emphasis role="bold">ln -s ../init.d/afs /sbin/rc2.d/K800afs</emphasis>
4342 </programlisting></para>
4346 <para><emphasis role="bold">(Optional)</emphasis> There are now copies of the AFS initialization file in both the
4347 <emphasis role="bold">/usr/vice/etc</emphasis> and <emphasis role="bold">/sbin/init.d</emphasis> directories. If you want
4348 to avoid potential confusion by guaranteeing that they are always the same, create a link between them. You can always
4349 retrieve the original script from the AFS CD-ROM if necessary. <programlisting>
4350 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
4351 # <emphasis role="bold">rm afs.rc</emphasis>
4352 # <emphasis role="bold">ln -s /sbin/init.d/afs afs.rc</emphasis>
4353 </programlisting></para>
4357 <para>Proceed to <link linkend="HDRWQ80">Configuring the Top Levels of the AFS Filespace</link>.</para>
4362 <primary>IRIX</primary>
4364 <secondary>AFS initialization script</secondary>
4366 <tertiary>on first AFS machine</tertiary>
4370 <sect2 id="HDRWQ77">
4371 <title>Activating the Script on IRIX Systems</title>
4375 <para>Change to the <emphasis role="bold">/etc/init.d</emphasis> directory and issue the <emphasis role="bold">ln
4376 -s</emphasis> command to create symbolic links that incorporate the AFS initialization script into the IRIX startup and
4377 shutdown sequence. <programlisting>
4378 # <emphasis role="bold">cd /etc/init.d</emphasis>
4379 # <emphasis role="bold">ln -s ../init.d/afs /etc/rc2.d/S35afs</emphasis>
4380 # <emphasis role="bold">ln -s ../init.d/afs /etc/rc0.d/K35afs</emphasis>
4381 </programlisting></para>
4385 <para><emphasis role="bold">(Optional)</emphasis> There are now copies of the AFS initialization file in both the
4386 <emphasis role="bold">/usr/vice/etc</emphasis> and <emphasis role="bold">/etc/init.d</emphasis> directories. If you want
4387 to avoid potential confusion by guaranteeing that they are always the same, create a link between them. You can always
4388 retrieve the original script from the AFS CD-ROM if necessary. <programlisting>
4389 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
4390 # <emphasis role="bold">rm afs.rc</emphasis>
4391 # <emphasis role="bold">ln -s /etc/init.d/afs afs.rc</emphasis>
4392 </programlisting></para>
4396 <para>Proceed to <link linkend="HDRWQ80">Configuring the Top Levels of the AFS Filespace</link>.</para>
4401 <primary>Linux</primary>
4403 <secondary>AFS initialization script</secondary>
4405 <tertiary>on first AFS machine</tertiary>
4409 <sect2 id="HDRWQ78">
4410 <title>Activating the Script on Linux Systems</title>
4414 <para>Issue the <emphasis role="bold">chkconfig</emphasis> command to activate the <emphasis role="bold">openafs-client</emphasis> and <emphasis role="bold">openafs-server</emphasis>
4415 configuration variables. Based on the instruction in the AFS initialization file that begins with the string
4416 <computeroutput>#chkconfig</computeroutput>, the command automatically creates the symbolic links that incorporate the
4417 script into the Linux startup and shutdown sequence. <programlisting>
4418 # <emphasis role="bold">/sbin/chkconfig --add openafs-client</emphasis>
4419 # <emphasis role="bold">/sbin/chkconfig --add openafs-server</emphasis>
4420 </programlisting></para>
4424 <para><emphasis role="bold">(Optional)</emphasis> There are now copies of the AFS initialization file in both the
4425 <emphasis role="bold">/usr/vice/etc</emphasis> and <emphasis role="bold">/etc/rc.d/init.d</emphasis> directories, and
4426 copies of the <emphasis role="bold">afsd</emphasis> options file in both the <emphasis
4427 role="bold">/usr/vice/etc</emphasis> and <emphasis role="bold">/etc/sysconfig</emphasis> directories. If you want to avoid
4428 potential confusion by guaranteeing that the two copies of each file are always the same, create a link between them. You
4429 can always retrieve the original script or options file from the AFS CD-ROM if necessary. <programlisting>
4430 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
4431 # <emphasis role="bold">rm afs.rc afs.conf</emphasis>
4432 # <emphasis role="bold">ln -s /etc/rc.d/init.d/afs afs.rc</emphasis>
4433 # <emphasis role="bold">ln -s /etc/sysconfig/afs afs.conf</emphasis>
4434 </programlisting></para>
4438 <para>Proceed to <link linkend="HDRWQ80">Configuring the Top Levels of the AFS Filespace</link>.</para>
4443 <primary>Solaris</primary>
4445 <secondary>AFS initialization script</secondary>
4447 <tertiary>on first AFS machine</tertiary>
4451 <sect2 id="HDRWQ79">
4452 <title>Activating the Script on Solaris Systems</title>
4456 <para>Change to the <emphasis role="bold">/etc/init.d</emphasis> directory and issue the <emphasis role="bold">ln
4457 -s</emphasis> command to create symbolic links that incorporate the AFS initialization script into the Solaris startup and
4458 shutdown sequence. <programlisting>
4459 # <emphasis role="bold">cd /etc/init.d</emphasis>
4460 # <emphasis role="bold">ln -s ../init.d/afs /etc/rc3.d/S99afs</emphasis>
4461 # <emphasis role="bold">ln -s ../init.d/afs /etc/rc0.d/K66afs</emphasis>
4462 </programlisting></para>
4466 <para><emphasis role="bold">(Optional)</emphasis> There are now copies of the AFS initialization file in both the
4467 <emphasis role="bold">/usr/vice/etc</emphasis> and <emphasis role="bold">/etc/init.d</emphasis> directories. If you want
4468 to avoid potential confusion by guaranteeing that they are always the same, create a link between them. You can always
4469 retrieve the original script from the AFS CD-ROM if necessary. <programlisting>
4470 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
4471 # <emphasis role="bold">rm afs.rc</emphasis>
4472 # <emphasis role="bold">ln -s /etc/init.d/afs afs.rc</emphasis>
4473 </programlisting></para>
4478 <primary>AFS filespace</primary>
4480 <secondary>configuring top levels</secondary>
4484 <primary>configuring</primary>
4486 <secondary>AFS filespace (top levels)</secondary>
4491 <sect1 id="HDRWQ80">
4492 <title>Configuring the Top Levels of the AFS Filespace</title>
4494 <para>If you have not previously run AFS in your cell, you now configure the top levels of your cell's AFS filespace. If you
4495 have run a previous version of AFS, the filespace is already configured. Proceed to <link linkend="HDRWQ83">Storing AFS Binaries
4496 in AFS</link>. <indexterm>
4497 <primary>root.cell volume</primary>
4499 <secondary>creating and replicating</secondary>
4500 </indexterm> <indexterm>
4501 <primary>volume</primary>
4503 <secondary>creating</secondary>
4505 <tertiary>root.cell</tertiary>
4506 </indexterm> <indexterm>
4507 <primary>creating</primary>
4509 <secondary>root.cell volume</secondary>
4512 <para>You created the <emphasis role="bold">root.afs</emphasis> volume in <link linkend="HDRWQ60">Starting the File Server,
4513 Volume Server, and Salvager</link>, and the Cache Manager mounted it automatically on the local <emphasis
4514 role="bold">/afs</emphasis> directory when you ran the AFS initialization script in <link linkend="HDRWQ72">Verifying the AFS
4515 Initialization Script</link>. You now set the access control list (ACL) on the <emphasis role="bold">/afs</emphasis> directory;
4516 creating, mounting, and setting the ACL are the three steps required when creating any volume.</para>
4518 <para>After setting the ACL on the <emphasis role="bold">root.afs</emphasis> volume, you create your cell's <emphasis
4519 role="bold">root.cell</emphasis> volume, mount it as a subdirectory of the <emphasis role="bold">/afs</emphasis> directory, and
4520 set the ACL. Create both a read/write and a regular mount point for the <emphasis role="bold">root.cell</emphasis> volume. The
4521 read/write mount point enables you to access the read/write version of replicated volumes when necessary. Creating both mount
4522 points essentially creates separate read-only and read-write copies of your filespace, and enables the Cache Manager to traverse
4523 the filespace on a read-only path or read/write path as appropriate. For further discussion of these concepts, see the chapter
4524 in the <emphasis>OpenAFS Administration Guide</emphasis> about administering volumes. <indexterm>
4525 <primary>root.afs volume</primary>
4527 <secondary>replicating</secondary>
4528 </indexterm> <indexterm>
4529 <primary>volume</primary>
4531 <secondary>replicating root.afs and root.cell</secondary>
4532 </indexterm> <indexterm>
4533 <primary>replicating volumes</primary>
4536 <para>Then replicate both the <emphasis role="bold">root.afs</emphasis> and <emphasis role="bold">root.cell</emphasis> volumes.
4537 This is required if you want to replicate any other volumes in your cell, because all volumes mounted above a replicated volume
4538 must themselves be replicated in order for the Cache Manager to access the replica.</para>
4540 <para>When the <emphasis role="bold">root.afs</emphasis> volume is replicated, the Cache Manager is programmed to access its
4541 read-only version (<emphasis role="bold">root.afs.readonly</emphasis>) whenever possible. To make changes to the contents of the
4542 <emphasis role="bold">root.afs</emphasis> volume (when, for example, you mount another cell's <emphasis
4543 role="bold">root.cell</emphasis> volume at the second level in your filespace), you must mount the <emphasis
4544 role="bold">root.afs</emphasis> volume temporarily, make the changes, release the volume and remove the temporary mount point.
4545 For instructions, see <link linkend="HDRWQ91">Enabling Access to Foreign Cells</link>. <indexterm>
4546 <primary>fs commands</primary>
4548 <secondary>setacl</secondary>
4549 </indexterm> <indexterm>
4550 <primary>commands</primary>
4552 <secondary>fs setacl</secondary>
4553 </indexterm> <indexterm>
4554 <primary>access control list (ACL), setting</primary>
4555 </indexterm> <indexterm>
4556 <primary>setting</primary>
4558 <secondary>ACL</secondary>
4559 </indexterm> <orderedlist>
4561 <para>Issue the <emphasis role="bold">fs setacl</emphasis> command to edit the ACL on the <emphasis
4562 role="bold">/afs</emphasis> directory. Add an entry that grants the <emphasis role="bold">l</emphasis> (<emphasis
4563 role="bold">lookup</emphasis>) and <emphasis role="bold">r</emphasis> (<emphasis role="bold">read</emphasis>) permissions
4564 to the <emphasis role="bold">system:anyuser</emphasis> group, to enable all AFS users who can reach your cell to traverse
4565 through the directory. If you prefer to enable access only to locally authenticated users, substitute the <emphasis
4566 role="bold">system:authuser</emphasis> group.</para>
4568 <para>Note that there is already an ACL entry that grants all seven access rights to the <emphasis
4569 role="bold">system:administrators</emphasis> group. It is a default entry that AFS places on every new volume's root
4572 <para>The top-level AFS directory, typically /afs, is a special case:
4573 when the client is configured to run in dynroot mode (e.g.
4574 <emphasis role="bold">afsd -dynroot</emphasis>, attempts to set
4575 the ACL on this directory will return <emphasis role="bold">
4576 Connection timed out</emphasis>. This is because the dynamically-
4577 generated root directory is not a part of the global AFS space,
4578 and cannot have an access control list set on it.</para>
4581 # <emphasis role="bold">/usr/afs/bin/fs setacl /afs system:anyuser rl</emphasis>
4585 <primary>commands</primary>
4587 <secondary>vos create</secondary>
4589 <tertiary>root.cell volume</tertiary>
4593 <primary>vos commands</primary>
4595 <secondary>create</secondary>
4597 <tertiary>root.cell volume</tertiary>
4601 <primary>fs commands</primary>
4603 <secondary>mkmount</secondary>
4607 <primary>commands</primary>
4609 <secondary>fs mkmount</secondary>
4613 <primary>mount point</primary>
4617 <primary>creating</primary>
4619 <secondary>mount point</secondary>
4623 <primary>volume</primary>
4625 <secondary>mounting</secondary>
4629 <listitem id="LIWQ81">
4630 <para>Issue the <emphasis role="bold">vos create</emphasis> command to create the <emphasis
4631 role="bold">root.cell</emphasis> volume. Then issue the <emphasis role="bold">fs mkmount</emphasis> command to mount it as
4632 a subdirectory of the <emphasis role="bold">/afs</emphasis> directory, where it serves as the root of your cell's local
4633 AFS filespace. Finally, issue the <emphasis role="bold">fs setacl</emphasis> command to create an ACL entry for the
4634 <emphasis role="bold">system:anyuser</emphasis> group (or <emphasis role="bold">system:authuser</emphasis> group).</para>
4636 <para>For the <replaceable>partition name</replaceable> argument, substitute the name of one of the machine's AFS server
4637 partitions (such as <emphasis role="bold">/vicepa</emphasis>). For the <replaceable>cellname</replaceable> argument,
4638 substitute your cell's fully-qualified Internet domain name (such as <emphasis role="bold">example.com</emphasis>).</para>
4641 # <emphasis role="bold">/usr/afs/bin/vos create</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <emphasis
4642 role="bold">root.cell</emphasis>
4643 # <emphasis role="bold">/usr/afs/bin/fs mkmount /afs/</emphasis><replaceable>cellname</replaceable> <emphasis role="bold">root.cell</emphasis>
4644 # <emphasis role="bold">/usr/afs/bin/fs setacl /afs/</emphasis><replaceable>cellname</replaceable> <emphasis role="bold">system:anyuser rl</emphasis>
4648 <primary>creating</primary>
4650 <secondary>symbolic link</secondary>
4652 <tertiary>for abbreviated cell name</tertiary>
4656 <primary>symbolic link</primary>
4658 <secondary>for abbreviated cell name</secondary>
4662 <primary>cell name</primary>
4664 <secondary>symbolic link for abbreviated</secondary>
4669 <para><emphasis role="bold">(Optional)</emphasis> Create a symbolic link to a shortened cell name, to reduce the length of
4670 pathnames for users in the local cell. For example, in the <emphasis role="bold">example.com</emphasis> cell, <emphasis
4671 role="bold">/afs/example</emphasis> is a link to <emphasis role="bold">/afs/example.com</emphasis>. <programlisting>
4672 # <emphasis role="bold">cd /afs</emphasis>
4673 # <emphasis role="bold">ln -s</emphasis> <replaceable>full_cellname</replaceable> <replaceable>short_cellname</replaceable>
4674 </programlisting> <indexterm>
4675 <primary>read/write mount point for root.afs volume</primary>
4676 </indexterm> <indexterm>
4677 <primary>root.afs volume</primary>
4679 <secondary>read/write mount point</secondary>
4680 </indexterm> <indexterm>
4681 <primary>creating</primary>
4683 <secondary>read/write mount point</secondary>
4688 <para>Issue the <emphasis role="bold">fs mkmount</emphasis> command to create a read/write mount point for the <emphasis
4689 role="bold">root.cell</emphasis> volume (you created a regular mount point in Step <link
4690 linkend="LIWQ81">2</link>).</para>
4692 <para>By convention, the name of a read/write mount point begins with a period, both to distinguish it from the regular
4693 mount point and to make it visible only when the <emphasis role="bold">-a</emphasis> flag is used on the <emphasis
4694 role="bold">ls</emphasis> command.</para>
4696 <para>Change directory to <emphasis role="bold">/usr/afs/bin</emphasis> to make it easier to access the command
4700 # <emphasis role="bold">cd /usr/afs/bin</emphasis>
4701 # <emphasis role="bold">./fs mkmount /afs/.</emphasis><replaceable>cellname</replaceable> <emphasis role="bold">root.cell -rw</emphasis>
4705 <primary>commands</primary>
4707 <secondary>vos addsite</secondary>
4711 <primary>vos commands</primary>
4713 <secondary>addsite</secondary>
4717 <primary>volume</primary>
4719 <secondary>defining replication site</secondary>
4723 <primary>defining</primary>
4725 <secondary>replication site for volume</secondary>
4729 <listitem id="LIWQ82">
4730 <para>Issue the <emphasis role="bold">vos addsite</emphasis> command to define a replication site
4731 for both the <emphasis role="bold">root.afs</emphasis> and <emphasis role="bold">root.cell</emphasis> volumes. In each
4732 case, substitute for the <replaceable>partition name</replaceable> argument the partition where the volume's read/write
4733 version resides. When you install additional file server machines, it is a good idea to create replication sites on them
4734 as well. <programlisting>
4735 # <emphasis role="bold">./vos addsite</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <emphasis
4736 role="bold">root.afs</emphasis>
4737 # <emphasis role="bold">./vos addsite</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <emphasis
4738 role="bold">root.cell</emphasis>
4739 </programlisting> <indexterm>
4740 <primary>fs commands</primary>
4742 <secondary>examine</secondary>
4743 </indexterm> <indexterm>
4744 <primary>commands</primary>
4746 <secondary>fs examine</secondary>
4751 <para>Issue the <emphasis role="bold">fs examine</emphasis> command to verify that the Cache Manager can access both the
4752 <emphasis role="bold">root.afs</emphasis> and <emphasis role="bold">root.cell</emphasis> volumes, before you attempt to
4753 replicate them. The output lists each volume's name, volumeID number, quota, size, and the size of the partition that
4754 houses them. If you get an error message instead, do not continue before taking corrective action. <programlisting>
4755 # <emphasis role="bold">./fs examine /afs</emphasis>
4756 # <emphasis role="bold">./fs examine /afs/</emphasis><replaceable>cellname</replaceable>
4757 </programlisting> <indexterm>
4758 <primary>commands</primary>
4760 <secondary>vos release</secondary>
4761 </indexterm> <indexterm>
4762 <primary>vos commands</primary>
4764 <secondary>release</secondary>
4765 </indexterm> <indexterm>
4766 <primary>volume</primary>
4768 <secondary>releasing replicated</secondary>
4769 </indexterm> <indexterm>
4770 <primary>releasing replicated volume</primary>
4775 <para>Issue the <emphasis role="bold">vos release</emphasis> command to release a replica of the <emphasis
4776 role="bold">root.afs</emphasis> and <emphasis role="bold">root.cell</emphasis> volumes to the sites you defined in Step
4777 <link linkend="LIWQ82">5</link>. <programlisting>
4778 # <emphasis role="bold">./vos release root.afs</emphasis>
4779 # <emphasis role="bold">./vos release root.cell</emphasis>
4780 </programlisting> <indexterm>
4781 <primary>fs commands</primary>
4783 <secondary>checkvolumes</secondary>
4784 </indexterm> <indexterm>
4785 <primary>commands</primary>
4787 <secondary>fs checkvolumes</secondary>
4792 <para>Issue the <emphasis role="bold">fs checkvolumes</emphasis> to force the Cache Manager to notice that you have
4793 released read-only versions of the volumes, then issue the <emphasis role="bold">fs examine</emphasis> command again. This
4794 time its output mentions the read-only version of the volumes (<emphasis role="bold">root.afs.readonly</emphasis> and
4795 <emphasis role="bold">root.cell.readonly</emphasis>) instead of the read/write versions, because of the Cache Manager's
4796 bias to access the read-only version of the <emphasis role="bold">root.afs</emphasis> volume if it exists.
4798 # <emphasis role="bold">./fs checkvolumes</emphasis>
4799 # <emphasis role="bold">./fs examine /afs</emphasis>
4800 # <emphasis role="bold">./fs examine /afs/</emphasis><replaceable>cellname</replaceable>
4801 </programlisting></para>
4803 </orderedlist></para>
4806 <primary>storing</primary>
4808 <secondary>AFS binaries in volumes</secondary>
4812 <primary>creating</primary>
4814 <secondary>volume</secondary>
4816 <tertiary>for AFS binaries</tertiary>
4820 <primary>volume</primary>
4822 <secondary>for AFS binaries</secondary>
4826 <primary>binaries</primary>
4828 <secondary>storing AFS in volume</secondary>
4832 <primary>usr/afsws directory</primary>
4836 <primary>directories</primary>
4838 <secondary>/usr/afsws</secondary>
4842 <sect1 id="HDRWQ83">
4843 <title>Storing AFS Binaries in AFS</title>
4845 <note><para>Sites with existing binary distribution mechanisms, including
4846 those which use packaging systems such as RPM, may wish to skip this step,
4847 and use tools native to their operating system to manage AFS configuration
4848 information.</para></note>
4850 <para>In the conventional configuration, you make AFS client binaries and configuration files available in the subdirectories of
4851 the <emphasis role="bold">/usr/afsws</emphasis> directory on client machines (<emphasis role="bold">afsws</emphasis> is an
4852 acronym for <emphasis role="bold">AFS w</emphasis><emphasis>ork</emphasis><emphasis
4853 role="bold">s</emphasis><emphasis>tation</emphasis>). You can conserve local disk space by creating <emphasis
4854 role="bold">/usr/afsws</emphasis> as a link to an AFS volume that houses the AFS client binaries and configuration files for
4855 this system type.</para>
4857 <para>In this section you create the necessary volumes. The conventional location to which to link <emphasis
4858 role="bold">/usr/afsws</emphasis> is <emphasis role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
4859 role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/usr/afsws</emphasis>, where
4860 <replaceable>sysname</replaceable> is the appropriate system type name as specified in the <emphasis>OpenAFS Release
4861 Notes</emphasis>. The instructions in <link linkend="HDRWQ133">Installing Additional Client Machines</link> assume that you have
4862 followed the instructions in this section.</para>
4864 <para>If you have previously run AFS in the cell, the volumes possibly already exist. If so, you need to perform Step <link
4865 linkend="LIWQ86">8</link> only.</para>
4867 <para>The current working directory is still <emphasis role="bold">/usr/afs/bin</emphasis>, which houses the <emphasis
4868 role="bold">fs</emphasis> and <emphasis role="bold">vos</emphasis> command suite binaries. In the following commands, it is
4869 possible you still need to specify the pathname to the commands, depending on how your PATH environment variable is set.
4872 <primary>commands</primary>
4874 <secondary>vos create</secondary>
4876 <tertiary>volume for AFS binaries</tertiary>
4880 <primary>vos commands</primary>
4882 <secondary>create</secondary>
4884 <tertiary>volume for AFS binaries</tertiary>
4887 <listitem id="LIWQ84">
4888 <para>Issue the <emphasis role="bold">vos create</emphasis> command to create volumes for storing
4889 the AFS client binaries for this system type. The following example instruction creates volumes called
4890 <replaceable>sysname</replaceable>, <replaceable>sysname</replaceable>.<emphasis role="bold">usr</emphasis>, and
4891 <replaceable>sysname</replaceable>.<emphasis role="bold">usr.afsws</emphasis>. Refer to the <emphasis>OpenAFS Release
4892 Notes</emphasis> to learn the proper value of <replaceable>sysname</replaceable> for this system type. <programlisting>
4893 # <emphasis role="bold">vos create</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <replaceable>sysname</replaceable>
4894 # <emphasis role="bold">vos create</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <replaceable>sysname</replaceable><emphasis
4895 role="bold">.usr</emphasis>
4896 # <emphasis role="bold">vos create</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <replaceable>sysname</replaceable><emphasis
4897 role="bold">.usr.afsws</emphasis>
4898 </programlisting></para>
4902 <para>Issue the <emphasis role="bold">fs mkmount</emphasis> command to mount the newly created volumes. Because the
4903 <emphasis role="bold">root.cell</emphasis> volume is replicated, you must precede the <emphasis>cellname</emphasis> part
4904 of the pathname with a period to specify the read/write mount point, as shown. Then issue the <emphasis role="bold">vos
4905 release</emphasis> command to release a new replica of the <emphasis role="bold">root.cell</emphasis> volume, and the
4906 <emphasis role="bold">fs checkvolumes</emphasis> command to force the local Cache Manager to access them. <programlisting>
4907 # <emphasis role="bold">fs mkmount -dir /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/</emphasis><replaceable>sysname</replaceable> <emphasis
4908 role="bold">-vol</emphasis> <replaceable>sysname</replaceable>
4909 # <emphasis role="bold">fs mkmount -dir /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis
4910 role="bold">/usr</emphasis> <emphasis role="bold">-vol</emphasis> <replaceable>sysname</replaceable><emphasis
4911 role="bold">.usr</emphasis>
4912 # <emphasis role="bold">fs mkmount -dir /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis
4913 role="bold">/usr/afsws</emphasis> <emphasis role="bold">-vol</emphasis> <replaceable>sysname</replaceable><emphasis
4914 role="bold">.usr.afsws</emphasis>
4915 # <emphasis role="bold">vos release root.cell</emphasis>
4916 # <emphasis role="bold">fs checkvolumes</emphasis>
4917 </programlisting></para>
4921 <para>Issue the <emphasis role="bold">fs setacl</emphasis> command to grant the <emphasis role="bold">l</emphasis>
4922 (<emphasis role="bold">lookup</emphasis>) and <emphasis role="bold">r</emphasis> (<emphasis role="bold">read</emphasis>)
4923 permissions to the <emphasis role="bold">system:anyuser</emphasis> group on each new directory's ACL. <programlisting>
4924 # <emphasis role="bold">cd /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/</emphasis><replaceable>sysname</replaceable>
4925 # <emphasis role="bold">fs setacl -dir . usr usr/afsws -acl system:anyuser rl</emphasis>
4926 </programlisting> <indexterm>
4927 <primary>commands</primary>
4929 <secondary>fs setquota</secondary>
4930 </indexterm> <indexterm>
4931 <primary>fs commands</primary>
4933 <secondary>setquota</secondary>
4934 </indexterm> <indexterm>
4935 <primary>quota for volume</primary>
4936 </indexterm> <indexterm>
4937 <primary>volume</primary>
4939 <secondary>setting quota</secondary>
4940 </indexterm> <indexterm>
4941 <primary>setting</primary>
4943 <secondary>volume quota</secondary>
4947 <listitem id="LIWQ85">
4948 <para>Issue the <emphasis role="bold">fs setquota</emphasis> command to set an unlimited quota on
4949 the volume mounted at the <emphasis role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
4950 role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/usr/afsws</emphasis> directory. This
4951 enables you to copy all of the appropriate files from the CD-ROM into the volume without exceeding the volume's
4954 <para>If you wish, you can set the volume's quota to a finite value after you complete the copying operation. At that
4955 point, use the <emphasis role="bold">vos examine</emphasis> command to determine how much space the volume is occupying.
4956 Then issue the <emphasis role="bold">fs setquota</emphasis> command to set a quota that is slightly larger.</para>
4959 # <emphasis role="bold">fs setquota /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis
4960 role="bold">/usr/afsws 0</emphasis>
4965 <para>Unpack the distribution tarball into the <emphasis role="bold">/tmp/afsdist</emphasis> directory,
4966 if it is not already. <indexterm>
4967 <primary>copying</primary>
4969 <secondary>AFS binaries into volume</secondary>
4970 </indexterm> <indexterm>
4971 <primary>CD-ROM</primary>
4973 <secondary>copying AFS binaries into volume</secondary>
4974 </indexterm> <indexterm>
4975 <primary>first AFS machine</primary>
4977 <secondary>copying</secondary>
4979 <tertiary>AFS binaries into volume</tertiary>
4984 <para>Copy the contents of the indicated directories from the
4985 distribution into the <emphasis
4986 role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
4987 role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/usr/afsws</emphasis> directory.
4989 # <emphasis role="bold">cd /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/</emphasis><replaceable>sysname</replaceable><emphasis
4990 role="bold">/usr/afsws</emphasis>
4991 # <emphasis role="bold">cp -rp /tmp/afsdist/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/bin .</emphasis>
4992 # <emphasis role="bold">cp -rp /tmp/afsdist/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/etc .</emphasis>
4993 # <emphasis role="bold">cp -rp /tmp/afsdist/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/include .</emphasis>
4994 # <emphasis role="bold">cp -rp /tmp/afsdist/</emphasis><replaceable>sysname</replaceable><emphasis role="bold">/lib .</emphasis>
4997 <primary>creating</primary>
4999 <secondary>symbolic link</secondary>
5001 <tertiary>to AFS binaries</tertiary>
5002 </indexterm> <indexterm>
5003 <primary>symbolic link</primary>
5005 <secondary>to AFS binaries from local disk</secondary>
5009 <listitem id="LIWQ86">
5010 <para>Create <emphasis role="bold">/usr/afsws</emphasis> on the local disk as a symbolic link to the
5011 directory <emphasis role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
5012 role="bold">/@sys/usr/afsws</emphasis>. You can specify the actual system name instead of <emphasis
5013 role="bold">@sys</emphasis> if you wish, but the advantage of using <emphasis role="bold">@sys</emphasis> is that it
5014 remains valid if you upgrade this machine to a different system type. <programlisting>
5015 # <emphasis role="bold">ln -s /afs/</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/@sys/usr/afsws /usr/afsws</emphasis>
5016 </programlisting> <indexterm>
5017 <primary>PATH environment variable for users</primary>
5018 </indexterm> <indexterm>
5019 <primary>variables</primary>
5021 <secondary>PATH, setting for users</secondary>
5026 <para><emphasis role="bold">(Optional)</emphasis> To enable users to issue commands from the AFS suites (such as <emphasis
5027 role="bold">fs</emphasis>) without having to specify a pathname to their binaries, include the <emphasis
5028 role="bold">/usr/afsws/bin</emphasis> and <emphasis role="bold">/usr/afsws/etc</emphasis> directories in the PATH
5029 environment variable you define in each user's shell initialization file (such as <emphasis
5030 role="bold">.cshrc</emphasis>).</para>
5032 </orderedlist></para>
5035 <primary>storing</primary>
5037 <secondary>AFS documentation in volumes</secondary>
5041 <primary>creating</primary>
5043 <secondary>volume</secondary>
5045 <tertiary>for AFS documentation</tertiary>
5049 <primary>volume</primary>
5051 <secondary>for AFS documentation</secondary>
5055 <primary>documentation, creating volume for AFS</primary>
5059 <primary>usr/afsdoc directory</primary>
5063 <primary>directories</primary>
5065 <secondary>/usr/afsdoc</secondary>
5069 <sect1 id="HDRWQ87">
5070 <title>Storing AFS Documents in AFS</title>
5072 <para>The AFS distribution includes the following documents: <itemizedlist>
5074 <para><emphasis>OpenAFS Release Notes</emphasis></para>
5078 <para><emphasis>OpenAFS Quick Beginnings</emphasis></para>
5082 <para><emphasis>OpenAFS User Guide</emphasis></para>
5086 <para><emphasis>OpenAFS Administration Reference</emphasis></para>
5090 <para><emphasis>OpenAFS Administration Guide</emphasis></para>
5092 </itemizedlist></para>
5094 <note><para>OpenAFS Documentation is not currently provided with all
5095 distributions, but may be downloaded separately from the OpenAFS
5096 website</para></note>
5098 <para>The OpenAFS Documentation Distribution has a directory for each
5099 document format provided. The different formats are suitable for online
5100 viewing, printing, or both.</para>
5102 <para>This section explains how to create and mount a volume to house the documents, making them available to your users. The
5103 recommended mount point for the volume is <emphasis role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
5104 role="bold">/afsdoc</emphasis>. If you wish, you can create a link to the mount point on each client machine's local disk,
5105 called <emphasis role="bold">/usr/afsdoc</emphasis>. Alternatively, you can create a link to the mount point in each user's home
5106 directory. You can also choose to permit users to access only certain documents (most probably, the <emphasis>OpenAFS User
5107 Guide</emphasis>) by creating different mount points or setting different ACLs on different document directories.</para>
5109 <para>The current working directory is still <emphasis role="bold">/usr/afs/bin</emphasis>, which houses the <emphasis
5110 role="bold">fs</emphasis> and <emphasis role="bold">vos</emphasis> command suite binaries you use to create and mount volumes.
5111 In the following commands, it is possible you still need to specify the pathname to the commands, depending on how your PATH
5112 environment variable is set. <orderedlist>
5114 <primary>commands</primary>
5116 <secondary>vos create</secondary>
5118 <tertiary>volume for AFS documentation</tertiary>
5122 <primary>vos commands</primary>
5124 <secondary>create</secondary>
5126 <tertiary>volume for AFS documentation</tertiary>
5130 <para>Issue the <emphasis role="bold">vos create</emphasis> command to create a volume for storing the AFS documentation.
5131 Include the <emphasis role="bold">-maxquota</emphasis> argument to set an unlimited quota on the volume. This enables you
5132 to copy all of the appropriate files from the CD-ROM into the volume without exceeding the volume's quota.</para>
5134 <para>If you wish, you can set the volume's quota to a finite value after you complete the copying operations. At that
5135 point, use the <emphasis role="bold">vos examine</emphasis> command to determine how much space the volume is occupying.
5136 Then issue the <emphasis role="bold">fs setquota</emphasis> command to set a quota that is slightly larger.</para>
5139 # <emphasis role="bold">vos create</emphasis> <<replaceable>machine name</replaceable>> <<replaceable>partition name</replaceable>> <emphasis
5140 role="bold">afsdoc -maxquota 0</emphasis>
5145 <para>Issue the <emphasis role="bold">fs mkmount</emphasis> command to mount the new volume. Because the <emphasis
5146 role="bold">root.cell</emphasis> volume is replicated, you must precede the <emphasis>cellname</emphasis> with a period to
5147 specify the read/write mount point, as shown. Then issue the <emphasis role="bold">vos release</emphasis> command to
5148 release a new replica of the <emphasis role="bold">root.cell</emphasis> volume, and the <emphasis role="bold">fs
5149 checkvolumes</emphasis> command to force the local Cache Manager to access them. <programlisting>
5150 # <emphasis role="bold">fs mkmount -dir /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/afsdoc</emphasis> <emphasis
5151 role="bold">-vol</emphasis> <emphasis role="bold">afsdoc</emphasis>
5152 # <emphasis role="bold">vos release root.cell</emphasis>
5153 # <emphasis role="bold">fs checkvolumes</emphasis>
5154 </programlisting></para>
5158 <para>Issue the <emphasis role="bold">fs setacl</emphasis> command to grant the <emphasis role="bold">rl</emphasis>
5159 permissions to the <emphasis role="bold">system:anyuser</emphasis> group on the new directory's ACL. <programlisting>
5160 # <emphasis role="bold">cd /afs/.</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/afsdoc</emphasis>
5161 # <emphasis role="bold">fs setacl . system:anyuser rl</emphasis>
5162 </programlisting></para>
5166 <para>Unpack the OpenAFS documentation distribution into the
5167 <emphasis role="bold">/tmp/afsdocs</emphasis> directory. You may use
5168 a different directory, in which case the location you use should be
5169 subsituted in the following examples. For instructions on unpacking
5170 the distribution, consult the documentation for your operating
5171 system's <emphasis role="bold">tar</emphasis> command.
5173 <primary>copying</primary>
5175 <secondary>AFS documentation from distribution</secondary>
5176 </indexterm> <indexterm>
5177 <primary>OpenAFS Distribution</primary>
5179 <secondary>copying AFS documentation from</secondary>
5180 </indexterm> <indexterm>
5181 <primary>first AFS machine</primary>
5183 <secondary>copying</secondary>
5185 <tertiary>AFS documentation from OpenAFS distribution</tertiary>
5186 </indexterm> <indexterm>
5187 <primary>index.htm file</primary>
5188 </indexterm> <indexterm>
5189 <primary>files</primary>
5191 <secondary>index.htm</secondary>
5196 <para>Copy the AFS documents in one or more formats from the unpacked distribution into subdirectories of the <emphasis
5197 role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/afsdoc</emphasis> directory. Repeat
5198 the commands for each format. <programlisting>
5199 # <emphasis role="bold">mkdir</emphasis> <replaceable>format_name</replaceable>
5200 # <emphasis role="bold">cd</emphasis> <replaceable>format_name</replaceable>
5201 # <emphasis role="bold">cp -rp /tmp/afsdocs/</emphasis><replaceable>format</replaceable> <emphasis role="bold">.</emphasis>
5202 </programlisting></para>
5204 <para>If you choose to store the HTML version of the documents in AFS, note that in addition to a subdirectory for each
5205 document there are several files with a <emphasis role="bold">.gif</emphasis> extension, which enable readers to move
5206 easily between sections of a document. The file called <emphasis role="bold">index.htm</emphasis> is an introductory HTML
5207 page that contains a hyperlink to each of the documents. For online viewing to work properly, these files must remain in
5208 the top-level HTML directory (the one named, for example, <emphasis
5209 role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/afsdoc/html</emphasis>).</para>
5213 <para><emphasis role="bold">(Optional)</emphasis> If you believe it is helpful to your users to access the AFS documents
5214 in a certain format via a local disk directory, create <emphasis role="bold">/usr/afsdoc</emphasis> on the local disk as a
5215 symbolic link to the documentation directory in AFS (<emphasis
5216 role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
5217 role="bold">/afsdoc/</emphasis><replaceable>format_name</replaceable>). <programlisting>
5218 # <emphasis role="bold">ln -s /afs/</emphasis><replaceable>cellname</replaceable><emphasis role="bold">/afsdoc/</emphasis><replaceable>format_name</replaceable> <emphasis
5219 role="bold">/usr/afsdoc</emphasis>
5220 </programlisting></para>
5222 <para>An alternative is to create a link in each user's home directory to the <emphasis
5223 role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
5224 role="bold">/afsdoc/</emphasis><replaceable>format_name</replaceable> directory.</para>
5226 </orderedlist></para>
5229 <primary>storing</primary>
5231 <secondary>system binaries in volumes</secondary>
5235 <primary>creating</primary>
5237 <secondary>volume</secondary>
5239 <tertiary>for system binaries</tertiary>
5243 <primary>volume</primary>
5245 <secondary>for system binaries</secondary>
5249 <primary>binaries</primary>
5251 <secondary>storing system in volumes</secondary>
5255 <sect1 id="HDRWQ88">
5256 <title>Storing System Binaries in AFS</title>
5258 <para>You can also choose to store other system binaries in AFS volumes, such as the standard UNIX programs conventionally
5259 located in local disk directories such as <emphasis role="bold">/etc</emphasis>, <emphasis role="bold">/bin</emphasis>, and
5260 <emphasis role="bold">/lib</emphasis>. Storing such binaries in an AFS volume not only frees local disk space, but makes it
5261 easier to update binaries on all client machines.</para>
5263 <para>The following is a suggested scheme for storing system binaries in AFS. It does not include instructions, but you can use
5264 the instructions in <link linkend="HDRWQ83">Storing AFS Binaries in AFS</link> (which are for AFS-specific binaries) as a
5267 <para>Some files must remain on the local disk for use when AFS is inaccessible (during bootup and file server or network
5268 outages). The required binaries include the following: <itemizedlist>
5270 <para>A text editor, network commands, and so on</para>
5274 <para>Files used during the boot sequence before the <emphasis role="bold">afsd</emphasis> program runs, such as
5275 initialization and configuration files, and binaries for commands that mount file systems</para>
5279 <para>Files used by dynamic kernel loader programs</para>
5281 </itemizedlist></para>
5283 <para>In most cases, it is more secure to enable only locally authenticated users to access system binaries, by granting the
5284 <emphasis role="bold">l</emphasis> (<emphasis role="bold">lookup</emphasis>) and <emphasis role="bold">r</emphasis> (<emphasis
5285 role="bold">read</emphasis>) permissions to the <emphasis role="bold">system:authuser</emphasis> group on the ACLs of
5286 directories that contain the binaries. If users need to access a binary while unauthenticated, however, the ACL on its directory
5287 must grant those permissions to the <emphasis role="bold">system:anyuser</emphasis> group.</para>
5289 <para>The following chart summarizes the suggested volume and mount point names for storing system binaries. It uses a separate
5290 volume for each directory. You already created a volume called <replaceable>sysname</replaceable> for this machine's system type
5291 when you followed the instructions in <link linkend="HDRWQ83">Storing AFS Binaries in AFS</link>.</para>
5293 <para>You can name volumes in any way you wish, and mount them at other locations than those suggested here. However, this
5294 scheme has several advantages: <itemizedlist>
5296 <para>Volume names clearly identify volume contents</para>
5300 <para>Using the <replaceable>sysname</replaceable> prefix on every volume makes it is easy to back up all of the volumes
5301 together, because the AFS Backup System enables you to define sets of volumes based on a string included in all of their
5306 <para>It makes it easy to track related volumes, keeping them together on the same file server machine if desired</para>
5310 <para>There is a clear relationship between volume name and mount point name</para>
5312 </itemizedlist></para>
5314 <informaltable frame="none">
5316 <colspec colwidth="50*" />
5318 <colspec colwidth="50*" />
5322 <entry><emphasis role="bold">Volume Name</emphasis></entry>
5324 <entry><emphasis role="bold">Mount Point</emphasis></entry>
5330 <entry><replaceable>sysname</replaceable></entry>
5333 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable></entry>
5337 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">bin</emphasis></entry>
5340 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5341 role="bold">/bin</emphasis></entry>
5345 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">etc</emphasis></entry>
5348 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5349 role="bold">/etc</emphasis></entry>
5353 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr</emphasis></entry>
5356 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5357 role="bold">/usr</emphasis></entry>
5361 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.afsws</emphasis></entry>
5364 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5365 role="bold">/usr/afsws</emphasis></entry>
5369 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.bin</emphasis></entry>
5372 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5373 role="bold">/usr/bin</emphasis></entry>
5377 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.etc</emphasis></entry>
5380 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5381 role="bold">/usr/etc</emphasis></entry>
5385 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.inc</emphasis></entry>
5388 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5389 role="bold">/usr/include</emphasis></entry>
5393 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.lib</emphasis></entry>
5396 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5397 role="bold">/usr/lib</emphasis></entry>
5401 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.loc</emphasis></entry>
5404 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5405 role="bold">/usr/local</emphasis></entry>
5409 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.man</emphasis></entry>
5412 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5413 role="bold">/usr/man</emphasis></entry>
5417 <entry><replaceable>sysname</replaceable>.<emphasis role="bold">usr.sys</emphasis></entry>
5420 role="bold">/afs/</emphasis><replaceable>cellname</replaceable>/<replaceable>sysname</replaceable><emphasis
5421 role="bold">/usr/sys</emphasis></entry>
5428 <primary>foreign cell, enabling access</primary>
5432 <primary>cell</primary>
5434 <secondary>enabling access to foreign</secondary>
5438 <primary>access</primary>
5440 <secondary>to local and foreign cells</secondary>
5444 <primary>AFS filespace</primary>
5446 <secondary>enabling access to foreign cells</secondary>
5450 <primary>root.cell volume</primary>
5452 <secondary>mounting for foreign cells in local filespace</secondary>
5456 <primary>database server machine</primary>
5458 <secondary>entry in client CellServDB file</secondary>
5460 <tertiary>for foreign cell</tertiary>
5464 <primary>CellServDB file (client)</primary>
5466 <secondary>adding entry</secondary>
5468 <tertiary>for foreign cell</tertiary>
5472 <sect1 id="HDRWQ91">
5473 <title>Enabling Access to Foreign Cells</title>
5475 <para>With current OpenAFS releases, there exist a number of mechanisms for
5476 providing access to foreign cells. You may add mount points in your AFS
5477 filespace for each foreign cell you wish users to access, or you can
5478 enable a 'synthetic' AFS root, which contains mountpoints for either all
5479 AFS cells defined in the client machine's local
5480 <emphasis role="bold">/usr/vice/etc/CellServDB</emphasis>, or for all cells
5481 providing location information in the DNS.
5485 <title>Enabling a Synthetic AFS root</title>
5487 <para>When a synthetic root is enabled, the client cache machine creates its
5488 own root.afs volume, rather than using the one provided with your cell. This
5489 allows clients to access all cells in the
5490 <emphasis role="bold">CellServDB</emphasis> file and, optionally, all cells
5491 registered in the DNS, without requiring system administrator action to
5492 enable this access. Using a synthetic root has the additional advantage that
5493 it allows a client to start its AFS service without a network available, as
5494 it is no longer necessary to contact a fileserver to obtain the root volume.
5497 <para>OpenAFS supports two complimentary mechanisms for creating the
5498 synthetic root. Starting the cache manager with the
5499 <emphasis role="bold">-dynroot</emphasis> option adds all cells listed
5500 in <emphasis role="bold">/usr/vice/etc/CellServDB</emphasis> to the client's
5501 AFS root. Adding the <emphasis role="bold">-afsdb</emphasis> option in
5502 addition to this enables DNS lookups for any cells that are not found in
5503 the client's CellServDB file. Both of these options are added to the AFS
5504 initialisation script, or options file, as detailed in
5505 <link linkend="HDRWQ70">Configuring the Cache Manager</link>.</para>
5508 <title>Adding foreign cells to a conventional root volume</title>
5510 <para>In this section you create a mount point in your AFS filespace for the <emphasis role="bold">root.cell</emphasis> volume
5511 of each foreign cell that you want to enable your users to access. For users working on a client machine to access the cell,
5512 there must in addition be an entry for it in the client machine's local <emphasis
5513 role="bold">/usr/vice/etc/CellServDB</emphasis> file. (The instructions in <link linkend="HDRWQ66">Creating the Client
5514 CellServDB File</link> suggest that you use the <emphasis role="bold">CellServDB.sample</emphasis> file included in the AFS
5515 distribution as the basis for your cell's client <emphasis role="bold">CellServDB</emphasis> file. The sample file lists all of
5516 the cells that had agreed to participate in the AFS global namespace at the time your AFS CD-ROM was created. As mentioned in
5517 that section, the AFS Product Support group also maintains a copy of the file, updating it as necessary.)</para>
5519 <para>The chapter in the <emphasis>OpenAFS Administration Guide</emphasis> about cell administration and configuration issues
5520 discusses the implications of participating in the global AFS namespace. The chapter about administering client machines
5521 explains how to maintain knowledge of foreign cells on client machines, and includes suggestions for maintaining a central
5522 version of the file in AFS. <orderedlist>
5524 <para>Issue the <emphasis role="bold">fs mkmount</emphasis> command to mount each foreign cell's <emphasis
5525 role="bold">root.cell</emphasis> volume on a directory called <emphasis
5526 role="bold">/afs/</emphasis><replaceable>foreign_cell</replaceable>. Because the <emphasis role="bold">root.afs</emphasis>
5527 volume is replicated, you must create a temporary mount point for its read/write version in a directory to which you have
5528 write access (such as your cell's <emphasis role="bold">/afs/.</emphasis><replaceable>cellname</replaceable> directory).
5529 Create the mount points, issue the <emphasis role="bold">vos release</emphasis> command to release new replicas to the
5530 read-only sites for the <emphasis role="bold">root.afs</emphasis> volume, and issue the <emphasis role="bold">fs
5531 checkvolumes</emphasis> command to force the local Cache Manager to access the new replica.</para>
5534 <para>You need to issue the <emphasis role="bold">fs mkmount</emphasis> command only once for each foreign cell's
5535 <emphasis role="bold">root.cell</emphasis> volume. You do not need to repeat the command on each client machine.</para>
5538 <para>Substitute your cell's name for <replaceable>cellname</replaceable>.</para>
5541 # <emphasis role="bold">cd /afs/.</emphasis><replaceable>cellname</replaceable>
5542 # <emphasis role="bold">/usr/afs/bin/fs mkmount temp root.afs</emphasis>
5545 <para>Repeat the <emphasis role="bold">fs mkmount</emphasis> command for each foreign cell you wish to mount at this
5549 # <emphasis role="bold">/usr/afs/bin/fs mkmount temp/</emphasis><replaceable>foreign_cell</replaceable> <emphasis role="bold">root.cell -c</emphasis> <replaceable>foreign_cell</replaceable>
5552 <para>Issue the following commands only once.</para>
5555 # <emphasis role="bold">/usr/afs/bin/fs rmmount temp</emphasis>
5556 # <emphasis role="bold">/usr/afs/bin/vos release root.afs</emphasis>
5557 # <emphasis role="bold">/usr/afs/bin/fs checkvolumes</emphasis>
5561 <primary>fs commands</primary>
5563 <secondary>newcell</secondary>
5567 <primary>commands</primary>
5569 <secondary>fs newcell</secondary>
5573 <listitem id="LIWQ92">
5574 <para>If this machine is going to remain an AFS client after you complete the installation, verify
5575 that the local <emphasis role="bold">/usr/vice/etc/CellServDB</emphasis> file includes an entry for each foreign
5578 <para>For each cell that does not already have an entry, complete the following instructions: <orderedlist>
5580 <para>Create an entry in the <emphasis role="bold">CellServDB</emphasis> file. Be sure to comply with the formatting
5581 instructions in <link linkend="HDRWQ66">Creating the Client CellServDB File</link>.</para>
5585 <para>Issue the <emphasis role="bold">fs newcell</emphasis> command to add an entry for the cell directly to the
5586 list that the Cache Manager maintains in kernel memory. Provide each database server machine's fully qualified
5587 hostname. <programlisting>
5588 # <emphasis role="bold">/usr/afs/bin/fs newcell</emphasis> <<replaceable>foreign_cell</replaceable>> <<replaceable>dbserver1></replaceable> \
5589 [<<replaceable>dbserver2></replaceable>] [<<replaceable>dbserver3></replaceable>]
5590 </programlisting></para>
5594 <para>If you plan to maintain a central version of the <emphasis role="bold">CellServDB</emphasis> file (the
5595 conventional location is <emphasis role="bold">/afs/</emphasis><replaceable>cellname</replaceable><emphasis
5596 role="bold">/common/etc/CellServDB</emphasis>), create it now as a copy of the local <emphasis
5597 role="bold">/usr/vice/etc/CellServDB</emphasis> file. Verify that it includes an entry for each foreign cell you
5598 want your users to be able to access. <programlisting>
5599 # <emphasis role="bold">mkdir common</emphasis>
5600 # <emphasis role="bold">mkdir common/etc</emphasis>
5601 # <emphasis role="bold">cp /usr/vice/etc/CellServDB common/etc</emphasis>
5602 # <emphasis role="bold">/usr/afs/bin/vos release root.cell</emphasis>
5603 </programlisting></para>
5605 </orderedlist></para>
5609 <para>Issue the <emphasis role="bold">ls</emphasis> command to verify that the new cell's mount point is visible in your
5610 filespace. The output lists the directories at the top level of the new cell's AFS filespace. <programlisting>
5611 # <emphasis role="bold">ls /afs/</emphasis><replaceable>foreign_cell</replaceable>
5612 </programlisting></para>
5616 <para>If you wish to participate in the global AFS namespace, and only
5617 intend running one database server, please
5618 register your cell with grand.central.org at this time.
5619 To do so, email the <emphasis role="bold">CellServDB</emphasis> fragment
5620 describing your cell, together with a contact name and email address
5621 for any queries, to cellservdb@grand.central.org. If you intend
5622 on deploying multiple database servers, please wait until you have
5623 installed all of them before registering your cell.</para>
5626 <para>If you wish to allow your cell to be located through DNS lookups,
5627 at this time you should also add the necessary configuration to your
5630 <para>AFS database servers may be located by creating AFSDB records
5631 in the DNS for the domain name corresponding to the name of your cell.
5632 It's outside the scope of this guide to give an indepth description of
5633 managing, or configuring, your site's DNS. You should consult the
5634 documentation for your DNS server for further details on AFSDB
5637 </orderedlist></para>
5641 <sect1 id="HDRWQ93">
5642 <title>Improving Cell Security</title>
5645 <primary>cell</primary>
5647 <secondary>improving security</secondary>
5651 <primary>security</primary>
5653 <secondary>improving</secondary>
5657 <primary>root superuser</primary>
5659 <secondary>controlling access</secondary>
5663 <primary>access</primary>
5665 <secondary>to root and admin accounts</secondary>
5669 <primary>admin account</primary>
5671 <secondary>controlling access to</secondary>
5675 <primary>AFS filespace</primary>
5677 <secondary>controlling access by root superuser</secondary>
5680 <para>This section discusses ways to improve the security of AFS data
5681 in your cell. Also see the chapter in the <emphasis>OpenAFS
5682 Administration Guide</emphasis> about configuration and administration
5685 <sect2 id="HDRWQ94">
5686 <title>Controlling root Access</title>
5688 <para>As on any machine, it is important to prevent unauthorized users from logging onto an AFS server or client machine as
5689 the local superuser <emphasis role="bold">root</emphasis>. Take care to keep the <emphasis role="bold">root</emphasis>
5690 password secret.</para>
5692 <para>The local <emphasis role="bold">root</emphasis> superuser does not have special access to AFS data through the Cache
5693 Manager (as members of the <emphasis role="bold">system:administrators</emphasis> group do), but it does have the following
5694 privileges: <itemizedlist>
5696 <para>On client machines, the ability to issue commands from the <emphasis role="bold">fs</emphasis> suite that affect
5697 AFS performance</para>
5701 <para>On server machines, the ability to disable authorization checking, or to install rogue process binaries</para>
5703 </itemizedlist></para>
5706 <sect2 id="HDRWQ95">
5707 <title>Controlling System Administrator Access</title>
5709 <para>Following are suggestions for managing AFS administrative privilege: <itemizedlist>
5711 <para>Create an administrative account for each administrator named
5713 <replaceable>username</replaceable><emphasis role="bold">.admin</emphasis>.
5714 Administrators authenticate under these identities only when
5715 performing administrative tasks, and destroy the administrative
5716 tokens immediately after finishing the task (either by issuing the
5717 <emphasis role="bold">unlog</emphasis> command, or the
5718 <emphasis role="bold">kinit</emphasis> and
5719 <emphasis role="bold">aklog</emphasis> commands to adopt their
5720 regular identity).</para>
5724 <para>Set a short ticket lifetime for administrator accounts (for example, 20 minutes) by using the
5725 facilities of your KDC. For instance, with a MIT Kerberos KDC, this
5726 can be performed using the
5727 <emphasis role="bold">--max-ticket-life</emphasis> argument to
5728 the <emphasis role="bold">kadmin modify_principal</emphasis>
5729 command. Do not however, use a short lifetime for users
5730 who issue long-running <emphasis role="bold">backup</emphasis> commands.</para>
5734 <para>Limit the number of system administrators in your cell, especially those who belong to the <emphasis
5735 role="bold">system:administrators</emphasis> group. By default they have all ACL rights on all directories in the local
5736 AFS filespace, and therefore must be trusted not to examine private files.</para>
5740 <para>Limit the use of system administrator accounts on machines in public areas. It is especially important not to
5741 leave such machines unattended without first destroying the administrative tokens.</para>
5745 <para>Limit the use by administrators of standard UNIX commands that make connections to remote machines (such as the
5746 <emphasis role="bold">telnet</emphasis> utility). Many of these programs send passwords across the network without
5747 encrypting them.</para>
5749 </itemizedlist></para>
5752 <primary>BOS Server</primary>
5754 <secondary>checking mode bits on AFS directories</secondary>
5758 <primary>mode bits on local AFS directories</primary>
5762 <primary>UNIX mode bits on local AFS directories</primary>
5766 <sect2 id="HDRWQ96">
5767 <title>Protecting Sensitive AFS Directories</title>
5769 <para>Some subdirectories of the <emphasis role="bold">/usr/afs</emphasis> directory contain files crucial to cell security.
5770 Unauthorized users must not read or write to these files because of the potential for misuse of the information they
5773 <para>As the BOS Server initializes for the first time on a server machine, it creates several files and directories (as
5774 mentioned in <link linkend="HDRWQ50">Starting the BOS Server</link>). It sets their owner to the local superuser <emphasis
5775 role="bold">root</emphasis> and sets their mode bits to enable writing by the owner only; in some cases, it also restricts
5778 <para>At each subsequent restart, the BOS Server checks that the owner and mode bits on these files are still set
5779 appropriately. If they are not, it write the following message to the <emphasis role="bold">/usr/afs/logs/BosLog</emphasis>
5783 Bosserver reports inappropriate access on server directories
5786 <para>The BOS Server does not reset the mode bits, which enables you to set alternate values if you wish.</para>
5788 <para>The following charts lists the expected mode bit settings. A question mark indicates that the BOS Server does not check
5789 that mode bit.</para>
5791 <informaltable frame="none">
5793 <colspec colwidth="30*" />
5795 <colspec colwidth="70*" />
5799 <entry><emphasis role="bold">/usr/afs</emphasis></entry>
5801 <entry><computeroutput>drwxr</computeroutput>?<computeroutput>xr-x</computeroutput></entry>
5805 <entry><emphasis role="bold">/usr/afs/backup</emphasis></entry>
5807 <entry><computeroutput>drwx</computeroutput>???<computeroutput>---</computeroutput></entry>
5811 <entry><emphasis role="bold">/usr/afs/bin</emphasis></entry>
5813 <entry><computeroutput>drwxr</computeroutput>?<computeroutput>xr-x</computeroutput></entry>
5817 <entry><emphasis role="bold">/usr/afs/db</emphasis></entry>
5819 <entry><computeroutput>drwx</computeroutput>???<computeroutput>---</computeroutput></entry>
5823 <entry><emphasis role="bold">/usr/afs/etc</emphasis></entry>
5825 <entry><computeroutput>drwxr</computeroutput>?<computeroutput>xr-x</computeroutput></entry>
5829 <entry><emphasis role="bold">/usr/afs/etc/KeyFile</emphasis></entry>
5831 <entry><computeroutput>-rw</computeroutput>????<computeroutput>---</computeroutput></entry>
5835 <entry><emphasis role="bold">/usr/afs/etc/UserList</emphasis></entry>
5837 <entry><computeroutput>-rw</computeroutput>?????<computeroutput>--</computeroutput></entry>
5841 <entry><emphasis role="bold">/usr/afs/local</emphasis></entry>
5843 <entry><computeroutput>drwx</computeroutput>???<computeroutput>---</computeroutput></entry>
5847 <entry><emphasis role="bold">/usr/afs/logs</emphasis></entry>
5849 <entry><computeroutput>drwxr</computeroutput>?<computeroutput>xr-x</computeroutput></entry>
5856 <primary>first AFS machine</primary>
5858 <secondary>client functionality</secondary>
5860 <tertiary>removing</tertiary>
5864 <primary>removing</primary>
5866 <secondary>client functionality from first AFS machine</secondary>
5871 <sect1 id="HDRWQ98">
5872 <title>Removing Client Functionality</title>
5874 <para>Follow the instructions in this section only if you do not wish this machine to remain an AFS client. Removing client
5875 functionality means that you cannot use this machine to access AFS files. <orderedlist>
5877 <para>Remove the files from the <emphasis role="bold">/usr/vice/etc</emphasis> directory. The command does not remove the
5878 directory for files used by the dynamic kernel loader program, if it exists on this system type. Those files are still
5879 needed on a server-only machine. <programlisting>
5880 # <emphasis role="bold">cd /usr/vice/etc</emphasis>
5881 # <emphasis role="bold">rm *</emphasis>
5882 # <emphasis role="bold">rm -rf C</emphasis>
5883 </programlisting></para>
5887 <para>Create symbolic links to the <emphasis role="bold">ThisCell</emphasis> and <emphasis
5888 role="bold">CellServDB</emphasis> files in the <emphasis role="bold">/usr/afs/etc</emphasis> directory. This makes it
5889 possible to issue commands from the AFS command suites (such as <emphasis role="bold">bos</emphasis> and <emphasis
5890 role="bold">fs</emphasis>) on this machine. <programlisting>
5891 # <emphasis role="bold">ln -s /usr/afs/etc/ThisCell ThisCell</emphasis>
5892 # <emphasis role="bold">ln -s /usr/afs/etc/CellServDB CellServDB</emphasis>
5893 </programlisting></para>
5897 <para>On IRIX systems, issue the <emphasis role="bold">chkconfig</emphasis> command to deactivate the <emphasis
5898 role="bold">afsclient</emphasis> configuration variable. <programlisting>
5899 # <emphasis role="bold">/etc/chkconfig -f afsclient off</emphasis>
5900 </programlisting></para>
5904 <para>Reboot the machine. Most system types use the <emphasis role="bold">shutdown</emphasis> command, but the appropriate
5905 options vary. <programlisting>
5906 # <emphasis role="bold">cd /</emphasis>
5907 # <emphasis role="bold">shutdown</emphasis> <replaceable>appropriate_options</replaceable>
5908 </programlisting></para>
5910 </orderedlist></para>