Bug 1169999 - Debian 7 wheezy, /sbin/mount.glusterfs fails to automount and print help
Summary: Debian 7 wheezy, /sbin/mount.glusterfs fails to automount and print help
Keywords:
Status: CLOSED DUPLICATE of bug 1171259
Alias: None
Product: GlusterFS
Classification: Community
Component: scripts
Version: 3.6.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: bugs@gluster.org
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-12-03 00:06 UTC by Tom Downes
Modified: 2014-12-16 12:54 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-12-16 12:54:17 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Tom Downes 2014-12-03 00:06:41 UTC
Description of problem: On Debian 7 wheezy, /sbin/mount.glusterfs does not accept -n option and fails for less than two options (e.g. -h). Makes glusterfs native client unusable in autofs.

Version-Release number of selected component (if applicable): 3.6.1-1

How reproducible: 100%

Steps to Reproduce:
1. Install 3.6.1-1 on Debian wheezy with autofs and glusterfs client
2. Enable verbose logging (/etc/default/autofs and restart service)
3. Create a very basic autofs entry.

dest -fstype=glusterfs houseofbricks:/gvol

4. 

Actual results:

When cd'ing to automount directory:

-bash: cd: dest: Too many levels of symbolic links

In /var/log/syslog

Dec  2 17:23:59 testautofs automount[9114]: spawn_mount: mtab link detected, passing -n to mount
Dec  2 17:23:59 testautofs automount[9114]: >> WARNING: getfattr not found, certain checks will be skipped..
Dec  2 17:23:59 testautofs automount[9114]: >> Illegal option -n
...
Dec  2 17:27:35 testautofs automount[11193]: mounted /spot/dest

(the last line is misleading)

Expected results:
Dec  2 17:54:51 testautofs automount[12189]: attempting to mount entry /spot/dest
Dec  2 17:54:51 testautofs automount[12189]: >> WARNING: getfattr not found, certain checks will be skipped..
Dec  2 17:54:51 testautofs automount[12189]: >> rw
Dec  2 17:54:52 testautofs automount[12189]: mounted /spot/dest

Additional info:

Automounting works after the hackiest of hacks. mount.glusterfs still fails on basic arguments like -h, however, due to lack of error checking on argument list.

*** mount.glusterfs	Wed Nov 12 13:02:44 2014
--- mount.glusterfs.hack	Tue Dec  2 18:04:21 2014
*************** main ()
*** 555,563 ****
          ## `mount` specifies options as a last argument
          shift 2;
      fi
!     while getopts "Vo:h" opt; do
          case "${opt}" in
              o)
                  parse_options ${OPTARG};
  		shift 2;
                  ;;
--- 555,566 ----
          ## `mount` specifies options as a last argument
          shift 2;
      fi
!     while getopts "Vo:hn" opt; do
          case "${opt}" in
+             n)
+                 ;; 
              o)
+     		echo "${OPTARG}" 2>/dev/stderr
                  parse_options ${OPTARG};
  		shift 2;
                  ;;

Comment 1 Tom Downes 2014-12-03 00:11:25 UTC
Woops. This line is one hack too far and can be removed.

+     		echo "${OPTARG}" 2>/dev/stderr

Comment 2 Kaleb KEITHLEY 2014-12-16 12:54:17 UTC
Even though this predates 1171259.

*** This bug has been marked as a duplicate of bug 1171259 ***


Note You need to log in before you can comment on or make changes to this bug.