osi-syscall-fix-20050302
[openafs.git] / README
1 Copyright 2000, International Business Machines Corporation and others.
2 All Rights Reserved.
3
4 This software has been released under the terms of the IBM Public
5 License.  For details, see the LICENSE file in the top-level source
6 directory or online at http://www.openafs.org/dl/license10.html
7
8 Short instructions for sites upgrading from a previous version of AFS:
9 % ./configure --enable-transarc-paths
10 % make
11 % make dest
12
13 will create a Transarc-style dest tree in ${SYS_NAME}/dest where
14 ${SYS_NAME} is the AFS sysname of the system you built for.
15 This assumes if you're building for Linux that your kernel source is
16 in /usr/src/linux.
17
18 Otherwise, please read on.
19
20 Building OpenAFS on UNIX and LINUX
21 ----------------------------------
22
23 A. Creating the proper directory structure.
24
25    Uncompress the source into a directory of your choice. A directory
26    in afs space is also valid. In the directory that you uncompressed the
27    source in, you will only have an src/ directory.
28
29    1. Pick a system to build for, and note its default AFS sys_name.
30       A directory will be automatically created for binaries to be written 
31       into with this name when you build.
32
33       alpha_dux40
34       alpha_dux50 (only tested on 5.0A, does not work with 5.1)
35       i386_fbsd_42, i386_fbsd_43, i386_fbsd_44, i386_fbsd_45,
36               i386_fbsd_46, i386_fbsd_47, i386_fbsd_50, i386_fbsd_51,
37               i386_fbsd_52, i386_fbsd_53
38       i386_linux22
39       i386_linux24
40       i386_linux26
41       i386_umlinux22
42       i386_umlinux24
43       i386_obsd31, i386_obsd32, i386_obsd33, i386_obsd34, i386_obsd35,
44               i386_obsd36
45       rs_aix42
46       sgi_65 (file server not tested)
47       sun4_413 (No client support, no fileserver support, db servers only)
48       sun4x_56, sun4x_57, sun4x_58, sun4x_59 (logging UFS not supported 
49               for mixed-use partitions containing client cache)
50       ppc_darwin_70
51       ppc_linux22
52       ppc_linux24
53       alpha_linux22 
54       alpha_linux24 
55       ia64_linux24
56       ia64_linux26
57       sparc_linux22
58       sparc_linux24
59       sparc64_linux22
60       sparc64_linux24
61       hp_ux110 (See notes below for information on getting missing header)
62       hp_ux102 (Client port possible, but db servers and utilities work)
63
64    2. Using configure in the top level directory, configure for your
65       AFS system type, providing the necessary flags:
66       % ./configure --with-afs-sysname=sun4x_58 --enable-transarc-paths
67
68       For Linux systems you need also provide the path in which your
69       kernel headers for your configured kernel can be found. This should
70       be the path of the directory containing a child directory named
71       "include". So if your version file was 
72       /usr/src/linux/include/linux/version.h you would invoke:
73       % ./configure --with-afs-sysname=i386_linux24 --with-linux-kernel-headers=/usr/src/linux
74
75       Currently you can build for only one Linux kernel at a time,
76       and the version is extracted from the kernel headers in the root
77       you specify.
78
79       Be prepared to provide the switches --enable-obsolete and
80       --enable-insecure if you require the use of any bundled but obsolete
81       or insecure software included with OpenAFS. See README.obsolete and
82       README.insecure for more details.
83
84   There are two modes for directory path handling: "Transarc mode" and "default mode":
85   - In Transarc mode, we retain compatibility with Transarc/IBM AFS tools
86     by putting client configuaration files in /usr/vice/etc, and server
87     files in /usr/afs under the traditional directory layout.
88   - In default mode, files are located in standardized locations, usually
89     under $(prefix).
90   - Client programs, libraries, and related files always go in standard
91     directories under $(prefix).  This rule covers things that would go
92     into $(bindir), $(includedir), $(libdir), $(mandir), and $(sbindir).
93   - Other files get located in the following places:
94
95     Directory     Transarc Mode              Default Mode
96     ============  =========================  ==============================
97     viceetcdir    /usr/vice/etc              $(sysconfdir)/openafs
98     afssrvdir     /usr/afs/bin (servers)     $(libexecdir)/openafs
99     afsconfdir    /usr/afs/etc               $(sysconfdir)/openafs/server
100     afslocaldir   /usr/afs/local             $(localstatedir)/openafs
101     afsdbdir      /usr/afs/db                $(localstatedir)/openafs/db
102     afslogdir     /usr/afs/logs              $(localstatedir)/openafs/logs
103     afsbosconfig  $(afslocaldir)/BosConfig   $(afsconfdir)/BosConfig
104     afsbosserver  $(afsbindir)/bosserver     $(sbindir)/bosserver
105
106
107 B  Building
108
109    1. Now, you can build OpenAFS. 
110
111       % make
112
113    2. Install your build using either "make install" to install 
114       into the current system (you will need to be root, and files
115       will be placed as appropriate for Transarc or standard paths),
116       "make install DESTDIR=/some/path" to install into an alternate 
117       directory tree, or if you configured with --enable-transarc-paths
118       make dest to create a complete binary tree in the dest directory      
119       under the directory named for the sys_name you built for,
120       e.g. sun4x_57/dest or i386_linux22/dest 
121
122    2. As appropriate you can clean up or, if you're using Linux, build for
123       another kernel version.
124       To clean up:
125          % make clean
126
127 C  Problems
128
129    If you have a problem building this source, you may want to visit
130    http://www.openafs.org/ to see if any problems have been reported 
131    or to find out how to get more help.
132
133    Mailing lists have been set up to help; More details can be found
134    on the openafs.org site.
135
136 D  Linux Notes
137
138    To build for another Linux kernel version:
139    the system type defined in step A1.
140       % ./configure --with-afs-sysname=i386_linux22 --with-linux-kernel-headers=/usr/src/linux-2.2.19-i686
141       % make 
142
143    Your dest tree will now include an additional kernel module for your
144    additional kernel headers. Be aware that if the kernel version string
145    which UTS_RELEASE is defined to in include/linux/version.h matches the
146    last kernel you built for, the previous kernel module will be
147    overwritten.
148
149 E  HP-UX 11.0 Notes
150
151    HP-UX 11.0 requires a header called vfs_vm.h which HP has provided on their
152    web site: http://h21007.www2.hp.com/dspp/tech/tech_TechSoftwareDetailPage_IDX/1,1703,687,00.html
153    To navigate down from the top level of the portal, one would do
154
155         www.hp.com/dspp -> i want to... -> download software -> operating systems
156
157    to get to the same page. 
158
159 F  OpenBSD Notes
160
161    You need kernel source installed to build OpenAFS.  Use the
162    --with-bsd-kernel-headers= configure option if your kernel source is not
163    in /usr/src/sys.
164
165    There is a package builder in src/packaging/OpenBSD.  "sh buildpkg.sh"
166    should make a package for the client.  Use pkg_add to install.  The
167    package will install using transarc-paths, regardless of how you
168    configured.  The package builder does not work on OpenBSD 3.5 and later
169    due to the incompatible re-write of pkg_create.
170
171    There is no server package, but I am told that "make install" will put
172    server binaries in /usr/afs.
173
174    Your kernel may panic when you try to shutdown after running the OpenAFS
175    client.  To prevent this, change the "dangling vnode" panic in
176    sys/kern/vfs_syscalls.c to a printf and build a new kernel.
177
178    You can't run arla and OpenAFS at the same time.
179
180 G  FreeBSD Notes
181
182    The FreeBSD client is very new and untested.  Do not trust it for
183    production work.
184
185    You need kernel source installed to build OpenAFS.  Use the
186    --with-bsd-kernel-headers= configure option if your kernel source is not
187    in /usr/src/sys.
188
189    You also need access to your kernel build directory for the opt_global.h
190    include file.  Use the --with-bsd-kernel-build= configure option if your
191    kernel build is not GENERIC in the standard place.
192
193    There is a package builder in src/packaging/OpenBSD.  "sh buildpkg.sh"
194    should make a package for the client.  Use pkg_add to install.  The
195    package will install using transarc-paths, regardless of how you
196    configured.  The builder uses an old version of the /usr/vice/etc/rc file
197    that probably won't work.  You might be able to replace it with something
198    like "kldload libafs.ko; /usr/vice/etc/afsd".
199
200    There is no server package, but I am told that "make install" will put
201    server binaries in /usr/afs.