won't mount NFS mounts with space in the name
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
autofs5 (Ubuntu) |
Triaged
|
Medium
|
Unassigned |
Bug Description
Binary package hint: autofs5
Using the auto.net file to mount NFS mounts on the local network.
One of the machines (a NAS) has a number of similarly named exports with spaces in the name. autonfs appears to only see the name upto the first space.
The awk script in /etc/auto.net that parses the output of showmount doesn't consider that there may be spaces in the export name.
For example, the Network Recycle Bin's
$ showmount -e korby
Export list for korby:
/Qweb
/Qusb
/Qrecordings
/Qmultimedia
/Qdownload
/Public
/Photos
/Network Recycle Bin 4
/Network Recycle Bin 3
/Network Recycle Bin 1
/Media
/Documents
/DVD_rip
Turns into
$ /etc/auto.net korby
-fstype=
/DVD_rip korby:/DVD_rip \
/Documents korby:/Documents \
/Media korby:/Media \
/Network korby:/Network \
/Network korby:/Network \
/Network korby:/Network \
/Photos korby:/Photos \
/Public korby:/Public \
/Qdownload korby:/Qdownload \
/Qmultimedia korby:/Qmultimedia \
/Qrecordings korby:/Qrecordings \
/Qusb korby:/Qusb \
/Qweb korby:/Qweb
This prevents autofs from mounting any of the korby shares as it finds a duplicate mount (let alone, the mount it thinks it's a duplicate of is invalid as well).
Oct 20 14:50:49 sara-linux automount[21712]: attempting to mount entry /net/korby
Oct 20 14:50:49 sara-linux automount[21712]: lookup_mount: lookup(program): looking up korby
Oct 20 14:50:49 sara-linux automount[21712]: lookup_mount: lookup(program): korby -> -fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): expanded entry: -fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): gathered options: fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): dequote("/DVD_rip") -> /DVD_rip
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): gathered options: fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): dequote(
Oct 20 14:50:49 sara-linux automount[21712]: add_offset_entry: parse(sun): added multi-mount offset /DVD_rip -> -fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): dequote(
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): gathered options: fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): dequote(
Oct 20 14:50:49 sara-linux automount[21712]: add_offset_entry: parse(sun): added multi-mount offset /Documents -> -fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): dequote("/Media") -> /Media
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): gathered options: fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): dequote(
Oct 20 14:50:49 sara-linux automount[21712]: add_offset_entry: parse(sun): added multi-mount offset /Media -> -fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): dequote("/Network") -> /Network
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): gathered options: fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): dequote(
Oct 20 14:50:49 sara-linux automount[21712]: add_offset_entry: parse(sun): added multi-mount offset /Network -> -fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mount: parse(sun): dequote("/Network") -> /Network
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): gathered options: fstype=
Oct 20 14:50:49 sara-linux automount[21712]: parse_mapent: parse(sun): dequote(
Oct 20 14:50:49 sara-linux automount[21712]: parse(sun): syntax error or duplicate offset /Network -> korby:/Network
Oct 20 14:50:49 sara-linux automount[21712]: parse(sun): error adding multi-mount
Oct 20 14:50:49 sara-linux automount[21712]: cache_delete_
Oct 20 14:50:49 sara-linux automount[21712]: cache_delete_
Oct 20 14:50:49 sara-linux automount[21712]: cache_delete_
Oct 20 14:50:49 sara-linux automount[21712]: cache_delete_
Oct 20 14:50:49 sara-linux automount[21712]: dev_ioctl_
Oct 20 14:50:49 sara-linux automount[21712]: failed to mount /net/korby
I will attempt to rewrite the awk to consider the spaces.
ProblemType: BugDistroRelease: Ubuntu 10.04
Package: autofs5 5.0.5-0ubuntu2
ProcVersionSign
Uname: Linux 2.6.35-22-generic x86_64
NonfreeKernelMo
Architecture: amd64
Date: Wed Oct 20 14:43:14 2010Installatio
ProcEnviron:
PATH=(custom, user)
LANG=en_AU.utf8
SHELL=
---
Architecture: amd64DistroRelease: Ubuntu 10.04Installati
NonfreeKernelMo
Package: autofs5 5.0.5-0ubuntu2
PackageArchitec
ProcEnviron:
PATH=(custom, user)
LANG=en_AU.utf8
SHELL=/bin/bash
ProcVersionSign
Uname: Linux 2.6.35-22-generic x86_64
UnreportableReason: This is not a genuine Ubuntu package
UserGroups: adm admin cdrom dialout lpadmin plugdev proxy sambashare
TEST CASE:
Setup a lucid NFS server with the following exports (and associated directories):
/home
"/space filename"
"/space filename2"
Note that "" is important as space is used as a de-limited in /etc/exports
showmount -e <server> from a Lucid client with autofs5 installed shows:
Export list for <server>:
/space filename2 *
/space filename *
/home *
Setup autofs5 with the following line in /etc/auto.master on the client
/net /etc/auto.net
restart autofs
cd /net/<server> fails with 'No such file or directory message'
Removing one of the exports with a space from the NFS server (and restarting autofs on the client) partially fixes the issue; however the "space filename" export is not mounted correctly and is inaccessible:
total 0
drwxr-xr-x 2 root root 0 2010-10-22 09:11 space
drwxr-xr-x 2 root root 0 2010-10-22 09:11 home
description: | updated |
Changed in autofs5 (Ubuntu): | |
status: | Incomplete → Confirmed |
importance: | Undecided → Medium |
status: | Confirmed → Triaged |
Changed in autofs5 (Ubuntu): | |
status: | Triaged → In Progress |
tags: | added: testcase |
Changed in autofs5 (Ubuntu): | |
status: | In Progress → Triaged |
NB: autofs5 is from Maverick as the machine is being updated slowly to maverick. (2G phone connection to internet)