Provided by: nfstest_3.2-2_all bug

NAME

       nfstest_xattr - Extended Attributes tests

SYNOPSIS

       nfstest_xattr --server <server> [options]

DESCRIPTION

       Verify correct functionality of extended attributes

       Extended   attributes   are   name:value  pairs  associated  permanently  with  files  and
       directories, similar to the environment strings associated with a  process.  An  attribute
       may  be  defined  or  undefined.  If  it  is defined, its value may be empty or non-empty.
       Extended attributes are extensions to the normal attributes which are associated with  all
       inodes  in  the  system.  They  are  often  used  to provide additional functionality to a
       filesystem.

       Tests are divided into five groups: getxattr, setxattr, removexattr, listxattr and  cinfo.
       The  getxattr  tests verify the retrieval of extended attribute values. The setxattr tests
       verify the creation or modification of extended attributes. The removexattr  tests  verify
       the  removal  of  extended  attributes. The listxattr tests verify the listing of extended
       attributes. And finally, the cinfo tests verify the change info returned by the server  is
       correct when the file is either modified or not from a different client.

       Furthermore,  when  a different client is holding a read delegation, verify the delegation
       is recalled only when creating, modifying or removing an extended attribute. On the  other
       hand,  verify  the  read  delegation is not recalled when listing attributes or retrieving
       their values.

       Negative testing is included like retrieval or removal of an extended attribute name which
       does  not  exist.  Creating  an  attribute  which  already  exists should fail while using
       XATTR_CREATE flag. Trying to modify an attribute which does not exist should fail if using
       XATTR_REPLACE flag.

OPTIONS

       --version
              show program's version number and exit

       -h, --help
              show this help message and exit

       -f FILE, --file=FILE
              File  where  options  are specified besides the system wide file /etc/nfstest, user
              wide file $HOME/.nfstest or in the current directory .nfstest file

   NFS specific options:
       -s SERVER, --server=SERVER
              Server name or IP address

       -e EXPORT, --export=EXPORT
              Exported file system to mount [default: '/']

       --nfsversion=NFSVERSION
              NFS version, e.g., 3, 4, 4.1, etc. [default: 4.2]

       -m MTPOINT, --mtpoint=MTPOINT
              Mount point [default: '/mnt/t']

       -p PORT, --port=PORT
              NFS server port [default: 2049]

       --proto=PROTO
              NFS protocol name [default: 'tcp']

       --sec=SEC
              Security flavor [default: 'sys']

       --nconnect=NCONNECT
              Multiple TCP connections option [default: '1']

       -o MTOPTS, --mtopts=MTOPTS
              Mount options [default: 'hard,rsize=4096,wsize=4096']

       --datadir=DATADIR
              Data directory where files are created, directory is created  on  the  mount  point
              [default: '']

   Logging options:
       -v VERBOSE, --verbose=VERBOSE
              Verbose level for debug messages [default: 'opts|info|dbg1|dbg2|dbg3']

       --tverbose=TVERBOSE
              Verbose level for test messages [default: '1']

       --createlog
              Create log file

       --rexeclog
              Create rexec log files

       --warnings
              Display warnings

       --tag=TAG
              Informational tag, it is displayed as an INFO message [default: '']

       --notty
              Do not use terminal colors on output

       --isatty
              Use terminal colors on output -- useful when running with nohup

   Packet trace options:
       --createtraces
              Create a packet trace for each test

       --tbsize=TBSIZE
              Capture buffer size for tcpdump [default: 192k]

       --trcdelay=TRCDELAY
              Seconds to delay before stopping packet trace [default: 2.0]

       --keeptraces
              Do not remove any trace files [default: remove trace files if no errors]

       --rmtraces
              Remove trace files [default: remove trace files if no errors]

       -i INTERFACE, --interface=INTERFACE
              Device interface [default: automatically selected]

   File options:
       --nfiles=NFILES
              Number of files to create [default: 2]

       --filesize=FILESIZE
              File size to use for test files [default: 64k]

       --rsize=RSIZE
              Read size to use when reading files [default: 4k]

       --wsize=WSIZE
              Write size to use when writing files [default: 4k]

       --iodelay=IODELAY
              Seconds to delay I/O operations [default: 0.1]

       --offset-delta=OFFSET_DELTA
              Read/Write offset delta [default: 4k]

   Path options:
       --sudo=SUDO
              Full path of binary for sudo [default: '/usr/bin/sudo']

       --kill=KILL
              Full path of binary for kill [default: '/usr/bin/kill']

       --nfsstat=NFSSTAT
              Full path of binary for nfsstat [default: '/usr/sbin/nfsstat']

       --tcpdump=TCPDUMP
              Full path of binary for tcpdump [default: '/usr/sbin/tcpdump']

       --iptables=IPTABLES
              Full path of binary for iptables [default: '/usr/sbin/iptables']

       --messages=MESSAGES
              Full path of log messages file [default: '/var/log/messages']

       --trcevents=TRCEVENTS
              Full path of tracing events directory [default: '/sys/kernel/debug/tracing/events']

       --trcpipe=TRCPIPE
              Full path of trace pipe file [default: '/sys/kernel/debug/tracing/trace_pipe']

       --tmpdir=TMPDIR
              Temporary directory [default: '/tmp']

   Debug options:
       --nocleanup
              Do not cleanup created files

       --notimestamps
              Do not display timestamps in debug messages

       --bugmsgs=BUGMSGS
              File containing test messages to mark as bugs if they failed

       --nomount
              Do not mount server and run the tests on local disk space

       --basename=BASENAME
              Base name for all files and logs [default: automatically generated]

       --nfsdebug=NFSDEBUG
              Set NFS kernel debug flags and save log messages [default: '']

       --rpcdebug=RPCDEBUG
              Set RPC kernel debug flags and save log messages [default: '']

       --tracepoints=TRACEPOINTS
              List of trace points modules to enable [default: '']

       --nfsstats
              Get NFS stats [default: 'False']

       --pktdisp
              Display main packets related to the given test

       --nfserrors
              Fail every NFS error found in the packet trace

       --client-ipaddr=CLIENT_IPADDR
              IP address of localhost

   Reporting options:
       --xunit-report
              Generate xUnit compatible test report

       --xunit-report-file=XUNIT_REPORT_FILE
              Path to xout report file

   Test options:
       --runtest=RUNTEST
              Comma  separated list of tests to run, if list starts with a '^' then all tests are
              run except the ones listed [default: 'all']

       --num-xattrs=NUM_XATTRS
              Number of extended attributes to create for listxattr tests  with  many  attributes
              [default: 20]

       --client=CLIENT
              Remote NFS client and options used for delegation tests. Clients are separated by a
              ',' and each client definition is a list of arguments separated by a ':'  given  in
              the   following   order   if   positional   arguments   is   used  (see  examples):
              clientname:server:export:nfsversion:port:proto:sec:mtpoint                [default:
              'nfsversion=3:proto=tcp:port=2049']

       --client-nfsvers=CLIENT_NFSVERS
              Comma  separated  list  of valid NFS versions to use in the --client option. An NFS
              version from this list, which is different than  that  given  by  --nfsversion,  is
              selected and included in the --client option [default: 4.0,4.1]

