| Summary: | mount.glusterfs mounts to incorrect mount point | ||
|---|---|---|---|
| Product: | [Community] GlusterFS | Reporter: | Krishna Srinivas <krishna> |
| Component: | unclassified | Assignee: | Harshavardhana <fharshav> |
| Status: | CLOSED CURRENTRELEASE | QA Contact: | |
| Severity: | medium | Docs Contact: | |
| Priority: | low | ||
| Version: | mainline | CC: | amarts, cww, gluster-bugs |
| Target Milestone: | --- | ||
| Target Release: | --- | ||
| Hardware: | All | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | Type: | --- | |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
PATCH: http://patches.gluster.com/patch/1011 in master (mount.glusterfs had a problem understanding when "volfile" was given as one of the mount arguments.) :-) done too.. |
following change causes mount point to be incorrect. This is seen when fstab/automount file indicates to read client conf file from a local directory. @@ -175,10 +188,24 @@ function main () -e 's/[,]*volume-id=[^,]*//' \ -e 's/[,]*log-server=[^,]*//' \ -e 's/[,]*log-server-port=[^,]*//'); - # following line is product of love towards sed - # $2=$(echo "$@" | sed -n 's/[^ ]* \([^ ]*\).*/\1/p'); - - mount_point="$2"; + + # + [ -n "$helper" ] && { + cmd_line=$(echo "$cmd_line --$helper"); + exec $cmd_line; + exit 0; + } + + mount_provided=$(echo "$@" | cut -f2 -d'/'); + + [ -n "$mount_provided" ] && { + mount_point="/$mount_provided"; + } + + [ -z "$mount_point" ] && { + usage; + exit 0; + }