Skip to content

SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.

mount: accept all extra mount options

chrislu8e81619d0260
diff --git a/weed/command/fuse.go b/weed/command/fuse.go
index a0dcaa86ca..c686f9b421 100644
--- a/weed/command/fuse.go
+++ b/weed/command/fuse.go
@@ -190,6 +190,8 @@ func runFuse(cmd *Command, args []string) bool {
}
case "fusermount.path":
fusermountPath = parameter.value
+ default:
+ mountOptions.extraOptions = append(mountOptions.extraOptions, fmt.Sprintf("%s:%s", parameter.name, parameter.value))
}
}
diff --git a/weed/command/mount.go b/weed/command/mount.go
index 0046ca03d0..028757c253 100644
--- a/weed/command/mount.go
+++ b/weed/command/mount.go
@@ -31,6 +31,7 @@ type MountOptions struct {
debugPort *int
localSocket *string
disableXAttr *bool
+ extraOptions []string
}
var (
diff --git a/weed/command/mount_std.go b/weed/command/mount_std.go
index 5226e708ba..40b285ccf1 100644
--- a/weed/command/mount_std.go
+++ b/weed/command/mount_std.go
@@ -166,7 +166,7 @@ func RunMount(option *MountOptions, umask os.FileMode) bool {
// mount fuse
fuseMountOptions := &fuse.MountOptions{
AllowOther: *option.allowOthers,
- Options: nil,
+ Options: option.extraOptions,
MaxBackground: 128,
MaxWrite: 1024 * 1024 * 2,
MaxReadAhead: 1024 * 1024 * 2,