The Pnfs Version 3.1.5


News


Compatibility

No problem coming from 3.1.3/4. For earlier versions consult V3.1.3.

The list of groupids(newgrp) is honoured.

All operations are checked against all groups the user belongs to.

Patches.

.(getattr)(<pnfsId>)

The command returns a one line string for a directory and a 8 line text of a file, describing the attributes of the directory or all file levels. The strings are a ':' separated list of the mode(octal), uid(dec), gid(dec), and the atime,mtime,ctime in hex. This values can be used unchanged to set the appropiate values of a different file using the pset-attr command.

.(pset)(<pnfsId>)(attr)(<level>)(<attrString>)

The command can be used to set the attributes of a directory or a file level to the values of a different directory or file. The <attrString> has to have the same format as the return value of .(getattr)(<pnfsId>).

Note : When using this command together with 'touch' on solaris the 'touch -a ...' option must be used. Otherwise the date of the file is set to the current date and not to the date specified with the pset command.

These two commands are mainly used by the pcpattr command which copies all attributes of a directory or all attributes of all file levels to a different directory of file.


pcpattr : new command to copy attributes.

pcpattr <sourceFile>      <destinationFile>
pcpattr <sourceDirectory> <destinationDirectory>
pcpattr is able to copy attributes of a directory or file object to another directory or file object. Source and destination objects must be of the same type. The attributes are the User ID (uid), the Group ID (gid), all timestamps (ctime,mtime,atime) and the access modes. The filesize is not modified.
The pcpattr command should only be used by the root user and from a trusted pnfs host. Otherwise the root owned levels won't change the attributes and the results are not predictable.

Example :

There are two regular files in the /pnfs/fs/local/usr/patrick subdirectory fileA and fileB. These file have different modification timestamps, owners and access modes.
elchtop:/pnfs/fs/local/usr/patrick # pls
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 fileA
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(1)(fileA)
-rwxrwxrwx   1 root     users           0 Aug  1 19:30 .(use)(2)(fileA)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(3)(fileA)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(4)(fileA)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(5)(fileA)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(6)(fileA)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(7)(fileA)
-rw-r--r--   1 amanda   users           0 Aug  1 19:31 fileB
-rw-r--r--   1 amanda   users           0 Aug  1 19:31 .(use)(1)(fileB)
-rw-r--r--   1 amanda   users           0 Aug  1 19:31 .(use)(2)(fileB)
-rw-r--r--   1 amanda   users           0 Aug  1 19:31 .(use)(3)(fileB)
-rw-------   1 root     root            0 Aug  1 19:31 .(use)(4)(fileB)
-rw-------   1 root     root            0 Aug  1 19:31 .(use)(5)(fileB)
-rw-------   1 root     root            0 Aug  1 19:31 .(use)(6)(fileB)
-rw-r--r--   1 amanda   users           0 Aug  1 19:31 .(use)(7)(fileB)

elchtop:/pnfs/fs/local/usr/patrick # pcpattr fileA fileB

elchtop:/pnfs/fs/local/usr/patrick # pls

-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 fileA
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(1)(fileA)
-rwxrwxrwx   1 root     users           0 Aug  1 19:30 .(use)(2)(fileA)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(3)(fileA)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(4)(fileA)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(5)(fileA)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(6)(fileA)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(7)(fileA)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 fileB
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(1)(fileB)
-rwxrwxrwx   1 root     users           0 Aug  1 19:30 .(use)(2)(fileB)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(3)(fileB)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(4)(fileB)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(5)(fileB)
-rw-------   1 root     root            0 Aug  1 19:30 .(use)(6)(fileB)
-rwxrwxrwx   1 patrick  users           0 Aug  1 19:30 .(use)(7)(fileB)
After the pcpattr command finished, fileB has exactly the same attributes as fileB.

Solved Bugs.


Performance Remark.

For security reasons, all operations performed as 'root' accesses the 'admin' database to check privileges of the perticular client host. Therefore the 'root' user should only perform administration tasks and avoid intensive i/o operations.