Search code examples
glusterfs

How can I improve Glusterfs performance with small files?


I am new with glusterfs.

I have two glusterfs server with one volume called vol1. And the vol1 was was mounted with client servers ( using fuse ) which end users where uploading their data.

Here is my issue:- Gulsterfs performance is really poor with smaller files. for an eg:- getting 20 sec to execute "ls -l | wc -l" against 4580 files ( each files less than 10 KB ). On the other hand I didn't have any issue with bigger files size.

It will take few second to execute the same command against the files if i copied those to my root volumes.

My Glusterfs server is running on cloud and both servers has 1GB connectivity. And the version i am using is glusterfs 3.7.16.

I really appreciate if anyone can guide me to improve the gulster performance with samllerfiles


Solution

  • There're some new tuning options in GlusterFs 3.9:

    gluster volume set glustervol1 features.cache-invalidation on
    gluster volume set glustervol1 features.cache-invalidation-timeout 600
    gluster volume set glustervol1 performance.stat-prefetch on
    gluster volume set glustervol1 performance.cache-invalidation on
    #Only for SMB access
    gluster volume set glustervol1 performance.cache-samba-metadata on
    gluster volume set glustervol1 performance.md-cache-timeout 600
    

    It could improve second access to dir, but first listing still very slow.

    Details: http://blog.gluster.org/2016/11/announcing-gluster-3-9/