Easy Move dcache data from pool to pool

UserCase

we want to retire non-resilient pool umfs07_2 from dcache which holds 1.7TB data,so we need to move these data to other small pools. the CopyManager could only handle from one pool to another pool..but we dont have single pool whose size is as big as 1.7TB..so these data need to be copied to several pools..

attributes of dcache data we can base on

for each file name in /pnfs namespace, there is a unique pnfsid. PNFS database holds the mapping from file name to pnfsid. there is a database "companion" who maps the pnfsid to the pools who stores this file. For example:
companion=> select * from cacheinfo where pnfsid='00010000000000000016E620';
          pnfsid          |   pool   |          ctime          
--------------------------+----------+-------------------------
 00010000000000000016E620 | c-3-26_1 | 2008-04-04 17:08:18.153
 00010000000000000016E620 | c-2-38_1 | 2008-04-04 17:08:19.16
 00010000000000000016E620 | c-2-32_1 | 2008-04-04 17:08:24.843
 00010000000000000016E620 | c-3-24_1 | 2008-04-04 17:08:36.789
 00010000000000000016E620 | c-7-35_1 | 2008-04-04 17:08:59.321

the file whose pnfsid is 00010000000000000016E620 resides on 5 different pools..

when you unregister pnfsid of a certain pool from the admin tool, the entries related to this pool will all be deleted, but when you register pnfsid , new entries related to this pool would be added to "cacheinfo" again..

For exmaple:
companion=> select count(*) from cacheinfo where pool='c-1-15_1' ;
 count 
-------
    73
(1 row)

root@head01 /opt/d-cache/config# ssh -l admin -c blowfish -p 22223 localhost

    dCache Admin (VII) (user=admin)


[head01.aglt2.org] (local) admin > cd c-1-15_1
[head01.aglt2.org] (c-1-15_1) admin > pnfs unregister

companion=> select count(*) from cacheinfo where pool='c-1-15_1' ;
 count 
-------
     0
(1 row)


[head01.aglt2.org] (c-1-15_1) admin > pnfs register    
[head01.aglt2.org] (c-1-15_1) admin > 

companion=> select count(*) from cacheinfo where pool='c-1-15_1' ;
 count 
-------
    73
(1 row)

when files are stored in pools, their real name is actually the pnfsid of this file.. so it is possible to move these files among pools independent of dcache, then register the pnfs to the pool, dcache will be aware of the existence of the file..

An Example on how to do it

1. mount the umfs07 :/dcache1/pool/ (which is the storage space for pool umfs07_1 ) to node c-2-20 and c-2-30 (2 destination pools)

2. copy data from umfs07:/dcache1/pool/data/* to c-2-20:/dcache/pool/data/ and c-2-30:/dcache/pool/data/

3. restart dcache-pool services on the destination pools' nodes..

4. login to the admin interface to register pnfs to the destination pools

 
root@head01 /opt/d-cache/config# ssh -l admin -c blowfish -p 22223 localhost

    dCache Admin (VII) (user=admin)


[head01.aglt2.org] (local) admin > cd c-2-20_1
[head01.aglt2.org] (c-2-20_1) admin > pnfs register
[head01.aglt2.org] (c-2-20_1) admin >..
[head01.aglt2.org] (local) admin > cd c-2-30_1
[head01.aglt2.org] (c-2-30_1) admin > pnfs register

5. restart your replica Manager if these pools are resilient pools which are considered by your repilca Manager..

6. delete data from umfs07:/dcache/pool/data ..

-- WenjingWu - 05 Apr 2008
Topic revision: r3 - 05 Apr 2008, WenjingWu
This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback