We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
假设目录d下只有n个文件f,ls d会触发1 opendir + 1 read dir + n getattr fuse调用。 当n很大时,getattr会导致严重的性能问题。
ls d
1 opendir + 1 read dir + n getattr
可以从以下两方面优化:
-omax_stat_cache_size=xxx
ls -f
注:上述数据在centos7.0,fuse2.9.2版本下测得。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
假设目录d下只有n个文件f,
ls d
会触发1 opendir + 1 read dir + n getattr
fuse调用。 当n很大时,getattr会导致严重的性能问题。可以从以下两方面优化:
-omax_stat_cache_size=xxx
参数增大stat cache的size,这样第一次ls会较慢,但是后续的ls就快了,因为文件的元数据都在本地cache中。默认这个值是1000,大约消耗4MB内存,请根据您机器内存大小调整为合适的值。ls -f
命令,这个命令会消除n次getattr调用,提高性能。注:上述数据在centos7.0,fuse2.9.2版本下测得。
The text was updated successfully, but these errors were encountered: