DPM DPNS Test

From GridPP Wiki
Jump to: navigation, search

The YAIM install should have setup the DPNS name space with paths like /dpm/DOMAIN/home/VO, e.g. /dpm/scotgrid.ac.uk/home/dteam.

To test DPNS functionality then on the DPNS server try simple tests like:

 # export DPNS_HOST=se2-gla
 # dpns-ls -l /dpm/scotgrid.ac.uk/home
 drwxrwxr-x   0 root     alice                     0 Jul 25 17:29 alice
 drwxrwxr-x   0 root     atlas                     0 Jul 25 17:29 atlas
 drwxrwxr-x   0 root     cms                       0 Jul 25 17:29 cms
 drwxrwxr-x   1 root     dteam                     0 Jul 28 15:15 dteam
 drwxrwxr-x   0 root     lhcb                      0 Jul 25 17:29 lhcb
 drwxrwxr-x   0 root     sixt                      0 Jul 25 17:30 sixt
 # dpns-mkdir /dpm/scotgrid.ac.uk/home/dteam/testDir
 # dpns-ls -l /dpm/scotgrid.ac.uk/home/dteam
 -rw-rw-r--   1 dteam001 dteam               2904532 Jul 28 15:09 k2
 drwxrwxr-x   0 root     root                      0 Jul 29 13:10 testDir
 # dpns-rm -fr /dpm/scotgrid.ac.uk/home/dteam/testDir
 # dpns-rm /dpm/scotgrid.ac.uk/home/dteam/testDir
 /dpm/scotgrid.ac.uk/home/dteam/testDir: No such file or directory

N.B. As this test is done from a DPNS trusted host no GSI authentication is required and the files end up owned by root. Remember this if you are, e.g., adding a new path for a VO and make use of dpns-chown and dpns-chmod appropriately.

Now you probably want to test the GSI features of DPNS from another host as a user, e.g.:

 ~[graeme@ui1-gla graeme]$ export DPNS_HOST=se2-gla
 ~[graeme@ui1-gla graeme]$ dpns-ls /dpm
 send2nsd: NS002 - send error : No valid credential found
 /dpm: Could not establish context
 ~[graeme@ui1-gla graeme]$ grid-proxy-init
 Your identity: /C=UK/O=eScience/OU=Glasgow/L=Compserv/CN=graeme stewart
 Enter GRID pass phrase for this identity:
 Creating proxy ................................................................................ Done
 Your proxy is valid until: Sat Jul 30 02:56:15 2005
 ~[graeme@ui1-gla graeme]$ dpns-ls -l /dpm/scotgrid.ac.uk/home/dteam
 -rw-rw-r--   1 dteam001 dteam               2904532 Jul 28 15:09 k2
 ~[graeme@ui1-gla graeme]$ dpns-mkdir /dpm/scotgrid.ac.uk/home/dteam/utest
 ~[graeme@ui1-gla graeme]$ dpns-ls -l /dpm/scotgrid.ac.uk/home/dteam
 -rw-rw-r--   1 dteam001 dteam               2904532 Jul 28 15:09 k2
 drwxrwxr-x   0 dteam001 dteam                     0 Jul 29 14:56 utest
 ~[graeme@ui1-gla graeme]$ dpns-rm -fr /dpm/scotgrid.ac.uk/home/dteam/utest