Skip to contentSkip to conversation

autofs fails to recognize filesystems given with LABEL or UUID

PATCH New Matthias Koenig 1 participant 1 message Mar 6, 2007

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 autofs fails to recognize filesystems given with LABEL or UUID

Hi,

after applying the patch autofs-4.1.4-dont_create_remote_dirs.patch we noticed that autofs does not create mountpoints for filessystems, which are specified in fstab with LABEL or UUID. This is because the contained_in_local_fs() function does not recognize the keywords. This also happens in autofs 5.0.1.
Patch to fix this is below.

Matthias

lib/mounts.c +3 -1
Index: autofs-4.1.4/lib/mounts.c
===================================================================
@@ -315,7 +315,9 @@ int contained_in_local_fs(const char *pa
 						ret = 1;
 				} else
 					ret = 1;
-			}
+			} else if (!strncmp("LABEL=", this->fs_name, 6) ||
+				   !strncmp("UUID=", this->fs_name, 5))
+				ret = 1;
 			break;
 		}
 	}

_______________________________________________
autofs mailing list
[email protected]
http://linux.kernel.org/mailman/listinfo/autofs