DRM(1)
ποΈ drm(1) β distributed remove ποΈ
part of the mpiFileUtils suite, bestie π
β¨ NAME β¨
drm β distributed remove. Yes, it's literally in the name, and yes, it slays.
π SYNOPSIS π
drm [OPTION] PATH...
π DESCRIPTION π
Okay so picture this: drm is a parallel MPI application that recursively deletes a directory and all its contents. It's a tool for removing files recursively in parallel, and it behaves like rm -rf but it is faster. No cap. π₯
DO NOT USE SHELL REGEX!!! The--matchand--excludeoptions use POSIX regex syntax. Because of this, make sure that the shell does not try to interpret your regex before it gets passed to the program. You can generally use quotes around your regex to prevent the shell from expanding. An example of this using the--matchoption with--dryrunwould be:
mpirun -np 128 drm --dryrun -v --name --match 'file_.*'
/path/to/dir/*
Like, literally quote your regex or the shell will eat it alive, bestie. π
πΈ OPTIONS πΈ
-i,--inputFILE β Read source list from FILE. Heads up: FILE must be generated by another tool from the mpiFileUtils suite. Don't just feed it anything, okay? π-o,--outputFILE β Write the list of itemsdrmattempts to delete to FILE in mpiFileUtils format. The format can be changed with the--textoption. Cute. β¨-t,--textβ Must be used with the--outputoption. Write the list of itemsdrmattempts to delete to FILE in ascii text format. Plain and simple, bestie. π-l,--liteβ Walk file system without stat. It's giving low-effort walk, but make it intentional. π¦--statβ Walk file system with stat. The full stat experience. πββοΈ--excludeREGEX β Do not remove items whose full path matches REGEX, processed byregexec(3). Like, leave those alone. π ββοΈ--matchREGEX β Only remove items whose full path matches REGEX, processed byregexec(3). If it matches, it goes. Periodt. π₯--nameβ Change--excludeandmatchto apply to item name rather than its full path. So you can match on the name itself, not the whole path. iykyk. π--dryrunβ Print a list of files that would be deleted without deleting them. This is useful to check the list of items satisfying--excludeor--matchoptions before actually deleting anything. Literally always do a vibe check first. π--aggressiveβ This option will delete files during the walk phase, and then delete directories by level after the walk indrm. You cannot use this option with--dryrun. So no take-backs with this one, bestie. π-T,--tracelessβ Delete child items without updating themtimeon their parent directory. Sneaky and efficient. π§--progressN β Print progress message to stdout approximately every N seconds. The number of seconds must be a non-negative integer. A value of0disables progress messages. So0means no spam, got it. π«Ά-v,--verboseβ Run in verbose mode. Give me all the details, queen. π-q,--quietβ Run tool silently. No output is printed. Shhh. π€«-h,--helpβ Print a brief message listing thedrm(1)options and usage. The classic. π
π¦ EXAMPLES π¦
- To delete a directory and its contents:
mpirun -np 128 drm -v /dir/to/delete
- Delete all items (files and directories) ending with
.corefrom directory tree:
mpirun -np 128 drm --match '.core$' /dir/to/delete/from
- List items that would be deleted without removing them:
mpirun -np 128 drm --dryrun --match '.core$' /dir/to/delete/from
- Delete all items named
foo:
mpirun -np 128 drm --name --match '^foo$' /dir/to/delete/from
π SEE ALSO π
The mpiFileUtils source code and all documentation may be downloaded from <https://github.com/hpc/mpifileutils> β go get your read on, bestie. π
π AUTHOR π
HPC. Icons only. π
π COPYRIGHT π
2022, LLNL/LANL/UT-Battelle/DDN. Respect the copyright, bestie. β¨
xoxo, your drm bestie π
β this was version 0.12, dated Jan 29, 2025. π«Άπ
π¦ where this page comes from
- nixpkgs unstable: mpifileutils 0.12
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms