mfspatadmin(1)
β¨ mfspatadmin β¨
okay bestie, welcome to mfspatadmin, aka the MooseFS patterns administration tool π it's part of MooseFS, and it's the little trio of commands that runs the ~vibes~ department for your files. no cap.
πΈ SYNOPSIS πΈ
mfscreatepattern [-?] [-M MOUNTPOINT] -n pattern [-u uid] [-g gid] [-p
priority] [-c storage_class] [-t trash_retention] [-f eattr]
mfsdeletepattern [-?] [-M MOUNTPOINT] -n pattern [-u uid] [-g gid]
mfslistpattern [-?] [-M MOUNTPOINT]
π DESCRIPTION π
So this is a little squad of tools for managing patterns, and patterns are literally the main character move where you override storage classes, trash retention and/or extra attributes whenever a new file gets created or an existing file gets renamed. it's giving "rules for your files, but make them aesthetic" β¨
mfscreatepatternβ adds a new pattern definition, which is described down below πmfsdeletepatternβ removes a specific pattern definition ποΈmfslistpatternβ lists all the pattern definitions π
π OPTIONS π
-nβ defines the pattern that will be matched against file names. it's simple GLOB format (peep the NOTES section below, iykyk). this option is required for the add and delete commands, like you literally cannot skip it fr fr.-uβ defines a user id that has to be equal to the effective user id of whoever creates or renames a file. if you don't specify it, the user id just won't be checked on match. lowkey chill like that.-gβ defines a group id that has to be equal to one of the group ids of the user who creates or renames a file. if you don't specify it, the group id won't be checked on match either.-pβ priority of the match. when more than one pattern matches a file name, the patterns with higher priority take precedence, periodt. priority can be anywhere from0(lowest) to255(highest), and if you don't specify it, the default value of128is used. and heads up π if two or more patterns with the same priority match a file name (both having the highest possible priority for that file), only one of them β unspecified which one β will be used. chaotic but that's the rules bestie.-cβ name of the storage class that will be set on match πΎ-tβ value of the trash retention that will be set on match. the minimum unit is hours, and for how to format the value go look at TIME below π°οΈ-fβ names of flags, separated by commas, that will be set on match. each flag must be preceded with either a'+'or'-'sign, meaning the flag should be set on or off respectively. for descriptions of the flags, refer tomfseattr(1)π·οΈ-Mβ MooseFS mount point. you don't need to specify this if the tool is run inside a MooseFS mounted directory, or if MooseFS is mounted in/mnt/mfs/ποΈ-?β displays a short usage message π«Ά
okay so for the add command, at least one of the-c,-t,-foptions must be defined. not negotiable bestie, it's the vibe check for your create command.
π¦ NOTES π¦
β° TIME β°
For variables that define time without requiring one single, specific unit, time can be defined as a number of seconds or hours (integer), depending on the minimum unit for that variable β or as a time period in one of two possible formats:
first format: #.#T where T is one of: s-seconds, m-minutes, h-hours, d-days or w-weeks. fractions of the minimum unit will be rounded.
second format: #w#d#h#m#s β any number of definitions can be omitted, but the remaining definitions must be in order (so #d#m is still a valid definition, but #m#d is not π
). ranges: s,m: 0 to 59, h: 0 to 23, d: 0 to 6, w is unlimited, and the first definition is also always unlimited (i.e. for #d#h#m, d will be unlimited).
If the minimum unit of a variable is larger than seconds, units below the minimum one will not be accepted. for example, a variable that has hours as its minimum unit will not accept s and m units. sorry bestie, no sneaking around the units π
Examples:
1.5d is the same as 1d12h, is the same as 36h
2.5w is the same as 2w3d12h, is the same as 420h; 2w84h is not a valid
time period (h is not the first definition, so it is bound by range 0 to
23)
π PATTERN DEFINITION π
A pattern is a string with optional wildcards (similar to UNIX glob). Recognized wildcards:
*β matches any number of any characters including none?β matches any single character[abc]β matches one character given in the bracket[FROM-TO]β matches one character from the range given in the bracket[!abc]β matches one character that is not given in the bracket[!FROM-TO]β matches one character that is not from the range given in the bracket
Examples of patterns:
exactnameβ matches file with name'exactname'only*.txtβ matches any'text'file (formally file with name suffix'.txt').myproject*β matches any file with name prefix'myproject'.letter[0-9]β matches files with names'letter0','letter1','letter2', ...'letter9'.[CB]atβ matches files with names'Cat'and'Bat'.[!0-9]*β matches files with names that don't start with a digit
π REPORTING BUGS π
Found a bug? spill the tea to <bugs@moosefs.com> bestie, they wanna know π
π COPYRIGHT π
Copyright (C) 2026 Jakub Kruszona-Zawadzki, Saglabs SA
This file is part of MooseFS.
MooseFS is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2 (only).
MooseFS is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, see <https://www.gnu.org/licenses/>.
β SEE ALSO β
mfsmount(8), mfstools(1), mfssclass(1), mfseattr(1)
and that's the whole page bestie!! β¨ this is MooseFS version 4.59.2-1, from May 2026 β go forth and pattern your little heart out, you got this π«Άππ
π¦ where this page comes from
- arch rolling: moosefs 4.59.2-2 Β· GPL-2.0-only
- nixos 26.05: moosefs 4.59.2
- nixpkgs unstable: moosefs 4.59.2
- ubuntu stonking: moosefs-client 4.59.2-1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms