release notes | Book: 2.16, 3.0, 3.1, 3.2, 4.0, 4.1, 4.2 | Wiki | Q&A black_bg
Web: Multi-page, Single page | PDF: A4-size, Letter-size | eBook: epub black_bg

The Basic Setup

The standard configuration assumes that the database server is installed on the same machine as the replica service — usually the admin node of the dCache instance. If this is not the case you need to set the property replica.db.host.

To create and configure the database replica used by the replica service in the database server do:

[root] # createdb -U dcache replica
[root] # psql -U dcache -d replica -f /usr/share/dcache/replica/psql_install_replicas.sql

To activate the replica service you need to

  1. Enable the replica service in a layout file.

    [<someDomain>]
    ...
    
    [<someDomain>/replica]
  2. Configure the service in the /etc/dcache/dcache.conf file on the node with the dCacheDomain and on the node on which the pnfsmanager is running.

    dcache.enable.replica=true

    Note

    It will not work properly if you defined the replica service in one of the layout files and set this property to no on the node with the dCacheDomain or on the node on which the pnfsmanager is running.

  3. Define a pool group for the resilient pools if necessary.

  4. Start the replica service.

In the default configuration, all pools of the dCache instance which have been created with the command dcache pool create will be managed. These pools are in the pool group named default which does exist by default. The replica service will keep the number of replicas between 2 and 3 (including). At each restart of the replica service the pool configuration in the database will be recreated.

Example:

This is a simple example to get started with. All your pools are assumed to be in the pool group default.

  1. In your layout file in the directory /etc/dcache/layouts define the replica service.

    [dCacheDomain]
    ...
    
    [replicaDomain]
    [replicaDomain/replica]
  2. In the file /etc/dcache/dcache.conf set the value for the property replicaManager to true and the replica.poolgroup to default.

    dcache.enable.replica=true
    replica.poolgroup=default
  3. The pool group default exists by default and does not need to be defined.

  4. To start the replica service restart dCache.

    [root] # dcache restart

[return to top]

Define a poolgroup for resilient pools

For more complex installations of dCache you might want to define a pool group for the resilient pools.

Define the resilient pool group in the /var/lib/dcache/config/poolmanager.conf file on the host running the poolmanager service. Only pools defined in the resilient pool group will be managed by the replica service.

Example:

Login to the admin interface and cd to the PoolManager. Define a poolgroup for resilient pools and add pools to that poolgroup.

(local) admin > cd PoolManager
(PoolManager) admin > psu create pgroup ResilientPools
(PoolManager) admin > psu create pool  pool3
(PoolManager) admin > psu create pool  pool4
(PoolManager) admin > psu addto pgroup ResilientPools pool3
(PoolManager) admin > psu addto pgroup ResilientPools pool4
(PoolManager) admin > save

By default the pool group named ResilientPools is used for replication.

To use another pool group defined in /var/lib/dcache/config/poolmanager.conf for replication, please specify the group name in the etc/dcache.conf file.

replica.poolgroup=<NameOfResilientPoolGroup>.