TESTS

   ngetxattr01
       Verify getting extended attribute

   ngetxattr02
       Verify getting extended attribute fails when attribute does not exist

   dgetxattr01
       Verify getting extended attribute
       when delegation is granted on second client

   dgetxattr02
       Verify getting extended attribute fails when attribute does not exist
       when delegation is granted on second client

   nsetxattr01
       Verify setting extended attribute with SETXATTR4_EITHER when attribute does not exist

   nsetxattr02
       Verify setting extended attribute with SETXATTR4_CREATE when attribute does not exist

   nsetxattr03
       Verify setting extended attribute with SETXATTR4_REPLACE fails when attribute does not exist

   nsetxattr04
       Verify setting extended attribute with SETXATTR4_EITHER when attribute already exists

   nsetxattr05
       Verify setting extended attribute with SETXATTR4_CREATE fails when attribute already exists

   nsetxattr06
       Verify setting extended attribute with SETXATTR4_REPLACE when attribute already exists

   dsetxattr01
       Verify setting extended attribute with SETXATTR4_EITHER when attribute does not exist
       when delegation is granted on second client

   dsetxattr02
       Verify setting extended attribute with SETXATTR4_CREATE when attribute does not exist
       when delegation is granted on second client

   dsetxattr03
       Verify setting extended attribute with SETXATTR4_REPLACE fails when attribute does not exist
       when delegation is granted on second client

   dsetxattr04
       Verify setting extended attribute with SETXATTR4_EITHER when attribute already exists
       when delegation is granted on second client

   dsetxattr05
       Verify setting extended attribute with SETXATTR4_CREATE fails when attribute already exists
       when delegation is granted on second client

   dsetxattr06
       Verify setting extended attribute with SETXATTR4_REPLACE when attribute already exists
       when delegation is granted on second client

   nremovexattr01
       Verify removing extended attribute

   nremovexattr02
       Verify removing extended attribute fails when attribute does not exist

   dremovexattr01
       Verify removing extended attribute
       when delegation is granted on second client

   dremovexattr02
       Verify removing extended attribute fails when attribute does not exist
       when delegation is granted on second client

   nlistxattr01
       Verify listing extended attributes with no user namespace attributes

   nlistxattr02
       Verify listing extended attribute

   nlistxattr03
       Verify listing extended attribute (many attributes)

   dlistxattr01
       Verify listing extended attributes with no user namespace attributes
       when delegation is granted on second client

   dlistxattr02
       Verify listing extended attribute
       when delegation is granted on second client

   dlistxattr03
       Verify listing extended attribute (many attributes)
       when delegation is granted on second client

   ncinfo01
       Verify SETXATTR change info with SETXATTR4_EITHER when attribute does not exist

   ncinfo02
       Verify SETXATTR change info with SETXATTR4_EITHER when attribute already exists

   ncinfo03
       Verify SETXATTR change info with SETXATTR4_CREATE when attribute does not exist

   ncinfo04
       Verify SETXATTR change info with SETXATTR4_REPLACE when attribute already exists

   mcinfo01
       Verify SETXATTR change info with SETXATTR4_EITHER when attribute does not exist
       when file is modified on second client

   mcinfo02
       Verify SETXATTR change info with SETXATTR4_EITHER when attribute already exists
       when file is modified on second client

   mcinfo03
       Verify SETXATTR change info with SETXATTR4_CREATE when attribute does not exist
       when file is modified on second client

   mcinfo04
       Verify SETXATTR change info with SETXATTR4_REPLACE when attribute already exists
       when file is modified on second client

   getxattr
       Run all GETXATTR tests: ngetxattr01, ngetxattr02, dgetxattr01,
       dgetxattr02

   ngetxattr
       Run all GETXATTR tests when no open on second client: ngetxattr01,
       ngetxattr02

   dgetxattr
       Run all GETXATTR tests when delegation is granted on second client:
       dgetxattr01, dgetxattr02

   setxattr
       Run all SETXATTR tests: nsetxattr01, nsetxattr02, nsetxattr03,
       nsetxattr04, nsetxattr05, nsetxattr06, dsetxattr01, dsetxattr02,
       dsetxattr03, dsetxattr04, dsetxattr05, dsetxattr06

   nsetxattr
       Run all SETXATTR tests when no open on second client: nsetxattr01,
       nsetxattr02, nsetxattr03, nsetxattr04, nsetxattr05, nsetxattr06

   dsetxattr
       Run all SETXATTR tests when delegation is granted on second client:
       dsetxattr01, dsetxattr02, dsetxattr03, dsetxattr04, dsetxattr05,
       dsetxattr06

   removexattr
       Run all REMOVEXATTR tests: nremovexattr01, nremovexattr02,
       dremovexattr01, dremovexattr02

   nremovexattr
       Run all REMOVEXATTR tests when no open on second client: nremovexattr01,
       nremovexattr02

   dremovexattr
       Run all REMOVEXATTR tests when delegation is granted on second client:
       dremovexattr01, dremovexattr02

   listxattr
       Run all LISTXATTRS tests: nlistxattr01, nlistxattr02, nlistxattr03,
       dlistxattr01, dlistxattr02, dlistxattr03

   nlistxattr
       Run all LISTXATTRS tests when no open on second client: nlistxattr01,
       nlistxattr02, nlistxattr03

   dlistxattr
       Run all LISTXATTRS tests when delegation is granted on second client:
       dlistxattr01, dlistxattr02, dlistxattr03

   cinfo
       Run all CINFO tests: ncinfo01, ncinfo02, ncinfo03, ncinfo04, mcinfo01,
       mcinfo02, mcinfo03, mcinfo04

   ncinfo
       Run all CINFO tests when no open on second client: ncinfo01, ncinfo02,
       ncinfo03, ncinfo04

   mcinfo
       Run all CINFO tests when file is modified on second client: mcinfo01,
       mcinfo02, mcinfo03, mcinfo04

   all
       Run all tests: ngetxattr01, ngetxattr02, dgetxattr01, dgetxattr02,
       nsetxattr01, nsetxattr02, nsetxattr03, nsetxattr04, nsetxattr05,
       nsetxattr06, dsetxattr01, dsetxattr02, dsetxattr03, dsetxattr04,
       dsetxattr05, dsetxattr06, nremovexattr01, nremovexattr02,
       dremovexattr01, dremovexattr02, nlistxattr01, nlistxattr02,
       nlistxattr03, dlistxattr01, dlistxattr02, dlistxattr03, ncinfo01,
       ncinfo02, ncinfo03, ncinfo04, mcinfo01, mcinfo02, mcinfo03, mcinfo04

EXAMPLES

       The only required option is --server
       $ nfstest_xattr --server 192.168.0.11

NOTES

       The  user  id in the local host and the host specified by --client must have access to run
       commands as root using the 'sudo' command without the need for a password.

       The user id must be able to 'ssh' to remote host without the need for a password.

       Valid only for NFS version 4.2 and above.

SEE ALSO

       baseobj(3),  formatstr(3),   nfstest.test_util(3),   nfstest_alloc(1),   nfstest_cache(1),
       nfstest_delegation(1),       nfstest_dio(1),       nfstest_fcmp(1),       nfstest_file(1),
       nfstest_interop(1),  nfstest_io(1),  nfstest_lock(1),   nfstest_pkt(1),   nfstest_pnfs(1),
       nfstest_posix(1),   nfstest_rdma(1),  nfstest_sparse(1),  nfstest_ssc(1),  nfstest_xid(1),
       packet.nfs.nfs4_const(3)

BUGS

       No known bugs.

AUTHOR

       Jorge Mora (mora@netapp.com)