This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
cluster:151 [2016/11/03 14:45] hmeij07 [Mirror Data] |
cluster:151 [2016/12/01 19:02] hmeij07 [Mirror Meta] |
||
---|---|---|---|
Line 6: | Line 6: | ||
A document for me to recall and make notes of what I read in the manual pages and what needs testing. | A document for me to recall and make notes of what I read in the manual pages and what needs testing. | ||
- | Basically during the Summer of 2016 I investigated if the HPCC could afford enterprise level storage. I wanted 99.999% uptime, snapshots, high availability and other goodies such as parallel NFS. Netapp came the closest but, eh, still at $42K lots of other options show up. The story is detailed | + | Basically during the Summer of 2016 I investigated if the HPCC could afford enterprise level storage. I wanted 99.999% uptime, snapshots, high availability and other goodies such as parallel NFS. Netapp came the closest but, eh, still at $42K lots of other options show up. That story is detailed at [[cluster: |
This page is best read from the bottom up. | This page is best read from the bottom up. | ||
- | ==== cluster idea ==== | + | ==== beeGFS |
- | * Storage servers: buy 2 now 4k+4k then 3rd in July 4k? | + | * Storage servers: |
+ | * buy 2 with each 12x2TB slow disk, Raid 6, 20T usable (clustered, parallel file system) | ||
+ | * create 2 6TB volumes on each, quota at 2TB via XFS, 3 users/ | ||
+ | * only $HOME changes to ''/ | ||
+ | * create 2 buddymirrors; | ||
+ | * on UPS | ||
+ | * on Infiniband | ||
- | * move test users over on 2 nodes, test, only change is $HOME | + | * Client servers: |
+ | * all compute/ | ||
- | * Home cluster | + | * Meta servers: |
- | * cottontail (mngt+admingiu) | + | * cottontail2 (root meta, on Infiniband) plus n38-n45 nodes (on Infiniband) |
- | * 2-3 new units storage (+snapshots/meta backup) | + | * all mirrored (total=9) |
- | * cottontail2 meta + n38-n45 meta, all mirrored | + | * cottontail2 on UPS |
+ | |||
+ | * Management and Monitor servers | ||
+ | * cottontail (on UPS, on Infiniband) | ||
+ | |||
+ | * Backups (rsnapshot.org via rsync daemons [[cluster: | ||
+ | * sharptail:/ | ||
+ | * serverA:/mnt/ | ||
+ | * serverB:/ | ||
+ | |||
+ | * Costs (includes 3 year NBD warranty) | ||
+ | * Microway $12,500 | ||
+ | * CDW | ||
==== beegfs-admin-gui ==== | ==== beegfs-admin-gui ==== | ||
* '' | * '' | ||
+ | |||
+ | ==== upgrade ==== | ||
+ | |||
+ | * [[http:// | ||
+ | * New feature - High Availability for Metadata Servers (self-healing, | ||
+ | |||
+ | A bit complicated. | ||
+ | |||
+ | * Repo base URL baseurl=http:// | ||
+ | * [ ] beegfs-mgmtd-6.1-el6.x86_64.rpm | ||
+ | * '' | ||
+ | * beegfs-mgmtd.x86_64 | ||
+ | * '' | ||
+ | * http:// | ||
+ | |||
+ | |||
+ | So the wget/rpm approach (list all packages present on a particular node else you will get a dependencies failure!) | ||
+ | |||
+ | < | ||
+ | |||
+ | # get them all | ||
+ | wget http:// | ||
+ | |||
+ | # client and meta node | ||
+ | rpm -Uvh ./ | ||
+ | |||
+ | # updated? | ||
+ | [root@cottontail2 beegfs_6]# beegfs-ctl | head -2 | ||
+ | BeeGFS Command-Line Control Tool (http:// | ||
+ | Version: 6.1 | ||
+ | |||
+ | #Sheeesh | ||
+ | </ | ||
+ | |||
+ | |||
+ | ==== Resync Data #2 ==== | ||
+ | |||
+ | If you have 2 buddymirrors and 2 storage servers each with 2 storage objects, beegfs will write to all primary storage targets even if numtargets is to 1 ... it will use all storage objects so best to numtargets' | ||
+ | |||
+ | How does one add a server? | ||
+ | |||
+ | < | ||
+ | |||
+ | # define storage objects, 2 per server | ||
+ | [root@petaltail ~]# / | ||
+ | [root@petaltail ~]# / | ||
+ | [root@swallowtail data]# / | ||
+ | [root@swallowtail data]# / | ||
+ | |||
+ | |||
+ | [root@cottontail2 ~]# beegfs-df | ||
+ | METADATA SERVERS: | ||
+ | TargetID | ||
+ | ======== | ||
+ | | ||
+ | |||
+ | STORAGE TARGETS: | ||
+ | TargetID | ||
+ | ======== | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | |||
+ | # define mirrrogroups | ||
+ | [root@cottontail2 ~]# beegfs-ctl --addmirrorgroup [--nodetype=storage] --primary=21701 --secondary=13601 --groupid=1 | ||
+ | [root@cottontail2 ~]# beegfs-ctl --addmirrorgroup [--nodetype=storage] --primary=13602 --secondary=21702 --groupid=2 | ||
+ | |||
+ | [root@cottontail2 ~]# beegfs-ctl --listmirrorgroups | ||
+ | | ||
+ | | ||
+ | 1 | ||
+ | 2 | ||
+ | |||
+ | # define buddygroups, | ||
+ | [root@cottontail2 ~]# beegfs-ctl --setpattern --buddymirror / | ||
+ | New chunksize: 524288 | ||
+ | New number of storage targets: 1 | ||
+ | Path: /home1 | ||
+ | Mount: /mnt/beegfs | ||
+ | |||
+ | [root@cottontail2 ~]# beegfs-ctl --setpattern --buddymirror / | ||
+ | New chunksize: 524288 | ||
+ | New number of storage targets: 1 | ||
+ | Path: /home2 | ||
+ | Mount: /mnt/beegfs | ||
+ | |||
+ | # drop /home/hmeij in / | ||
+ | [root@petaltail mysql_bak_ptt]# | ||
+ | 3623 | ||
+ | [root@petaltail mysql_bak_ptt]# | ||
+ | 3678 | ||
+ | [root@swallowtail data]# find / | ||
+ | 3623 | ||
+ | [root@swallowtail data]# find / | ||
+ | 3678 | ||
+ | |||
+ | # with numtargets=1 beegfs still writes to all primary targets found in all buddygroups | ||
+ | |||
+ | # rebuild test servers with from scratch with numparts=2 | ||
+ | # drop hmeij/ into home1/ and obtain slightly more files (couple of 100s), not double the amount | ||
+ | # /home/hmeij has 7808 files in it which gets split over primaries but numparts=2 would yield 15,616 files? | ||
+ | # drop another copy in home2/ and file counts double to circa 7808 | ||
+ | [root@cottontail2 ~]# beegfs-ctl --getentryinfo | ||
+ | Path: /home1 | ||
+ | Mount: /mnt/beegfs | ||
+ | EntryID: 0-583C50A1-FA | ||
+ | Metadata node: cottontail2 [ID: 250] | ||
+ | Stripe pattern details: | ||
+ | + Type: Buddy Mirror | ||
+ | + Chunksize: 512K | ||
+ | + Number of storage targets: desired: 2 | ||
+ | [root@cottontail2 ~]# beegfs-ctl --getentryinfo | ||
+ | Path: /home2 | ||
+ | Mount: /mnt/beegfs | ||
+ | EntryID: 1-583C50A1-FA | ||
+ | Metadata node: cottontail2 [ID: 250] | ||
+ | Stripe pattern details: | ||
+ | + Type: Buddy Mirror | ||
+ | + Chunksize: 512K | ||
+ | + Number of storage targets: desired: 2 | ||
+ | |||
+ | Source: /home/hmeij 7808 files in 10G | ||
+ | |||
+ | TargetID | ||
+ | ======== | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | [root@cottontail2 ~]# rsync -ac --bwlimit=2500 /home/hmeij / | ||
+ | [root@cottontail2 ~]# rsync -ac --bwlimit=2500 /home/hmeij / | ||
+ | TargetID | ||
+ | ======== | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | |||
+ | # first rsync drops roughly 5G in both primaries which then get copied to secondaries. | ||
+ | # second rsync does the same so both storage servers loose 20G roughly | ||
+ | # now shut a storage server down and the whole filesystem can still be accessed (HA) | ||
+ | |||
+ | </ | ||
+ | |||
+ | ==== Resync Data #1 ==== | ||
+ | |||
+ | [[http:// | ||
+ | |||
+ | //If the primary storage target of a buddy group is unreachable, | ||
+ | |||
+ | Testing out fail over and deletion of data on secondary then a full resync process: | ||
+ | |||
+ | |||
+ | * started a full --resyncstorage --mirrorgroupid=101 --timestamp=0 | ||
+ | * got --getentryinfo EntryID for a file in my / | ||
+ | * did a cat / | ||
+ | * brought primary storage down | ||
+ | * redid the cat above (it hangs for a couple of minutes, then displays the file content) | ||
+ | * while primary down, I ran rm -rf / | ||
+ | * a cat now generates the expected file not found error | ||
+ | * brought up primary and started a full --resyncstorage --mirrorgroupid=101 --timestamp=0 | ||
+ | * the nr of files and dirs discovered is as expected lower by the correct values | ||
+ | * when I now search for the EntryIDs obtained before they are gone from / | ||
+ | |||
+ | Nice that it works. | ||
+ | |||
+ | So you can full storage content mirror. You'll still need rsnapshots to recover lost data or point in time restores. | ||
==== Mirror Data ==== | ==== Mirror Data ==== | ||
Line 63: | Line 250: | ||
| | ||
# enable mirroring for data by directory -numTargets needs to be set to max nr of storage servers? | # enable mirroring for data by directory -numTargets needs to be set to max nr of storage servers? | ||
+ | # changed to 11/02/2016: | ||
+ | [root@n7 ~]# beegfs-ctl --setpattern --buddymirror / | ||
[root@n7 ~]# beegfs-ctl --setpattern --buddymirror / | [root@n7 ~]# beegfs-ctl --setpattern --buddymirror / | ||
New chunksize: 524288 | New chunksize: 524288 | ||
Line 107: | Line 296: | ||
[root@petaltail chroots]# ls -lh / | [root@petaltail chroots]# ls -lh / | ||
-rw-rw-rw- 1 root root 4.9G Apr 7 2014 / | -rw-rw-rw- 1 root root 4.9G Apr 7 2014 / | ||
+ | ^^^^^^^^ | ||
# copy on secondary | # copy on secondary | ||
Line 113: | Line 303: | ||
[root@swallowtail ~]# ls -lh / | [root@swallowtail ~]# ls -lh / | ||
-rw-rw-rw- 1 root root 4.9G Apr 7 2014 / | -rw-rw-rw- 1 root root 4.9G Apr 7 2014 / | ||
+ | ^^^^^^^^ | ||
# seems to work, notice the '' | # seems to work, notice the '' | ||
Line 123: | Line 314: | ||
* so the important line that tells you that this file is mirrored is "Type: Buddy Mirror" | * so the important line that tells you that this file is mirrored is "Type: Buddy Mirror" | ||
* " | * " | ||
+ | |||
+ | Another note: I changed paths for mirrormd and buddymirror to ''/ | ||
+ | |||
+ | < | ||
+ | |||
+ | [root@cottontail2 ~]# beegfs-net | ||
+ | meta_nodes | ||
+ | ============= | ||
+ | cottontail2 [ID: 250] | ||
+ | | ||
+ | |||
+ | [root@cottontail2 ~]# beegfs-ctl --listnodes --nodetype=meta --details | ||
+ | cottontail2 [ID: 250] | ||
+ | | ||
+ | | ||
+ | ^^^ | ||
+ | |||
+ | </ | ||
+ | |||
==== Quota ==== | ==== Quota ==== | ||
Line 133: | Line 343: | ||
* do BEFORE populating XFS file systems | * do BEFORE populating XFS file systems | ||
+ | ==== Meta Backup/ | ||
+ | |||
+ | [[http:// | ||
+ | |||
+ | < | ||
+ | |||
+ | # latest tar | ||
+ | rpm -Uvh / | ||
+ | |||
+ | # backup | ||
+ | cd /data; tar czvf / | ||
+ | |||
+ | # restore | ||
+ | cd / | ||
+ | |||
+ | # test | ||
+ | cd /data; diff -r beegfs_meta beegfs_meta.orig | ||
+ | # no results | ||
+ | |||
+ | </ | ||
+ | |||
+ | |||
+ | |||
+ | ==== Resync Meta ==== | ||
+ | |||
+ | [[http:// | ||
+ | |||
+ | * older versions | ||
+ | * new future version will work like storage mirror with HA and self-healing | ||
==== Mirror Meta ==== | ==== Mirror Meta ==== | ||
+ | |||
+ | //Metadata mirroring can currently not be disabled after it has been enabled for a certain directory// | ||
Definitely want Meta content mirrored, that way I can use the n38-n45 nodes with local 15K disk, plus maybe cottontail2 (raid 1 with hot and cold spare). | Definitely want Meta content mirrored, that way I can use the n38-n45 nodes with local 15K disk, plus maybe cottontail2 (raid 1 with hot and cold spare). | ||
Line 139: | Line 380: | ||
Content mirroring will require more disk space. Perhaps snapshots to another node is more useful, also solves backup issue. | Content mirroring will require more disk space. Perhaps snapshots to another node is more useful, also solves backup issue. | ||
- | + | V6 does buddymirror meta mirroring [[http:// | |
< | < | ||
- | # enable meta mirroring, directory based | + | # 2015.03 |
+ | # change to 11/04/2016: used --createdir to make this home. | ||
+ | [root@n7 ~]# beegfs-ctl --mirrormd / | ||
[root@n7 ~]# beegfs-ctl --mirrormd / | [root@n7 ~]# beegfs-ctl --mirrormd / | ||
Mount: '/ | Mount: '/ | ||
Operation succeeded. | Operation succeeded. | ||
+ | |||
+ | # V6.1 does it a root level not from a path | ||
+ | beegfs-ctl --addmirrorgroup --nodetype=meta --primary=38 --secondary=39 --groupid=1 | ||
+ | beegfs-ctl --addmirrorgroup --nodetype=meta --primary=250 --secondary=37 --groupid=2 | ||
+ | beegfs-ctl --mirrromd | ||
# put some new content in | # put some new content in | ||
Line 160: | Line 407: | ||
[root@sharptail ~]# ssh n38 find / | [root@sharptail ~]# ssh n38 find / | ||
/ | / | ||
- | ^^^^^^ | + | |
# and find | # and find | ||
[root@sharptail ~]# ssh n39 find / | [root@sharptail ~]# ssh n39 find / | ||
Line 237: | Line 484: | ||
* set in / | * set in / | ||
- | * backup | + | * backup/restore/mirror |
- | * attempt a restore | + | * see more towards top this page |
- | * or just snapshot | + | |
* storage server tuning | * storage server tuning | ||
Line 281: | Line 527: | ||
* made easy [[http:// | * made easy [[http:// | ||
* rpms pulled from repository via petaltail in '' | * rpms pulled from repository via petaltail in '' | ||
+ | * '' | ||
+ | * use '' | ||
< | < |