Difference between revisions of "DCache Administration Console Commands"

From Public PIC Wiki
Jump to navigation Jump to search
Line 22: Line 22:
 
* With '''\s''' you will be able to access to all '''cell[@domain]'''s, while branches of this command such like '''\sn''' or '''\sp''' are useful to directly access to the ''namespace'' or ''poolmanager'' cells without the needing of specifying the ''cell[@domain]''.
 
* With '''\s''' you will be able to access to all '''cell[@domain]'''s, while branches of this command such like '''\sn''' or '''\sp''' are useful to directly access to the ''namespace'' or ''poolmanager'' cells without the needing of specifying the ''cell[@domain]''.
 
== Pool commands ==
 
== Pool commands ==
 +
=== Introduction ===
 +
* Any command run on a pool is a temporary change: on any pool service restart configuration will be restored back to the default value or to the value set in the '''setup''' file (locate in '''/dcpool*/vpool*/setup''').
 +
* If you want to make permanent changes, you should '''save''' changes. Running the '''save''' command will update the already mentioned '''setup''' file.
 
=== Disable / enable pools ===
 
=== Disable / enable pools ===
* Command help:
+
* Command help ('''\s dc???_? help hsm'''):
 
  pool disable [options] [<errorCode> [<errorMessage>]] # suspend sending 'up messages'
 
  pool disable [options] [<errorCode> [<errorMessage>]] # suspend sending 'up messages'
 
       OPTIONS :
 
       OPTIONS :
Line 35: Line 38:
 
  pool suppress hsmload on|off
 
  pool suppress hsmload on|off
 
* Examples:
 
* Examples:
pool disable -rdonly # disallows store, stage, p2p-client
+
:* Disallow store + stage + p2p-client (set pool in read only mode)
  pool enable          # sets pool to enabled (rw mode, a.k.a allow everything)
+
  '''''[dccore01] (local) admin >''''' '''pool disable -rdonly'''
 +
:* Enable pool (set pool to RW)
 +
'''''[dccore01] (local) admin >''''' '''pool enable'''
 +
 
 +
=== HSM Configuration ===hsm create <type> [<name> [<provider>]] [-<key>=<value>] ...
 +
* Command help ('''\s dc???_? help hsm'''):
 +
hsm ls [<name>] ...
 +
hsm remove <name>
 +
hsm set <name> [-<key>=<value>] ...
 +
hsm show providers # show available nearline storage providers
 +
hsm unset <name> [-<key>] ...
 +
* Examples:
 +
:* Show ''enstore'' configuration:
 +
'''''[dccore01] (local) admin >''''' '''hsm ls enstore'''
 +
enstore(enstore):script
 +
  pnfs                /pnfs/fs/usr
 +
  command            /opt/enstore/bin/real-encp.sh
 +
  c:gets              200
 +
  c:puts              20
 +
  c:removes          2
 +
:* Set maximum restores to 400:
 +
'''''[dccore01] (local) admin >''''' '''hsm set enstore -c:gets=400'''

Revision as of 09:06, 31 July 2017

About this document

  • This document shows several examples of useful commands that can be run in the dCache Administration Console.
  • Administration console can be accessed through [PCells GUI] or through SSHv2 as follows (in the example, dccore.pic.es is the physical machine running the admin cell):
ssh -2 -x -o StrictHostKeyChecking=no -l admin -c blowfish -p 22224 dccore.pic.es
  • In this document we show what we consider the most important commands for the everyday's administration tasks, and basically the ones that may be useful for the Manager On Duty. Maybe some important commands are missing, but will be added as soon as we detect that these may be important for the MoD.
  • This document is divided in two main blocks:
  1. Pool commands: shows useful commands that can be run on pools.
  2. Service commands: show useful commands that can be run on servers (this will include doors)

The basics =

  • If you access the Administration Console through SSHv2 you should access to the different cells as follows:
\? [command]...  # display help for shell commands
\c cell[@domain] [user]  # connect to cell
\exception [trace]  # controls display of stack traces
\h [command]...  # display help for cell commands
\l [cell[@domain]|pool/poolgroup]...  # list cells
\q # quit
\s (cell[@domain]|pool/poolgroup)[,(cell[@domain]|pool/poolgroup)]... command...  # send command
\sl pnfsid|path command...  # send to locations
\sn command...  # send pnfsmanager command
\sp command...  # send poolmanager command
\timeout [seconds]  # sets the command timeout
  • With \s you will be able to access to all cell[@domain]s, while branches of this command such like \sn or \sp are useful to directly access to the namespace or poolmanager cells without the needing of specifying the cell[@domain].

Pool commands

Introduction

  • Any command run on a pool is a temporary change: on any pool service restart configuration will be restored back to the default value or to the value set in the setup file (locate in /dcpool*/vpool*/setup).
  • If you want to make permanent changes, you should save changes. Running the save command will update the already mentioned setup file.

Disable / enable pools

  • Command help (\s dc???_? help hsm):
pool disable [options] [<errorCode> [<errorMessage>]] # suspend sending 'up messages'
     OPTIONS :
       -fetch    #  disallows fetch (transfer to client)
       -stage    #  disallows staging (from HSM)
       -store    #  disallows store (transfer from client)
       -p2p-client
       -rdonly   #  := store,stage,p2p-client
       -strict   #  := disallows everything
pool enable # start sending 'up messages' again
pool suppress hsmload on|off
  • Examples:
  • Disallow store + stage + p2p-client (set pool in read only mode)
[dccore01] (local) admin > pool disable -rdonly
  • Enable pool (set pool to RW)
[dccore01] (local) admin > pool enable

=== HSM Configuration ===hsm create <type> [<name> [<provider>]] [-<key>=<value>] ...

  • Command help (\s dc???_? help hsm):
hsm ls [<name>] ...
hsm remove <name>
hsm set <name> [-<key>=<value>] ...
hsm show providers # show available nearline storage providers
hsm unset <name> [-<key>] ...
  • Examples:
  • Show enstore configuration:
[dccore01] (local) admin > hsm ls enstore
enstore(enstore):script
  pnfs                /pnfs/fs/usr
  command             /opt/enstore/bin/real-encp.sh
  c:gets              200
  c:puts              20
  c:removes           2
  • Set maximum restores to 400:
[dccore01] (local) admin > hsm set enstore -c:gets=400