Miklos Szeredi
2007-Dec-04 10:03 UTC
[sshfs] sshfs mounted applications fail with "error loading shared libraries"
> On Dec 3, 2007 5:19 AM, Miklos Szeredi <miklos at szeredi.hu> wrote: > > > Yes it is weird. I hope you can help me with this problem as sshfs is > > > so much simpler than nfs. > > > > Can you please do one more thing: start up sshfs normally, then on the > > server do a strace of the sftp-server process: > > > > strace -o /tmp/strace.log -p `pidof sftp-server` > > Attached the sftp-server log.Thanks. I think I can see the explanation. Here's the failure: read(3, "\0\0\0H\3\0\0\3\347\0\0\0003/mnt/exports/tools/"..., 16384) = 140 open("/mnt/exports/tools/ISE9.2i/bin/lin64/libXst_Core.so", O_RDONLY) = 105 close(105) = 0 select(5, [3], [4], NULL, NULL) = 1 (out [4]) write(4, "\0\0\0\30e\0\0\3\347\0\0\0\4\0\0\0\7Failure\0\0\0\0", 28) = 28 The file handle is 105, which suggests, that there's some limit around 100 open files. Looking at the sftp-server source confirms this: Handle handles[100]; So, unfortunately it seems sftp-server can only handle 100 open files at a time. It's easy enough to fix, if you are willing to recompile the sftp-server binary. Miklos
Vasanth Asokan
2007-Dec-06 00:24 UTC
[sshfs] sshfs mounted applications fail with "error loading shared libraries"
On Dec 4, 2007 2:03 AM, Miklos Szeredi <miklos at szeredi.hu> wrote:> > > On Dec 3, 2007 5:19 AM, Miklos Szeredi <miklos at szeredi.hu> wrote: > > > > Yes it is weird. I hope you can help me with this problem as sshfs is > > > > so much simpler than nfs. > > > > > > Can you please do one more thing: start up sshfs normally, then on the > > > server do a strace of the sftp-server process: > > > > > > strace -o /tmp/strace.log -p `pidof sftp-server` > > > > Attached the sftp-server log. > > Thanks. I think I can see the explanation. Here's the failure: > > read(3, "\0\0\0H\3\0\0\3\347\0\0\0003/mnt/exports/tools/"..., 16384) = 140 > open("/mnt/exports/tools/ISE9.2i/bin/lin64/libXst_Core.so", O_RDONLY) = 105 > close(105) = 0 > select(5, [3], [4], NULL, NULL) = 1 (out [4]) > write(4, "\0\0\0\30e\0\0\3\347\0\0\0\4\0\0\0\7Failure\0\0\0\0", 28) = 28 > > The file handle is 105, which suggests, that there's some limit around > 100 open files. Looking at the sftp-server source confirms this: > > Handle handles[100]; > > So, unfortunately it seems sftp-server can only handle 100 open files > at a time. > > It's easy enough to fix, if you are willing to recompile the > sftp-server binary. >Thanks Miklos. I guess arbitrarily increasing the number of handles is not a good long term fix. It is hard to guesstimate how many clients can be supported through a single sshfs mounted file system if there is a fundamental file handle limit in sftp-server. Making it 1000 is going to fail somewhere else down the line. Is that correct? p.s, I am recompiling sftp-server with 1000 handles to verify that at-least I can get one client working.
Maybe Matching Threads
- [Bug 1555] New: add hard link and attribute extensions to sftp-server
- [Bug 1399] New: add statfs extension to sftp-server
- [Bug 1400] New: add atomic rename extension to sftp-server
- Hardlink patches for sftp
- [PATCH 00/18] virtiofs: Fix various races and cleanups round 1