module development
Subsystems (2)
Hi all,
I'm new to this list. I need to develop a module for autofs for a custom fs type, but I'm not really familiar with autofs. I'm supposing to do this I need to do a module like modules/mount_generic.c but with my custom stuff. For the mounting process it's all right, but to umount the fs I also need to do some operations.
There isn't any hook to do my custom operations before or after (in my cas doesn't matter) umounting it?
I'm sorry if this a simple or trivial question, but I didn't found how to do this as a module.
Thank you all,
Jordi
Signature · 11 lines
......................................................................
__
/ / Jordi Prats Català
C E / S / C A Departament de Sistemes
/_/ Centre de Supercomputació de Catalunya
Gran Capità, 2-4 (Edifici Nexus) · 08034 Barcelona
T. 93 205 6464 · F. 93 205 6979 · [email protected]
......................................................................
pgp:0x5D0D1321
......................................................................Ian Kent
maintainerQuoted 7 lines · Jordi Prats
Hi all,
I'm new to this list. I need to develop a module for autofs for a custom fs type, but I'm not really familiar with autofs. I'm supposing to do this I need to do a module likemodules/mount_generic.cbut with my custom stuff. For the mounting process it's all right, but to umount the fs I also need to do some operations.
Quoted 5 lines
There isn't any hook to do my custom operations before or after (in my cas doesn't matter) umounting it?
I'm sorry if this a simple or trivial question, but I didn't found how to do this as a module.
Your right, at this stage there isn't an entry point for the umount operation.
Ian
Hi all,
I have modified autofs's source code to create an entry point for the umount operation. Here I attach a patch for autofs-4.1.4
This patch will allow to create a custom umount operation. In my case I need to perform an operation before mounting the fs and after. So, I think this could help others.
What I need to do to contribute this code?
Thank you,
Signature · 9 lines
......................................................................
__
/ / Jordi Prats
C E / S / C A Dept. de Sistemes
/_/ Centre de Supercomputació de Catalunya
Gran Capità, 2-4 (Edifici Nexus) · 08034 Barcelona
T. 93 205 6464 · F. 93 205 6979 · [email protected]
...................................................................... Quoted 12 lines · Ian Kent
Quoted 10 lines · Jordi Prats
Hi all,
I'm new to this list. I need to develop a module for autofs for a custom fs type, but I'm not really familiar with autofs. I'm supposing to do this I need to do a module likemodules/mount_generic.cbut with my custom stuff. For the mounting process it's all right, but to umount the fs I also need to do some operations.There isn't any hook to do my custom operations before or after (in my cas doesn't matter) umounting it?
Quoted 13 lines
Quoted 3 lines
I'm sorry if this a simple or trivial question, but I didn't found how to do this as a module.
Your right, at this stage there isn't an entry point for the umount operation.
Ian
config.log +537 -0
@@ -0,0 +1,537 @@ +This file contains any messages produced by compilers while +running configure, to aid debugging if configure makes a mistake. + +It was created by configure, which was +generated by GNU Autoconf 2.59. Invocation command line was + + $ ./configure + +## --------- ## +## Platform. ## +## --------- ## + +hostname = inf12 +uname -m = i686 +uname -r = 2.6.19-1.2911.fc6xen +uname -s = Linux +uname -v = #1 SMP Sat Feb 10 16:09:50 EST 2007 + +/usr/bin/uname -p = unknown +/bin/uname -X = unknown + +/bin/arch = i686 +/usr/bin/arch -k = unknown +/usr/convex/getsysinfo = unknown +hostinfo = unknown +/bin/machine = unknown +/usr/bin/oslevel = unknown +/bin/universe = unknown + +PATH: /usr/kerberos/sbin +PATH: /usr/kerberos/bin +PATH: /usr/local/sbin +PATH: /usr/local/bin +PATH: /sbin +PATH: /bin +PATH: /usr/sbin +PATH: /usr/bin +PATH: /root/bin + + +## ----------- ## +## Core tests. ## +## ----------- ## + +configure:1307: checking for binaries in +configure:1309: result: /usr/bin:/bin:/usr/sbin:/sbin +configure:1319: checking for mount +configure:1337: found /bin/mount +configure:1349: result: /bin/mount +configure:1378: checking for umount +configure:1396: found /bin/umount +configure:1408: result: /bin/umount +configure:1437: checking for fsck.ext2 +configure:1455: found /sbin/fsck.ext2 +configure:1467: result: /sbin/fsck.ext2 +configure:1495: checking for fsck.ext3 +configure:1513: found /sbin/fsck.ext3 +configure:1525: result: /sbin/fsck.ext3 +configure:1555: checking if mount accepts the -s option +configure:1562: result: yes +configure:1619: checking for gcc +configure:1635: found /usr/bin/gcc +configure:1645: result: gcc +configure:1889: checking for C compiler version +configure:1892: gcc --version </dev/null >&5 +gcc (GCC) 4.1.1 20070105 (Red Hat 4.1.1-51) +Copyright (C) 2006 Free Software Foundation, Inc. +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +configure:1895: $? = 0 +configure:1897: gcc -v </dev/null >&5 +Using built-in specs. +Target: i386-redhat-linux +Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic --host=i386-redhat-linux +Thread model: posix +gcc version 4.1.1 20070105 (Red Hat 4.1.1-51) +configure:1900: $? = 0 +configure:1902: gcc -V </dev/null >&5 +gcc: '-V' option must have argument +configure:1905: $? = 1 +configure:1928: checking for C compiler default output file name +configure:1931: gcc conftest.c >&5 +configure:1934: $? = 0 +configure:1980: result: a.out +configure:1985: checking whether the C compiler works +configure:1991: ./a.out +configure:1994: $? = 0 +configure:2011: result: yes +configure:2018: checking whether we are cross compiling +configure:2020: result: no +configure:2023: checking for suffix of executables +configure:2025: gcc -o conftest conftest.c >&5 +configure:2028: $? = 0 +configure:2053: result: +configure:2059: checking for suffix of object files +configure:2080: gcc -c conftest.c >&5 +configure:2083: $? = 0 +configure:2105: result: o +configure:2109: checking whether we are using the GNU C compiler +configure:2133: gcc -c conftest.c >&5 +configure:2139: $? = 0 +configure:2143: test -z + || test ! -s conftest.err +configure:2146: $? = 0 +configure:2149: test -s conftest.o +configure:2152: $? = 0 +configure:2165: result: yes +configure:2171: checking whether gcc accepts -g +configure:2192: gcc -c -g conftest.c >&5 +configure:2198: $? = 0 +configure:2202: test -z + || test ! -s conftest.err +configure:2205: $? = 0 +configure:2208: test -s conftest.o +configure:2211: $? = 0 +configure:2222: result: yes +configure:2239: checking for gcc option to accept ANSI C +configure:2309: gcc -c -g -O2 conftest.c >&5 +configure:2315: $? = 0 +configure:2319: test -z + || test ! -s conftest.err +configure:2322: $? = 0 +configure:2325: test -s conftest.o +configure:2328: $? = 0 +configure:2346: result: none needed +configure:2364: gcc -c -g -O2 conftest.c >&5 +conftest.c:2: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'me' +configure:2370: $? = 1 +configure: failed program was: +| #ifndef __cplusplus +| choke me +| #endif +configure:2504: checking for yp_match in -lnsl +configure:2534: gcc -o conftest -g -O2 conftest.c -lnsl >&5 +configure:2540: $? = 0 +configure:2544: test -z + || test ! -s conftest.err +configure:2547: $? = 0 +configure:2550: test -s conftest +configure:2553: $? = 0 +configure:2566: result: yes +configure:2574: checking for res_query in -lresolv +configure:2604: gcc -o conftest -g -O2 conftest.c -lresolv >&5 +configure:2610: $? = 0 +configure:2614: test -z + || test ! -s conftest.err +configure:2617: $? = 0 +configure:2620: test -s conftest +configure:2623: $? = 0 +configure:2636: result: yes +configure:2672: checking for hes_resolve in -lhesiod +configure:2702: gcc -o conftest -g -O2 conftest.c -lhesiod -lresolv >&5 +configure:2708: $? = 0 +configure:2712: test -z + || test ! -s conftest.err +configure:2715: $? = 0 +configure:2718: test -s conftest +configure:2721: $? = 0 +configure:2734: result: yes +configure:2753: checking how to run the C preprocessor +configure:2788: gcc -E conftest.c +configure:2794: $? = 0 +configure:2826: gcc -E conftest.c +conftest.c:18:28: error: ac_nonexistent.h: No such file or directory +configure:2832: $? = 1 +configure: failed program was: +| /* confdefs.h. */ +| +| #define PACKAGE_NAME "" +| #define PACKAGE_TARNAME "" +| #define PACKAGE_VERSION "" +| #define PACKAGE_STRING "" +| #define PACKAGE_BUGREPORT "" +| #define HAVE_MOUNT 1 +| #define PATH_MOUNT "/bin/mount" +| #define HAVE_UMOUNT 1 +| #define PATH_UMOUNT "/bin/umount" +| #define HAVE_E2FSCK 1 +| #define PATH_E2FSCK "/sbin/fsck.ext2" +| #define HAVE_E3FSCK 1 +| #define PATH_E3FSCK "/sbin/fsck.ext3" +| #define HAVE_SLOPPY_MOUNT 1 +| /* end confdefs.h. */ +| #include <ac_nonexistent.h> +configure:2871: result: gcc -E +configure:2895: gcc -E conftest.c +configure:2901: $? = 0 +configure:2933: gcc -E conftest.c +conftest.c:18:28: error: ac_nonexistent.h: No such file or directory +configure:2939: $? = 1 +configure: failed program was: +| /* confdefs.h. */ +| +| #define PACKAGE_NAME "" +| #define PACKAGE_TARNAME "" +| #define PACKAGE_VERSION "" +| #define PACKAGE_STRING "" +| #define PACKAGE_BUGREPORT "" +| #define HAVE_MOUNT 1 +| #define PATH_MOUNT "/bin/mount" +| #define HAVE_UMOUNT 1 +| #define PATH_UMOUNT "/bin/umount" +| #define HAVE_E2FSCK 1 +| #define PATH_E2FSCK "/sbin/fsck.ext2" +| #define HAVE_E3FSCK 1 +| #define PATH_E3FSCK "/sbin/fsck.ext3" +| #define HAVE_SLOPPY_MOUNT 1 +| /* end confdefs.h. */ +| #include <ac_nonexistent.h> +configure:2983: checking for egrep +configure:2993: result: grep -E +configure:2998: checking for ANSI C header files +configure:3023: gcc -c -g -O2 conftest.c >&5 +configure:3029: $? = 0 +configure:3033: test -z + || test ! -s conftest.err +configure:3036: $? = 0 +configure:3039: test -s conftest.o +configure:3042: $? = 0 +configure:3131: gcc -o conftest -g -O2 conftest.c >&5 +conftest.c: In function 'main': +conftest.c:35: warning: incompatible implicit declaration of built-in function 'exit' +configure:3134: $? = 0 +configure:3136: ./conftest +configure:3139: $? = 0 +configure:3154: result: yes +configure:3178: checking for sys/types.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for sys/stat.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for stdlib.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for string.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for memory.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for strings.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for inttypes.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for stdint.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3178: checking for unistd.h +configure:3194: gcc -c -g -O2 conftest.c >&5 +configure:3200: $? = 0 +configure:3204: test -z + || test ! -s conftest.err +configure:3207: $? = 0 +configure:3210: test -s conftest.o +configure:3213: $? = 0 +configure:3224: result: yes +configure:3246: checking rpcsvc/nis.h usability +configure:3258: gcc -c -g -O2 conftest.c >&5 +configure:3264: $? = 0 +configure:3268: test -z + || test ! -s conftest.err +configure:3271: $? = 0 +configure:3274: test -s conftest.o +configure:3277: $? = 0 +configure:3287: result: yes +configure:3291: checking rpcsvc/nis.h presence +configure:3301: gcc -E conftest.c +configure:3307: $? = 0 +configure:3327: result: yes +configure:3362: checking for rpcsvc/nis.h +configure:3369: result: yes +configure:3405: checking for ldap_init in -lldap +configure:3435: gcc -o conftest -g -O2 conftest.c -lldap -llber -lresolv >&5 +configure:3441: $? = 0 +configure:3445: test -z + || test ! -s conftest.err +configure:3448: $? = 0 +configure:3451: test -s conftest +configure:3454: $? = 0 +configure:3467: result: yes +configure:3529: checking for gcc +configure:3555: result: gcc +configure:3799: checking for C compiler version +configure:3802: gcc --version </dev/null >&5 +gcc (GCC) 4.1.1 20070105 (Red Hat 4.1.1-51) +Copyright (C) 2006 Free Software Foundation, Inc. +This is free software; see the source for copying conditions. There is NO +warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +configure:3805: $? = 0 +configure:3807: gcc -v </dev/null >&5 +Using built-in specs. +Target: i386-redhat-linux +Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic --host=i386-redhat-linux +Thread model: posix +gcc version 4.1.1 20070105 (Red Hat 4.1.1-51) +configure:3810: $? = 0 +configure:3812: gcc -V </dev/null >&5 +gcc: '-V' option must have argument +configure:3815: $? = 1 +configure:3818: checking whether we are using the GNU C compiler +configure:3874: result: yes +configure:3880: checking whether gcc accepts -g +configure:3931: result: yes +configure:3948: checking for gcc option to accept ANSI C +configure:4055: result: none needed +configure:4073: gcc -c -g -O2 conftest.c >&5 +conftest.c:2: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'me' +configure:4079: $? = 1 +configure: failed program was: +| #ifndef __cplusplus +| choke me +| #endif +configure:4219: checking whether gcc -fPIE works +configure:4244: gcc -o conftest -fPIE -pie conftest.c >&5 +configure:4247: $? = 0 +configure:4249: ./conftest +configure:4252: $? = 0 +configure:4265: result: yes +configure:4279: checking location of the init.d directory +configure:4285: result: /etc/init.d +configure:4358: creating ./config.status + +## ---------------------- ## +## Running config.status. ## +## ---------------------- ## + +This file was extended by config.status, which was +generated by GNU Autoconf 2.59. Invocation command line was + + CONFIG_FILES = + CONFIG_HEADERS = + CONFIG_LINKS = + CONFIG_COMMANDS = + $ ./config.status + +on inf12 + +config.status:661: creating Makefile.conf +config.status:764: creating include/config.h + +## ---------------- ## +## Cache variables. ## +## ---------------- ## + +ac_cv_c_compiler_gnu=yes +ac_cv_env_CC_set= +ac_cv_env_CC_value= +ac_cv_env_CFLAGS_set= +ac_cv_env_CFLAGS_value= +ac_cv_env_CPPFLAGS_set= +ac_cv_env_CPPFLAGS_value= +ac_cv_env_CPP_set= +ac_cv_env_CPP_value= +ac_cv_env_LDFLAGS_set= +ac_cv_env_LDFLAGS_value= +ac_cv_env_build_alias_set= +ac_cv_env_build_alias_value= +ac_cv_env_host_alias_set= +ac_cv_env_host_alias_value= +ac_cv_env_target_alias_set= +ac_cv_env_target_alias_value= +ac_cv_exeext= +ac_cv_header_inttypes_h=yes +ac_cv_header_memory_h=yes +ac_cv_header_rpcsvc_nis_h=yes +ac_cv_header_stdc=yes +ac_cv_header_stdint_h=yes +ac_cv_header_stdlib_h=yes +ac_cv_header_string_h=yes +ac_cv_header_strings_h=yes +ac_cv_header_sys_stat_h=yes +ac_cv_header_sys_types_h=yes +ac_cv_header_unistd_h=yes +ac_cv_lib_hesiod_hes_resolve=yes +ac_cv_lib_ldap_ldap_init=yes +ac_cv_lib_nsl_yp_match=yes +ac_cv_lib_resolv_res_query=yes +ac_cv_objext=o +ac_cv_path_E2FSCK=/sbin/fsck.ext2 +ac_cv_path_E3FSCK=/sbin/fsck.ext3 +ac_cv_path_MOUNT=/bin/mount +ac_cv_path_UMOUNT=/bin/umount +ac_cv_prog_CPP='gcc -E' +ac_cv_prog_ac_ct_CC=gcc +ac_cv_prog_cc_g=yes +ac_cv_prog_cc_stdc= +ac_cv_prog_egrep='grep -E' + +## ----------------- ## +## Output variables. ## +## ----------------- ## + +CC='gcc' +CFLAGS='-fPIE' +CPP='gcc -E' +CPPFLAGS='' +DAEMON_CFLAGS='-fPIE' +DAEMON_LDFLAGS='-pie' +DEFS='-DHAVE_CONFIG_H' +E2FSCK='/sbin/fsck.ext2' +E3FSCK='/sbin/fsck.ext3' +ECHO_C='' +ECHO_N='-n' +ECHO_T='' +EGREP='grep -E' +EXEEXT='' +HAVE_E2FSCK='1' +HAVE_E3FSCK='1' +HAVE_HESIOD='1' +HAVE_LDAP='1' +HAVE_MOUNT='1' +HAVE_NISPLUS='1' +HAVE_UMOUNT='1' +HESIOD_FLAGS='' +LDAP_FLAGS='' +LDFLAGS='-pie' +LIBHESIOD=' -lhesiod' +LIBLDAP=' -lldap -llber -lresolv' +LIBNSL='-lnsl' +LIBOBJS='' +LIBRESOLV='-lresolv' +LIBS='' +LTLIBOBJS='' +MOUNT='/bin/mount' +OBJEXT='o' +PACKAGE_BUGREPORT='' +PACKAGE_NAME='' +PACKAGE_STRING='' +PACKAGE_TARNAME='' +PACKAGE_VERSION='' +PATH_SEPARATOR=':' +SHELL='/bin/sh' +UMOUNT='/bin/umount' +ac_ct_CC='gcc' +bindir='${exec_prefix}/bin' +build_alias='' +datadir='${prefix}/share' +exec_prefix='${prefix}' +host_alias='' +includedir='${prefix}/include' +infodir='${prefix}/info' +initdir='/etc/init.d' +libdir='${exec_prefix}/lib' +libexecdir='${exec_prefix}/libexec' +localstatedir='${prefix}/var' +mandir='${prefix}/man' +oldincludedir='/usr/include' +prefix='/usr' +program_transform_name='s,x,x,' +sbindir='${exec_prefix}/sbin' +sharedstatedir='${prefix}/com' +sysconfdir='${prefix}/etc' +target_alias='' + +## ----------- ## +## confdefs.h. ## +## ----------- ## + +#define HAVE_E2FSCK 1 +#define HAVE_E3FSCK 1 +#define HAVE_INTTYPES_H 1 +#define HAVE_MEMORY_H 1 +#define HAVE_MOUNT 1 +#define HAVE_SLOPPY_MOUNT 1 +#define HAVE_STDINT_H 1 +#define HAVE_STDLIB_H 1 +#define HAVE_STRINGS_H 1 +#define HAVE_STRING_H 1 +#define HAVE_SYS_STAT_H 1 +#define HAVE_SYS_TYPES_H 1 +#define HAVE_UMOUNT 1 +#define HAVE_UNISTD_H 1 +#define PACKAGE_BUGREPORT "" +#define PACKAGE_NAME "" +#define PACKAGE_STRING "" +#define PACKAGE_TARNAME "" +#define PACKAGE_VERSION "" +#define PATH_E2FSCK "/sbin/fsck.ext2" +#define PATH_E3FSCK "/sbin/fsck.ext3" +#define PATH_MOUNT "/bin/mount" +#define PATH_UMOUNT "/bin/umount" +#define STDC_HEADERS 1 + +configure: exit 0
config.status +933 -0
933 lines not on this page · raw message
daemon/automount.c +1 -25
@@ -139,31 +139,7 @@static int umount_ent (const char *root,const char *name,const char *type) { -char path_buf[PATH_MAX ]; -struct stat st; -int sav_errno; -int is_smbfs = (strcmp (type,"smbfs" ) ==0 ); -int status; -int rv =0 ; - -sprintf (path_buf,"%s/%s" , root, name); - status =lstat (path_buf, &st); - sav_errno = errno; - -/* EIO appears to correspond to an smb mount that has gone away */ -if (!status || - (is_smbfs && (sav_errno ==EIO || sav_errno ==EBADSLT ))) { -int umount_ok =0 ; - -if (!status && (S_ISDIR (st.st_mode) && (st.st_dev != ap.dev))) - umount_ok =1 ; - -if (umount_ok || is_smbfs) { - rv =spawnll (LOG_DEBUG , -PATH_UMOUNT ,PATH_UMOUNT , path_buf,NULL ); - } - } -return rv; +return do_umount (root, name, type); }/* Like ftw, except fn gets called twice: before a directory is
daemon/Makefile +2 -2
@@ -6,8 +6,8 @@ -include ../Makefile.conf include ../Makefile.rules -SRCS = automount.c spawn.c module.c mount.c -OBJS = automount.o spawn.o module.o mount.o +SRCS = automount.c spawn.c module.c mount.c umount.c +OBJS = automount.o spawn.o module.o mount.o umount.o version := $(shell cat ../.version)
daemon/module.c +69 -0
75 lines not on this page · raw message
daemon/umount.c +63 -0
63 lines not on this page · raw message
daemon/umount.c~ +64 -0
64 lines not on this page · raw message
include/automount.h +13 -0
@@ -130,6 +130,9 @@int signal_children (int sig);int do_mount (const char *root,const char *name,int name_len,const char *what,const char *fstype,const char *options); + +int do_umount (const char *root,const char *name,const char *type); +int mkdir_path (const char *path,mode_t mode);int rmdir_path (const char *path);
@@ -200,22 +203,32 @@int mount_init (void **context);int mount_mount (const char *root,const char *name,int name_len,const char *what,const char *fstype,const char *options,void *context); + +int mount_umount (const char *root,const char *name,int name_len, +const char *fstype,void *context); +int mount_done (void *context);#endif typedef int (*mount_init_t ) (void **);typedef int (*mount_mount_t ) (const char *,const char *,int ,const char *,const char *,const char *,void *); + +typedef int (*mount_umount_t ) (const char *,const char *,int ,const char *, +void *); +typedef int (*mount_done_t ) (void *);struct mount_mod {mount_init_t mount_init;mount_mount_t mount_mount; +mount_umount_t mount_umount;mount_done_t mount_done;void *dlhandle;void *context; };struct mount_mod *open_mount (const char *name,const char *err_prefix); +struct mount_mod *open_umount (const char *name,const char *err_prefix);int close_mount (struct mount_mod *);/* mapent cache definition */
include/config.h +28 -0
@@ -0,0 +1,28 @@ +/* include/config.h. Generated by configure. */ +#ident "$Id: config.h.in,v 1.4 2004/02/03 15:23:21 raven Exp $" +/* -*- c -*- +* +* config.h.in: Pattern file for autofs to be filled in by configure +* +*/ + +/* Program paths */ +#define HAVE_MOUNT 1 +#define PATH_MOUNT "/bin/mount" + +#define HAVE_UMOUNT 1 +#define PATH_UMOUNT "/bin/umount" + +/* #undef HAVE_SMBMOUNT */ +/* #undef PATH_SMBMOUNT */ + +#define HAVE_E2FSCK 1 +#define PATH_E2FSCK "/sbin/fsck.ext2" + +#define HAVE_E3FSCK 1 +#define PATH_E3FSCK "/sbin/fsck.ext3" + +/* Define this option if mount(8) supports the -s (sloppy) option */ +#define HAVE_SLOPPY_MOUNT 1 + +/* #undef ENABLE_EXT_ENV */
Makefile.conf +60 -0
60 lines not on this page · raw message
modules/Makefile +2 -2
@@ -10,13 +10,13 @@ lookup_multi.c \ parse_sun.c \ mount_generic.c mount_nfs.c mount_afs.c mount_autofs.c \ - mount_changer.c mount_bind.c + mount_changer.c mount_bind.c umount_generic.c MODS := lookup_yp.so lookup_file.so lookup_program.so lookup_userhome.so \ lookup_multi.so \ parse_sun.so \ mount_generic.so mount_nfs.so mount_afs.so mount_autofs.so \ - mount_changer.so mount_bind.so + mount_changer.so mount_bind.so umount_generic.so ifeq ($(EXT2FS), 1) SRCS += mount_ext2.c
modules/#umount_generic.# +1 -0
@@ -0,0 +1 @@ +-cn
modules/umount_generic.c +73 -0
73 lines not on this page · raw message
modules/umount_generic.c~ +74 -0
74 lines not on this page · raw message
samples/autofs-ldap-auto-master +17 -0
@@ -0,0 +1,17 @@ +ELF �4 4 ( 4 4�4�� � �� � �� � � ȫȫp � � ܫܫ� � ( (�(� Q�td /lib/ld-linux.so.2 GNU � �M # ��|CE��K��8��qX������2����� N � � + � � ! ~ g � [ C � � J � � � s � � u a e b I � � 9 ^ � � � 9 5 � w _ � + � $ � � B } � b � ; R W � H� ��� 8� ��* ȑ p <� � 8� ��� � + � �� C 8� i @� libldap-2.3.so.0 __gmon_start__ _Jv_RegisterClasses ldap_msgfree ldap_get_dn ldap_simple_bind_s ldap_control_free ldap_next_entry ldap_value_free ldap_search_ext_s ldap_err2string ldap_memfree ldap_first_entry _fini ldap_init ldap_get_values ldap_unbind ldap_set_option liblber-2.3.so.0 libc.so.6 _IO_stdin_used setlocale optind strrchr __strdup memset getopt optarg stderr fwrite strchr fprintf __libc_start_main snprintf _edata __bss_start _end GLIBC_2.0 ii � �� 8�$ <� @�% Ĭ Ȭ ̬ Ь Ԭ ج ܬ � � + � � � �� �� �� � � � � � � � � � $� (� ,� U����� �P �K + �� �5���%�� �%Ĭh ������%Ȭh ������%̬h ������%Ьh �����%Ԭh �����%جh( �����%ܬh0 �����%�h8 �p����%�h@ �`����%�hH �P����%�hP �@����%�hX �0����%��h` � ����%��hh �����%��hp � ����% �hx ������%�h� ������%�h� ������%�h� ������%�h� �����%�h� �����%�h� �����%�h� �����% �h� �p����%$�h� �`����%(�h� �P����%,�h� �@��� 1�^����PTRh �h�QVh���������U��S��� [�È# ��������t�2���X[�Ð�����U����=D� t����4��ҡ4����u��D��ÐU����ث��t� ��t �$ث���Ð������������U��W��V��S��\ �����$t DŽ$X DŽ$T �D$D�D$EDŽ$P �D$� �D$ �$�����$�������$D ��$| �$�����\$�\$D�t$��$D �|$��$X DŽ$L �D$Б��$H �D$ �$�c�����$P �D$(��$T �D$$ �D$ �D$�|$�D$ �t$�\$�D$ �D$ �,$������t�D$8 �D$8��\ [^_]Ë�$P �,$�D$�3�����t҉D$�,$�������D$4t��8 t���$p �D$��D$ �$�D$������$D �$������$H �$������$X ��t�$����DŽ$X ��$T ��t�$����DŽ$T ��$P ��t�$�����DŽ$P ��$x �$�,�����$D ��$| �$����DŽ$L �D$$ �D$ �|$�D$ ��$H ��$P �D$(��$T �D$�D$4�t$�\$�D$ �D$�,$�2������������$P �,$�D$������D$8 ����u� �t$�,$�x�������t��$x �t$�,$�D$�;����t$�,$�Ë�$| �D$�"����ۉ�t4���t&��t"� ��t�D$�T$�$�������D$8 �$������t��<$�����t&