SHA256
1
0
forked from pool/openafs

Accepting request 586757 from home:hauky

Hello,

this package should replace the package openafs18.
The reason for this request is that I would like to
get this software into Factory, but it violaites the nameing
convention. Thus, I decided to have one package "openafs"
with the up-to-date version of the software.
The package "openafs16" should still stay in filesystems.
Once this is accepted, I will create a deletion request
for filesystems/openafs18

Many thanks.

OBS-URL: https://build.opensuse.org/request/show/586757
OBS-URL: https://build.opensuse.org/package/show/filesystems/openafs?expand=0&rev=1
This commit is contained in:
David Sterba 2018-03-14 17:57:49 +00:00 committed by Git OBS Bridge
commit a7c8d16e59
35 changed files with 4335 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

769
ChangeLog Normal file
View File

@ -0,0 +1,769 @@
commit 774df869fc1753e94f79c6a0b617b7adb9e4060c
Author: Jeffrey Altman <jaltman@auristor.com>
Date: Sat Feb 10 10:47:24 2018 -0500
rx: Do not count RXGEN_OPCODE towards abort threshold
An RXGEN_OPCODE is returned for opcodes that are not implemented by the
rx service. These opcodes might be deprecated opcodes that are no
longer supported or more recently registered opcodes that have yet to
be implemented. Clients should not be punished for issuing unsupported
calls. The clients might be old and are issuing no longer supported
calls or they might be newer and are issuing yet to be implemented calls
as part of a feature test and fallback strategy.
This change ignores RXGEN_OPCODE errors when deciding how to adjust the
rx_call.abortCount. When an RXGEN_OPCODE abort is sent the
rx_call.abortCount and rx_call.abortError are left unchanged which
preserves the state for the next failing call.
Note that this change intentionlly prevents the incrementing of the
abortCount for client connections as they never send delay aborts.
Reviewed-on: https://gerrit.openafs.org/12906
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit f82d1c7d5aeae148305e867c1f79c6ea2f9e0a2a)
Change-Id: I7a4216bea3a355c31a390c5b4753b4ab0c25661c
Reviewed-on: https://gerrit.openafs.org/12914
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit cabecc719195047ea321bd62e95d52503d15686e
Author: Benjamin Kaduk <kaduk@mit.edu>
Date: Tue Dec 26 17:42:39 2017 -0600
Make OpenAFS 1.8.0pre5
Update version strings for the fifth 1.8.0 prerelease.
Change-Id: I118da0fc55013ccfb2b5cd586cefb1b0c27f10d9
Reviewed-on: https://gerrit.openafs.org/12910
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 5f0714312b211c4a6d6157df6f1f3d9e26dcc03f
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Fri Feb 9 17:59:19 2018 -0500
Update NEWS for 1.8.0pre5
Change-Id: I09e509694c5f7ad59e279b89bd9e144aca2ec4e7
Reviewed-on: https://gerrit.openafs.org/12904
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 50fcd6763d4387950390b732d2a131c230d44c99
Author: Marcio Barbosa <mbarbosa@sinenomine.net>
Date: Wed Jun 21 16:24:05 2017 -0400
ubik: check if epoch is sane before db relabel
The sync-site relabels its database at the end of the first write
transaction. The new label will be equal to the time at which the
sync-site in question first received its coordinator mandate. This time
is stored by a global called ubik_epochTime. In order to make sure that
the new database label is sane, only relabel the database if
ubik_epochTime is within a specific range.
Reviewed-on: https://gerrit.openafs.org/12640
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Andrew Deason <adeason@dson.org>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
(cherry picked from commit f5c289d00aaf7c5525b477da5b89f6675456c211)
Change-Id: I78ebd2b8aeae01ef5e3b826ad6f1de5a5c1db79e
Reviewed-on: https://gerrit.openafs.org/12886
Reviewed-by: Marcio Brito Barbosa <mbarbosa@sinenomine.net>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 2b3df9b2f48dcbf3690e093000879b0f06c7e176
Author: Benjamin Kaduk <kaduk@mit.edu>
Date: Sat Dec 9 11:37:59 2017 -0600
Replace <rpc/types.h> with <rx/xdr.h>
Our in-tree xdr.h appears to have started life as a concatenation of
rpc/types.h and rpc/xdr.h, and should include all the needed functionality.
Indeed, commit 7293ddf325b149cae60d3abe7199d08f196bd2b9 even indicates
that we expect to be using our in-tree XDR everywhere anyway, so the
system XDR is superfluous.
Note that afs/sysincludes.h (not afsincludes.h!) already includes
rx/xdr.h ifndef AFS_LINUX22_ENV.
This change should help systems running glibc 2.26 or newer, which has
stopped providing the Sun RPC headers by default.
While here remove some duplicate includes of rpc/types.h in the
AIX-specific sources.
The Solaris NFS translator bits cannot really be changed, since the system
headers are used and have tight interdependencies.
Update rxgen to not emit rpc/types.h inclusion.
[mmeffie: squash 12801 to not emit rpc/types.h from rxgen]
Reviewed-on: https://gerrit.openafs.org/12800
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit e443a9fb67dbc29e6cc36661a4ac6e91af113f23)
Change-Id: I351e5c1e1223c49ca76e3d68c264ac1625abae60
Reviewed-on: https://gerrit.openafs.org/12894
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 833e2783a39367f3cebfb79f403a75752f81ab09
Author: Ian Wienand <iwienand@redhat.com>
Date: Fri Feb 2 10:52:26 2018 +1100
Add .gitreview
git-review [1] makes it much easier to submit changes. Add a default
configuration file.
[1] https://docs.openstack.org/infra/git-review/usage.html
Reviewed-on: https://gerrit.openafs.org/12884
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit c7c71d2429cf685f3ffad6b2e6d102d900edc197)
Change-Id: I271cfeb6aea888ae40539e248a18131b0affeda8
Reviewed-on: https://gerrit.openafs.org/12901
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 780ed24d360df6772b2408017a5d555ae36217c0
Author: Mark Vitale <mvitale@sinenomine.net>
Date: Tue Jun 30 01:54:21 2015 -0400
SOLARIS: Avoid vcache locks when flushing pages for RO vnodes
We have multiple code paths that hold the following locks at the same
time:
- avc->lock for a vcache
- The page lock for a page in 'avc'
In order to avoid deadlocks, we need a consistent ordering for obtaining
these two locks. The code in afs_putpage() currently obtains avc->lock
before the page lock (Obtain*Lock is called before pvn_vplist_dirty).
The code in afs_getpages() also obtains avc->lock before the page lock,
but it does so in a loop for all requested pages (via pvn_getpages()).
On the second iteration of that loop, it obtains avc->lock, and the page
from the first iteration of the loop is still locked. Thus, it obtains a
page lock before locking avc->lock in some cases.
Since we have two code paths that obtain those two locks in a different
order, a deadlock can occur. Fixing this properly requires changing at
least one of those code paths, so the locks are taken in a consistent
order. However, doing so is complex and will be done in a separate
future commit.
For this commit, we can avoid the deadlock for RO volumes by simply
avoiding taking avc->lock in afs_putpages() at all while the pages are
locked. Normally, we lock avc->lock because pvn_vplist_dirty() will call
afs_putapage() for each dirty page (and afs_putapage() requires
avc->lock held). But for RO volumes, we will have no dirty pages
(because RO volumes cannot be written to from a client), and so
afs_putapage() will never be called.
So to avoid this deadlock issue for RO volumes, avoid taking avc->lock
across the pvn_vplist_dirty() call in afs_putpage(). We now pass a dummy
pageout callback function to pvn_vplist_dirty() instead, which should
never be called, and which panics if it ever is.
We still need to hold avc->lock a few other times during afs_putpage()
for other minor reasons, but none of these hold page locks at the same
time, so the deadlock issue is still avoided.
[mmeffie: comments, and fix missing write lock, fix lock releases]
[adeason: revised commit message]
Reviewed-on: https://gerrit.openafs.org/12247
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Andrew Deason <adeason@dson.org>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 5e09a694ec2c0cd20f5dee500eff6bc3dd04c097)
Change-Id: I5d4e4ddba12c09dc549edeee3cad7de40582ac65
Reviewed-on: https://gerrit.openafs.org/12900
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 5bb7684f07b5f346b68230c2f38edad4c46dc648
Author: Benjamin Kaduk <kaduk@mit.edu>
Date: Thu Jan 4 22:00:15 2018 -0600
rx: remove trailing semicolons from FBSD mutex operations
Since the first introduction of FreeBSD support, the macros
(MUTEX_ENTER, etc.) for kernel mutex operations have included
trailing semicolons, unique among all the platforms.
This did not cause problems until the recent work on rx event
handlers, which put a MUTEX_ENTER() in the body of an 'if' clause
with no brackets, and attempted to follow it with an 'else' clause.
This results in the following (rather obtuse) compiler error:
/root/openafs/src/rx/rx.c:3666:5: error: expected expression
else
^
Which is more visible in the preprocessed source, as
if (condition)
expression;;
else
other_expression;
is clearly invalid C.
To fix the FreeBSD kernel module build, remove the unneeded semicolons.
Reviewed-on: https://gerrit.openafs.org/12853
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 0760feb7992e1e39f716c5f583fe7f6e85584262)
Change-Id: I503a5967a167e9be92721af8dc82d191f3bf18ba
Reviewed-on: https://gerrit.openafs.org/12899
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 2f07951a47a8a820c89e4e6ab1e347858acd8ab5
Author: Benjamin Kaduk <kaduk@mit.edu>
Date: Sat Dec 9 11:44:51 2017 -0600
libuafs: remove stale afs_nfsdisp.lo rule
afs_nfsdisp.lo is not used, so we do not need a build rule for it.
Reviewed-on: https://gerrit.openafs.org/12802
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Michael Meffie <mmeffie@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit decb4308d4e18ad9f6f181e3df5f737698dba7ad)
Change-Id: I53680df1c8648ceb43cc032cada573964622d5b4
Reviewed-on: https://gerrit.openafs.org/12898
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 4988628a2e41955951a49ea0032cabe13f9337d3
Author: Christof Hanke <christof.hanke@rzg.mpg.de>
Date: Mon Dec 18 16:58:39 2017 +0100
Avoid gcc warning
When using the configure option --enable-checking with gcc 7.2.1,
the compilation fails with
vutil.c:860:20: error: %s directive writing up to 255 bytes into \
a region of size 63 [-Werror=format-overflow=]
This can be seen in the logs of the openSUSE Tumbleweed builder
for e.g. build 2368.
Avoid this warning by using snprintf which is provided by libroken
for all platforms.
Reviewed-on: https://gerrit.openafs.org/12813
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
(cherry picked from commit fd4eaebb60dbefc27be98015fee23a3cf5d9752d)
Change-Id: I3be14f6f1228fd09f036da7ff4f1505c65e49406
Reviewed-on: https://gerrit.openafs.org/12897
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 35636bd9e32015bc10e09ccbb34a71a1459cdc4b
Author: Marcio Barbosa <mbarbosa@sinenomine.net>
Date: Mon Aug 21 14:21:54 2017 -0400
ubik: avoid DISK_Begin on sites that didn't vote for sync
As already described on 7c708506, SDISK_Begin fails on remotes if
lastYesState is not set. To fix this problem, 7c708506 does not allow
write transactions until we know that lastYesState is set on at least
quorum (ubik_syncSiteAdvertised == 1). In other words, if enough sites
received a beacon packet informing that a sync-site was elected, write
transactions will be allowed. This means that ubik_syncSiteAdvertised
can be true while lastYesState is not set in a few sites.
Consider the following scenario in a cell with frequent write
transactions:
Site A => Sync-site (up)
Site B => Remote 1 (up)
Site C => Remote 2 (down - unreachable)
Since A and B are up, we have quorum. After the second wave of beacons,
ubik_syncSiteAdvertised will be true and write transactions will be
allowed. At some point, C is not unreachable anymore. Site A sends a
copy of its database to C, but C did not vote for A yet (lastYesState ==
0). A new write transaction is initialized and, since lastYesState is
not set on C, DISK_Begin fails on this remote site and C is marked as
down. Since C is reachable, A will mark this remote site as up. The
sync-site will send its database to C, but C did not vote for A yet. A
new write transaction is initialized and, since lastYesState is not set
on C, DISK_Begin fails on this remote site and C is marked as down. In a
cell with frequent write transactions, this cycle will repeat forever.
As a result, the sync-site will be constantly sending its database to C
and quorum will be operating with less sites, increasing the chances
of re-elections.
To fix this problem, do not call DISK_Begin on remotes that did not
vote for the sync-site yet.
Reviewed-on: https://gerrit.openafs.org/12715
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 68ec78950a6e39dc1bf15012d4b889728086d0b7)
Change-Id: I3764c23125f0bc675762449cd29b282ba403f871
Reviewed-on: https://gerrit.openafs.org/12896
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 51816cfd047c05921218ecb1161c9dd7986a422f
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Wed Jan 31 16:52:40 2018 -0500
add rfc3961.h to kernel sources
Export this header to the kernel sources in the libafs_tree, since it is
needed for the kernel module build.
FIXES 134476
Reviewed-on: https://gerrit.openafs.org/12882
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 073522b3d49467af107d1143cfa015c53347e1e3)
Change-Id: I4e5c7883a1dd4b66b9252f4e630ca489f05e9ad3
Reviewed-on: https://gerrit.openafs.org/12890
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 07811e3b15de8926d63b423804c620bc3501745b
Author: Benjamin Kaduk <kaduk@mit.edu>
Date: Mon Jan 8 22:28:24 2018 -0600
Add param.h files for recent FreeBSD
Add files for FreeBSD 10.4, 11.1, and 12.0 (12-CURRENT), for i386 and amd64.
Reviewed-on: https://gerrit.openafs.org/12863
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 88dc4d93f5ef080da8f56fac453f095e6c79d4a0)
Change-Id: I6ddb0f03e209b0ce9c7ed1168c86a675d7802c23
Reviewed-on: https://gerrit.openafs.org/12888
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 0ba9b5559e112005a6f621ebe55f382bcc2aae0d
Author: Benjamin Kaduk <kaduk@mit.edu>
Date: Mon Jan 8 21:27:04 2018 -0600
FBSD: catch up to missing sysnames
Add sysnames for i386 and amd64 10.4, 11.1, and 12.0 (12-CURRENT, at present).
Reviewed-on: https://gerrit.openafs.org/12862
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit c390f368a5012f866c1b4ce46d6ac6af6cef2fd5)
Change-Id: I5183c19d446fd0c00bd26c32ca3f7f00a4d12907
Reviewed-on: https://gerrit.openafs.org/12887
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 1f10f087264cb39a8354c0baf71eb1fa13071466
Author: Marcio Barbosa <mbarbosa@sinenomine.net>
Date: Mon Aug 21 15:50:14 2017 -0400
ubik: update ubik_dbVersion during SDISK_SendFile
The ubik_dbVersion global represents the sync site's database version
and it is mostly used by the remote sites for sanity checks. Currently,
this global is updated when database changes are made on the sync site
(SDISK_Commit or SDISK_SetVersion), as well as every time we vote "yes"
for the sync-site in a beacon reply. Unfortunately, ubik_dbVersion is
not updated when a copy of the sync site's database is received via
DISK_SendFile, and it won't get updated until our next "yes" vote.
During this window, the current database version will not match
ubik_dbVersion. As a result, any write transaction during this time
frame will fail on the remote site in question.
To fix this problem, do not wait for the next beacon packet to update
ubik_dbVersion when the sync site's database is received; just update
it when we get the new database. Since no write transactions are
allowed while the db is transferring, ubik_dbVersion can be safely
updated.
Reviewed-on: https://gerrit.openafs.org/12716
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Andrew Deason <adeason@dson.org>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 50c1d1088d2adcbb37b6a9d23fdd63617b1267be)
Change-Id: Icbbe9efb9c8dab9ac69237380e824d4a523a53d3
Reviewed-on: https://gerrit.openafs.org/12885
Reviewed-by: Marcio Brito Barbosa <mbarbosa@sinenomine.net>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit e9419dc895801bda6962f2ac0f5981631a0d95c7
Author: Andrew Deason <adeason@sinenomine.net>
Date: Thu Jan 11 21:27:28 2018 -0600
LINUX: Avoid locking inode in check_dentry_race
Currently, check_dentry_race locks the parent inode in order to ensure
it is not running in parallel with d_splice_alias for the same inode.
(For old Linux kernel versions; see commit b0461f2d: "LINUX:
Workaround d_splice_alias/d_lookup race".)
However, it is possible to hit this area of code when the parent inode
is already locked. When someone tries to create a file, directory, or
symlink, Linux tries to lookup the dentry for the target path, to see
if it already exists. While looking up the last component of the path,
Linux locks the directory, and if it finds a dentry for the target
name, it calls d_invalidate on it while the parent directory is
locked.
For a dentry with a NULL inode, we'll then try to lock the parent
inode in check_dentry_race. But since the inode is already locked, we
will deadlock.
From a user's point of view, the hang can be reproduced by doing
something similar to:
$ mkdir dir # succeeds
$ rmdir dir
$ ls -l dir
ls: cannot access dir: No such file or directory
$ mkdir dir # hangs
To avoid this, we can just change which lock we're using to avoid
check_dentry_race/d_splice_alias from running in parallel. Instead of
locking the parent inode, introduce a new global lock (called
dentry_race_sem), and lock that in check_dentry_race and around our
d_splice_alias call. We know that those are the only two users of this
new lock, so this should avoid any such deadlocks.
This does potentially reduce performance, since all tasks that hit
check_dentry_race or d_splice_alias will take the same global lock.
However, this at least still allows us to make use of negative
dentries, and this entire code path only applies to older Linux
kernels. It could be possible to add a new lock into struct vcache
instead, but using a global lock like this commit does is much
simpler.
Reviewed-on: https://gerrit.openafs.org/12868
Tested-by: Benjamin Kaduk <kaduk@mit.edu>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit ef1d4c8d328e9b9affc9864fd084257e9fa08445)
Change-Id: Ia8e28519fff36baca7dc4061ceef6719a2a738d4
Reviewed-on: https://gerrit.openafs.org/12881
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit f523c92a74bace287d1139fab77a030b9598ef61
Author: Caitlyn Marko <cmarko@sinenomine.net>
Date: Thu Feb 9 09:16:17 2017 -0500
SOLARIS: save kernel module function arguments for debugging
Add the -Wu,-save_args compiler option when building kernel modules
under Solaris 10 and 11 for the amd64 architecture.
Binaries generated with this option save function arguments on the stack
during function entry for debugging purposes. Up to six integer
arguments are saved on function entry, and are not modified during the
execution of the function.
[mmeffie: commit message update]
Reviewed-on: https://gerrit.openafs.org/12798
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 32d0493a7e4f74f5e5efdfde5eca29ed7d1bf3ec)
Change-Id: I478ce65da78b86aa3c13e1c615bafd51d0f5d567
Reviewed-on: https://gerrit.openafs.org/12903
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 96ce04c78b5f745424165494c9b76d7ce227eeaa
Author: Marcio Barbosa <mbarbosa@sinenomine.net>
Date: Mon Feb 5 21:16:17 2018 +0000
autoconf: detect ctf-tools and add ctf to libafs
CTF is a reduced form of debug information similar to DWARF and stab. It
describes types and function prototypes. The principal objective of the
format is to shrink the data size as much as possible so that it could
be included in a production environment. MDB, DTrace, and other tools
use CTF debug information to read and display structures correctly.
This commit introduces a new configure option called --with-ctf-tools.
This option can be used to specify an alternative path where the tools
can be found. If the path is not provided, the tools will be searched
in a set of default directories (including $PATH). The CTF debugging
information will only be included if the corresponding --enable-debug /
--enable-debug-kernel is specified.
Note: at the moment, the Solaris kernel module is the only module
benefited by this commit.
Reviewed-on: https://gerrit.openafs.org/12680
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 88cb536f99dc58fdbeb9fa6c47c26774241a0cb6)
Change-Id: I174347370a83b31f68d2631c965e17d72b438cd1
Reviewed-on: https://gerrit.openafs.org/12902
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 0247eb0a8c154811f495142276029a617ae0825a
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Sat Dec 30 17:59:38 2017 -0500
autoconf: refactor linux-checks.m4
Further refactoring of the autoconf macros. Divy up the linux kernel
checks into smaller files.
This is a non-functional change. Care has been taken preserve the
ordering of the autoconf tests. Except for whitespace, the generated
configure file has not been changed by this refactoring. This has been
verified with a 'diff -u -w -B' comparison of the generated configure
file before and after applying this commit.
Reviewed-on: https://gerrit.openafs.org/12844
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 6a2b85cd4c00a08e165cb96d2cb56bf87c6324bc)
Change-Id: Iae325bc14fb160f27791b2f3d82198fe671badd8
Reviewed-on: https://gerrit.openafs.org/12878
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit e05b0b10b942ba3585f6d5d505a282c2de95c243
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Sat Dec 30 12:12:59 2017 -0500
autoconf: refactor ostype.m4
Further refactoring of the autoconf macros. Move more linux and solaris
specific checks into their own files.
This is a non-functional change. Care has been taken preserve the
ordering of the autoconf tests. Except for whitespace, the generated
configure file has not been changed by this refactoring. This has been
verified with a 'diff -u -w -B' comparison of the generated configure
file before and after applying this commit.
Reviewed-on: https://gerrit.openafs.org/12843
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 3c2e39bab7d927aa5f20d02a5e327927a4b2b553)
Change-Id: I4d91753afd90e4735ab61413e757f6852750a3de
Reviewed-on: https://gerrit.openafs.org/12877
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit e54963757320adb95b0c73bbd84fb8bf34319210
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Fri Dec 29 14:24:28 2017 -0500
autoconf: refactor acinclude.m4
The acinclude.m4 is very large and often requires to be changed for
unrelated commits. Divy up the large acinclude.m4 into a number of
smaller files to avoid so many contentions and to make the autoconf
system easier to maintain.
This is a non-functional change. Care has been taken preserve the
ordering of the autoconf tests. Except for whitespace, the generated
configure file has not been changed by this refactoring. This has been
verified with a 'diff -u -w -B' comparison of the generated configure
file before and after applying this commit.
Reviewed-on: https://gerrit.openafs.org/12842
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit c72622a244e561173e86ffe88ee3c9a8c823a76a)
Change-Id: I9504eaa2430fd35f79b55c3df96c82cc7e58fafd
Reviewed-on: https://gerrit.openafs.org/12876
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 0798b54b258f48cae8a5b1b3e107a22693d37937
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Mon Feb 8 12:12:22 2016 -0500
CellServDB update 14 Mar 2017
Update all remaining copies of CellServDB in the tree, and make the
Red Hat packaging use it by default too.
Reviewed-on: https://gerrit.openafs.org/12880
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Mark Vitale <mvitale@sinenomine.net>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 3ca1352170f87994d42578c5bc75e52c4103bc69)
Change-Id: I773d35745e14903dd3069a0627932153900e0ba6
Reviewed-on: https://gerrit.openafs.org/12889
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 5eb64632fd76bb7e26a90ab08c83132e7ac99e23
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Wed Jan 17 17:33:50 2018 -0500
redhat: fix conditional for kernel-debuginfo files directive
Commit 443dd5367e0cd9050ad39a6594c5be521271b4e9 added support for a
separate debuginfo package for the kernel module. Unfortunately, the
%files directive for the kernel module debuginfo package was incorrectly
placed in the %if stanza of the build_userspace condition, so the
rpmbuild fails when attempting to build just the kernel module.
That is, when running rpmbuild with the options:
rpmbuild --define "build_userspace 0" --define "build_modules 1" ...
rpmbuild fails with:
RPM build errors:
Installed (but unpackaged) file(s) found:
/usr/lib/debug/lib/modules/.../extra/openafs/openafs.ko.debug
Fix this by moving the new %files directive out of the build_userspace
conditional.
Reviewed-on: https://gerrit.openafs.org/12874
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
Tested-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit f599e1ce6354c42a9c0c8f7205ba8a03c35ea72b)
Change-Id: I07e25d3dd43b2cd7056cefb8f0f5c10f78347b85
Reviewed-on: https://gerrit.openafs.org/12875
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 781624f7f4290a1f44a0f48a04d780e10dd5b3e1
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Fri Jul 21 22:30:43 2017 -0400
redhat: avoid rpmbuild exclude directives
Older versions of rpmbuild do not support the files exclude directive,
so fall back to the old way in which we remove the files to be excluded
and list the files to be included.
Reviewed-on: https://gerrit.openafs.org/12733
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit a71288a387095ccb4be83c1abae34ada80f53185)
Change-Id: I01c20bc21ec6143be76458c311d826023c370d51
Reviewed-on: https://gerrit.openafs.org/12873
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit 9d62e1d5c6e9e888a029a0b6080c27c0b4353ba2
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Fri Jul 21 22:16:44 2017 -0400
redhat: move .krb variants to the kauth-client subpackage
Move the deprecated klog.krb, pagsh.krb, and tokens.krb programs and man
pages to the optional openafs-kauth-client subpackage.
Reviewed-on: https://gerrit.openafs.org/12732
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 4d247e1ae446c512031511273d556ef1fd32dca1)
Change-Id: I3c6164022b07f0c3283cb54ffd26e1f9c3dd67bb
Reviewed-on: https://gerrit.openafs.org/12872
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit ea1bf1bd751d391d49bdb33e2e3f2cc79fe8ccde
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Thu Jul 20 04:13:04 2017 -0400
redhat: specify man pages without wildcards
Currently, some of the man pages are specified with the full name and
some are specified with a wildcard for the filename extension. Instead,
specify all the man pages without a wildcards to be more consistent and
to avoid putting incorrect man pages in packages.
This change removes a stray copy the klog.krb5.1 man page from
openafs-kauth-client subpackage and moves the AuthLog/AuthLog.dir man
pages to the optional openafs-kauth-server subpackage.
Reviewed-on: https://gerrit.openafs.org/12731
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit 671db4ca5a76625d9b7133510cc1cbdda8a5d9b9)
Change-Id: I9d10cc7aad94a2dc004526acb426a9b9badc8e3c
Reviewed-on: https://gerrit.openafs.org/12871
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
commit f56ea0e095f4837a65762f5a8fbc6b5c9d58a394
Author: Michael Meffie <mmeffie@sinenomine.net>
Date: Fri Jul 21 18:05:48 2017 -0400
redhat: remove afsd.fuse man page
The afsd.fuse binary is not currently packaged; do not package the man
page.
Reviewed-on: https://gerrit.openafs.org/12730
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>
(cherry picked from commit a9810b829bdccfed4d1718b11cf4dd51f9565e00)
Change-Id: I7c829a492e999cc989e9341e94f56d6669722a4c
Reviewed-on: https://gerrit.openafs.org/12870
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Benjamin Kaduk <kaduk@mit.edu>

