Erez Zadok [Sat, 4 Jun 2005 16:34:33 +0000 (16:34 +0000)]
* amd/ops_nfs.c (mount_nfs_fh): set timeo/retrans mount options
only if the user specified them in amd.conf or elsewhere. If they
were not specified, don't do anything, which would let the OS use
its own defaults.
* amd/get_args.c (get_args): negative timeo/retrans are "good" in
that they represent uninitialized values (meaning to let the OS
use it's default values). So only check if user specified a value
equal to zero (invalid).
* amd/amd.h: define AMU_TYPE_NONE so we know when users didn't
specify timeo/retrans at all.
Erez Zadok [Fri, 3 Jun 2005 14:46:35 +0000 (14:46 +0000)]
*******************************************************************
*** Released am-utils-6.1-rc7 ***
*******************************************************************
* m4/macros/os_cflags.m4 (CFLAGS): use custom-OS C flags for
configuring, not just for building. That way the two phases
(configure and compile) are in sync. This fixes getwire() on
OSF/1 systems.
* conf/nfs_prot/nfs_prot_sunos5_8.h: define INADDR_NONE if not
defined in system headers.
Erez Zadok [Wed, 1 Jun 2005 21:17:26 +0000 (21:17 +0000)]
* libamu/Makefile.am (EXTRA_DIST): remove alloca.c as it's no
longer needed.
Erez Zadok [Sat, 28 May 2005 19:11:28 +0000 (19:11 +0000)]
* completed set of fixes for irix6.5.
* Minor new ports alpha-unknown-linux-gentoo1.4.16
alphaev56-dec-osf4.0f, mips-unknown-linux-gentoo1.4.16, and
sparc64-unknown-linux-gentoo1.4.16, and mips-sgi-irix6.5. Test
those systems with both cc and gcc, where possible.
Erez Zadok [Sat, 28 May 2005 18:35:54 +0000 (18:35 +0000)]
* include/am_xdr_func.h: remove trailing comma at end of enum
list.
Erez Zadok [Sat, 28 May 2005 18:34:10 +0000 (18:34 +0000)]
* m4/macros/os_cflags.m4: with gcc 3.4.3 on irix-6.5, we get pte_t
undefined. So give it a dummy value.
Erez Zadok [Sat, 28 May 2005 17:35:46 +0000 (17:35 +0000)]
minor typo
Erez Zadok [Sat, 28 May 2005 17:34:10 +0000 (17:34 +0000)]
* conf/checkmount/checkmount_osf.c (fixmount_check_mount): add
extra parentheses around assignments as "if" expressions (gcc
complains).
* conf/nfs_prot/nfs_prot_osf4.h: add missing extern definitions
for plock, hstrerror, getmntinfo, alloca, xdr_exportnode, and
xdr_groups.
Erez Zadok [Sat, 28 May 2005 16:44:42 +0000 (16:44 +0000)]
* libamu/alloca.c: remove file from distro.
* configure.in: don't call AC_FUNC_ALLOCA any more.
* include/am_defs.h: remove header fixups for <alloca.h>, now that
we don't need it.
Erez Zadok [Sat, 28 May 2005 16:39:23 +0000 (16:39 +0000)]
* amd/amq_svc.c (amqsvc_is_client_allowed): rewrite function to
avoid only use of alloca() in am-utils, and to use strdup
explicitly. This way we can avoid using alloca, a feature that's
not portable on various systems.
Erez Zadok [Sat, 28 May 2005 15:54:03 +0000 (15:54 +0000)]
* amq/amq.c: remove unused lint/rcsid cruft.
Erez Zadok [Fri, 27 May 2005 21:26:34 +0000 (21:26 +0000)]
* configure.in: check for <linux/socket.h>, which, if found,
appears to be preferable to <sys/socket.h>. Use it to find
<linux/nfs_mount.h>. On some Linux systems
(Gentoo), both exist but only one must be included, or else you
get redefined structure errors.
* libamu/wire.c (is_network_member): check if masknum is
INADDR_NONE, not "< 0" because it's an unsigned quantity.
* libamu/util.c (xstrlcpy): remove useless test for size_t < 0,
because it's an unsigned quantity.
Erez Zadok [Thu, 26 May 2005 13:45:00 +0000 (13:45 +0000)]
*******************************************************************
*** Released am-utils-6.1-rc6 ***
*******************************************************************
* conf/mtab/mtab_aix.c, conf/checkmount/checkmount_aix.c: only
define an extern for mntctl() if needed.
* ltmain.sh: update from latest libtool-1.5.18, so we can properly
that matches the appropriate libtool M4 macros. This makes
Erez Zadok [Thu, 26 May 2005 13:36:35 +0000 (13:36 +0000)]
* conf/nfs_prot/nfs_prot_aix5_2.h: AIX 5.3 complains about
missing definition of struct thread_credentials in <sys/vfs.h>
but trying to bring that definition in drags a whole lot of other
messy stuff. So just provide a dummy definition for this
structure.
Erez Zadok [Tue, 24 May 2005 04:45:01 +0000 (04:45 +0000)]
* Makefile.am (EXTRA_DIST_M4): distribute m4/macros/libtool.m4.
* m4/macros/header_templates.m4: template for HAVE_EXTERN_MNTCTL.
* m4/macros/check_extern.m4: include <sys/vmount.h> on AIX
systems, so we can find extern definition for mntctl().
* conf/mtab/mtab_aix.c, conf/checkmount/checkmount_aix.c: onlu
define an xtern for mntctl() if needed.
* amd/ops_nfs.c (prime_nfs_fhandle_cache): never, ever, use C++
style comments in C code. Some C compilers don't accept it.
* amd/info_ldap.c (amu_ldap_init, get_ldap_timestamp): force cast
of "time_t *ts" to u_long, to avoid complaints on AIX 5.2 with
xlC.
* amd/get_args.c: rename symbol conf_file to amu_conf_file to
avoid conflict with libldap.a from openldap-2.0.21 on AIX 5.2.
Oh, when will people who develop libraries learn to always prefix
their exported symbols with a library-specific name?
* configure.in: check for mntctl() extern on AIX systems.
* ltmain.sh: update from latst libtool-1.5.18, so we can properly
build on AIX 5.2/5.3 with cc and with gcc.
* m4/macros/libtool.m4: update from latest libtool-1.5.18. This
time, and from now on, we must include libtool.m4 from the libtool
distribution itself. That way we ensure that we use an ltmain.sh
that macthes the appropriate libtool M4 macros. This makes
am-utils no longer dependent on having libtool installed on a
given system on which you run bootstrap.
Erez Zadok [Tue, 24 May 2005 04:44:12 +0000 (04:44 +0000)]
import of libtool 1.5.18 M4 macros
Erez Zadok [Mon, 23 May 2005 19:03:31 +0000 (19:03 +0000)]
* minor new port: i386-pc-linux-deb3.0.
Erez Zadok [Sun, 22 May 2005 23:19:00 +0000 (23:19 +0000)]
* minor new ports: i386-unknown-netbsdelf2.0.2 and
i386-unknown-openbsd3.7.
Erez Zadok [Fri, 20 May 2005 17:05:12 +0000 (17:05 +0000)]
silly unbalanced ifdef
Erez Zadok [Fri, 20 May 2005 14:34:26 +0000 (14:34 +0000)]
* minor new ports: i386-pc-linux-gentoo1.4.16 and
powerpc-unknown-linux-yellowdog2.3.
* include/{mount_headers2.h, am_defs.h}: safer setup before
inclusion of <linux/nfs_mount.h>, which is broken on several
systems.
* configure.in: test for <linux/nfs2.h>. Separate special test
for <linux/nfs_mount.h> because we need to define __KERNEL__ for
that test, as well as optionally define struct nfs2_fh for some
systems (gentoo with 2.4 kernel, yellowdog 2.3, and others).
* config.guess.long: support Gentoo and Yellow Dog Linux distros.
* minor new ports: i386-pc-linux-suse9.2 and
i386-unknown-freebsd5.4.
Erez Zadok [Wed, 18 May 2005 18:12:31 +0000 (18:12 +0000)]
actually commit the change -- duh
Erez Zadok [Wed, 18 May 2005 17:59:41 +0000 (17:59 +0000)]
* amd/nfs_subr.c: use NFS_FHSIZE, not FHSIZE.
Erez Zadok [Wed, 18 May 2005 01:09:36 +0000 (01:09 +0000)]
credit bug when it belongs
Erez Zadok [Wed, 18 May 2005 01:03:19 +0000 (01:03 +0000)]
*******************************************************************
*** Released am-utils-6.1-rc5 ***
*******************************************************************
Erez Zadok [Tue, 17 May 2005 16:48:55 +0000 (16:48 +0000)]
* amd/info_ldap.c (amu_ldap_init): change plog to dlog, to avoid
sending annoying warning for a minor issue.
* amd/nfs_subr.c: check for NULL pointer before dereferencing it.
Ion Badulescu [Tue, 17 May 2005 15:05:23 +0000 (15:05 +0000)]
* amd/nfs_subr.c: check for NULL pointer before dereferencing it
Erez Zadok [Mon, 16 May 2005 23:23:29 +0000 (23:23 +0000)]
start rc5
Erez Zadok [Mon, 16 May 2005 19:00:30 +0000 (19:00 +0000)]
* m4/macros/host_macros.m4: if a NetBSD system, remove 'elf' part
from OS name because it's no longer relevant. Also, don't include
the major OS version number in the OS name because that's also
unnecessary (and users can always use $osver in maps).
Erez Zadok [Mon, 16 May 2005 18:41:40 +0000 (18:41 +0000)]
suggestion from Dan Riley <dsr at mail.lns.cornell.edu>. Better
fix from Ion Badulescu: use [FHSIZE-sizeof(u_int)] which is the
actual size we use.
Erez Zadok [Mon, 16 May 2005 18:08:53 +0000 (18:08 +0000)]
* amd/nfs_subr.c: use [1] for out-of-band pointer at the end of
struct am_fh, because it's the most portable method. Bug fix
suggestion from Dan Riley <dsr at mail.lns.cornell.edu>.
* amd/amfs_generic.c (amfs_lookup_mntfs): reset currently used
def_opts to options given in -opts, appended with the /default
options. Bug fix suggestion from Dan Riley <dsr at
mail.lns.cornell.edu>.
Erez Zadok [Sat, 14 May 2005 04:12:09 +0000 (04:12 +0000)]
*******************************************************************
*** Released am-utils-6.1-rc4 ***
*******************************************************************
Erez Zadok [Fri, 13 May 2005 13:29:24 +0000 (13:29 +0000)]
document memleak in NEWS item
Daniel Ottavio [Thu, 12 May 2005 23:01:25 +0000 (23:01 +0000)]
* amd/amd.c (main) : fixed memory leak detected by valgrind
* amd/info_ldap.c (amu_ldap_init) : fixed memory leak detected by
valgrind
Erez Zadok [Wed, 11 May 2005 18:42:51 +0000 (18:42 +0000)]
* m4/macros/{check_checkmount_style.m4, check_mnttab_style.m4,
check_nfs_fh_dref.m4, check_nfs_prot_headers.m4,
check_nfs_sa_dref.m4, check_umount_style.m4, os_cflags.m4}: check
for "macosx" as valid OS string, so we compile properly on Darwin
systems.
Erez Zadok [Wed, 11 May 2005 13:22:27 +0000 (13:22 +0000)]
*******************************************************************
*** Released am-utils-6.1-rc3 ***
*******************************************************************
* rerun bootstrap to get a working configure script that actually
checks for limits.h and dependent linux autofs/nfs headers.
* configure.in: remove redundant check for limits.h.
Erez Zadok [Tue, 10 May 2005 01:03:34 +0000 (01:03 +0000)]
start rc3
Erez Zadok [Tue, 10 May 2005 01:03:05 +0000 (01:03 +0000)]
changelog commit
Erez Zadok [Mon, 9 May 2005 03:10:16 +0000 (03:10 +0000)]
* amd/amfs_generic.c (amfs_lookup_mntfs): removed redundant use of
old_def_opts variable.
* amd/amfs_generic.c (amfs_lookup_mntfs) : Make sure when a map
entry has a single dash '-', that the default options are reset.
This functionality was somehow lost from earlier releases and
reported by Dan Riley <dsr@mail.lns.cornell.edu>.
(AC_CHECK_MNT2_NFS_OPTS): Check for private NFS mount option (IRIX 6).
if missing.
Erez Zadok [Thu, 5 May 2005 20:02:38 +0000 (20:02 +0000)]
powerpc64-unknown-linux-sles9.
Erez Zadok [Thu, 5 May 2005 20:01:35 +0000 (20:01 +0000)]
* config.guess.long: detect SuSE Enterprise Server and call it
"sles" not "suse".
Erez Zadok [Tue, 3 May 2005 03:14:31 +0000 (03:14 +0000)]
* doc/am-utils.texi (amd): document proper use of
/etc/hosts.allow. Don't spawn a new Amd process because Amd will
get confused if someone else waitpid's on its children (which
often do important un/mount work). Issue reported by Francis
Montagnac <Francis.Montagnac at sophia.inria.fr>.
Erez Zadok [Tue, 3 May 2005 02:40:14 +0000 (02:40 +0000)]
* minor new ports: powerpc64-unknown-linux-rhel4, and
powerpc64-unknown-linux-suse9.
Daniel Ottavio [Mon, 2 May 2005 00:27:47 +0000 (00:27 +0000)]
* amd/amfs_host.c (amfs_host_umount): We do not want to pass
ENOENT as an error because if the directory does not exists our
work is done anyway.
* conf/umount/umount_linux.c (umount_fs): If we are successful or
there was an ENOENT, remove the mount entry from the mtab file.
Ion Badulescu [Sun, 1 May 2005 18:06:18 +0000 (18:06 +0000)]
* amd/nfs_subr.c: am_fh definition moved here from amd.h;
restructured to better reflect its duality (old/new filehandles)
(fh_to_mp3): fhh_gen is always used, even for new style f/h
(mp_to_fh): ditto
* amd/amd.h: moved am_fh definition to nfs_subr.c (which is the
only place where it's used)
Erez Zadok [Sat, 30 Apr 2005 16:37:55 +0000 (16:37 +0000)]
* m4/macros/host_macros.m4: use sw_vers on Apple machines to find
out more appropriate OS name (macosx) and OS version (10.3.x) than
uname(3) reports.
Erez Zadok [Fri, 29 Apr 2005 18:50:44 +0000 (18:50 +0000)]
* config.guess, config.sub, doc/texinfo.tex: updates from latest
official GNU distributions.
from latest official GNU versions.
Erez Zadok [Fri, 29 Apr 2005 18:48:19 +0000 (18:48 +0000)]
* m4/macros/host_macros.m4: for macosx, change architecture value
from "Power Macintosh" to "powerpc".
* libamu/util.c (xstrlcpy): format 'len' parameter as u_long, not
int (it's a size_t).
Erez Zadok [Mon, 25 Apr 2005 03:37:15 +0000 (03:37 +0000)]
record timeo/retrans toplvl bug fix
Christos Zoulas [Mon, 25 Apr 2005 01:54:50 +0000 (01:54 +0000)]
Only take into account mounts that have a non-empty mountpoint.
Erez Zadok [Sun, 17 Apr 2005 03:05:54 +0000 (03:05 +0000)]
* scripts/amd.conf.5, doc/am-utils.texi (normalize_slashes
Parameter), scripts/amd.conf-sample: document new
normalize_slashes global configuration parameter.
* amd/opts.c (deslashify, normalize_slash): don't touch trailing
slashes, even if multiples of them, if user said
normalize_slashes=no in amd.conf.
* amd/conf.c (gopt_normalize_slashes): new function to record if
to normalize slashes or not.
* amd/amd.h (CFM_NORMALIZE_SLASHES): new flag to decide if to
normalize double-slashes or not ("yes" by default).
* amd/autil.c (am_mounted): pass TRUE when calling mf_mounted.
This is the parent mntfs which does the mf->mf_fo
(am_opts type), and we're passing TRUE here to tell mf_mounted to
actually free the am_opts.
* amd/autil.c (mf_mounted): Be careful when calling free_ops and
XFREE here. Some pseudo file systems like nfsx call this
function, even though it would be called by the lower-level amd
file system functions. nfsx needs to call this function because
of the other actions it takes. So we pass a boolean from the
caller (yes, not so clean workaround) to determine if we should
free or not. If we're not freeing (often because we're called
from a callback function), then just to be sure, we'll zero out
the am_opts structure and set the pointer to NULL. The parent
mntfs node owns this memory and is going to free it with a call to
mf_mounted(mntfs,TRUE).
* amd/amd.h: pass flag to mf_mounted, to free or not to free the
am_opts.
* amd/amfs_nfsx.c (amfs_nfsx_cont): call mf_mounted with FALSE to
tell it not to free the am_opts, to avoid double free.
* include/am_defs.h: include limits.h if found.
* configure.in: check for limits.h. Check for certain Linux
headers such as auto_fs.h after checking for limits.h, and include
the latter if it exists, because some Linux headers depend on
limits.h. This prevents warnings during configure time.
* amd/amfs_toplvl.c (amfs_toplvl_mount): do NOT set retrans/timeo
values from default global UDP settings, because it can cause
unexpected timeouts in Amd on slow systems. The default that each
OS provides for these toplvl NFS mounts should be OK, or else you
can use the map_options entry.
Daniel Ottavio [Sat, 9 Apr 2005 18:15:35 +0000 (18:15 +0000)]
* amd/nfs_subr.c (mp_to_fh): Replace xstrlcpy with memcpy because the
source buffer is treated more as a filehandle than a string.
* amd/nfs_subr.c (fh_to_mp3): Replace xstrlcpy with memcpy because the
source buffer is treated more as a filehandle than a string.
* amd/opts.c (free_op): No longer need to assign pointer to NULL
after XFREE.
* amd/opts.c (expand_op): Revert back to using strncpy() instead
of xstrlcpy. The code is correct and relies on the semantics of
strncpy.
* libamu/mount_fs.c (compute_nfs_args): Leave XXX warning that use
of xstrlcpy in NFS_HN_DREF may corrupt a struct nfs_args, or
truncate our concocted "hostname:/path" string prematurely if the
nap->hostname field is ever less than 64 bytes long
(MAXHOSTNAMELEN).
* libamu/util.c (xstrlcpy): Return immediately if len is 0 to
avoid unnecessary work. Log an error and return if len is less
than 0.
Erez Zadok [Thu, 7 Apr 2005 23:31:07 +0000 (23:31 +0000)]
* include/am_utils.h (XFREE): XFREE() should nullify the pointer
even when compiling without debugging. It's safer this way.
Erez Zadok [Thu, 7 Apr 2005 23:27:22 +0000 (23:27 +0000)]
update NEWS
Erez Zadok [Thu, 7 Apr 2005 05:52:06 +0000 (05:52 +0000)]
fix typo
Erez Zadok [Thu, 7 Apr 2005 05:50:38 +0000 (05:50 +0000)]
* libamu/xutil.c (am_set_hostname),
hlfsd/stubs.c (nfsproc_lookup_2_svc),
fsinfo/fsinfo.c (fsi_get_args),
fixmount/fixmount.c (is_same_host, remove_mount, main),
conf/mtab/mtab_isc3.c (mnt_dup, mtab_of),
conf/mount/mount_svr4.c (mount_svr4),
conf/mount/mount_linux.c (setup_loop_device),
conf/hn_dref/hn_dref_linux.h (NFS_HN_DREF),
conf/hn_dref/hn_dref_isc3.h (NFS_HN_DREF),
amd/opts.c (expand_op),
amd/ops_nfs.c (mount_nfs_fh),
amd/nfs_subr.c (fh_to_mp3, mp_to_fh),
amd/amfs_host.c (amfs_host_mount),
amd/am_ops.c (merge_opts):
use the new xstrnlen instead of strlen.
* conf/checkmount/checkmount_{default,svr4}.c
(fixmount_check_mount): document why NOT to use xstrnlen.
* libamu/xutil.c: am_hostname need not be MAXHOSTNAMELEN+1 any
more, just MAXHOSTNAMELEN.
* libamu/xutil.c (real_plog): use strlcpy (not xstrlcpy to avoid
recursion, since xstrlcpy may use plog).
Erez Zadok [Thu, 7 Apr 2005 05:09:16 +0000 (05:09 +0000)]
* libamu/util.c (xstrlcpy): truncating a string is serious. Use
XLOG_ERROR not XLOG_WARNING.
Erez Zadok [Thu, 7 Apr 2005 03:50:41 +0000 (03:50 +0000)]
* include/am_utils.h: external definition for new xstrlcpy
function.
* libamu/util.c (xstrlcpy): new function. Similar to strncpy, but
uses strlcpy to guarantee that the resulting string is null
terminated, and also warn if the resulting string was truncated.
* libamu/xutil.c (get_server_pid): move this function from util.c
which is for general-purpose utilities.
* m4/macros/header_templates.m4: template for HAVE_EXTERN_STRLCPY.
* include/am_defs.h: provide extern definition for strlcpy, if
needed.
* libamu/Makefile.am (EXTRA_DIST): include strlcpy.c in distro.
* configure.in: search for strlcpy and its extern.
Erez Zadok [Thu, 7 Apr 2005 03:08:46 +0000 (03:08 +0000)]
* amq/pawd.c (find_mt): It only handles *some* filesystem types,
so it breaks on direct xfs mounts for example. The fix (from
Christos Zoulas) is simple: We need to exclude toplvl to avoid
infinite recursion, but all other fs's are game.
Erez Zadok [Thu, 31 Mar 2005 21:59:42 +0000 (21:59 +0000)]
* amd/nfs_subr.c (fh_to_mp3): strncpy may not null terminate if
copying exactly len bytes, so add null just to be safe.
the memset can be removed because strncpy() should padd the
Daniel Ottavio [Wed, 30 Mar 2005 13:48:33 +0000 (13:48 +0000)]
* amd/nfs_subr.c (fh_to_mp3): Increased the n of strncpy()
to make sure it null terminates.
Daniel Ottavio [Wed, 30 Mar 2005 04:57:39 +0000 (04:57 +0000)]
* amd/nfs_subr.c (fh_to_mp3): Fix memset bug. In this case
the memset can be removed because strncpy() should padd the
buffer with NULLs anyway.
Rainer Orth [Mon, 21 Mar 2005 19:08:05 +0000 (19:08 +0000)]
* include/am_defs.h: Clarify comment.
Erez Zadok [Mon, 21 Mar 2005 17:14:27 +0000 (17:14 +0000)]
* include/am_defs.h: undefine "GROUP" so Solaris 10 with gcc-2.96
won't complain about a conflict for this definition between
<rpcsvc/nis.h> and <sys/acl.h>.
Erez Zadok [Mon, 21 Mar 2005 00:16:53 +0000 (00:16 +0000)]
* amd/readdir.c (amfs_readdir_browsable): use %p, not %lx.
* libamu/mount_fs.c (print_nfs_args): print pointer with %p, not
%lx.
Erez Zadok [Sat, 19 Mar 2005 03:25:02 +0000 (03:25 +0000)]
*******************************************************************
*** Released am-utils-6.1-rc1 ***
*******************************************************************
Erez Zadok [Sat, 19 Mar 2005 03:05:25 +0000 (03:05 +0000)]
* conf/transp/transp_tli.c (get_nfs_version): use proper type for
versout on Solaris (rpcvcers_t).
* amd/mapc.c (mapc_showtypes): if last map type to print, don't
append newline or comma to it.
* libamu/mount_fs.c (print_nfs_args): cast struct netbuf pointer
to %lx because on Solaris 10 sparc gcc-3.4.3 complains about
casting it to an int (size is different).
Erez Zadok [Fri, 18 Mar 2005 14:37:29 +0000 (14:37 +0000)]
* configure.in, NEWS: prepare for 6.1-rc1 release.
* scripts/amd2ldif.in, ldap.schema: fixes by Adam Morley
<adam-at-gmi-dot-com> to synchronize what amd2ldif does vs. what
the ldap.schema expects.
Erez Zadok [Fri, 18 Mar 2005 01:11:33 +0000 (01:11 +0000)]
* amd/map.c (exported_ap_free): We're using a free-list data
structure and re-using malloc'ed objects. So, to be safe, memset
entire structure when it's freed, not just the pointer.
(umount_exported): bug fix to on-exit code. Don't run
am_unmounted() unless unmount_mp() didn't run, since the latter
already calls am_unmounted(). This way we avoid a double-free
bug.
Erez Zadok [Wed, 16 Mar 2005 03:52:56 +0000 (03:52 +0000)]
* tasks: updates. Executable maps is supported. NFSv4 and
FreeBSD autofs isn't.
* Makefile.am (EXTRA_DIST): include FAQ in distro.
* doc/Makefile.am (alldocs): install README.lda and README.osx.
* FAQ: new file, better late than never.
Erez Zadok [Tue, 15 Mar 2005 04:08:26 +0000 (04:08 +0000)]
* scripts/amd2ldif.in: patch to add the amdMapName attribute to
the amdMapTimestamp object when amd2ldif converts it. This is
necessary if you are using type:=auto mounts and want those
mountmaps looked up through LDAP. Patch from Jim Zajkowski
<jim.zajkowski@gmail.com>.
* m4/macros/*.m4: properly quote AC_DEFUN'ed macro name, and fix
regexp/patsubst M4 commands. Newer versions of autoconf (e.g.,
v2.59) complain about those.
Erez Zadok [Sun, 13 Mar 2005 03:36:50 +0000 (03:36 +0000)]
* amd/ops_nfs.c (prime_nfs_fhandle_cache): rearrange code so it's
cleaner.
Erez Zadok [Sun, 13 Mar 2005 03:35:17 +0000 (03:35 +0000)]
* minor new ports: i386-pc-linux-rhel4.
* minor new ports: powerpc-apple-darwin7.8.0.
Erez Zadok [Fri, 11 Mar 2005 03:42:01 +0000 (03:42 +0000)]
* ltmain.sh: upgrade from libtool-1.5.6.
Erez Zadok [Thu, 10 Mar 2005 08:12:34 +0000 (08:12 +0000)]
* m4/macros/check_{fs_mntent,mnttab_type,mount_type}.m4: check for
Linux 2.6 kernel modules, which have a .ko extension, not .o. Now
we can properly detect which file systems exist on Linux 2.6 based
systems (SLES9, RHEL4, Fedora, etc.).
Erez Zadok [Wed, 9 Mar 2005 18:48:59 +0000 (18:48 +0000)]
* m4/macros/host_macros.m4: find out what's the OS software
distribution name, if any.
* m4/macros/header_templates.m4: template for DISTRO_NAME.
* amd/get_args.c (get_version_string): print again full_os, os,
osver, and vendor (bug fix).
(get_version_string): print distribution name, if known (e.g.,
rh9, suse8, etc.).
* amd/mapc.c (mapc_showtypes): wrap around list of supported map.
Erez Zadok [Wed, 9 Mar 2005 02:29:55 +0000 (02:29 +0000)]
* amd/map.c (umount_exported): when unmounting file systems on
exit (when amd.conf global unmount_on_exit=yes), use unmount_mp()
instead of unmount_node() because the latter always unmounts in
the foreground, whereas the former unmounts in the bg/fg as
needed. Unmounting always in the foreground has two problems: (1)
if the unmount hangs, amd hangs, and (2) for type:=program, the
unmount script is execve'd(!) thus replacing the main amd process,
which never gets to finish up, leaving the amd mount points hung.
Erez Zadok [Tue, 8 Mar 2005 07:47:10 +0000 (07:47 +0000)]
match printf format
Erez Zadok [Tue, 8 Mar 2005 06:05:32 +0000 (06:05 +0000)]
* NEWS: mention new feature of executable maps.
* AUTHORS: Acknowledge Erik Kline.
* scripts/amd.conf.5: document executable maps and
exec_map_timeout parameter.
* scripts/amd.conf-sample: examples of an executable map and
exec_map_timeout.
* m4/macros/header_templates.m4: template for HAVE_MAP_EXEC.
* doc/am-utils.texi: document Executable maps and exec_map_timeout
parameter.
* amd/conf.c (gopt_exec_map_timeout): function to parse
exec_map_timeout [global] parameter.
* amd/amd.h (AMFS_EXEC_MAP_TIMEOUT): define default executable map
timeout to 10 seconds, and a global placeholder for the
configurable value.
* amd/amd.c (init_global_options): initialize default executable
map timeout.
* amd/Makefile.am (EXTRA_amd_SOURCES): include info_exec.c in
tarball.
* configure.in: enable executable maps.
* amd/mapc.c: define executable map functions and behavior.
* amd/info_exec.c: executable map implementation from Erik Kline
<ekline at ekline dot com>, modified, cleaned-up, and fixed.
This is not the correct behavior.
Erez Zadok [Tue, 8 Mar 2005 02:51:30 +0000 (02:51 +0000)]
* amd/info_file.c (file_init_or_mtime): consolidate identical
file_init and file_mtime into one function.
Erez Zadok [Sun, 6 Mar 2005 03:19:01 +0000 (03:19 +0000)]
* doc/am-utils.texi (Program Filesystem): if umount/unmount are
not specified, Amd uses "umount ${fs}" by default.
* amd/amfs_program.c (amfs_program_match): if neither unmount nor
umount parameters are specified, use the default userland umount
program with "umount ${fs}". This way type:=program doesn't have
to specify the umount program for basic unmounting actions.
(amfs_program_init): save unmount program string in mf_private
only if it's NULL, not based on mf_refc.
* configure.in: auto-detect name of userland unmount program.
* aux_conf.h.in (UNMOUNT_PROGRAM): macro for default userland
unmount program.
* amd/ops_cachefs.c (cachefs_init): save unmount program string in
mf_private only if it's NULL, not based on mf_refc.
Erez Zadok [Sun, 6 Mar 2005 02:21:28 +0000 (02:21 +0000)]
* configure.in: don't "discover" inheritance file system any more,
since we don't have the .c file for it.
* amd/get_args.c (get_version_string): hack to still show that we
support the inherit file system in output of amd -v.
Ion Badulescu [Sun, 6 Mar 2005 01:26:30 +0000 (01:26 +0000)]
* amd/amfs_inherit.c: removed, dead code
* amd/Makefile.am,
amd/am_ops.c,
amd/amd.h,
conf/autofs/autofs_linux.h,
conf/autofs/autofs_solaris_v1.h,
conf/autofs/autofs_solaris_v2_v3.h,
m4/macros/header_templates.m4: removed references to amfs_inherit.c
Erez Zadok [Sat, 5 Mar 2005 07:09:17 +0000 (07:09 +0000)]
* amd/autil.c (am_mounted): completely rewrite the unmount
no/timeout code to (1) make more sense for odd conditions, and (2)
allow utimeout=N mount options to override FS_NOTIMEOUT default
flags for disk-based file systems such as ufs, pcfs, cdfs, etc.
* libamu/mount_fs.c (mount_fs): use safer XFREE() not free().
* conf/umount/umount_linux.c (umount_fs): strtok is destructive,
so use strdup'ed string.
* conf/mount/mount_linux.c (parse_opts): strtok is destructive, so
use strdup'ed string.
Erez Zadok [Sat, 5 Mar 2005 04:49:16 +0000 (04:49 +0000)]
* scripts/amd.conf.5, doc/am-utils.texi (cache_duration
Parameter): clarify actual behavior: this Parameter affects
initial mount timeout as well as the linear backoff what happens
the initial failed EBUSY unmount.
* doc/am-utils.texi (opts Option): better explanation of
utimeout=N mount pseudo-option.
* amd/amd.h (AM_TTL, AM_TTL_W): better comments, minor cleanup.
Erez Zadok [Fri, 4 Mar 2005 18:42:43 +0000 (18:42 +0000)]
* AUTHORS: add Dan Ottavio.
* scripts/amd.conf.5: document new debug_mtab_file option.
* scripts/amd.conf-sample (debug_mtab_file): show example.
* doc/am-utils.texi (debug_mtab_file Parameter): document new
option.
* conf/mtab/mtab_{file,mach3}.c (open_locked_mtab): if mtab file
doesn't exist by the time Amd tries to exist, return a 0 rather
than hang indefinitely.
* amd/conf.c (gopt_debug_mtab_file): new function to parse
debug_mtab_file option.
* amd/amd.h: placeholder for debug_mtab_file string.
Define default debug_mtab_file to "/tmp/mtab".
* NEWS: document new debug_mtab_file option.
Erez Zadok [Thu, 3 Mar 2005 02:59:02 +0000 (02:59 +0000)]
* conf/transp/transp_{sockets,tli}.c (amu_get_myaddress): when
users want Amd's NFS service to bind to some arbitrary "localhost"
address, show which address was actually resolved and bound to.
Erez Zadok [Wed, 2 Mar 2005 03:00:09 +0000 (03:00 +0000)]
* amd/srvr_nfs.c (start_nfs_pings): move code from elsewhere
(update_nfs_pingval) that initializes the pinger, as well as turns
it on/off as needed, and handles changing its value. This is to
avoid races and other infinite-loop conditions that could result
in ping storms.
* amd/srvr_amfs_auto.c (amfs_generic_find_srvr): when creating a
new file server structure, default the ping value to AM_PINGER
(30sec) and set the FSF_PING_UNINIT flag.
* amd/amd.h (FSF_PING_UNINIT): new flag to tell whether the NFS
pinger had been initialized for a given file server.
* scripts/ctl-amd.in (stop): no need to check if
/var/lock/subsys/amd file exists if you do an rm -f afterward.
Ensure that proper return value is returned from script.
* NEWS, doc/am-utils.texi (opts Option): update meaning of ping=N
so that if N=-1, pings are off; if N=0, pings are set to the
default value (currently 30 seconds).
* amd/nfs_prot_svc.c (nfs_program_2): on TLI system, try to call
__rpc_get_local_uid to verify if the RPC call through the
local host interface came from UID 0.
* configure.in: look for internal libnsl function
__rpc_get_local_uid (seems to be available on all known TLI
systems, Solaris and HP-UX 11).
* conf/transp/transp_tli.c (amu_svc_getcaller): unnecessary
function for TLI systems (and it violated a array's bounds,
discovered with libumem.so).
(bind_resv_port, bind_resv_port_only_udp, get_autofs_address):
just to be on the safe side, set struct t_bind's qlen field to non
zero (64 by default). This value cannot be zero for TCP
connections, and it's unclear if it's good to have it zero for UDP
connections, so setting it to 64 is safer.
Erez Zadok [Mon, 28 Feb 2005 01:38:28 +0000 (01:38 +0000)]
* doc/am-utils.texi (opts Option, Keep-alives): update text on
ping option.
* amd/srvr_nfs.c (update_nfs_pingval): new function to update NFS
server ping values, turn them off, or re-enable them.
(find_nfs_srvr): call update_nfs_pingval() as needed.
Erez Zadok [Sun, 27 Feb 2005 23:53:22 +0000 (23:53 +0000)]
* hlfsd/hlfsd.c (reaper, cleanup): don't use exit(3) in a signal
handler, but use _exit(2) instead.
Erez Zadok [Sun, 27 Feb 2005 23:33:34 +0000 (23:33 +0000)]
update description of _exit(2) fix
Erez Zadok [Sun, 27 Feb 2005 06:42:23 +0000 (06:42 +0000)]
NEWS item for last commit
Erez Zadok [Sun, 27 Feb 2005 06:41:27 +0000 (06:41 +0000)]
* amd/amd.c (parent_exit): This signal handler is called during
Amd initialization. The parent forks a child to do all the hard
automounting work, and waits for a SIGQUIT signal from the child.
When the parent gets the signal it's supposed to call this handler
and exit(3), thus completing the daemonizing process. Alas, on
some systems, especially Linux 2.4/2.6 with Glibc, exit(3) doesn't
always terminate the parent process. Worse, the parent process
now refuses to accept any more SIGQUIT signals -- they are
blocked. What's really annoying is that this doesn't happen all
the time, suggesting a race condition somewhere. (This happens
even if I change the logic to use another signal.) I traced this
to something which exit(3) does in addition to exiting the
process, probably some on_exit() stuff or other side-effects
related to signal handling. Either way, since at this stage the
parent process just needs to exit, a good workaround is to call
the real system call _exit(2). This seems to work reliably all
the time.
* scripts/wait4amd2die.in: change default to recognize that amd is
down more quickly (check every 3 seconds instead of 5).
Erez Zadok [Sun, 27 Feb 2005 04:23:08 +0000 (04:23 +0000)]
* libamu/xutil.c (amu_release_controlling_tty): warn if closing
stdin/stdout/stderr failed. No need for tempfd.
* scripts/ctl-{amd,hlfsd}.in: before running any real program in
these shell scripts, chdir to "/" to avoid possible hangs with
existing NFS mounts. This was causing ctl-amd's forked
grand-child amd process to hang if restartable_mounts=no. Go
figure.
* minor new port ia64-unknown-linux-rhel4
* fsinfo/fsi_util.c (set_ether_if): avoid u_long casting to -1
(RHEL4 gcc 3.4.3 ia64 compiler complains).
Erez Zadok [Thu, 24 Feb 2005 06:30:00 +0000 (06:30 +0000)]
* minor new port i386-unknown-freebsd6.0 (6.0-CURRENT-SNAP001).
* minor new port: i386-pc-linux-rhel3.
* INSTALL: major update of the compatibility list.
* m4/macros/os_cflags.m4: set AMU_CFLAGS not AM_CFLAGS.
Erez Zadok [Wed, 23 Feb 2005 03:59:08 +0000 (03:59 +0000)]
* scripts/amd.conf.5, doc/am-utils.texi (preferred_amq_port):
document new preferred_amq_port [global] option.
* scripts/amd.conf-sample (preferred_amq_port): example.
* include/am_utils.h: add preferred_amq_port to prototype.
* conf/transp/transp_tli.c (bind_preferred_amq_port): new function
to bind the Amq RPC service for UDP and TCP to a preferred port
(or to any port if preferred_amq_port==0).
(create_amq_service): decide if to bind to RPC_ANYFD, or to a
requested port.
* conf/transp/transp_sockets.c (create_amq_service): if
preferred_amq_port is greater than 0, then bind to that port for
both UDP and TCP. If preferred_amq_port==0, then bind to any
port.
* amd/nfs_start.c (mount_automounter): pass global
preferred_amq_port value to create_amq_service().
* amd/conf.c (gopt_preferred_amq_port): new function to parse
amd.conf value for preferred_amq_port.
* amd/amd.h: placeholder for preferred_amq_port.
* conf/transp/transp_tli.c (bind_resv_port_only_udp): rename old
bindnfs_port to a more proper name. This function binds the NFS
service to a specified port, and only for UDP.
* conf/transp/transp_tli.c: cleanup some code, rename some
functions, in preparation for RPC amq port specification code.
Erez Zadok [Tue, 22 Feb 2005 01:33:37 +0000 (01:33 +0000)]
cleanups
Erez Zadok [Tue, 22 Feb 2005 01:17:27 +0000 (01:17 +0000)]
go back to libtool 1.4.3
Erez Zadok [Sat, 19 Feb 2005 22:32:20 +0000 (22:32 +0000)]
* ltmain.sh: update from latest libtool version 1.5.6.
* */Makefile.am: don't redefine CFLAGS or LDFLAGS; they are
reserved for users to pass them on the command line. Instead, use
autoconf's internal AM_CFLAGS and AM_LDFLAGS.
* depcomp, install-sh, missing, mkinstalldirs: update from latest
versions of Automake 1.9.2.
* m4/macros/*.m4: properly quote AC_DEFUN'ed macro name. Newer
versions of autoconf (e.g., v2.59) complain about those.
Erez Zadok [Sat, 19 Feb 2005 21:49:01 +0000 (21:49 +0000)]
update from latest automake 1.9.2
Erez Zadok [Sat, 19 Feb 2005 21:38:58 +0000 (21:38 +0000)]
proper m4 quoting, to avoid underquoting errors from newer autoconf