[OpenAFS] OpenAFS 1.8.0 alpha 1 available

Gaja Sophie Peters gaja.peters@math.uni-hamburg.de
Thu, 29 Dec 2016 17:22:19 +0100


Am 14.12.16 um 05:57 schrieb Benjamin Kaduk:
> The OpenAFS Guardians are hapy to announce the availability of the first
> prerelease candidate of OpenAFS 1.8.0.

> A large number of bugfixes and new features are included, and there are also
> behavior and functional changes that may require administrator action as
> part of the upgrade; please consult the release notes for details.

I was looking for the release-notes, but didn't find them - but I wanted 
to try the client-bit myself, so this is my "story". I guess this is 
more of a "success" story, than a bug, so I'll provide my feedback 
(little as it may be) here, in case it may be helpful to anybody.

I used the Debian-Git-Repository of OpenAFS to build a package that can 
be installed on Ubuntu 14.04, which we use on most of our Linux-Clients.

The procedure wasn't quite straight-forward, and I can make no promises 
that I did everything completely right - however, it runs for me now, 
and seems to work. So far, I tested only the client-part of OpenAFS 1.8. 
The servers are still 1.6.18 (or so - the version from jessie-backports).

This is as much a reference for myself, what I actually did, because I 
didn't find anywhere a description, how to build a Debian-Package (not 
even a generic one)... At least I eventually found that there's a 
program "dpkg-build-package", which does most of the job.

Building a .deb-package with dpkg-buildpackage didnít (quite) work with 
an AFS-Home-directory, the build got stuck at "chown" - seems like the 
"fakeroot" didnít quite do what it was supposed to, so I started over in 
/var/tmp...

> cd /var/tmp
> git clone https://anonscm.debian.org/cgit/pkg-k5-afs/openafs.git
> cd openafs
> git checkout $(git tag|grep debian/1.8|tail -1)
> sudo apt-get build-dep openafs
> sudo apt-get install debian-keyring heimdal-multidev libperl-dev
> dpkg-buildpackage -d -b -uc -us
> sed -i s/rk_base64_/base64_/ src/auth/userok.c
> dpkg-buildpackage -d -b -uc -us -nc
> rm debian/tmp/usr/lib/perl/ukernel.so debian/tmp/usr/lib/perl/AFS/ukernel.pm
> sed -i 's/dh_strip --dbgsym-migration/dh_strip #--dbgsym-migration/' debian/rules
> dpkg-buildpackage -d -b -uc -us -nc
> cd ..

Now the building itself is finished. Next install it...

> sudo dpkg -i openafs-modules-dkms_1.8.0*_all.deb openafs-krb5_1.8.0*_amd64.deb openafs-client_1.8.0*_amd64.deb
> sudo rm -rf /var/cache/openafs/* /var/cache/openafs-client
> sudo reboot

Some comments:
- The original openafs-source is missing the "debian"-subdirectory which 
contains the pre-defined rules for "Configure". I could probably have 
done it manually, but since the Debian-Git already contains everything, 
I used that as a starting point.

- The "checkout" line tells git to use the 1.8.<most recent> tree, 
instead of the 1.6.20 tree

- the "build-dep" for openafs is not sufficient, because it takes only 
OpenAFS 1.6.X into account, so two more packages are needsd. I don't 
remember, why I put "debian-keyring" also into the list. I remember it 
was needed for SOMEthing, but not if it was for this build.

- The parameters -uc and -us "dpkg-buildpackage" (unsigned source, 
unsigned .changes) are probably not needed any more, because I told it 
to only create binary packages anyways, the "-d" tells it to ignore 
pre-depends, it wouldn't build on Ubuntu 14.04 otherwise, and the "-b" 
tells it to only create binary packages, no source-packages.

- Something in the debian/rules makes it garble the file 
"src/auth/userok.c", which fixes the following sed-line. The file is ok 
before I called the dpkg-buildpackage -- probably some difference 
between Debian and Ubuntu

- The next call to "dpkg-buildpackage" includes the parameter "-nc", to 
not clear the source-tree, otherwise it would have to rebuild some 
things that it already built.

- Two files are generated (or copied) during the build, which need to be 
removed (ukernel.so and ukernel.pm), otherwise it won't continue. The 
"rm" takes care of that. Also, the command dh_strip, which is called 
towards the end of the dpkg-buildpackage doesn't know the parameter 
--dbgsym-migration under Ubuntu, so just comment it out with sed.

- The third run of "dpkg-buildpackage" continues until the end and 
produces the final package-files in /var/tmp

- Next I installed with "dpkg -i" the three packages that are needed for 
a client-install and courageously rebooted - only to find out that AFS 
wasn't find my home-dir. (All other directories were working fine, 
except the one above my homedir and my homedir...)

- Any combination of "fs flush" "fs flushmount" and "fs flushall" didn't 
help either, so I manually cleared out the AFS-cache and restarted again.

- Current state: AFS apparently working. Didn't use it as a "real" 
(graphical) home-directory yet, because I did all this remotely, but 
copying files to and from the AFS seems to work fine.


In case anybody can (or wants to) make use of these packages, I copied 
them to the AFS in the publicly accessible directory

/afs/math.uni-hamburg.de/public/fmsv030/openafs-1.8.0~pre1-5_amd64_Ubuntu-14.04

As the directory-name suggests: the packages are only for 64bit Ubuntu 
14.04 - no guarantees are made that it won't break anything for you, the 
packages are unsigned (I think) and I only tested the client, not the 
server-part.


Greetings, and a Happy New Year,
Gaja Peters