1. 14 Dec, 2009 1 commit
  2. 13 Nov, 2009 1 commit
  3. 28 Sep, 2009 1 commit
    • J. Bruce Fields's avatar
      nfsd4: fix error return when pseudoroot missing · f39bde24
      J. Bruce Fields authored
      
      We really shouldn't hit this case at all, and forthcoming kernel and
      nfs-utils changes should eliminate this case; if it does happen,
      consider it a bug rather than reporting an error that doesn't really
      make sense for the operation (since there's no reason for a server to be
      accepting v4 traffic yet have no root filehandle).
      
      Also move some exp_pseudoroot code into a helper function while we're
      here.
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      f39bde24
  4. 15 Jun, 2009 1 commit
  5. 18 Mar, 2009 1 commit
    • David Shaw's avatar
      Short write in nfsd becomes a full write to the client · 31dec253
      David Shaw authored
      
      If a filesystem being written to via NFS returns a short write count
      (as opposed to an error) to nfsd, nfsd treats that as a success for
      the entire write, rather than the short count that actually succeeded.
      
      For example, given a 8192 byte write, if the underlying filesystem
      only writes 4096 bytes, nfsd will ack back to the nfs client that all
      8192 bytes were written.  The nfs client does have retry logic for
      short writes, but this is never called as the client is told the
      complete write succeeded.
      
      There are probably other ways it could happen, but in my case it
      happened with a fuse (filesystem in userspace) filesystem which can
      rather easily have a partial write.
      
      Here is a patch to properly return the short write count to the
      client.
      Signed-off-by: default avatarDavid Shaw <dshaw@jabberwocky.com>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      31dec253
  6. 07 Jan, 2009 1 commit
  7. 29 Sep, 2008 1 commit
    • J. Bruce Fields's avatar
      nfsd: permit unauthenticated stat of export root · 04716e66
      J. Bruce Fields authored
      
      RFC 2623 section 2.3.2 permits the server to bypass gss authentication
      checks for certain operations that a client may perform when mounting.
      In the case of a client that doesn't have some form of credentials
      available to it on boot, this allows it to perform the mount unattended.
      (Presumably real file access won't be needed until a user with
      credentials logs in.)
      
      Being slightly more lenient allows lots of old clients to access
      krb5-only exports, with the only loss being a small amount of
      information leaked about the root directory of the export.
      
      This affects only v2 and v3; v4 still requires authentication for all
      access.
      
      Thanks to Peter Staubach testing against a Solaris client, which
      suggesting addition of v3 getattr, to the list, and to Trond for noting
      that doing so exposes no additional information.
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      Cc: Peter Staubach <staubach@redhat.com>
      Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
      04716e66
  8. 23 Jun, 2008 2 commits
    • Miklos Szeredi's avatar
      nfsd: rename MAY_ flags · 8837abca
      Miklos Szeredi authored
      
      Rename nfsd_permission() specific MAY_* flags to NFSD_MAY_* to make it
      clear, that these are not used outside nfsd, and to avoid name and
      number space conflicts with the VFS.
      
      [comment from hch: rename MAY_READ, MAY_WRITE and MAY_EXEC as well]
      Signed-off-by: default avatarMiklos Szeredi <mszeredi@suse.cz>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      8837abca
    • NeilBrown's avatar
      knfsd: nfsd: Handle ERESTARTSYS from syscalls. · 599eb304
      NeilBrown authored
      
      OCFS2 can return -ERESTARTSYS from write requests (and possibly
      elsewhere) if there is a signal pending.
      
      If nfsd is shutdown (by sending a signal to each thread) while there
      is still an IO load from the client, each thread could handle one last
      request with a signal pending.  This can result in -ERESTARTSYS
      which is not understood by nfserrno() and so is reflected back to
      the client as nfserr_io aka -EIO.  This is wrong.
      
      Instead, interpret ERESTARTSYS to mean "try again later" by returning
      nfserr_jukebox.  The client will resend and - if the server is
      restarted - the write will (hopefully) be successful and everyone will
      be happy.
      
       The symptom that I narrowed down to this was:
          copy a large file via NFS to an OCFS2 filesystem, and restart
          the nfs server during the copy.
          The 'cp' might get an -EIO, and the file will be corrupted -
          presumably holes in the middle where writes appeared to fail.
      Signed-off-by: default avatarNeil Brown <neilb@suse.de>
      Signed-off-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      599eb304
  9. 15 Feb, 2008 1 commit
  10. 17 Jul, 2007 1 commit
  11. 09 May, 2007 1 commit
    • Jeff Layton's avatar
      RPC: add wrapper for svc_reserve to account for checksum · cd123012
      Jeff Layton authored
      When the kernel calls svc_reserve to downsize the expected size of an RPC
      reply, it fails to account for the possibility of a checksum at the end of
      the packet.  If a client mounts a NFSv2/3 with sec=krb5i/p, and does I/O
      then you'll generally see messages similar to this in the server's ring
      buffer:
      
      RPC request reserved 164 but used 208
      
      While I was never able to verify it, I suspect that this problem is also
      the root cause of some oopses I've seen under these conditions:
      
      https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=227726
      
      
      
      This is probably also a problem for other sec= types and for NFSv4.  The
      large reserved size for NFSv4 compound packets seems to generally paper
      over the problem, however.
      
      This patch adds a wrapper for svc_reserve that accounts for the possibility
      of a checksum.  It also fixes up the appropriate callers of svc_reserve to
      call the wrapper.  For now, it just uses a hardcoded value that I
      determined via testing.  That value may need to be revised upward as things
      change, or we may want to eventually add a new auth_op that attempts to
      calculate this somehow.
      
      Unfortunately, there doesn't seem to be a good way to reliably determine
      the expected checksum length prior to actually calculating it, particularly
      with schemes like spkm3.
      Signed-off-by: default avatarJeff Layton <jlayton@redhat.com>
      Acked-by: default avatarNeil Brown <neilb@suse.de>
      Cc: Trond Myklebust <trond.myklebust@fys.uio.no>
      Acked-by: default avatarJ. Bruce Fields <bfields@citi.umich.edu>
      Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
      cd123012
  12. 12 Feb, 2007 1 commit
  13. 20 Oct, 2006 3 commits
  14. 04 Oct, 2006 3 commits
  15. 11 Apr, 2006 1 commit
  16. 18 Jan, 2006 1 commit
  17. 22 Jun, 2005 1 commit
  18. 16 Apr, 2005 1 commit
    • Linus Torvalds's avatar
      Linux-2.6.12-rc2 · 1da177e4
      Linus Torvalds authored
      Initial git repository build. I'm not bothering with the full history,
      even though we have it. We can create a separate "historical" git
      archive of that later if we want to, and in the meantime it's about
      3.2GB when imported into git - space that would just make the early
      git days unnecessarily complicated, when we don't have a lot of good
      infrastructure for it.
      
      Let it rip!
      1da177e4