libafsauthent includes auth/cellconfig.c, which uses res_search, so it
requires -lresolv even if it isn't needed for gethostbyname. Add
LIB_AFSDB to the link line for libafsauthent.
libafsauthent includes auth/cellconfig.c, which uses res_search, so it
requires -lresolv even if it isn't needed for gethostbyname. Add
LIB_AFSDB to the link line for libafsauthent.
* Set the OpenAFS build version to the Debian package version with
-debian appended so that the Debian package versions can be
distinguished from unmodified upstream versions.
* Explicitly link libafsauthent with -lresolv -lcrypt. This is a
temporary fix for Linux that will be replaced by a better upstream fix
in the next release.
DAFS: variable declarations in C must be a top of block
Two instances of variable declarations not being present
at the top of a code block in src/vol/volume.c when building
with AFS_DEMAND_ATTACH_FS. Fix them.
Add a "check" rule to each of the docbook directories
that uses xmllint.exe (from Cygwin) to validate the
docbook source against the DTD. Validation failures
will halt the build.
These are virtual packages, and breaks is more correct than Conflicts
since upgrading to something that provides openafs-modules3 will fix
the problem but the packages can be co-installed from a file system
perspective.
Michael Meffie [Mon, 19 Apr 2010 14:00:52 +0000 (10:00 -0400)]
viced: host hash address collisions
Attempt to resolve collisions when adding a host to the
address hash table and another host with the same address:port
is already present in the hash table. Retrieve the uuid for
the host at that address and if the uuid matches the new host
and not the old, remove the address from the old host and
install the new host into the address hash.
Change-Id: Id182f907f63be556c61ffb91777edd35f0aa950d
Reviewed-on: http://gerrit.openafs.org/1786 Reviewed-by: Andrew Deason <adeason@sinenomine.net> Tested-by: Michael Meffie <mmeffie@sinenomine.net> Reviewed-by: Derrick Brashear <shadow@dementia.org> Tested-by: Derrick Brashear <shadow@dementia.org>
Andrew Deason [Thu, 8 Jul 2010 21:40:07 +0000 (16:40 -0500)]
GetInodeSummary: free inode info
In the salvager, GetInodeSummary stores some information about the
relevant inodes into a file. Free the memory for that information
after it's been written out, since we don't reference that memory
again.
Matt Benjamin [Thu, 24 Jun 2010 13:07:36 +0000 (09:07 -0400)]
An RPC test dispatch library for vice
A library framework for remote testing against file servers,
with the ability to establish multiple call/callback channel
pairs within a single test process and dispatch requests
arbitrarily on each. Thanks to Derrick for design and debugging
help. Additional callback processing intelligence will follow
in a future changeset. This version builds on Windows NT (but
might need further adjustment).
Simon Wilkinson [Sat, 10 Jul 2010 19:30:31 +0000 (20:30 +0100)]
Linux: Actually use freezer compatibility func
We were calling try_to_sleep, rather than afs_try_to_sleep. Whilst
try_to_sleep is present in all modern Linux kernels, on some older
systems we need to fall back to our own implementation, which is
what the afs_try_to_sleep function should do, but it can only do so
if we call it.
Simon Wilkinson [Sat, 10 Jul 2010 19:17:56 +0000 (20:17 +0100)]
Linux: Use freezer compatibility macros in RX
Commit eef18466d920985c37ed8d22a6557b609c6225a6 introduced some
compatibility macros for the refridgerator functionality. Use these
in the Linux kernel RX code, rather than rolling our own.
Autoconf apparently doesn't care because it runs it explicitly under
a shell, but it's sometimes useful to run it manually to check
something. Plus, executable shell scripts should be executable on
general principles.
Add changelog workaround for upstream packaging reuse
* Add a workaround in the clean target to allow the same packaging files
to be used by upstream, which removes changelog during distclean
because it's Autoconf-generated. This workaround will not trigger
during a normal Debian package build.
We used to mark executable some files that upstream didn't ship
executable properly, but one of them has disappeared and the other
is now correctly executable upstream.
* Tighten the dependencies on openafs-client in packages that symlink
their /usr/share/doc directories to openafs-client's to meet the
Policy requirements for changelog files.
* Install an upstream changelog file now that upstream provides one.
* Update kernel module packaging scripts:
- Remove selection of linux-image vs. kernel-image for kernel names.
- Use Breaks instead of Conflicts.
- Update standards version to 3.9.0.
Russ Allbery [Tue, 15 Jun 2010 01:13:02 +0000 (18:13 -0700)]
Drop support for lpia, add powerpcspe
* Remove the lpia architecture. This was an experiment in Ubuntu that
has apparently been dropped.
* Add preliminary support for powerpcspe, mapping that architecture to
ppc_linux26. The kernel build won't work unless uname -m on that
architecture returns ppc.
Andrew Deason [Wed, 7 Jul 2010 20:43:26 +0000 (15:43 -0500)]
Use afs_sfsize_t for *_SIZE results
Callers of FDH_SIZE and OS_SIZE should be storing the results in an
afs_sfsize_t. Some were using regular 'int's and other things, which
can screw up if the file is sufficiently large.
Ben Kaduk [Fri, 9 Jul 2010 04:38:16 +0000 (00:38 -0400)]
Remove incorrect critical section use in dnlc_lookup
Critical sections may not be used with (non-spin) locks. As such,
this code was wrong, and led to a panic.
We don't see why there what synchronization they may have been
providing, so just remove them and do not replace them.
Michael Meffie [Thu, 8 Jul 2010 18:45:22 +0000 (14:45 -0400)]
build fix on older linux
The commit d0abe56aa47d4561ba57527d53a2b0db2ea613c2 added
a duplicate inclusion of freezer.h. Older versions
of linux (circa 2.6.20) are missing include guards
on freezer.h.
Andrew Deason [Fri, 2 Jul 2010 19:28:29 +0000 (14:28 -0500)]
Fix VPrintDiskStats_r logging
VPrintDiskStats_r tried to log some information using separate Log()
statements on the same line. This looks very odd when logged, since we
add a timestamp to every Log() call these days. Fix it to print the
line as one call to Log().
Ben Kaduk [Thu, 8 Jul 2010 02:10:44 +0000 (22:10 -0400)]
Fix build
Previous commit to this file was not as tested as we thought.
This one actually builds (well, except for the part where flex
doesn't like et_lex.lex.l at the moment).
Ben Kaduk [Thu, 8 Jul 2010 00:47:55 +0000 (20:47 -0400)]
FBSD: sync with NFS for *pages vnops
We've had per-cpu counter variables for a while, use the proper
macros to adjust them.
FBSD90 has had the page queue locks pushed down a level, so we
don't need to lock them and should lock individual pages instead.
This fixes mmap() on FreeBSD HEAD.
Andrew Deason [Wed, 7 Jul 2010 17:52:10 +0000 (12:52 -0500)]
klog: refactor klog_prompter
The ifdefs in klog_prompter were getting a bit confusing. Split out
some logic into a separate "is this prompt a password prompt"
function. As a result, we can build without KRB5_PROMPT_TYPE_PASSWORD
defined, which happens to be the case on hp_ux11i.
Change-Id: I1d5f794bfc33017f699478e367cde91a3e77d33c
Reviewed-on: http://gerrit.openafs.org/2353 Tested-by: Andrew Deason <adeason@sinenomine.net> Reviewed-by: Simon Wilkinson <sxw@inf.ed.ac.uk> Reviewed-by: Derrick Brashear <shadow@dementia.org> Tested-by: Derrick Brashear <shadow@dementia.org>
kernel InitPeerParams has bogus branching and dup code
several of the mtu configuration cases for the kernel version
of InitPeerParams were bogus. clean up the function.
(a forthcoming change reworks this anyway, but..)
Andrew Deason [Tue, 6 Jul 2010 19:41:13 +0000 (14:41 -0500)]
HPUX: make osi_procname a stub
It is not immediately clear how to obtain the current process name on
HPUX, and the current osi_procname definition breaks the build, so
just make osi_procname a stub for HPUX.
Ben Kaduk [Sun, 4 Jul 2010 06:28:02 +0000 (02:28 -0400)]
FBSD: always close the rx socket when shutting down
The soclose(rx_socket) call is needed in order to restart AFS.
(Otherwise sobind() fails with EADDRINUSE.)
While here, use the defined constant SHUT_RDWR instead of
hardcoding '2' for soshutdown's second argument.
Ben Kaduk [Sun, 4 Jul 2010 02:58:39 +0000 (22:58 -0400)]
Do not recurse on the glock in rxk_NewSocketHost
If sobind() failed, we would lock the glock before going to bad,
which proceeded to lock the glock, panic()ing on the recursion attempt.
Remove the unneeded first call.
The executable %{_bindir}/kpasswd was included in the
the 'openafs' base package.
This change removes the kpasswd executable from the base package. It
is still built and is installed in the 'openafs-kpasswd' package. I
believe this was the original intent of the 'openafs-kpasswd' package.
Andrew Deason [Tue, 29 Jun 2010 18:19:11 +0000 (13:19 -0500)]
DAFS: Salvage VG on volume creation error
When trying to create a volume (either an entirely new volume or a
clone), request a demand-salvage on that volume group if we hit an
unexpected error. This can allow some situations to automatically
rectify themselves if, for example, a volume is missing its .vol
header, but still otherwise exists and causes an error during a clone.
Andrew Deason [Tue, 29 Jun 2010 19:44:31 +0000 (14:44 -0500)]
DAFS: Allow FSSYNC salvages on unknown volumes
Allow salvage requests over FSSYNC (FORCE_ERROR with the FSYNC_SALVAGE
reason code) that are requested on volumes that we do not know to
exist. This can be helpful if a salvage is requested on a volume that
someone attempted to create but failed, indicating that a
partially-created volume may be in the way.
Log an additional message when we do this, as it should not be a
normal occurrence.
Change-Id: I6e1bbe35111a41c489fe85cad36e6a8a6f323a5a
Reviewed-on: http://gerrit.openafs.org/2285 Reviewed-by: Tom Keiser <tkeiser@sinenomine.net> Reviewed-by: Derrick Brashear <shadow@dementia.org> Tested-by: Derrick Brashear <shadow@dementia.org>
cache-bypass explicitly reference pages involved in background i/o
Formerly, we assumed that any page eligible for background i/o could
be effectively pinned by lock_page. Persuant to concern expressed by
Simon that such pages might be eligible to be released by the kernel
after readpages returns, call get_page to increment the refcount on
each page before dispatching a background read (and matching put_page
when the i/o is completed).