109
README.SUSE.openafs Normal file
View File

@ -0,0 +1,109 @@
Here is described installation of openafs server and client on SUSE linux.
This text is based on AFS Quick Start Guide. The differences are:
- paths are adapted to SUSE installation
- uses Kerberos 5 authentization
Complete OpenAFS documentation is at http://openafs.org
SERVER SETUP
============
# choose an AFS cell name and a Kerberos realm name, the simplest setup is:
# - AFS cell name equal to DNS domain name
# - Kerberos realm name equal to uppercase AFS cell name
# create a partition for AFS filesystem and mount it under /vicepa
# start bosserver
/usr/sbin/bosserver -noauth &
# setup basic cell information
bos setcellname your.afs.server your.cell.name -noauth
# setup database servers processes
bos create your.afs.server ptserver simple /usr/lib/openafs/ptserver -cell your.cell.name -noauth
bos create your.afs.server buserver simple /usr/lib/openafs/buserver -cell your.cell.name -noauth
bos create your.afs.server vlserver simple /usr/lib/openafs/vlserver -cell your.cell.name -noauth
# If you want to use the old afs authentization (not recommended):
# bos addkey your.afs.server -kvno 0 -cell your.cell.name -noauth
# Authentication against heimdal krb5 server
# Here you can set up kerberos realm if you dont have any,
# see documentation in package krb5-doc
# restart kdc
rckrb5kdc restart
rckrb524d restart
# create afs principal in kerberos database
kadmin.local
add_principal afs@YOUR.KERBEROS.REALM # create afs key, use random password
ktremove -k /etc/krb5.keytab afs all # delete old afs key if any
# export the afs key to external keytab
# note the key version number (kvno), you will need it later for asetkey
ktadd -e des-cbc-crc:v4 afs@YOUR.KERBEROS.REALM
add_principal admin@YOUR.KERBEROS.REALM # create admin principal
quit # end kadmin.local
rm /etc/openafs/server/KeyFile # delete the old afs key file if any
# convert the afs key from /etc/krb5.keytab to /etc/openafs/server/KeyFile
# use <kvno> displayed by ktadd
asetkey add <kvno> /etc/krb5.keytab afs
# give admin the permissions to control bosserver
bos adduser your.afs.server admin -cell your.cell.name -noauth
# add admin to group system:administrators
pts createuser -name admin -id <user id> -cell your.cell.name -noauth
pts adduser admin system:administrators -cell your.cell.name -noauth
# restart bos server
bos restart your.afs.server -all -cell your.cell.name -noauth
# create fileserver processes
bos create your.afs.server fs fs /usr/lib/openafs/fileserver /usr/lib/openafs/volserver /usr/lib/openafs/salvager -cell your.cell.name -noauth
# create root volume
vos create your.afs.server /vicepa root.afs -cell your.cell.name -noauth
# restart bosserver with security enabled
rcopenafs-fileserver restart
CLIENT SETUP
============
IMPORTANT: Unfortunately, openafs client for linux kernel 2.6 has not reached
stable state yet. There may be problems.
edit /etc/sysconfig/openafs-client, set at least
REGENERATE_CELL_INFO="yes"
THIS_CELL="your.cell.name"
THIS_CELL_SERVER="your.afs.server"
If you are configuring first afs server and the volume root.cell does not
exist yet, you have to set also DYNROOT=no. After finishing the server
installaton it is better to change DYNROOT back to 'yes' as the client
behaves better on startup with network outage.
# start afs client
rcopenafs-client start
# login as admin
kinit admin
aklog -d # convert Kerberos 5 ticket to AFS token
To enable transparent login via pam, install package pam_krb5
and add 'call_modules=krb5afs' to /etc/security/pam_unix2.conf
For details look at pam_krb5afs(5), pam_krb5afs(8) and pam_unix2(8) manpages.
Now you have working afs server and client. You can continue with chapter
"Configuring the Top Levels of the AFS Filespace" of AFS Quick Start Guide.

