Skip to content
Snippets Groups Projects
Commit f38724ab authored by Martin Schroschk's avatar Martin Schroschk
Browse files

Merge branch 'lustre-find' into 'preview'

Add good practices

See merge request !656
parents 25c9124c 0c91fcd7
No related branches found
No related tags found
2 merge requests!673Automated merge from preview to main,!656Add good practices
...@@ -21,9 +21,34 @@ marie@login$ lfs setstripe -c 20 /scratch/ws/marie-stripe20/tar ...@@ -21,9 +21,34 @@ marie@login$ lfs setstripe -c 20 /scratch/ws/marie-stripe20/tar
This does not affect existing files. But all files that **will be created** in this This does not affect existing files. But all files that **will be created** in this
directory will be distributed over 20 OSTs. directory will be distributed over 20 OSTs.
## Good Practices
!!! hint "Avoid accessing metadata information"
Querying metadata information such as file and directory attributes is a resource intensive task
in Lustre filesystems. When these tasks are performed frequently or over large directories, it
can degrade the filesystem's performance and thus affect all users.
In this sense, you should minimize the usage of system calls querying or modifying file
and directory attributes, e.g. `stat()`, `statx()`, `open()`, `openat()` etc.
Please, also avoid commands basing on the above mentioned system calls such as `ls -l` and
`ls --color`. Instead, you should invoke `ls` or `ls -l <filename` to reduce metadata operations.
This also holds for commands walking the filesystems recursively performing massive metadata
operations such as `ls -R`, `find`, `locate`, `du` and `df`.
Lustre offers a number of commands that are suited to its architecture.
| Good | Bad |
|:-----|:----|
| `lfs df` | `df` |
| `lfs find` | `find` |
| `ls -l <filename>` | `ls -l` |
| `ls` | `ls --color` |
## Useful Commands for Lustre ## Useful Commands for Lustre
These commands work for `/scratch` and `/ssd`. These commands work for Lustre filesystems `/scratch` and `/ssd`.
### Listing Disk Usages per OST and MDT ### Listing Disk Usages per OST and MDT
......
...@@ -284,6 +284,7 @@ OpenMPI ...@@ -284,6 +284,7 @@ OpenMPI
OpenSSH OpenSSH
Opteron Opteron
OST OST
OSTs
OTF OTF
overfitting overfitting
pandarallel pandarallel
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment