diff options
author | Stefan Metzmacher <metze@samba.org> | 2007-08-10 09:05:18 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:29:25 -0500 |
commit | d68145a509b3e86e0d5ff44260f968eb1f39dfeb (patch) | |
tree | c2b1209ccea3ef2b36a7be2d84f56645fb375e78 /source3/configure.in | |
parent | b87c0dde7123b7598b49a236a76641846b885bf5 (diff) | |
download | samba-d68145a509b3e86e0d5ff44260f968eb1f39dfeb.tar.gz samba-d68145a509b3e86e0d5ff44260f968eb1f39dfeb.tar.bz2 samba-d68145a509b3e86e0d5ff44260f968eb1f39dfeb.zip |
r24302: add a module that overloads the file_id_create VFS function
and alters the device id depending on the configured algorithm.
The algorithm is configured via "fileid:algorithm":
- "fsname" (default) uses a uint64 hash over the mount point
- "fsid" uses the fsid returned from statfs()
This is needed for "clustering = yes" on some clusterfilesystems
metze
(This used to be commit 30f9171cca3e4f523cde7dfc96096c32e5af50be)
Diffstat (limited to 'source3/configure.in')
-rw-r--r-- | source3/configure.in | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/source3/configure.in b/source3/configure.in index d1ef464202..4029a0a10c 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6236,6 +6236,38 @@ AC_ARG_WITH(python, esac ]) AC_SUBST(PYTHON) + +# Checks for the vfs_fileid module +# Start +AC_CHECK_FUNC(getmntent) + +AC_CHECK_HEADERS(sys/statfs.h) + +AC_MSG_CHECKING([vfs_fileid: checking for statfs() and struct statfs.f_fsid)]) +AC_CACHE_VAL(vfsfileid_cv_statfs,[ + AC_TRY_RUN([ + #include <sys/types.h> + #include <sys/statfs.h> + int main(void) + { + struct statfs fsd; + fsid_t fsid = fsd.f_fsid; + return statfs (".", &fsd); + }], + vfsfileid_cv_statfs=yes, + vfsfileid_cv_statfs=no, + vfsfileid_cv_statfs=cross) +]) +AC_MSG_RESULT($vfsfileid_cv_statfs) + +if test x"$ac_cv_func_getmntent" = x"yes" -a \ + x"$vfsfileid_cv_statfs" = x"yes"; then + default_shared_modules="$default_shared_modules vfs_fileid" +fi +# End +# Checks for the vfs_fileid module + + for i in `echo $default_static_modules | sed -e 's/,/ /g'` do eval MODULE_DEFAULT_$i=STATIC @@ -6356,6 +6388,7 @@ SMB_MODULE(vfs_commit, \$(VFS_COMMIT_OBJ), "bin/commit.$SHLIBEXT", VFS) SMB_MODULE(vfs_gpfs, \$(VFS_GPFS_OBJ), "bin/gpfs.$SHLIBEXT", VFS) SMB_MODULE(vfs_notify_fam, \$(VFS_NOTIFY_FAM_OBJ), "bin/notify_fam.$SHLIBEXT", VFS) SMB_MODULE(vfs_readahead, \$(VFS_READAHEAD_OBJ), "bin/readahead.$SHLIBEXT", VFS) +SMB_MODULE(vfs_fileid, \$(VFS_FILEID_OBJ), "bin/fileid.$SHLIBEXT", VFS) SMB_SUBSYSTEM(VFS,smbd/vfs.o) |