466
RELNOTES-1.8.0~pre5 Normal file
View File

@ -0,0 +1,466 @@
User-Visible OpenAFS Changes
OpenAFS 1.8.0pre5
All Platforms
* Substantial code quality improvements, largely spotted by Coverity and
clang's static analysis.
- Add new library for platform independent functions (opr).
- Remove arbitrary path name length limits.
- Convert to Heimdal's roken library for reliability.
- Avoid garbage in allocated buffers (calloc).
- Modernize signal handling in pthreaded server processes (softsig).
- Improve code comments and additional Doxygen style comments.
- Reduce compiler warnings, dead code, unused variables, and
undefined behavior.
- Fix bugs found by static code analyzer (clang-analyzer).
- Improved unit test coverage.
- Make VLDB flag definitions consistent.
- Improve use of run-time assertions and add static assertions.
- Add compiler attributes to assist static analyzers.
- Clean up include headers in the entire tree.
- Improve command-line handling library (libcmd).
- Replace hash functions with Jenkin's hash function for faster
and more evenly distributed lookups.
- Provide a red-black tree data structure to enable algorithmic speedups.
- Convert backup and salvage servers to the common logging API (libutil).
- Improve volume id data type consistency (VolumeId).
- Import APIs for kerberos-style profile configuration support.
- Add new APIs to support UserList identities.
- Add new APIs to support tabular output from command-line utilities.
- Convert vnode macros to inline-functions.
* Improved support for non-DES encryption types:
- Convert to Heimdal's hcrypto library to support RFC 3961.
- Add extended key file format replacing rxkad.keytab, and
new key management APIs.
- Add support for extended key types to asetkey.
- Add akeyconvert to assist in upgrading to OpenAFS 1.8.x by converting an
existing rxkad.keytab file to an extended key file.
- Do not install the kaserver and related utilities by default to
discourage the use of these DES-dependent components.
- Remove obsolete klogin and klogin.krb programs.
- Add new token APIs to support new rx security classes.
* Migrate from LWP to POSIX threads (pthreads):
- Convert the ptserver and vlserver from LWP to pthreads.
- Remove LWP version of the file server binary.
- Convert afsd, aklog, asetkey, klog.krb5, pts, udebug, and vos, from LWP
to pthreads.
* Improvements to Rx:
- Restructure the Rx API to privatize the implementation.
- Convert rx events to a red-black tree data structure to improve
performance.
- Convert from mutexes to atomic operations for counters to reduce lock
contention.
- Provide per-opcode Rx statistics.
- Add an rx_opaque data type to support non-DES encryption types
and general code cleanup.
- Wake up the application thread after 'twind' is updated to avoid 100ms
transmit delays when the receive window transitions from closed to
open.
- Fix for OPENAFS-SA-2017-001: sanity-check peer transport parmeters
received in ack trailers
* Libraries (both internal and installed) are built using libtool, including
libuafs. The resulting shared libraries for libafsrpc and libafsauthent
should be more usable than previously.
* Improvements to the build system:
- Convert to libtool to build shared libraries.
- Clean up and improve the build system.
- Support out of tree builds.
- Add a makefile target to generate Doxygen source code documentation.
- Link the Java API for OpenAFS with libuafs.a and remove the
libjuafs.a library.
- Always build the rxperf tool.
- Fix man-page generation by make after ./regen.sh -q
- Support the SOURCE_DATE_EPOCH environment variable to improve build
reproducibility.
- Modernize language specific SWIG typemaps for libuafs Perl bindings.
- Refactor acinclude.m4 into a set of smaller m4 files (12876, 12877, 12878)
* Improvements to documentation:
- Document the new KeyFileExt file.
- Reorganized the README files.
- Improvements and fixes to documentation generation.
- Add experimental epub and mobi support
- Remove obsolete LWP information from the file server documentation.
- Update and reorganize the Quick Start Guide.
- Update the Admin Guide.
- Remove AIX, HP-UX, and IRIX information from the Quick Start Guide.
- Document the vldb and prdb (ubik) file formats.
- Add PtLog man page.
- Corrections and clarifications to man pages.
- Add ubik threading analysis doc.
- Normalize the location of text documents in the source tree.
* Improvements for troublshooting, debugging, and testing:
- Log more details on volume-server-to-fileserver communication errors
when possible.
- Set thread names in pthreaded servers on platforms which support
thread names.
- Add dynroot lock tracking to cmdebug
- Fix tracking of an fstrace call site in the cache manager background
process.
- Add the afsload tool to simulate multiple cache managers for file server
load testing.
- Add run-time checks for refcount imbalances in the cache manager.
- Fix missing newlines in afsd -debug output.
* Developer tool improvements:
- Improvements and fixes for rxgen (used to generate Rx RPC bindings).
- Add tool for man page verification of command options.
- Add tool to find Unix cache manager lock identification numbers.
- Add an option for pretty build output.
* RPM packaging updates:
- Update the spec file to keep up with accumulated changes.
- Move the klog.krb5 man page to the openafs-krb5 sub-package.
- Remove stray man pages. (12870, 12871)
- Prevent double-starting client on RHEL7
- Convert rpm spec file from deprecated 'make dest' to 'make install'.
- Fix rpmbuild command line option default handling.
- Support older versions of rpmbuild which do not support the
rpmbuild %exclude directive. (12873)
- Move the legacy kaserver and related programs to separate sub-packages,
which are only built when rpmbuild is given the '--with kauth' option
(12600, 12872)
* Add a new protection error code (PRNAMETOOLONG) instead of silently
truncating names which exceed the maximum name length (PR_MAXNAMELEN).
* Add an implementation limit (50000) on the number of names/ids which can
be transmitted by unauthenticated clients to the ptserver, avoiding
excessive resource consumption from unauthenticated requests.
* Add the -config option to vos, pts, and aklog to specify the path to the
cell configuration files.
* Add more details in vos release -verbose output.
* Add the cacheout -encrypt option to encrypt communication between the
cacheout client and the fileserver.
* Add the command line options to the afsio program to enable encryption of
traffic between afsio and the fileserver (-clear, -crypt).
* Add the vos release -force-reclone option to force recloning the volume to
be released without forcing a full volume dump being transmitted to all
remote sites.
* Fix vos to avoid writing loopback addresses into the VLDB in
certain cases.
* Print bos and pts error messages to standard error instead of
standard out.
* Improve formatting of the -help output of all commands.
* Change -n to -dryrun in all backup subcommands.
* Change the backup deletedump -port command line option to -portoffset.
* Add user and build host in the version string returned by
rxdebug -version.
* Support recent versions of gcc (7.2.1) (12897)
All Server Platforms
* Ubik servers using pthreads are now available and are used by default
* As part of improving Ubik reliability in certain edge cases, an extra
election cycle (about 60 seconds) may be needed before writes are
permitted. This is a conservative change that may be removed in
the future.
* Avoid continually retransmitting the ubik database to remote sites when
a write transaction occurs as remote sites are attempting to rejoin the
ubik cluster. (12896)
* Ensure the ubik database version number is updated on remote sites at the
point the database is transferred to remote sites instead of waiting for
the next ubik beacon. This avoids write transaction failures during the
window between the database transfer and the next ubik beacon (12885).
* Remove periodic background fsync by the fileserver (ihandle fsync thread).
* Fix potential file handle leak in the file server ihandle caching layer.
* Disable the so-called "hot threads" feature in the file server. The hot
threads feature was intended as an optimization for dispatching incoming
calls to the current listener thread, but has been reported to incur a
performance penalty on modern multi-core systems.
* Do not permit creation of users with id of ANONYMOUSID.
* Do not save/restore host states in the fsstate.dat file for hosts which
are in the process of retrieving CPS information from the ptserver when
the fileserver is being shutdown. This fixes a bug in which the fileserver
will incorrectly block all threads following a restart.
* Add the ptserver -restrict_anonymous option to inhibit exposure of user
names from the ptserver.
* Do not truncate server log files by default when server processes
are started. The -transarc-logs option provides backward compatibility
with IBM AFS log handling on server startup. Log messages may be lost
in back-to- back restarts when a server is running in this mode.
* Reopen server logs on SIGUSR1. This may be used by third-party log
rotation tools, such as logrotate, to reopen the log file handles after
log files have been renamed.
* Fix various bugs when logging with -mrafslogs enabled.
* Dynamically reload the kerberos realm to AFS cell mapping (krb.conf) and
exclusions for mapping kerberos principals to AFS identities (krb.excl)
configuration when the CellServDB cell configuration file is touched.
Previously, a restart of the file server was required after updating the
kerberos mapping configuration files.
* Add a command line option (-restricted_query) to the vlserver and
volserver to restrict information queries about volumes to a specific
group of users.
* Add a command line option to the server programs to specify an alternate
fully qualified log file name (-logfile).
* Add a command line option (-config) to the server programs to specify
an alternate path to the server configuration.
* Add a command line option to the ptserver and vlserver to specify an
alternate path to the database data files.
* Add a command line option to the volume server to enable encryption of
volume-server-to-volume-server-traffic (-s2scrypt).
* Increase the maximum number of LWP threads allowed for the ptserver and
vlserver from 16 to 64 (-lwp).
* Remove an unused file server command line option (-k).
* Fix an incorrect assertion in Demand Attach File Server which could cause
the file server process to abort in certain rare conditions.
* Deprecate the -bitmap-later configure option for non-Demand-Attach File
Servers (DAFS).
* Add -vhashsize support to non-Demand-Attach File Servers (DAFS).
* Add support for subnet ranges in the NetInfo and NetRestrict
configuration files.
* Add the GetXStats RPC to the audit log.
* Fix directory creation by bosserver when built for non-Transarc paths.
* Fix incomplete list of server addresses retreived by vos listaddr when the
vldb contains unreferenced multi-homed server entries.
* Remove obsolete bos blockscanner and unblockscanner commands that
were only needed for the removed MR-AFS functionality.
* Remove obsolete bos salvage options that were only used by the
removed MR-AFS functionality..
* Remove calls to the deprecated sbrk() function.
* Add an experimental feature to database servers to support ubik reads
while write transactions are in progress, enabled at build time with the
--enable-ubik-read-while-write configure option. This feature is not
considered ready for production usage at this time.
* Avoid filling the FileLog with "Volume x offline: not in service" when
a volume is administratively taken offline with vos offline.
* Print an error message when bosserver is started with an unknown
command line option.
* Modify the volume updateDate when the volume is changed by a salvage.
* Volume usage statistics are now preserved during reclone and restore
operations by default, the behavior previously enabled by
the -preserve-vol-stats flag to the volserver. The historical behavior
can be retained via the -clear-vol-stats argument.
All Client Platforms
* Use rxkad_crypt by default for connections to fileservers. This matches
the existing behavior of the Windows client and has been applied by
the distribution packaging on many platforms already.
* Add support for relative ACL changes with fs setacl. If a single plus (+)
or minus (-) character is appended to the rights' letters argument, the
new rights are computed relatively to the existing ones.
* Remove afsd -settime and afsd -nosettime support.
* Add the afsd -inumcalc option to specify the method used to calculate
inode numbers presented by AFS.
* Add the afsd -volume-ttl option to specify set the maximum amount of time
information retrieved from the vlserver will be cached, regardless of
callback expiry times.
* Return EIO on internal errors instead of the misleading ENOENT.
* Log ICMP errors received, if any, for unreachable servers.
* Improve performance of clients with multiple PAGs for different cells.
* Fix race condition between changing and using user tokens among cache
manager threads.
* Fix fs sysname for users with UID 2748 and 2750 when not running
in -rmtsys mode.
* Add Perl bindings for the user-space cache manager library (libuafs).
* Fixes to the bypasscache feature.
* Fix fs getcacheparms miscounts.
* Remove the obsolete Netscape plugin.
* Fix building gtx when ncurses is linked against libtinfo.
* Update to the GCO CellServDB update from 14 March 2017.
Linux
* Remove Linux 2.2 and 2.4 support.
* Changes to avoid EIO errors with multiple processes doing intensive mmap
writing. (Drop PageReclaim AOP_WRITEPAGE_ACTIVATE.)
* Prevent fakestat data inconsistencies in certain cases (131855).
* Fix dentry leak which can cause a crash on shutdown.
* Fix improper use of ENOENT and avoid incorrect use of linux negative
dentry cache.
* Use a more correct (less aggressive) scheme to react to downward
pressure on cache usage, avoiding d_invalidate(), which can cause
getcwd() failures on RHEL 7.4.
* Improve error reporting when encountering corrupt directories.
* Improve rx error handling in the Linux cache manager.
* Rename kpasswd to kapasswd when packaging RPMs to avoid colliding with
Kerberos kpasswd.
* Do not use the obsolete --enable-largefile-fileservers configure option
when packaging RPMs.
* In Red Hat packaging, use a separate rpm for kmod debuginfo,
removing a needless tight version dependency on the userspace package.
(12822, 12875)
* Use the RemainAfterExit systemd feature to avoid premature exit
when -afsdb is not given, for RPM packages.
* Remove Debian packaging files from the OpenAFS source tree. Debian
packaging files are currently maintained in the downstream Debian
infrastructure.
* Add the sparc_linux26 sysname.
* Desupport 32-bit Linux kernels on s390/s390x.
* Fix Debian/Ubuntu build regression on kernel 3.16.39.
* Fix --enable-kernel-debug for linux 4.8+.
* Fix a hang encountered when accessing a previously removed
directory entry (12811).
* Support linux 4.10, 4.11, 4.12, 4.13, 4.14, 4.15
Solaris
* Remove support for all Solaris and SunOS platforms prior to Solaris 8.
* Build 64-bit binaries for Solaris x86 by default.
* Use one-group PAGs on Solaris 11, which is required for PAG support
on Solaris 11 since supplemental groups must be sorted starting with
Solaris 11.1.
* Update search paths for solaris cc for recent versions Solaris Studio.
* Modernize declaration of module dependences by converting from the
deprecated _depends_on symbol to ELF dependencies.
* Avoid BAD TRAP panic due to invalid opcodes on x86 with Studio 12.5.
* Add ctf debug records to Solaris kernel modules when debug builds
are enabled and the ctf tools are present (ctfconvert/ctfmerge).
* Save kernel module function arguments on x86 for debugging purposes.
MacOS
* Stop processing upcalls once rx shutdown starts.
* Enable atomics for the darwin kernel.
* Add a syscall to enable/disable bulkstat at run-time, which is
disabled by default.
* Fix path to binaries in the prefpane.
* Fix builds on MacOS 10.12 by building only the active architecture
by default.
* Support versions up through 10.13 (High Sierra) and APFS
FreeBSD
* Use the native kernel module build system instead of an ad hoc
replacement build system.
* Remove FreeBSD packaging files from the OpenAFS source tree. FreeBSD
packaging files are currently maintained in the downstream FreeBSD Ports
Collection.
* Stay up to date with new FreeBSD releases (through 10.3).
* Do not claim AFS_VM_RDWR_ENV
* Add sysnames and files for i386 and amd64 10.4, 11.1, and 12.0
(12-CURRENT, at present). (12887, 12888)
* Remove trailing semicolons to fix the build on FreeBSD (12899)
NetBSD
* Stay up to date with new NetBSD releases (through 7.x)
* Update to use cprng(9) as the randomness source on NetBSD 6.99/7.x.
* Build system updates for NetBDS 6.99.x
* Do not claim AFS_VM_RDWR_ENV
OpenBSD
* Stay up to date with new OpenBSD releases (through 4.7)
* Do not claim AFS_VM_RDWR_ENV
AIX
* Updates for AIX support.
* Fix build system for AIX exports.
* Add the uidpag and localuid runtime options to the aklog LAM plugin.
(These runtime options override the use of UID-based PAGs, which were
introduced to appease the CDE screensaver.)

