Nfs server on cygwin slow

cygwinnfs

The setup:

We run an instance of cygwin nfsd on a Windows 2008 Server (Xeon 3,2 GHz). There are several Sun Solaris and SunOS machines accessing the shares.

This is the exports file:

/disk3    (rw,all_squash)
/disk2    (rw,all_squash)  

Those paths are soft linked to the relevant cygdrive/d/path/to/dir paths.
Some of the folders contain up to 10k files.

The Problem:

ls -la

on the mounted folder on the sun boxes takes 2 – 3 minutes and the general read performance is really bad.

cat filename

displays the file in slow bursts and this hurts performance on tasks that access those shared files heavily.

Processor load is not the issue, the nfs server idles most of the time, the cygwin tasks never get over 1% load.

Best Answer

There's been some work recently to speed up directory access, which will be in Cygwin 1.7.8. That's expected to be released some time in January, but you could try the latest snapshots at http://www.cygwin.com/snapshots.

Also, you might want to avoid symlinks in the path, as they cause additional overhead. You could mount the directories in question directly in /etc/fstab, like so:

c:/path/to/dir /disk3 ntfs binary 0 0

You could also try switching off the mapping of POSIX permissions to Windows ACLs (which means that permissions will be faked):

c:/path/to/dir /disk3 ntfs binary,noacl 0 0

See http://cygwin.com/cygwin-ug-net/using.html#mount-table for more on this.

In the end, though, Cygwin/Windows just doesn't make a terribly good server system.

Related Topic