Skip to content
  1. May 30, 2011
    • Boaz Harrosh's avatar
      pnfs-obj: objio_osd device information retrieval and caching · b6c05f16
      Boaz Harrosh authored
      
      
      When a new layout is received in objio_alloc_lseg all device_ids
      referenced are retrieved. The device information is queried for from MDS
      and then the osd_device is looked-up from the osd-initiator library. The
      devices are cached in a per-mount-point list, for later use. At unmount
      all devices are "put" back to the library.
      
      objlayout_get_deviceinfo(), objlayout_put_deviceinfo() middleware
      API for retrieving device information given a device_id.
      
      TODO: The device cache can get big. Cap its size. Keep an LRU and start
            to return devices which were not used, when list gets to big, or
            when new entries allocation fail.
      
      [pnfs-obj: Bugs in new global-device-cache code]
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      [gfp_flags]
      [use global device cache]
      [use layout driver in global device cache]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      b6c05f16
    • Boaz Harrosh's avatar
      pnfs-obj: decode layout, alloc/free lseg · 09f5bf4e
      Boaz Harrosh authored
      
      
      objlayout_alloc_lseg prepares an xdr_stream and calls the
      raid engins objio_alloc_lseg() to allocate a private
      pnfs_layout_segment.
      
      objio_osd.c::objio_alloc_lseg() uses passed xdr_stream to
      decode and store the layout_segment information in an
      objio_segment struct, using the pnfs_osd_xdr.h API for
      the actual parsing the layout xdr.
      
      objlayout_free_lseg calls objio_free_lseg() to free the
      allocated space.
      
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      [gfp_flags]
      [removed "extern" from function definitions]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      09f5bf4e
    • Boaz Harrosh's avatar
      pnfs-obj: pnfs_osd XDR client implementation · f1bc893a
      Boaz Harrosh authored
      
      
      * Add the fs/nfs/objlayout/pnfs_osd_xdr_cli.c file, which will
        include the XDR encode/decode implementations for the pNFS
        client objlayout driver.
      
      [Wrong type in comments]
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      f1bc893a
    • Benny Halevy's avatar
      pnfs-obj: pnfs_osd XDR definitions · 38b7c401
      Benny Halevy authored
      
      
      * Add the pnfs_osd_xdr.h header
      
      * defintions the pnfs_osd_layout structure including all it's
        sub-types and constants.
      * Declare the pnfs_osd_xdr_decode_layout API + all needed
        inline helpers.
      
      * Define the pnfs_osd_deviceaddr structure and all its subtypes and
        constants.
      * Declare API for decoding of a pnfs_osd_deviceaddr from XDR stream.
      
      * Define the pnfs_osd_ioerr structure, its substructures and constants.
      * Declare API for encoding of a pnfs_osd_ioerr into XDR stream.
      
      * Define the pnfs_osd_layoutupdate structure and its substructures.
      * Declare API for encoding of a pnfs_osd_layoutupdate into XDR stream.
      
      [Remove server definitions]
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      38b7c401
    • Benny Halevy's avatar
      pnfs-obj: objlayoutdriver module skeleton · c93407d0
      Benny Halevy authored
      
      
      * Define the PNFS_OBJLAYOUT Kconfig option in the nfs
        master Kconfig file.
      * Add the objlayout driver to the Kernel's Kbuild system.
      * Add the fs/nfs/objlayout/Kbuild file for building the
        objlayoutdriver.ko driver
      * Define fs/nfs/objlayout/objio_osd.c, register the driver on module
        initialization and unregister on exit.
      
      [pnfs-obj: remove of CONFIG_PNFS fallout]
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      [added "unsure" clause]
      [depend on NFS_V4_1]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      c93407d0
    • J. Bruce Fields's avatar
      pnfs: client stats · ae50c0b5
      J. Bruce Fields authored
      
      
      A pNFS client auto-negotiates a lot of features (minorversion level,
      pNFS layout type, etc.).  This is convenient, but makes certain kinds of
      failures hard for a user to detect.
      
      For example, if the client falls back on 4.0, or falls back to MDS IO
      because the user didn't connect to the right iscsi disks before
      mounting, the only symptoms may be reduced performance, which may not be
      noticed till long after the actual failure, and may be difficult for a
      user to diagnose.
      
      However, such "failures" may also be perfectly normal in some cases, so
      we don't want to spam the system logs with them.
      
      One approach would be to put some more information into
      /proc/self/mountstats.
      
      Signed-off-by: default avatarJ. Bruce Fields <bfields@fieldses.org>
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      [pnfs: add commit client stats]
      [fixup data types for "ret" variables in pnfs_try_to* inline funcs.]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      [fix definition of show_pnfs for !CONFIG_PNFS]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      [nfs41: Fix show_sessions in the not CONFIG_NFS_V4_1 case]
          There is a build error when CONFIG_NFS_V4 is set but
          CONFIG_NFS_V4_1 is *not* set. show_sessions() prototype
          was unbalanced between the two cases.
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      [pnfs: super.c remove CONFIG_PNFS]
      Signed-off-by: default avatarAndy Adamson <andros@netapp.com>
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      ae50c0b5
    • Benny Halevy's avatar
      pnfs: Use byte-range for cb_layoutrecall · 778b5502
      Benny Halevy authored
      
      
      Use recalled range to invalidate particular layout segments in the layout cache.
      
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      778b5502
    • Benny Halevy's avatar
      707ed5fd
    • Benny Halevy's avatar
      pnfs: Use byte-range for layoutget · fb3296eb
      Benny Halevy authored
      
      
      Add offset and count parameters to pnfs_update_layout and use them to get
      the layout in the pageio path.
      
      Order cache layout segments in the following order:
      * offset (ascending)
      * length (descending)
      * iomode (RW before READ)
      
      Test byte range against the layout segment in use in pnfs_{read,write}_pg_test
      so not to coalesce pages not using the same layout segment.
      
      [fix lseg ordering]
      [clean up pnfs_find_lseg lseg arg]
      [remove unnecessary FIXME]
      [fix ordering in pnfs_insert_layout]
      [clean up pnfs_insert_layout]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      fb3296eb
    • Benny Halevy's avatar
      SUNRPC: introduce xdr_init_decode_pages · f7da7a12
      Benny Halevy authored
      
      
      Initialize xdr_stream and xdr_buf using an array of page pointers
      and length of buffer.
      
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      f7da7a12
    • Benny Halevy's avatar
      NFSv4.1: use layout driver in global device cache · 35c8bb54
      Benny Halevy authored
      
      
      pnfs deviceids are unique per server, per layout type.
      struct nfs_client is currently used to distinguish deviceids from
      different nfs servers, yet these may clash between different layout
      types on the same server.  Therefore, use the layout driver associated
      with each deviceid at insertion time to look it up, unhash, or
      delete it.
      
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      35c8bb54
    • Marc Eshel's avatar
      pnfs: CB_NOTIFY_DEVICEID · 1be5683b
      Marc Eshel authored
      
      
      Note: This functionlaity is incomplete as all layout segments referring to
      the 'to be removed device id' need to be reaped, and all in flight I/O drained.
      
      [use be32 res in nfs4_callback_devicenotify]
      [use nfs_client to qualify deviceid for cb_notify_deviceid]
      [use global deviceid cache for CB_NOTIFY_DEVICEID]
      [refactor device cache _lookup_deviceid]
      [refactor device cache _find_get_deviceid]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      [Bug in new global-device-cache code]
      [layout_driver MUST set free_deviceid_node if using dev-cache]
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      1be5683b
    • Benny Halevy's avatar
      NFSv4.1: purge deviceid cache on nfs_free_client · 1775bc34
      Benny Halevy authored
      
      
      Use the pnfs_layoutdriver_type both as a qualifier for the deviceid,
      distinguishing deviceid from different layout types on the server,
      and for freeing the layout-driver allocated structure containing the
      nfs4_deviceid_node.
      
      [BUG in _deviceid_purge_client]
      [layout_driver MUST set free_deviceid_node if using dev-cache]
      [let ver < 4.1 compile]
      Signed-off-by: default avatarBoaz Harrosh <bharrosh@panasas.com>
      [removed EXPORT_SYMBOL_GPL(nfs4_deviceid_purge_client)]
      Signed-off-by: default avatarBenny Halevy <bhalevy@panasas.com>
      1775bc34
  2. May 29, 2011
  3. May 19, 2011
  4. May 18, 2011