Cache upload slow if stored on NFS (OD-1952)
jbauer opened 1 month ago

I use OneDev as docker image and storage volume for OneDev is mounted as NFS volume by docker. Docker itself sets a reasonable large NFS rsize and wsize mount options to increase NFS performance by reducing overhead. OneDev agents use local volumes.

However when OneDev Agents uploads the build cache (about 1-2GB) to OneDev server it takes very long. Manually testing NFS share using dd command with different block sizes shows that the block size should not be too small. With a block size of about 64kb NFS performance was ok.

I have seen in OneDev code that OneDev uses similar sized byte buffers but maybe there is (unconfigured) JDK or 3rd party code involved that drops down back to 8kb buffer size which is often the default size in JDK / library code.

Any chance you can check that by looking through the code and also any JDK/library code that is involved in build cache tar/untar/send/receive actions? I feel like OneDev effectively only uses 8kb buffers when working with build cache. Maybe git checkout and writing files to disk might also worth checking.

Just to give you an impression: Cache upload of roughly 2 GB took 12 minutes which equals about 2.8 MB/s. However the NFS server is very well capable of receiving data with 60-80 MB/s when using dd. Given that the build cache is one large tar archive OneDev should produce nearly the same performance.

issue 1 of 1
No labels
Issue Votes (0)
Watchers (2)
Please wait...
Page is in error, reload to recover