1. 02 11月, 2016 1 次提交
  2. 14 7月, 2016 1 次提交
    • A
      nfsd: implement machine credential support for some operations · ed941643
      Andrew Elble 提交于
      This addresses the conundrum referenced in RFC5661 18.35.3,
      and will allow clients to return state to the server using the
      machine credentials.
      
      The biggest part of the problem is that we need to allow the client
      to send a compound op with integrity/privacy on mounts that don't
      have it enabled.
      
      Add server support for properly decoding and using spo_must_enforce
      and spo_must_allow bits. Add support for machine credentials to be
      used for CLOSE, OPEN_DOWNGRADE, LOCKU, DELEGRETURN,
      and TEST/FREE STATEID.
      Implement a check so as to not throw WRONGSEC errors when these
      operations are used if integrity/privacy isn't turned on.
      
      Without this, Linux clients with credentials that expired while holding
      delegations were getting stuck in an endless loop.
      Signed-off-by: NAndrew Elble <aweits@rit.edu>
      Reviewed-by: NJeff Layton <jlayton@redhat.com>
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      ed941643
  3. 22 4月, 2015 1 次提交
  4. 03 2月, 2015 1 次提交
    • C
      nfsd: implement pNFS operations · 9cf514cc
      Christoph Hellwig 提交于
      Add support for the GETDEVICEINFO, LAYOUTGET, LAYOUTCOMMIT and
      LAYOUTRETURN NFSv4.1 operations, as well as backing code to manage
      outstanding layouts and devices.
      
      Layout management is very straight forward, with a nfs4_layout_stateid
      structure that extends nfs4_stid to manage layout stateids as the
      top-level structure.  It is linked into the nfs4_file and nfs4_client
      structures like the other stateids, and contains a linked list of
      layouts that hang of the stateid.  The actual layout operations are
      implemented in layout drivers that are not part of this commit, but
      will be added later.
      
      The worst part of this commit is the management of the pNFS device IDs,
      which suffers from a specification that is not sanely implementable due
      to the fact that the device-IDs are global and not bound to an export,
      and have a small enough size so that we can't store the fsid portion of
      a file handle, and must never be reused.  As we still do need perform all
      export authentication and validation checks on a device ID passed to
      GETDEVICEINFO we are caught between a rock and a hard place.  To work
      around this issue we add a new hash that maps from a 64-bit integer to a
      fsid so that we can look up the export to authenticate against it,
      a 32-bit integer as a generation that we can bump when changing the device,
      and a currently unused 32-bit integer that could be used in the future
      to handle more than a single device per export.  Entries in this hash
      table are never deleted as we can't reuse the ids anyway, and would have
      a severe lifetime problem anyway as Linux export structures are temporary
      structures that can go away under load.
      
      Parts of the XDR data, structures and marshaling/unmarshaling code, as
      well as many concepts are derived from the old pNFS server implementation
      from Andy Adamson, Benny Halevy, Dean Hildebrand, Marc Eshel, Fred Isaman,
      Mike Sager, Ricardo Labiaga and many others.
      Signed-off-by: NChristoph Hellwig <hch@lst.de>
      9cf514cc
  5. 20 11月, 2014 1 次提交
  6. 29 8月, 2014 1 次提交
  7. 09 5月, 2014 1 次提交
  8. 07 5月, 2014 4 次提交
  9. 28 3月, 2014 1 次提交
  10. 13 7月, 2013 1 次提交
    • J
      nfsd4: fix minorversion support interface · 35f7a14f
      J. Bruce Fields 提交于
      You can turn on or off support for minorversions using e.g.
      
      	echo "-4.2" >/proc/fs/nfsd/versions
      
      However, the current implementation is a little wonky.  For example, the
      above will turn off 4.2 support, but it will also turn *on* 4.1 support.
      
      This didn't matter as long as we only had 2 minorversions, which was
      true till very recently.
      
      And do a little cleanup here.
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      35f7a14f
  11. 15 5月, 2013 1 次提交
  12. 13 5月, 2013 2 次提交
  13. 24 2月, 2013 1 次提交
  14. 11 12月, 2012 5 次提交
  15. 28 11月, 2012 3 次提交
  16. 22 8月, 2012 1 次提交
  17. 21 8月, 2012 1 次提交
  18. 25 7月, 2012 2 次提交
  19. 11 7月, 2012 1 次提交
  20. 29 3月, 2012 1 次提交
  21. 08 11月, 2011 2 次提交
  22. 14 9月, 2011 1 次提交
  23. 27 8月, 2011 1 次提交
  24. 05 1月, 2011 1 次提交
  25. 12 10月, 2010 1 次提交
    • J
      nfsd4: expire clients more promptly · ecec6e34
      J. Bruce Fields 提交于
      Expire clients more promptly, at the expense of possibly running the
      laundromat thread more frequently.
      
      Though it's not the default, I'd like it to be feasible to run with a
      lease time of just a few seconds, at which point a minimum 10 second
      wait between laundromat runs seems a little much.
      Signed-off-by: NJ. Bruce Fields <bfields@redhat.com>
      ecec6e34
  26. 30 7月, 2010 1 次提交
    • J
      nfsd4: share file descriptors between stateid's · f9d7562f
      J. Bruce Fields 提交于
      The vfs doesn't really allow us to "upgrade" a file descriptor from
      read-only to read-write, and our attempt to do so in nfs4_upgrade_open
      is ugly and incomplete.
      
      Move to a different scheme where we keep multiple opens, shared between
      open stateid's, in the nfs4_file struct.  Each file will be opened at
      most 3 times (for read, write, and read-write), and those opens will be
      shared between all clients and openers.  On upgrade we will do another
      open if necessary instead of attempting to upgrade an existing open.
      We keep count of the number of readers and writers so we know when to
      close the shared files.
      Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
      f9d7562f
  27. 07 3月, 2010 2 次提交