View File

@ -0,0 +1,55 @@
#!/bin/sh
if [ $# != 1 ]; then
echo building a openafs-kernel module for the running kernel
echo Need one of: build build_debug install
exit 1
fi
LOGFILE=libafs_tree/build.log
kernel_flavour=`uname -r | awk -F- '{print $NF}'`
kernel_version=`uname -r | sed "s/-$kernel_flavour//"`
arch=`uname -m`
suse_flavour=`cat /etc/SuSE-release | head -1 | awk '{print $1}' `
suse_version=`cat /etc/SuSE-release | grep VERSION | awk '{print $NF}' `
echo This SuSE is version \"$suse_version\" of flavour \"$suse_flavour\"
echo you are running the kernel \"$kernel_version\" of flavour \"$kernel_flavour\" on \"$arch\"
echo all output is saved into $LOGFILE
if [ $1 == "build_debug" ]; then
DEBUG_OPT="--enable-debug-kernel"
fi
if [ $1 == "build" -o $1 == "build_debug" ]; then
cd libafs_tree
echo calling configure...
./configure --with-linux-kernel-headers=/usr/src/linux/ --with-linux-kernel-build=/usr/src/linux-obj/$arch/$kernel_flavour $DEBUG_OPT > build.log 2>&1
if [ $? != 0 ]; then
echo configure failed! See $LOGFILE for details
exit $?
fi
echo calling make
make >> build.log 2>&1
if [ $? != 0 ]; then
echo make failed! See $LOGFILE for details
exit $?
fi
echo
echo build sucessfull!
echo Now run $0 install to install the kernel-modules
exit 0
fi
if [ $1 == "install" ]; then
module_files="afspag.ko libafs.ko"
build_dir=libafs_tree/src/libafs/MODLOAD-$kernel_version-$kernel_flavour-MP/
install_dir=/lib/modules/$kernel_version-$kernel_flavour
echo installing kernel-modules into
for mod in $module_files; do
cp -v $build_dir/$mod $install_dir/$mod
done
/sbin/depmod -a
fi

1
ld.conf.openafs Normal file
View File

@ -0,0 +1 @@
/usr/lib64/openafs

11
logrotate.openafs-server Normal file
View File

@ -0,0 +1,11 @@
/var/log/openafs/*Log {
daily
compress
dateext
rotate 7
olddir /var/log/openafs/old
missingok
notifempty
create 640 root root
copytruncate
}

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8755289dc2772c2d75c81960128fd4ad9ae297f6efd5b1cc4360e7fddcc70154
size 3802039

View File

@ -0,0 +1 @@
b745f553867efce8788ecb41602f929a /home/kaduk/openafs/candidate/1.8.0pre5/openafs-1.8.0pre5-doc.tar.bz2

View File

@ -0,0 +1 @@
8755289dc2772c2d75c81960128fd4ad9ae297f6efd5b1cc4360e7fddcc70154 openafs-1.8.0pre5-doc.tar.bz2

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:371e44656152bb03018bd08d16ca4e07644f9414915d78a85e0e391b7f3e27b3
size 15106627

View File

@ -0,0 +1 @@
bb23eaadefe7811277065f26dadf2c4b /home/kaduk/openafs/candidate/1.8.0pre5/openafs-1.8.0pre5-src.tar.bz2

View File

@ -0,0 +1 @@
371e44656152bb03018bd08d16ca4e07644f9414915d78a85e0e391b7f3e27b3 openafs-1.8.0pre5-src.tar.bz2

View File

@ -0,0 +1,11 @@
--- a/src/rxkad/asn1_err.h.orig 2011-05-14 09:49:51.000000000 +0000
+++ a/src/rxkad/asn1_err.h 2011-05-14 09:53:49.000000000 +0000
@@ -6,7 +6,7 @@
struct et_list;
-void initialize_asn1_error_table_r(struct et_list **);
+extern void initialize_asn1_error_table_r(void);
void initialize_asn1_error_table(void);
#define init_asn1_err_tbl initialize_asn1_error_table

View File

@ -0,0 +1,13 @@
--- a/src/cf/curses.m4.orig 2018-01-07 08:17:41.815732371 +0100
+++ b/src/cf/curses.m4 2018-01-07 08:23:50.585670554 +0100
@@ -19,7 +19,9 @@
AC_CHECK_LIB([ncurses], [initscr],
[AC_CHECK_LIB([ncurses], [LINES], [openafs_cv_curses_lib=-lncurses],
[AC_CHECK_LIB([tinfo], [LINES],
- [openafs_cv_curses_lib="-lncurses -ltinfo"])])])
+ [openafs_cv_curses_lib="-lncurses -ltinfo"],
+ [AC_CHECK_LIB([ncurses], [_nc_LINES], [openafs_cv_curses_lib=-lncurses],
+ [AC_CHECK_LIB([tinfo], [_nc_LINES], [openafs_cv_curses_lib="-lncurses -ltinfo"])])])])])
AS_IF([test "x$openafs_cv_curses_lib" = x],
[AC_CHECK_LIB([Hcurses], [initscr], [openafs_cv_curses_lib=-lHcurses])])
AS_IF([test "x$openafs_cv_curses_lib" = x],

20
openafs-client.service Normal file
View File

@ -0,0 +1,20 @@
[Unit]
Description=OpenAFS Client
Wants=network-online.target
After=syslog.target network-online.target
Before=remote-fs.target
[Service]
Type=forking
RemainAfterExit=true
EnvironmentFile=/etc/sysconfig/openafs-client
ExecStartPre=/sbin/modprobe libafs
ExecStart=/usr/sbin/afsd $AFSD_ARGS
ExecStartPost=/usr/bin/fs sysname $SYSNAME
ExecStop=/bin/umount /afs
ExecStop=/usr/sbin/afsd -shutdown
ExecStop=/sbin/rmmod libafs
KillMode=none
[Install]
WantedBy=multi-user.target remote-fs.target

View File

@ -0,0 +1,20 @@
[Unit]
Description=OpenAFS Client Service
Wants=network-online.target
After=syslog.target network-online.target
Before=remote-fs.target
[Service]
Type=forking
RemainAfterExit=true
EnvironmentFile=/etc/sysconfig/openafs-client
ExecStartPre=/bin/chmod 0644 /etc/openafs/CellServDB
ExecStartPre=/sbin/modprobe libafs
ExecStart=/usr/sbin/afsd $AFSD_ARGS
ExecStop=/bin/umount /afs
ExecStop=/etc/openafs/afsd -shutdown
ExecStop=/sbin/rmmod libafs
KillMode=none
[Install]
WantedBy=multi-user.target remote-fs.target

11
openafs-server.service Normal file
View File

@ -0,0 +1,11 @@
[Unit]
Description=OpenAFS Server
After=syslog.target network.target
[Service]
EnvironmentFile=-/etc/sysconfig/openafs-server
ExecStart=/usr/sbin/bosserver -nofork $BOSSERVER_ARGS
ExecStop=/usr/sbin/bos shutdown localhost -wait -localauth
[Install]
WantedBy=multi-user.target

1
openafs.CellAlias Normal file
View File

@ -0,0 +1 @@
openafs.org openafs

0
openafs.SuidCells Normal file
View File

1
openafs.ThisCell Normal file
View File

@ -0,0 +1 @@
openafs.org

1
openafs.cacheinfo Normal file
View File

@ -0,0 +1 @@
/afs:/var/cache/openafs:102400

430
openafs.changes Normal file
View File

@ -0,0 +1,430 @@
-------------------------------------------------------------------
Tue Mar 6 10:03:44 UTC 2018 - christof.hanke@mpcdf.mpg.de
- cleanup package for Factory:
- rename package to openafs.
- remove sys-v init stuff.
- apply recommendations given in Request 581009
-------------------------------------------------------------------
Wed Feb 28 09:25:52 UTC 2018 - christof.hanke@mpcdf.mpg.de
- add compat macro for new _fillupdir macro introduced in Nov 2017
-------------------------------------------------------------------
Wed Feb 28 08:30:33 UTC 2018 - christof.hanke@mpcdf.mpg.de
- update to 1.8.0pre5
-------------------------------------------------------------------
Sun Jan 7 08:31:00 UTC 2018 - christof.hanke@mpcdf.mpg.de
- update to 1.8.0pre4
- add patch for ncurses detection
-------------------------------------------------------------------
Thu Dec 7 11:07:30 UTC 2017 - christof.hanke@mpcdf.mpg.de
- update to 1.8.0pre3
- add integrity check of tar-balls
-------------------------------------------------------------------
Fri Sep 1 20:07:48 UTC 2017 - christof.hanke@mpcdf.mpg.de
- do not strip binaries on install
- fix %postun server
-------------------------------------------------------------------
Fri Sep 1 11:51:03 UTC 2017 - christof.hanke@mpcdf.mpg.de
- update to 1.8.0pre2
- use a preamble-file for KMP
- sort/cleanup/beautify spec-file
-------------------------------------------------------------------
Fri Sep 1 07:05:21 UTC 2017 - christof.hanke@mpcdf.mpg.de
- spec-file:
+ use hardlinks for fdupes to provide correct header files in
kernel-source
+ minor bugfixes, reorganization
- rename changes file to openafs18.changes
-------------------------------------------------------------------
Thu Feb 9 14:41:57 UTC 2017 - christof.hanke@mpcdf.mpg.de
- rename package to openafs18-* so they don't override
stable openafs-1.6 ones
- move ld.so to main package -- was in server-packages
-------------------------------------------------------------------
Tue Feb 7 11:23:22 UTC 2017 - christof.hanke@mpcdf.mpg.de
- enable building of KMP
- make openafs-krb5-mit package dependend on openafs-client package
- add ld.so - config to main package
-------------------------------------------------------------------
Fri Jan 27 21:15:12 UTC 2017 - christof.hanke@rzg.mpg.de
- remove pam, is not build on x86_64 and i596
-------------------------------------------------------------------
Mon Dec 26 18:59:09 UTC 2016 - christof.hanke@rzg.mpg.de
- first version of 1.8
- remove docs package, put man pages in induvidual packets
- remove layout-patch, deal with this in spec file directly
-------------------------------------------------------------------
Sat Dec 3 14:56:56 UTC 2016 - christof.hanke@rzg.mpg.de
- add new ChangeLog
-------------------------------------------------------------------
Thu Dec 1 04:35:39 UTC 2016 - christof.hanke@rzg.mpg.de
- update to version 1.6.20
-------------------------------------------------------------------
Wed Nov 16 09:21:52 UTC 2016 - christof.hanke@rzg.mpg.de
- add missing RemainAfterExit=true to client-systemd unit.
-------------------------------------------------------------------
Tue Nov 15 09:28:55 UTC 2016 - christof.hanke@rzg.mpg.de
- update to version 1.6.19
-------------------------------------------------------------------
Tue Oct 4 11:19:50 UTC 2016 - aj@suse.com
- Update README: Change SuSE to SUSE.
-------------------------------------------------------------------
Thu Jul 21 07:52:14 UTC 2016 - christof.hanke@rzg.mpg.de
- update to version 1.6.18.2
-------------------------------------------------------------------
Fri Jun 24 04:42:48 UTC 2016 - christof.hanke@rzg.mpg.de
- update to version 1.6.18.1
-------------------------------------------------------------------
Tue May 10 15:19:28 UTC 2016 - christof.hanke@rzg.mpg.de
- update to version 1.6.18
Thu Mar 17 06:35:21 UTC 2016 - christof.hanke@rzg.mpg.de
- update to version 1.6.17
- cleanup
-------------------------------------------------------------------
Fri Dec 18 06:53:08 UTC 2015 - christof.hanke@rzg.mpg.de
- update to version 1.6.16
- remove fix for configure for new ncurses, now dealt with in
shipped package
-------------------------------------------------------------------
Sat Nov 21 04:47:46 UTC 2015 - christof.hanke@rzg.mpg.de
- start using change.log again
- fix configure test for new ncurses
-------------------------------------------------------------------
Thu Jun 17 17:04:25 UTC 2010 - cseader@novell.com
- update to version 1.4.12.1
-------------------------------------------------------------------
Wed Jan 25 21:39:00 CET 2006 - mls@suse.de
- converted neededforbuild to BuildRequires
-------------------------------------------------------------------
Mon Jan 23 15:58:43 CET 2006 - nadvornik@suse.cz
- fixed kernel module to compile
-------------------------------------------------------------------
Wed Jan 11 05:30:18 CET 2006 - mge@suse.de
- add openafs.SuidCells and openafs.CellServDB
- cleanup SPEC-file(s)
- finally adopt
sysconfig.transarcmode.openafs-client
rc.transarcmode.afs-server
rc.transarcmode.afs-client
to transarc mode; and fix a small typo in
rc.defaultmode.afs-client
-------------------------------------------------------------------
Fri Jan 6 01:12:31 CET 2006 - mge@suse.de
- set "%defattr(-,root,root)" for transarcmode-file-lists
- fix lib64 build problem in transarcmode
-------------------------------------------------------------------
Thu Jan 5 13:40:42 CET 2006 - mge@suse.de
- introduce transarc-mode and default-mode
- introduce "options"
-------------------------------------------------------------------
Thu Dec 29 16:07:00 CET 2005 - mge@suse.de
- build for SLES 9
- with heimdal krb5 support
- enable-largefile-fileserver
-------------------------------------------------------------------
Wed Dec 21 16:09:26 CET 2005 - nadvornik@suse.cz
- updated to 1.4.0
- fixed dangerous compiler warnings
-------------------------------------------------------------------
Mon Oct 31 12:37:05 CET 2005 - dmueller@suse.de
- don't build as root
-------------------------------------------------------------------
Fri Aug 26 12:51:02 CEST 2005 - nadvornik@suse.cz
- fixed kernel module to build
- fixed sysconfig file name
-------------------------------------------------------------------
Thu Jul 14 17:25:25 CEST 2005 - nadvornik@suse.cz
- updated to 1.3.85
- used LSB conforming init script names
-------------------------------------------------------------------
Tue Jul 5 10:44:32 CEST 2005 - hare@suse.de
- Update for linux 2.6.13.
-------------------------------------------------------------------
Thu May 12 12:27:01 CEST 2005 - nadvornik@suse.cz
- gcc4 fixes in kernel module
-------------------------------------------------------------------
Tue Apr 12 17:02:34 CEST 2005 - nadvornik@suse.cz
- fixed to compile with gcc4
-------------------------------------------------------------------
Wed Feb 23 12:08:07 CET 2005 - nadvornik@suse.cz
- fixed memory leaks and 64bit fixes backported from 1.3.79
- updated README.SUSE
-------------------------------------------------------------------
Thu Feb 3 13:19:05 CET 2005 - nadvornik@suse.cz
- updated to 1.3.78
-------------------------------------------------------------------
Mon Jan 31 15:58:33 CET 2005 - nadvornik@suse.cz
- fixed afs.h to be usable from userspace [#50283]
-------------------------------------------------------------------
Tue Jan 25 10:57:09 CET 2005 - nadvornik@suse.cz
- updated to latest snapshot
-------------------------------------------------------------------
Wed Sep 15 12:37:04 CEST 2004 - nadvornik@suse.cz
- added requres: kernel-nongpl [#45167]
- fixed kernel module oops [#44618]
-------------------------------------------------------------------
Wed Aug 11 15:51:03 CEST 2004 - nadvornik@suse.cz
- use kernel module from openafs 1.3.70 to support kernel 2.6
-------------------------------------------------------------------
Mon Mar 08 17:18:49 CET 2004 - nadvornik@suse.cz
- updated to 1.2.11
- added note that client for kernel 2.6 is not available
-------------------------------------------------------------------
Tue Jan 20 18:48:21 CET 2004 - ro@suse.de
- added pam-devel to neededforbuild
-------------------------------------------------------------------
Sat Dec 13 00:23:45 CET 2003 - meissner@suse.de
- Added hack if no MTU came from userspace.
- Removed superflous ppc64 patch part.
-------------------------------------------------------------------
Thu Dec 11 09:29:31 CET 2003 - meissner@suse.de
- ppc64 port added (status: no longer crashes, talks to the network,
but not successfully).
- Change headerfiles to make it possible to do a ppc -> ppc64 crosscompile.
-------------------------------------------------------------------
Mon Oct 6 17:30:17 CEST 2003 - olh@suse.de
- build with -fPIC on ppc32
-------------------------------------------------------------------
Tue Sep 16 17:37:34 CEST 2003 - nadvornik@suse.cz
- patch from cvs to use AllocLargeSpace for struct osi_file to prevent
oopses with some kernel configurations
-------------------------------------------------------------------
Thu Sep 11 12:58:57 CEST 2003 - nadvornik@suse.cz
- added option DYNROOT to sysconfig and enabled it by default [#27205]
-------------------------------------------------------------------
Wed Sep 10 17:07:51 CEST 2003 - nadvornik@suse.cz
- added cleanup before module build [#29649]
-------------------------------------------------------------------
Tue Sep 09 18:33:38 CEST 2003 - nadvornik@suse.cz
- fixed possible segfault
-------------------------------------------------------------------
Thu Sep 04 12:30:00 CEST 2003 - nadvornik@suse.cz
- set permissions of /var/lib/openafs to 700
- README.SuSE fixes
-------------------------------------------------------------------
Thu Aug 28 17:11:47 CEST 2003 - nadvornik@suse.cz
- use ghost for /afs, the directory is created by init-script
- fixed README.SuSE
-------------------------------------------------------------------
Thu Aug 21 14:32:58 CEST 2003 - nadvornik@suse.cz
- moved all static libraries to /usr/lib/afs, fixes conflict with libdes
- used default value for THIS_CELL_SERVER_NAME
- removed old patches
-------------------------------------------------------------------
Tue Aug 12 11:10:46 CEST 2003 - nadvornik@suse.cz
- fixed a bug in init script
-------------------------------------------------------------------
Mon Aug 11 18:26:28 CEST 2003 - nadvornik@suse.cz
- updated to final 1.2.10
-------------------------------------------------------------------
Wed Jul 30 19:34:34 CEST 2003 - nadvornik@suse.cz
- updated to 1.2.10-rc4
- do not destroy CellServDB even if REGENERATE_CELL_INFO=yes
- fixed to compile on x86_64
-------------------------------------------------------------------
Wed Jul 30 14:25:46 CEST 2003 - sf@suse.de
- use %_lib where it was missing
-------------------------------------------------------------------
Wed Jul 09 19:20:55 CEST 2003 - nadvornik@suse.cz
- fixed conflicts in filelist
-------------------------------------------------------------------
Fri Jun 20 14:59:23 CEST 2003 - nadvornik@suse.cz
- improved init scripts
-------------------------------------------------------------------
Thu Jun 19 14:40:52 CEST 2003 - nadvornik@suse.cz
- added README.SuSE
- fixed init scripts [#27426]
- installed man pages
-------------------------------------------------------------------
Thu Jun 12 17:45:39 CEST 2003 - poeml@suse.de
- add /usr/src/kernel-modules to the file list
-------------------------------------------------------------------
Wed Jun 4 21:26:09 CEST 2003 - schwab@suse.de
- Fix SMP configuration detection.
-------------------------------------------------------------------
Wed May 14 12:28:04 CEST 2003 - poeml@suse.de
- rework filelists:
- package/remove unpackaged files
- move some files into the server & client subpackages
- use %defattr
- fix deprecated tail -1 syntax (fixes building the kernel module)
-------------------------------------------------------------------
Mon May 12 14:50:05 CEST 2003 - nadvornik@suse.cz
- updated to 1.2.9
- added DATA_ENCRYPTION option to sysconfig
-------------------------------------------------------------------
Mon Mar 10 18:43:26 CET 2003 - poeml@suse.de
- x86_64: add -lresolv, -fPIC
- fix lib path on all 64 bit platforms
-------------------------------------------------------------------
Thu Mar 06 10:39:27 CET 2003 - nadvornik@suse.cz
- added sysconfig metadata
-------------------------------------------------------------------
Mon Feb 24 17:28:44 CET 2003 - nadvornik@suse.cz
- added dirs /afs, /etc/openafs, /var/lib/openafs to filelist
-------------------------------------------------------------------
Sun Feb 16 18:28:44 CET 2003 - olh@suse.de
- workaround broken -lresolv detection, lib64 fixes
-------------------------------------------------------------------
Wed Feb 12 16:42:07 CET 2003 - nadvornik@suse.cz
- fixed multiline strings in kernel module
-------------------------------------------------------------------
Fri Jan 24 11:11:23 CET 2003 - nadvornik@suse.cz
- updated to 1.2.8
- improved init script
-------------------------------------------------------------------
Fri Nov 29 10:21:04 CET 2002 - nadvornik@suse.cz
- included errno.h
- fixed multiline strings
-------------------------------------------------------------------
Fri Nov 22 16:47:51 CET 2002 - nadvornik@suse.cz
- first version of init scripts
-------------------------------------------------------------------
Wed Nov 20 19:20:53 CET 2002 - poeml@suse.de
- initial draft of a package. Lots of stuff missing, like init
scripts, or the kerberos 5 migration toolkit.

1023
openafs.spec Normal file

File diff suppressed because it is too large Load Diff

3
preamble Normal file
View File

@ -0,0 +1,3 @@
Requires: kernel-%1
Requires: %{name}-client = %{version}
Conflicts: %{name}-fuse-client = %{version}

372
rc.afs-client Normal file
View File

@ -0,0 +1,372 @@
#! /bin/sh
# Copyright (c) 1995-2000 SuSE GmbH Nuernberg, Germany.
#
# Author: Peter Poeml <poeml@suse.de>, 2001
# Additions by Christof Hanke <biber@induhviduals.de>, 2009
#
# /etc/init.d/afs-server
# and its symbolic link
# /usr/sbin/rcafs-server
#
# System startup script for OpenAFS
#
### BEGIN INIT INFO
# Provides: afs-client
# Required-Start: $local_fs
# Should-Start: $syslog $network $time
# Should-Stop: $null
# Required-Stop: $null
# Default-Start: 3 5
# Default-Stop: 0 2 1 6
# X-UnitedLinux-Default-Enabled: yes
# Short-Description: Start OpenAFS Client
# Description: Starts the OpenAFS Client by loading the required kernel-module and starting afsd.
### END INIT INFO
DAEMON="OpenAFS Client"
DAEMON_PIDFILE=
STARTPROC_LOGFILE=
SUPPORTS_HUP="no"
DAEMON_BIN=/usr/sbin/afsd
AFS_KERNEL_MODULE=libafs
#test -x $DAEMON_BIN || exit 5
# Shell functions sourced from /etc/rc.status:
# rc_check check and set local and overall rc status
# rc_status check and set local and overall rc status
# rc_status -v ditto but be verbose in local rc status
# rc_status -v -r ditto and clear the local rc status
# rc_failed set local and overall rc status to failed
# rc_failed <num> set local and overall rc status to <num><num>
# rc_reset clear local rc status (overall remains)
# rc_exit exit appropriate to overall rc status
. /etc/rc.status
. /etc/sysconfig/openafs-client
CACHEINFO=${CACHEINFO:-/etc/openafs/cacheinfo}
CACHE=${CACHEDIR:-/var/cache/openafs}
AFS=${AFSDIR:-/afs}
REGENERATE_CELL_INFO=${REGENERATE_CELL_INFO:-no}
REGENERATE_CACHE_INFO=${REGENERATE_CACHE_INFO:-yes}
MEMCACHE=${MEMCACHE:-yes}
VERBOSE=${VERBOSE:-no}
DYNROOT=${DYNROOT:-yes}
FAKESTAT=${FAKESTAT:-yes}
AFSDB=${AFSDB:-yes}
DATA_ENCRYPTION=${DATA_ENCRYPTION:-yes}
THIS_CELL_SERVER_NAME=${THIS_CELL_SERVER_NAME:-unknown}
SERVER_TIMEOUT=120
check_configfiles() {
if [ ! -f /etc/openafs/ThisCell ]; then
echo "Invalid configuration. Cellconfiguration in /etc/openafs/ThisCell is missing."
rc_failed 1
return
fi
if [ "$AFSDB" = "no" ] ; then
if [ ! -f /etc/openafs/CellServDB ]; then
echo "No CellServDB found and AFSDB=no."
echo "Either set AFSDB=yes in /etc/sysconfig/openafs [recommended] or"
echo "populate the /etc/openafs/CellServDB file"
rc_failed 1
return
fi
if [ "`grep -c \>$THIS_CELL /etc/openafs/CellServDB`" != "1" ] ; then
echo "Cannot find unique definition of your cell $THIS_CELL in /etc/openafs/CellServDB."
echo "Consider setting AFSDB=yes in /etc/sysconfig/openafs or"
echo "fix /etc/openafs/CellServDB."
rc_failed 1
fi
fi
}
generate_cellinfo() {
if [ "$REGENERATE_CELL_INFO" = "yes" -a "x$THIS_CELL" != "x" ]; then
rm -f /etc/openafs/ThisCell #it could be symlinks to server configuration
echo "$THIS_CELL" > /etc/openafs/ThisCell
if [ -f /etc/openafs/CellServDB -a ! -L /etc/openafs/CellServDB ]; then
if grep -q "^>$THIS_CELL\([[:space:]#].*\)\?$" /etc/openafs/CellServDB ; then
# CellServDB contains THIS_CELL, replace servers
awk "
/^>$THIS_CELL([[:space:]#].*)?$/ {
this_cell=1;
print \$0;
print \"$THIS_CELL_SERVER #$THIS_CELL_SERVER_NAME\";
next
}
/^>/ {
this_cell=0;
print \$0;
next
}
/^[^>[:space:]]+/ {
if (!this_cell) print \$0;
}
" /etc/openafs/CellServDB > /etc/openafs/CellServDB.new
else
# add THIS_CELL to CellServDB
echo ">$THIS_CELL #Cell name, generated from /etc/sysconfig/afs-client" >/etc/openafs/CellServDB.new
echo "$THIS_CELL_SERVER #$THIS_CELL_SERVER_NAME" >>/etc/openafs/CellServDB.new
cat /etc/openafs/CellServDB >> /etc/openafs/CellServDB.new
fi
mv -f /etc/openafs/CellServDB.new /etc/openafs/CellServDB
else
# new CellServDB
rm -f /etc/openafs/CellServDB #it could be symlinks to server configuration
echo ">$THIS_CELL #Cell name, generated from /etc/sysconfig/afs-client" >/etc/openafs/CellServDB
echo "$THIS_CELL_SERVER #$THIS_CELL_SERVER_NAME" >>/etc/openafs/CellServDB
fi
fi
}
generate_cacheinfo() {
if [ "$REGENERATE_CACHE_INFO" = "yes" -a "x$CACHESIZE" != "x" ]; then
if [ "$CACHESIZE" = "AUTOMATIC" ]; then
if [ "$MEMCACHE" = "yes" ]; then
useCACHESIZE=`awk '/^MemTotal:/{ print int($2 / 8);}' /proc/meminfo`
else
LINE=`df -k $CACHE | tail -1`
PART=`echo $LINE | awk '{ if ( ($NF != "/usr") && ($NF != "/") && ($NF != "/var") ) print $NF; else print "NONE";}'`
if [ "$PART" = "NONE" ]; then
echo "$CACHE is not a separate partition"
echo "you have to change the cachesize in $SYSCNF by hand"
return 1
else
PARTSIZE=`echo $LINE | awk '{print $2}'`
useCACHESIZE=`echo $PARTSIZE | awk '{printf "%d",int(($1*.8)/1024)*1024}'`
fi
fi
else
useCACHESIZE=$CACHESIZE
fi
echo $AFS:$CACHE:$useCACHESIZE >$CACHEINFO
chmod 0644 $CACHEINFO
mkdir -p $CACHE # to be sure
else
useCACHESIZE=`awk -F: '{print $3}' < $CACHEINFO`
fi
return 0
}
choose_afsdoptions() {
if [ "x$OPTIONS" = "x" -o "x$OPTIONS" = "xAUTOMATIC" ]; then
if [ $useCACHESIZE -lt 131072 ]; then
OPTIONS=$SMALL
elif [ $useCACHESIZE -lt 524288 ]; then
OPTIONS=$MEDIUM
elif [ $useCACHESIZE -lt 1048576 ]; then
OPTIONS=$LARGE
elif [ $useCACHESIZE -lt 2097152 ]; then
OPTIONS=$XLARGE
else
OPTIONS=$XXLARGE
fi
fi
AFSD_OPTIONS="$OPTIONS"
if [ "$MEMCACHE" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -memcache"
if [ "x$OPTIONS" != "x" -a "x$CACHESIZE" != "xAUTOMATIC" ];then
AFSD_OPTIONS="$AFSD_OPTIONS -blocks $useCACHESIZE"
fi
fi
if [ "$VERBOSE" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -verbose"
fi
if [ "$DYNROOT" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -dynroot"
fi
if [ "$FAKESTAT" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -fakestat"
fi
if [ "$AFSDB" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -afsdb"
fi
}
killafs() {
SIGNAL=$1
PIDS=`lsof -Fp $AFS | sed -e 's/p//'`
if [ "x" != "x$PIDS" ]; then
kill -$SIGNAL $PIDS >/dev/null 2>&1
sleep 3
fi
}
wait_for_server() {
TIMEOUT=$SERVER_TIMEOUT
if [ -f /usr/sbin/bosserver ] && checkproc /usr/sbin/bosserver ; then
# we run on the same machine as the server
while /usr/sbin/bos status localhost -localauth |grep -q "salvaging file system"; do
echo
echo -n "Waiting for local AFS server to come up ..."
sleep 1
TIMEOUT=$(( $TIMEOUT - 1 ))
[ $TIMEOUT -eq 0 ] && return 1
done
fi
return 0
}
# First reset status of this service
rc_reset
# Return values acc. to LSB for all commands but status:
# 0 - success
# 1 - generic or unspecified error
# 2 - invalid or excess argument(s)
# 3 - unimplemented feature (e.g. "reload")
# 4 - insufficient privilege
# 5 - program is not installed
# 6 - program is not configured
# 7 - program is not running
#
# Note that starting an already running service, stopping
# or restarting a not-running service as well as the restart
# with force-reload (in case signalling is not supported) are
# considered a success.
case "$1" in
start)
echo "Starting $DAEMON "
mkdir -p $AFS
if generate_cacheinfo; then
generate_cellinfo
check_configfiles
choose_afsdoptions
if /sbin/modprobe --allow-unsupported-modules $AFS_KERNEL_MODULE ; then
if wait_for_server; then
ps ax | grep -q '\[afsd\]' || $DAEMON_BIN $AFSD_OPTIONS || rc_failed 1
if [ "$DATA_ENCRYPTION" = "yes" ]; then
/usr/bin/fs setcrypt on
fi
if [ "x$SYSNAME" != "x" ]; then
/usr/bin/fs sysname $SYSNAME
fi
else
#local server not running
rc_failed 1
fi
else
#modprobe failed
rc_failed 5
fi
else
rc_failed 6
fi
# Remember status and be verbose
rc_status -v
;;
stop)
[ "x`whoami`" = xroot ] || exit 4 # do not allow regular user to kill all his processes
echo -n "Shutting down $DAEMON "
if ps ax | grep -q '\[afsd\]'; then
echo
echo "Sending all processes using $AFS the TERM signal ..."
killafs TERM
echo "Sending all processes using $AFS the KILL signal ..."
killafs KILL
umount $AFS
fi
if grep -q ^$AFS_KERNEL_MODULE /proc/modules ; then
/sbin/rmmod $AFS_KERNEL_MODULE || rc_failed 1
fi
# rmtsys doesn't go away, so kill them all to be sure
killall $DAEMON_BIN > /dev/null 2>&1
# Remember status and be verbose
rc_status -v
;;
try-restart)
## Stop the service and if this succeeds (i.e. the
## service was running before), start it again.
$0 stop && $0 start
# Remember status and be quiet
rc_status
;;
restart)
## Stop the service and regardless of whether it was
## running or not, start it again.
$0 stop
$0 start
# Remember status and be quiet
rc_status
;;
force-reload)
## Signal the daemon to reload its config. Most daemons
## do this on signal 1 (SIGHUP).
## If it does not support it, restart.
echo -n "Reload service $DAEMON"
if [ "$SUPPORTS_HUP" = "yes" ] ; then
killproc -p $DAEMON_PIDFILE -HUP $DAEMON_BIN
#touch $DAEMON_PIDFILE
rc_status -v
else
$0 stop && $0 start
rc_status
fi
;;
reload)
## Like force-reload, but if daemon does not support
## signalling, do nothing (!)
if [ "$SUPPORTS_HUP" = "yes" ] ; then
# If it supports signalling:
echo -n "Reload service $DAEMON"
killproc -p $DAEMON_PIDFILE -HUP $DAEMON_BIN
#touch $DAEMON_PIDFILE
rc_status -v
else
## Otherwise if it does not support reload:
rc_failed 3
rc_status -v
fi
;;
status)
echo -n "Checking for $DAEMON: "
## Check status with checkproc(8), if process is running
## checkproc will return with exit status 0.
# Status has a slightly different for the status command:
# 0 - service running
# 1 - service dead, but /var/run/ pid file exists
# 2 - service dead, but /var/lock/ lock file exists
# 3 - service not running
# NOTE: checkproc returns LSB compliant status values.
ps ax | grep -q '\[afsd\]' || rc_failed 3
rc_status -v
;;
probe)
## Optional: Probe for the necessity of a reload,
## give out the argument which is required for a reload.
if [ "$DAEMON_CONF" -nt "$DAEMON_PIDFILE" ]; then
if [ "$SUPPORTS_HUP" = "yes" ]; then
echo reload
else
echo restart
fi
fi
;;
*)
echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}"
exit 1
;;
esac
rc_exit

364
rc.afs-fuse-client Normal file
View File

@ -0,0 +1,364 @@
#! /bin/sh
# Copyright (c) 1995-2000 SuSE GmbH Nuernberg, Germany.
#
# Author: Peter Poeml <poeml@suse.de>, 2001
# Additions by Christof Hanke <biber@induhviduals.de>, 2009
#
# /etc/init.d/afs-server
# and its symbolic link
# /usr/sbin/rcafs-server
#
# System startup script for OpenAFS
#
### BEGIN INIT INFO
# Provides: afs-client
# Required-Start: $local_fs $named $network $remote_fs
# Should-Start: $syslog $time kdc afs-server
# Should-Stop: $null
# Required-Stop: $null
# Default-Start: 3 5
# Default-Stop: 0 2 1 6
# Short-Description: Start OpenAFS Client
# Description: Starts the OpenAFS Client by loading the required kernel-module and starting afsd.
### END INIT INFO
DAEMON="OpenAFS Client"
DAEMON_PIDFILE=
STARTPROC_LOGFILE=
SUPPORTS_HUP="no"
DAEMON_BIN=/usr/sbin/afsd.fuse
test -x $DAEMON_BIN || exit 5
# Shell functions sourced from /etc/rc.status:
# rc_check check and set local and overall rc status
# rc_status check and set local and overall rc status
# rc_status -v ditto but be verbose in local rc status
# rc_status -v -r ditto and clear the local rc status
# rc_failed set local and overall rc status to failed
# rc_failed <num> set local and overall rc status to <num><num>
# rc_reset clear local rc status (overall remains)
# rc_exit exit appropriate to overall rc status
. /etc/rc.status
. /etc/sysconfig/openafs-fuse-client
CACHEINFO=${CACHEINFO:-/etc/openafs/cacheinfo}
CACHE=${CACHEDIR:-/var/cache/openafs}
AFS=${AFSDIR:-/afs}
REGENERATE_CELL_INFO=${REGENERATE_CELL_INFO:-no}
REGENERATE_CACHE_INFO=${REGENERATE_CACHE_INFO:-yes}
MEMCACHE=${MEMCACHE:-yes}
VERBOSE=${VERBOSE:-no}
DYNROOT=${DYNROOT:-yes}
FAKESTAT=${FAKESTAT:-yes}
AFSDB=${AFSDB:-yes}
DATA_ENCRYPTION=${DATA_ENCRYPTION:-yes}
THIS_CELL_SERVER_NAME=${THIS_CELL_SERVER_NAME:-unknown}
SERVER_TIMEOUT=120
check_configfiles() {
if [ ! -f /etc/openafs/ThisCell ]; then
echo "Invalid configuration. Cellconfiguration in /etc/openafs/ThisCell is missing."
rc_failed 1
return
fi
if [ "$AFSDB" = "no" ] ; then
if [ ! -f /etc/openafs/CellServDB ]; then
echo "No CellServDB found and AFSDB=no."
echo "Either set AFSDB=yes in /etc/sysconfig/openafs [recommended] or"
echo "populate the /etc/openafs/CellServDB file"
rc_failed 1
return
fi
if [ "`grep -c \>$THIS_CELL /etc/openafs/CellServDB`" != "1" ] ; then
echo "Cannot find unique definition of your cell $THIS_CELL in /etc/openafs/CellServDB."
echo "Consider setting AFSDB=yes in /etc/sysconfig/openafs or"
echo "fix /etc/openafs/CellServDB."
rc_failed 1
fi
fi
}
generate_cellinfo() {
if [ "$REGENERATE_CELL_INFO" = "yes" -a "x$THIS_CELL" != "x" ]; then
rm -f /etc/openafs/ThisCell #it could be symlinks to server configuration
echo "$THIS_CELL" > /etc/openafs/ThisCell
if [ -f /etc/openafs/CellServDB -a ! -L /etc/openafs/CellServDB ]; then
if grep -q "^>$THIS_CELL\([[:space:]#].*\)\?$" /etc/openafs/CellServDB ; then
# CellServDB contains THIS_CELL, replace servers
awk "
/^>$THIS_CELL([[:space:]#].*)?$/ {
this_cell=1;
print \$0;
print \"$THIS_CELL_SERVER #$THIS_CELL_SERVER_NAME\";
next
}
/^>/ {
this_cell=0;
print \$0;
next
}
/^[^>[:space:]]+/ {
if (!this_cell) print \$0;
}
" /etc/openafs/CellServDB > /etc/openafs/CellServDB.new
else
# add THIS_CELL to CellServDB
echo ">$THIS_CELL #Cell name, generated from /etc/sysconfig/afs-client" >/etc/openafs/CellServDB.new
echo "$THIS_CELL_SERVER #$THIS_CELL_SERVER_NAME" >>/etc/openafs/CellServDB.new
cat /etc/openafs/CellServDB >> /etc/openafs/CellServDB.new
fi
mv -f /etc/openafs/CellServDB.new /etc/openafs/CellServDB
else
# new CellServDB
rm -f /etc/openafs/CellServDB #it could be symlinks to server configuration
echo ">$THIS_CELL #Cell name, generated from /etc/sysconfig/afs-client" >/etc/openafs/CellServDB
echo "$THIS_CELL_SERVER #$THIS_CELL_SERVER_NAME" >>/etc/openafs/CellServDB
fi
fi
}
generate_cacheinfo() {
if [ "$REGENERATE_CACHE_INFO" = "yes" -a "x$CACHESIZE" != "x" ]; then
if [ "$CACHESIZE" = "AUTOMATIC" ]; then
if [ "$MEMCACHE" = "yes" ]; then
useCACHESIZE=`awk '/^MemTotal:/{ print int($2 / 8);}' /proc/meminfo`
else
LINE=`df -k $CACHE | tail -1`
PART=`echo $LINE | awk '{ if ( ($NF != "/usr") && ($NF != "/") && ($NF != "/var") ) print $NF; else print "NONE";}'`
if [ "$PART" = "NONE" ]; then
echo "$CACHE is not a separate partition"
echo "you have to change the cachesize in $SYSCNF by hand"
return 1
else
PARTSIZE=`echo $LINE | awk '{print $2}'`
useCACHESIZE=`echo $PARTSIZE | awk '{printf "%d",int(($1*.8)/1024)*1024}'`
fi
fi
else
useCACHESIZE=$CACHESIZE
fi
echo $AFS:$CACHE:$useCACHESIZE >$CACHEINFO
chmod 0644 $CACHEINFO
mkdir -p $CACHE # to be sure
else
useCACHESIZE=`awk -F: '{print $3}' < $CACHEINFO`
fi
return 0
}
choose_afsdoptions() {
if [ "x$OPTIONS" = "x" -o "x$OPTIONS" = "xAUTOMATIC" ]; then
if [ $useCACHESIZE -lt 131072 ]; then
OPTIONS=$SMALL
elif [ $useCACHESIZE -lt 524288 ]; then
OPTIONS=$MEDIUM
elif [ $useCACHESIZE -lt 1048576 ]; then
OPTIONS=$LARGE
elif [ $useCACHESIZE -lt 2097152 ]; then
OPTIONS=$XLARGE
else
OPTIONS=$XXLARGE
fi
fi
AFSD_OPTIONS="$OPTIONS"
if [ "$MEMCACHE" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -memcache"
if [ "x$OPTIONS" != "x" -a "x$CACHESIZE" != "xAUTOMATIC" ];then
AFSD_OPTIONS="$AFSD_OPTIONS -blocks $useCACHESIZE"
fi
fi
if [ "$VERBOSE" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -verbose"
fi
if [ "$DYNROOT" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -dynroot"
fi
if [ "$FAKESTAT" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -fakestat"
fi
if [ "$AFSDB" = "yes" ]; then
AFSD_OPTIONS="$AFSD_OPTIONS -afsdb"
fi
}
killafs() {
SIGNAL=$1
PIDS=`lsof -Fp $AFS | sed -e 's/p//'`
if [ "x" != "x$PIDS" ]; then
kill -$SIGNAL $PIDS >/dev/null 2>&1
sleep 3
fi
}
wait_for_server() {
TIMEOUT=$SERVER_TIMEOUT
if [ -f /usr/sbin/bosserver ] && checkproc /usr/sbin/bosserver ; then
# we run on the same machine as the server
while /usr/sbin/bos status localhost -localauth |grep -q "salvaging file system"; do
echo
echo -n "Waiting for local AFS server to come up ..."
sleep 1
TIMEOUT=$(( $TIMEOUT - 1 ))
[ $TIMEOUT -eq 0 ] && return 1
done
fi
return 0
}
# First reset status of this service
rc_reset
# Return values acc. to LSB for all commands but status:
# 0 - success
# 1 - generic or unspecified error
# 2 - invalid or excess argument(s)
# 3 - unimplemented feature (e.g. "reload")
# 4 - insufficient privilege
# 5 - program is not installed
# 6 - program is not configured
# 7 - program is not running
#
# Note that starting an already running service, stopping
# or restarting a not-running service as well as the restart
# with force-reload (in case signalling is not supported) are
# considered a success.
case "$1" in
start)
echo "Starting $DAEMON "
mkdir -p $AFS
if generate_cacheinfo; then
generate_cellinfo
check_configfiles
choose_afsdoptions
if wait_for_server; then
ps ax | grep -q '\[afsd\]' || $DAEMON_BIN $AFSD_OPTIONS || rc_failed 1
if [ "$DATA_ENCRYPTION" = "yes" ]; then
/usr/bin/fs setcrypt on
fi
if [ "x$SYSNAME" != "x" ]; then
/usr/bin/fs sysname $SYSNAME
fi
else
#local server not running
rc_failed 1
fi
else
rc_failed 6
fi
# Remember status and be verbose
rc_status -v
;;
stop)
[ "x`whoami`" = xroot ] || exit 4 # do not allow regular user to kill all his processes
echo -n "Shutting down $DAEMON "
if ps ax | grep -q '\[afsd\]'; then
echo
echo "Sending all processes using $AFS the TERM signal ..."
killafs TERM
echo "Sending all processes using $AFS the KILL signal ..."
killafs KILL
umount $AFS
fi
if grep -q ^$AFS_KERNEL_MODULE /proc/modules ; then
/sbin/rmmod $AFS_KERNEL_MODULE || rc_failed 1
fi
# rmtsys doesn't go away, so kill them all to be sure
killall $DAEMON_BIN > /dev/null 2>&1
# Remember status and be verbose
rc_status -v
;;
try-restart)
## Stop the service and if this succeeds (i.e. the
## service was running before), start it again.
$0 stop && $0 start
# Remember status and be quiet
rc_status
;;
restart)
## Stop the service and regardless of whether it was
## running or not, start it again.
$0 stop
$0 start
# Remember status and be quiet
rc_status
;;
force-reload)
## Signal the daemon to reload its config. Most daemons
## do this on signal 1 (SIGHUP).
## If it does not support it, restart.
echo -n "Reload service $DAEMON"
if [ "$SUPPORTS_HUP" = "yes" ] ; then
killproc -p $DAEMON_PIDFILE -HUP $DAEMON_BIN
#touch $DAEMON_PIDFILE
rc_status -v
else
$0 stop && $0 start
rc_status
fi
;;
reload)
## Like force-reload, but if daemon does not support
## signalling, do nothing (!)
if [ "$SUPPORTS_HUP" = "yes" ] ; then
# If it supports signalling:
echo -n "Reload service $DAEMON"
killproc -p $DAEMON_PIDFILE -HUP $DAEMON_BIN
#touch $DAEMON_PIDFILE
rc_status -v
else
## Otherwise if it does not support reload:
rc_failed 3
rc_status -v
fi
;;
status)
echo -n "Checking for $DAEMON: "
## Check status with checkproc(8), if process is running
## checkproc will return with exit status 0.
# Status has a slightly different for the status command:
# 0 - service running
# 1 - service dead, but /var/run/ pid file exists
# 2 - service dead, but /var/lock/ lock file exists
# 3 - service not running
# NOTE: checkproc returns LSB compliant status values.
ps ax | grep -q '\[afsd\]' || rc_failed 3
rc_status -v
;;
probe)
## Optional: Probe for the necessity of a reload,
## give out the argument which is required for a reload.
if [ "$DAEMON_CONF" -nt "$DAEMON_PIDFILE" ]; then
if [ "$SUPPORTS_HUP" = "yes" ]; then
echo reload
else
echo restart
fi
fi
;;
*)
echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}"
exit 1
;;
esac
rc_exit

228
rc.afs-server Normal file
View File

@ -0,0 +1,228 @@
#! /bin/sh
# Copyright (c) 1995-2000 SuSE GmbH Nuernberg, Germany.
#
# Author: Peter Poeml <poeml@suse.de>, 2001
# Additions by Christof Hanke <biber@induhviduals.de>, 2009
#
# /etc/init.d/afs-server
# and its symbolic link
# /usr/sbin/rcafs-server
#
# System startup script for OpenAFS
#
### BEGIN INIT INFO
# Provides: afs-server
# Required-Start: $local_fs
# Should-Start: $syslog $time $network
# Should-Stop: $null
# Required-Stop: $null
# Default-Start: 3 5
# Default-Stop: 0 2 1 6
# Short-Description: Start OpenAFS Server
# Description: Start OpenAFS Server. Basically just starts the bosserver which manages the rest.
### END INIT INFO
DAEMON="OpenAFS Server"
DAEMON_PIDFILE=
STARTPROC_LOGFILE=
SUPPORTS_HUP="no"
DAEMON_BIN=/usr/sbin/bosserver
if [ `uname -p` = "x86_64" ]; then
LIBDIR=lib64
else
LIBDIR=lib
fi
VLSERVER_BIN=/usr/$LIBDIR/openafs/vlserver
PTSERVER_BIN=/usr/$LIBDIR/openafs/ptserver
FSSERVER_BIN=/usr/$LIBDIR/openafs/fileserver
VOLSERVER_BIN=/usr/$LIBDIR/openafs/volserver
SALVAGER_BIN=/usr/$LIBDIR/openafs/salvager
BOSCONFIG_FILE="/etc/openafs/server/BosConfig"
#test -x $DAEMON_BIN || exit 5
# Shell functions sourced from /etc/rc.status:
# rc_check check and set local and overall rc status
# rc_status check and set local and overall rc status
# rc_status -v ditto but be verbose in local rc status
# rc_status -v -r ditto and clear the local rc status
# rc_failed set local and overall rc status to failed
# rc_failed <num> set local and overall rc status to <num><num>
# rc_reset clear local rc status (overall remains)
# rc_exit exit appropriate to overall rc status
. /etc/rc.status
. /etc/sysconfig/openafs-server
REQUIRE_NETINFO=${REQUIRE_NETINFO=:-yes}
REGENERATE_BOS_CONFIG=${REGENERATE_BOS_CONFIG==:-no}
START_DB_SERVERS=${START_DB_SERVERS=:-no}
START_FILESERVER=${START_FILESERVER=:-no}
# First reset status of this service
rc_reset
# Return values acc. to LSB for all commands but status:
# 0 - success
# 1 - generic or unspecified error
# 2 - invalid or excess argument(s)
# 3 - unimplemented feature (e.g. "reload")
# 4 - insufficient privilege
# 5 - program is not installed
# 6 - program is not configured
# 7 - program is not running
#
# Note that starting an already running service, stopping
# or restarting a not-running service as well as the restart
# with force-reload (in case signalling is not supported) are
# considered a success.
# set ulimit for core files
ulimit -c 1000000
case "$1" in
start)
if [ "$REQUIRE_NETINFO" = "yes" ]; then
if [ ! -e /var/lib/openafs/NetInfo ]; then
echo -n "Not starting $DAEMON, because no Server-NetInfo file present."
echo -n "Create this file under /var/lib/openafs/NetInfo or disable this"
echo -n "check in /etc/sysconfig/openafs-server"
rc_failed 1
rc_exit
fi
fi
if [ "$REGENERATE_BOS_CONFIG" = "yes" ]; then
echo -n Regenerating BosConfig-file
# save old BosConfig
mv $BOSCONFIG_FILE $BOSCONFIG_FILE.initsave
if [ "$BOSSERVER_RESTRICTED"= "yes" ]; then
echo restrictmode 1 > $BOSCONFIG_FILE
else
echo restrictmode 0 > $BOSCONFIG_FILE
fi
if [ "$BOSSERVER_RESTART_TIME" != "" ]; then
echo "$BOSSERVER_RESTART_TIME" >> $BOSCONFIG_FILE
else
echo "never" >> $BOSCONFIG_FILE
fi
if [ "$BOSSERVER_RESTART_FOR_NEWBINARIES_TIME" != "" ]; then
echo "$BOSSERVER_RESTART_FOR_NEWBINARIES_TIME" >> $BOSCONFIG_FILE
else
echo "never" >> $BOSCONFIG_FILE
fi
if [ "$START_DB_SERVERS" = "yes" ]; then
echo "bnode simple vlserver 1" >> $BOSCONFIG_FILE
echo "parm $VLSERVER_BIN $VLSERVER_OPTIONS" >> $BOSCONFIG_FILE
echo "end" >> $BOSCONFIG_FILE
echo "bnode simple ptserver 1" >> $BOSCONFIG_FILE
echo "parm $PTSERVER_BIN $PTSERVER_OPTIONS" >> $BOSCONFIG_FILE
echo "end" >> $BOSCONFIG_FILE
fi
if [ "$START_FILE_SERVERS" = "yes" ]; then
echo "bnode fs fs 1" >> $BOSCONFIG_FILE
echo "parm $FSSERVER_BIN $FSSERVER_OPTIONS" >> $BOSCONFIG_FILE
echo "parm $VOLSERVER_BIN $VOLSERVER_OPTIONS" >> $BOSCONFIG_FILE
echo "parm $SALVAGER_BIN $SALVAGER_OPTIONS" >> $BOSCONFIG_FILE
echo "end" >> $BOSCONFIG_FILE
fi
fi
echo -n "Starting $DAEMON"
startproc $DAEMON_BIN $BOSSERVER_OPTIONS
# Remember status and be verbose
rc_status -v
;;
stop)
echo -n "Shutting down $DAEMON"
checkproc $DAEMON_BIN && /usr/sbin/bos shutdown localhost -localauth -wait
killproc -HUP $DAEMON_BIN
# Remember status and be verbose
rc_status -v
;;
try-restart)
## Stop the service and if this succeeds (i.e. the
## service was running before), start it again.
$0 stop && $0 start
# Remember status and be quiet
rc_status
;;
restart)
## Stop the service and regardless of whether it was
## running or not, start it again.
$0 stop
$0 start
# Remember status and be quiet
rc_status
;;
force-reload)
## Signal the daemon to reload its config. Most daemons
## do this on signal 1 (SIGHUP).
## If it does not support it, restart.
echo -n "Reload service $DAEMON"
if [ "$SUPPORTS_HUP" = "yes" ] ; then
killproc -p $DAEMON_PIDFILE -HUP $DAEMON_BIN
#touch $DAEMON_PIDFILE
rc_status -v
else
$0 stop && $0 start
rc_status
fi
;;
reload)
## Like force-reload, but if daemon does not support
## signalling, do nothing (!)
if [ "$SUPPORTS_HUP" = "yes" ] ; then
# If it supports signalling:
echo -n "Reload service $DAEMON"
killproc -p $DAEMON_PIDFILE -HUP $DAEMON_BIN
#touch $DAEMON_PIDFILE
rc_status -v
else
## Otherwise if it does not support reload:
rc_failed 3
rc_status -v
fi
;;
status)
echo -n "Checking for $DAEMON: "
## Check status with checkproc(8), if process is running
## checkproc will return with exit status 0.
# Status has a slightly different for the status command:
# 0 - service running
# 1 - service dead, but /var/run/ pid file exists
# 2 - service dead, but /var/lock/ lock file exists
# 3 - service not running
# NOTE: checkproc returns LSB compliant status values.
checkproc $DAEMON_BIN
rc_status -v
;;
probe)
## Optional: Probe for the necessity of a reload,
## give out the argument which is required for a reload.
if [ "$DAEMON_CONF" -nt "$DAEMON_PIDFILE" ]; then
if [ "$SUPPORTS_HUP" = "yes" ]; then
echo reload
else
echo restart
fi
fi
;;
*)
echo "Usage: $0 {start|stop|status|try-restart|restart|force-reload|reload|probe}"
exit 1
;;
esac
rc_exit

144
sysconfig.openafs-client Normal file
View File

@ -0,0 +1,144 @@
## Path: Network/File systems/AFS client
## Description: AFS client configuration, default mode
## Type: yesno
## Default: no
#
# Set to "yes" if you want to generate CellServDB and ThisCell files
# from THIS_CELL and THIS_CELL_SERVER variables.
# If you want more complicated setting, set REGENERATE_CELL_INFO to "no"
# and edit the files manually.
#
REGENERATE_CELL_INFO="no"
## Type: string
## Default: ""
#
# This cell name
#
THIS_CELL=""
## Type: string
## Default: ""
#
# IP address of afs server for this cell
#
THIS_CELL_SERVER=""
## Type: string
## Default: ""
#
# DNS name of afs server for this cell
#
THIS_CELL_SERVER_NAME=""
## Type: yesno
## Default: yes
#
# Set to "yes" if you want to use data encription (secure, slower)
#
DATA_ENCRYPTION="yes"
## Type: yesno
## Default: yes
#
# Set to "yes" if you want to generate cacheinfo file
#
REGENERATE_CACHE_INFO="yes"
## Type: string
## Default: ""
#
# AFS client configuration options
#
XXLARGE="-stat 8000 -daemons 6 -volumes 256 -files 50000"
XLARGE="-stat 3600 -daemons 5 -volumes 196 -files 50000"
LARGE="-stat 2800 -daemons 5 -volumes 128"
MEDIUM="-stat 2000 -daemons 3 -volumes 70"
SMALL="-stat 300 -daemons 2 -volumes 50"
## Type: yesno
## Default: yes
#
# Instead of mounting the home cell's root.afs volume at the AFS mount
# point (typically /afs) a fake root is constructed from information
# available in the client's CellServDB.
# With this option enabled openafs can start up even on network outage.
#
DYNROOT="yes"
## Type: yesno
## Default: yes
#
# Instead of calling a stat on a mountpoint to a foreign cell,
# return a faked status to the application.
# "ls -l /afs" is the most prominent example for its usefulness.
#
FAKESTAT="yes"
## Type: yesno
## Default: yes
#
# Instead of looking up database server in CellServDB try DNS first.
# With this option enabled openafs can access cells which are not in the packaged CellServDB-file, but
# which do provide the required DNS-information.
#
AFSDB="yes"
## Type: yesno
## Default: yes
#
# use memory-only cache
#
MEMCACHE="yes"
## Type: string(AUTOMATIC)
## Default: AUTOMATIC
#
# if you set CACHESIZE to "AUTOMATIC", it will automatically be chosen
# deduced by parition sizes (does not work if your cache is on / or
# /usr or /var) or by machine memory size for memory-only cache,
# otherwise the value in (1k-blocks) specified here will be used.
#
CACHESIZE="AUTOMATIC"
## Type: string(AUTOMATIC,$XXLARGE,$XLARGE,$LARGE,$MEDIUM,$SMALL)
## Default: AUTOMATIC
#
# If you set OPTIONS to "AUTOMATIC", the init script will choose a set
# of options based on the cache size, otherwise the values specified here
# will be used.
#
OPTIONS="AUTOMATIC"
## Type: string(/var/cache/openafs)
## Default: /var/cache/openafs
#
# Path to cache directory, it is recommended to use separate partition.
# It does not work on reiserfs. A valid directory must be specified
# even if memory only cache is used.
# Recommended cache directory is "/var/cache/openafs"
#
CACHEDIR="/var/cache/openafs"
## Type: string(/afs)
## Default: /afs
#
# AFS directory. You should never need to change this
#
AFSDIR=/afs
## Type: yesno
## Default: no
#
# Set to "yes" for a lot of debugging information from afsd. Only
# useful for debugging as it prints _a lot_ of information.
#
VERBOSE="no"
## Type: string
## Default: ""
#
# SYSNAME of client. Used to expand the magic "@sys" in pathes within /afs.
# If left blank, the hardcoded sysname (e.g. amd64_linux26) will be used.
SYSNAME=""

View File

@ -0,0 +1,13 @@
#
# startup options for the openAFS client.
# see man afsd for details
AFSD_ARGS="-fakestat -memcache -blocks 102400 -dynroot -afsdb"
#
# sysname to set after startup
# leave empty for default setting.
SYSNAME=""

View File

@ -0,0 +1,145 @@
## Path: Network/File systems/AFS client
## Description: AFS client configuration, default mode
## This package is for the fuse-client
## Type: yesno
## Default: no
#
# Set to "yes" if you want to generate CellServDB and ThisCell files
# from THIS_CELL and THIS_CELL_SERVER variables.
# If you want more complicated setting, set REGENERATE_CELL_INFO to "no"
# and edit the files manually.
#
REGENERATE_CELL_INFO="no"
## Type: string
## Default: ""
#
# This cell name
#
THIS_CELL=""
## Type: string
## Default: ""
#
# IP address of afs server for this cell
#
THIS_CELL_SERVER=""
## Type: string
## Default: ""
#
# DNS name of afs server for this cell
#
THIS_CELL_SERVER_NAME=""
## Type: yesno
## Default: yes
#
# Set to "yes" if you want to use data encription (secure, slower)
#
DATA_ENCRYPTION="yes"
## Type: yesno
## Default: yes
#
# Set to "yes" if you want to generate cacheinfo file
#
REGENERATE_CACHE_INFO="yes"
## Type: string
## Default: ""
#
# AFS client configuration options
#
XXLARGE="-stat 8000 -daemons 6 -volumes 256 -files 50000"
XLARGE="-stat 3600 -daemons 5 -volumes 196 -files 50000"
LARGE="-stat 2800 -daemons 5 -volumes 128"
MEDIUM="-stat 2000 -daemons 3 -volumes 70"
SMALL="-stat 300 -daemons 2 -volumes 50"
## Type: yesno
## Default: yes
#
# Instead of mounting the home cell's root.afs volume at the AFS mount
# point (typically /afs) a fake root is constructed from information
# available in the client's CellServDB.
# With this option enabled openafs can start up even on network outage.
#
DYNROOT="yes"
## Type: yesno
## Default: yes
#
# Instead of calling a stat on a mountpoint to a foreign cell,
# return a faked status to the application.
# "ls -l /afs" is the most prominent example for its usefulness.
#
FAKESTAT="yes"
## Type: yesno
## Default: yes
#
# Instead of looking up database server in CellServDB try DNS first.
# With this option enabled openafs can access cells which are not in the packaged CellServDB-file, but
# which do provide the required DNS-information.
#
AFSDB="yes"
## Type: yesno
## Default: yes
#
# use memory-only cache
#
MEMCACHE="yes"
## Type: string(AUTOMATIC)
## Default: AUTOMATIC
#
# if you set CACHESIZE to "AUTOMATIC", it will automatically be chosen
# deduced by parition sizes (does not work if your cache is on / or
# /usr or /var) or by machine memory size for memory-only cache,
# otherwise the value in (1k-blocks) specified here will be used.
#
CACHESIZE="AUTOMATIC"
## Type: string(AUTOMATIC,$XXLARGE,$XLARGE,$LARGE,$MEDIUM,$SMALL)
## Default: AUTOMATIC
#
# If you set OPTIONS to "AUTOMATIC", the init script will choose a set
# of options based on the cache size, otherwise the values specified here
# will be used.
#
OPTIONS="AUTOMATIC"
## Type: string(/var/cache/openafs)
## Default: /var/cache/openafs
#
# Path to cache directory, it is recommended to use separate partition.
# It does not work on reiserfs. A valid directory must be specified
# even if memory only cache is used.
# Recommended cache directory is "/var/cache/openafs"
#
CACHEDIR="/var/cache/openafs"
## Type: string(/afs)
## Default: /afs
#
# AFS directory. You should never need to change this
#
AFSDIR=/afs
## Type: yesno
## Default: no
#
# Set to "yes" for a lot of debugging information from afsd. Only
# useful for debugging as it prints _a lot_ of information.
#
VERBOSE="no"
## Type: string
## Default: ""
#
# SYSNAME of client. Used to expand the magic "@sys" in pathes within /afs.
# If left blank, the hardcoded sysname (e.g. amd64_linux26) will be used.
SYSNAME=""

View File

@ -0,0 +1,7 @@
#
# startup options for the openAFS client.
# see man afsd for details
AFSD_ARGS="-fakestat -memcache -blocks 102400 -dynroot -afsdb"

79
sysconfig.openafs-server Normal file
View File

@ -0,0 +1,79 @@
## Path: Network/File systems/AFS server
## Description: AFS server configuration, default mode
## Type: yesno
## Default: no
#
# Set to "yes" if you want to generate the BosConfig file
# from START_DB_SERVERS, START_FILESERVER and accompanying variables.
# If you want more complicated setting, set REGENERATE_BOS_CONFIG to "no"
# and edit the files manually.
#
REGENERATE_BOS_CONFIG="no"
## Type: yesno
## Default: yes
#
# Set to "yes" if you require a NetInfo file before starting the service.
# useful for new installations, where you might forget this issue.
#
REQUIRE_NETINFO="yes"
## Type: yesno
## Default: no
#
# Set to "yes" if want to start the database servers (vlserver,ptserver) on this host.
# Only useful if REGENERATE_BOS_CONFIG is set to 'yes'
#
START_DB_SERVERS="no"
## Type: yesno
## Default: no
#
# Set to "yes" if want to start the fileserver on this host.
# Only useful if REGENERATE_BOS_CONFIG is set to 'yes'
#
START_FILESERVER="no"
## Type: yesno
## Default: no
#
# Set to "yes" if want to start the bosserver in restricted mode on this host.
# Only useful if REGENERATE_BOS_CONFIG is set to 'yes'
#
BOSSERVER_RESTICTED="no"
## Type: string
## Default: ""
#
# Set time to restart the AFS-servers at a given time in the week.
# Leave empty if you don't want to restart the servers at all
# Only useful if REGENERATE_BOS_CONFIG is set to 'yes'
#
BOSSERVER_RESTART_TIME=""
## Type: string
## Default: ""
#
# Set time to check for new server-binaries of the AFS-servers at a given time in the week.
# Leave empty if you don't want to do this automatic restart.
# When upgrading the openafs-servers rpm, running server processes are not restarted automatically.
# Use this to do so automatically.
# Only useful if REGENERATE_BOS_CONFIG is set to 'yes'
#
BOSSERVER_RESTART_FOR_NEWBINARIES_TIME=""
## Type: string
## Default: ""
#
# AFS server configuration options
# command line options how to start the required servers.
# Only useful if REGENERATE_BOS_CONFIG is set to 'yes'
#
BOSSERVER_OPTIONS=""
PTSERVER_OPTIONS=""
VLSERVER_OPTIONS=""
FSSERVER_OPTIONS=""
VOLSERVER_OPTIONS=""
SALVAGER_OPTIONS=""

View File

@ -0,0 +1,4 @@
## Path: Network/File systems/AFS server
## Description: AFS server configuration, default mode
# all is set in /etc/openafs/BosConfig