nginx static file buffer
        Posted  
        
            by 
                Philip
            
        on Server Fault
        
        See other posts from Server Fault
        
            or by Philip
        
        
        
        Published on 2012-04-11T09:40:05Z
        Indexed on 
            2012/04/11
            11:33 UTC
        
        
        Read the original article
        Hit count: 295
        
nginx
|file-server
I have a nfs which several frontend-servers are connected to for making the files stored on the nfs available for http downloads. It looks like I have problems with the way apache is serving the files, there seems to be a very small buffer or no buffer at all which results in a lot disk seeks. I did some testing with loading the whole requested file into memory at once and serve it to the client from memory. With this technique I need less disk seeks for a download stream.
Since I don't want to implement this by myself for production use I thought that I could maybe use nginx for that because the documentation says that it uses buffers for static file serving.
Is it possible to increase the buffer size to a few mb, if so which config parameter do I have to change for this? Has anyone experience with large buffers for static file serving? Is there a better way to reduce disk seeks?
© Server Fault or respective owner