Functionality
The Directory Auto-Restriping feature will have the following functionality
- When the number of sub files under a directory is more than 50k, it will trigger directory split, i.e. it will become a striped directory with two stripes, and "lfs getdirstripe <dir>" will show it’s in ‘splitting’ status. Then, nearly half of its sub files will be migrated to newly allocated stripe according to their name hash. Later when "lfs getdirstripe <dir>" doesn’t show ‘splitting’, it means sub-files have finished migration. This also applies on striped directory: when the number of sub files under one stripe is more than 50k, this striped directory will be split automatically, the target stripe count will be doubled, but if there aren’t enough MDTs, the target stripe count will be MDT count.
- Directory auto-restripe is done on server, and doesn’t involve client, though it’s triggered by a readdir from client.
- During directory auto-restripe, if some MDS is rebooted, sub file migrations will fail and report error messages, but when MDS gets back, sub file migrations will resume, and auto-restripe will finish.
- Generally Directory auto-restriping is opaque to client, that is, most operations on/under this directory will run like on/under a normal directory, and NFS re-export is supported. In theory, it should be complete opaque, but there may be some corner cases, and will be addressed later.
Test Plan
- Basic functionality test: plain directory auto-restripe; striped directory auto-restripe.
- Directory auto-restripe with concurrent create and unlink.
- Enable directory auto-restripe in racer.sh, but I’m afraid racer.sh is not stable.
- Access NFS re-export during directory auto-restripe.
- Performance test: evaluate system performance drop during directory auto-restripe.
|