SlideShare a Scribd company logo
第4回クラウドストレージ研究会

GlusterFS 技術と動向
                                                  1of2


            

       2011/12/8
(株)NTTPCコミュニケーションズ


            Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     1 
発表者の紹介


               高橋 敬祐 (TAKAHASHI Keisuke)
                  (個人用)Twitter ID : @keithseahus
•         NTTPCコミュニケーションズ在籍 (2006年〜)
          – Webマイニング系開発
          – 分散FS特にGlusterFSの調査,研究,それを利用した開発及びOSS活動
          – 宇宙航空関連実証実験及び開発
          – その他先端技術調査                   •  出入りしている勉強会
                                           –  VIOPS
     •    この界隈で特に関係の深い人                    –  クラウドネットワーク研究会
           –  伊藤氏 ( @thatsdone )           –  クラウドストレージ研究会
           –  STEC 伊藤氏 ( @HarrisonIto )    –  Tokyo Erlang Workshop
           –  NTTPC 中冨 ( @nakacya )        –  その他
           –  NTTPC 高田 ( @mikiT_T )

                   Google Groups: http://groups.google.com/group/gluster-ja
                                             Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     2 
GlusterFS 技術と動向 1of2

1.  GlusterFSの概要と動向
2.  GlusterFSの技術
 1.  ストレージの階層構造
 2.  分散アルゴリズム
   1.    分散アルゴリズム
   2.    Elasticなレイアウト変更
   3.    特殊なケース
 3.  メタデータ構造
 4.  レプリケーション
   1.    レプリケーション
   2.    レプリケーションのデータフロー
   3.    レプリカ障害とその対応
 5.  運用面での注意点
3.  FAQ
4.  まとめ

                           Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     3 
GlusterFSの概要と動向



       Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     4 
GlusterFSの概要と動向




                 さんの                                                     もオススメ!


   @doryokujin
                       Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     5 
ストレージの階層構造




     Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     6 
ストレージの階層構造




block device

               Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     7 
ストレージの階層構造

GlusterFSはblock deviceを直接管理することはできません。
   (カーネル空間のファイルシステムではありません。)




    file system

    block device

                   Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     8 
ストレージの階層構造




   VFS

file system

block device

               Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     9 
ストレージの階層構造

GlusterFSはカーネル空間ファイルシステムの上で動作します。
下位のファイルシステムへの操作はglusterfsdが行います。




     glusterfsd

        VFS

     file system

    block device

                   Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     10 
ストレージの階層構造

glusterfsがglusterfsdへの命令を実行します。
glusterfs-glusterfsd間はデフォルトではTCP/IPで接続されます。




       glusterfs

       glusterfsd

         VFS

      file system

      block device

                      Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     11 
ストレージの階層構造

   glusterfsにはFUSEとのI/Fがあります。




   FUSE

 glusterfs

 glusterfsd

   VFS

file system

block device

                Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     12 
ストレージの階層構造

そのため、POSIX準拠のファイルシステムとして
マウントすることができます。



   VFS

   FUSE

 glusterfs

 glusterfsd

   VFS

file system

block device

               Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     13 
ストレージの階層構造




   VFS

   FUSE

 glusterfs

 glusterfsd

   VFS

file system

block device

               Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     14 
分散アルゴリズム




    Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     15 
分散アルゴリズム




           Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     16 
分散アルゴリズム




                                           ③800〜1199




                                                                                              ①0〜399

                                        ②400〜799

注)ハッシュ値及びbrick名は説明のために簡略化してあります。以下同じ。         Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     17 
分散アルゴリズム


  A
/path/to/fileA
                 ③800〜1199




 768

                                                                    ①0〜399

            ②400〜799

                    Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     18 
分散アルゴリズム




/path/to/fileA
                 ③800〜1199




 768

                                                                    ①0〜399
           A
            ②400〜799

                    Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     19 
Elasticなレイアウト変更




       Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     20 
Elasticなレイアウト変更

brick追加直後の状態(gluster volume add-brick ④)
古いハッシュテーブル                                      新しいハッシュテーブル
   (3 bricks)                                      (4 bricks)


      ③800〜1199                                                          ④900〜1199




                                            ③600〜899                                         ①0〜299
                  ①0〜399
 A
 ②400〜799
                                                                         ②300〜599

      既存データの読み書きは
     古いハッシュテーブルに基づき
         実行される。
                           Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     21 
Elasticなレイアウト変更

新規ファイルの作成には新しいハッシュテーブルを使う
    古いハッシュテーブル                                     新しいハッシュテーブル
       (3 bricks)                                     (4 bricks)


         ③800〜1199                                                          ④900〜1199




                                               ③600〜899                                         ①0〜299
                     ①0〜399
     A
     ②400〜799
                                                                            ②300〜599


B    /path/to/fileB                           1024
                              Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     22 
Elasticなレイアウト変更

新規ファイルの作成には新しいハッシュテーブルを使う
古いハッシュテーブル                                         新しいハッシュテーブル
   (3 bricks)                                         (4 bricks)
                     リンク先brickの書かれた
     B                 スパースファイル                                      B
         ③800〜1199                                                          ④900〜1199




                                               ③600〜899                                         ①0〜299
                     ①0〜399
 A
 ②400〜799
                                                                            ②300〜599



 /path/to/fileB                               1024
                              Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     23 
Elasticなレイアウト変更

rebalanceを実行(gluster volume rebalance <volume> start)
  古いハッシュテーブル                                          新しいハッシュテーブル
     (3 bricks)                                          (4 bricks)

        B                                                               B
            ③800〜1199                                                          ④900〜1199




                                                  ③600〜899                                         ①0〜299
                        ①0〜399
    A
    ②400〜799
                                                                               ②300〜599




                                 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     24 
Elasticなレイアウト変更

rebalanceを実行(gluster volume rebalance <volume> start)
  古いハッシュテーブル                                          新しいハッシュテーブル
     (3 bricks)                                          (4 bricks)

        B                                                               B
            ③800〜1199                                                          ④900〜1199


                                               A
                                                  ③600〜899                                         ①0〜299
                        ①0〜399
    A                    リンク先brickの書かれた
    ②400〜799               スパースファイル
                                                                               ②300〜599




                                 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     25 
Elasticなレイアウト変更

                 rebalanceを実行中...
古いハッシュテーブル                                         新しいハッシュテーブル
   (3 bricks)                                         (4 bricks)

     B                                                               B
         ③800〜1199                                                          ④900〜1199


                                            A
                                               ③600〜899                                         ①0〜299
                     ①0〜399
 A                    リンク先brickの書かれた
 ②400〜799               スパースファイル
                                                                            ②300〜599




                              Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     26 
Elasticなレイアウト変更

              rebalanceを実行中...
古いハッシュテーブル                                      新しいハッシュテーブル
   (3 bricks)                                      (4 bricks)

  B                                                               B
      ③800〜1199                                                          ④900〜1199


                                         A
                                            ③600〜899                                         ①0〜299
                  ①0〜399

 ②400〜799
                                                                         ②300〜599




                           Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     27 
Elasticなレイアウト変更

                                  rebalanceを実行中...
           古いハッシュテーブル                                           新しいハッシュテーブル
              (3 bricks)                                           (4 bricks)

               B                                                           B
                    ③800〜1199                                                  ④900〜1199


                                                            A
                                                              ③600〜899                     ①0〜299
                                    ①0〜399

            ②400〜799
                                                                               ②300〜599


       C     /path/to/fileC                                  384
rebalance中のファイル生成処理は...
                     Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     28 
Elasticなレイアウト変更

                  rebalanceを実行中...
    古いハッシュテーブル                                      新しいハッシュテーブル
       (3 bricks)                                      (4 bricks)

      B                                                               B
          ③800〜1199                                                          ④900〜1199


                                             A
                                                                                                 ①0〜299
                  C                             ③600〜899
                      ①0〜399

     ②400〜799                                                        C
                                                                             ②300〜599



     /path/to/fileC                            384
rebalance実行前と同様                Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     29 
Elasticなレイアウト変更

                     rebalance完了
  古いハッシュテーブル                                      新しいハッシュテーブル
     (3 bricks)                                      (4 bricks)

    B                                                               B
        ③800〜1199                                                          ④900〜1199


                                           A
古いハッシュテーブルを破棄
                                                                                               ①0〜299
          C                                   ③600〜899
                    ①0〜399

   ②400〜799                                                        C
                                                                           ②300〜599




                             Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     30 
Elasticなレイアウト変更


                 B
                    ④900〜1199


    A
B                                                                           C
    ③600〜899
                                                               ①0〜299


               C
                 ②300〜599
               Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     31 
特殊なケース




   Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     32 
特殊なケース




                         ③800〜1199



一部brickがdisk full!!



                                                                            ①0〜399

                      ②400〜799

                            Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     33 
特殊なケース

            そこへ新規ファイル作成
  A
/path/to/fileA
                 ③800〜1199




 768

                                                                    ①0〜399

            ②400〜799

                    Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     34 
特殊なケース

                                                実体は書き込み可能な
                                                   brickへ
                            A
  /path/to/fileA
                   ③800〜1199




   768

                                                                      ①0〜399

     A        ②400〜799
リンク付きスパースファイル
                      Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     35 
メタデータ構造




   Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     36 
メタデータ構造




          Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     37 
メタデータ構造



          メタデータ (xattr)




                                            (実)データ




             Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     38 
メタデータ構造


               A


   VFS

   FUSE

 glusterfs

 glusterfsd

   VFS

file system

block device

                   Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     39 
メタデータ構造




   VFS               glusterfsがxattrを記述
                   (するようにglusterfsdに命令)
   FUSE

 glusterfs
               A
 glusterfsd

   VFS

file system

block device

                    Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     40 
メタデータ構造




   VFS

   FUSE

 glusterfs

 glusterfsd
                   glusterfsdがfile system上に
   VFS                      xattrを記述

file system
               A
block device

                    Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     41 
メタデータ構造




  VFS
                                     glusterfsを
 FUSE                                経由しないと
                                     xattrが付与
glusterfs
                                     されない!
glusterfsd

                   VFS

                  file system
             A                              B
                 block device

                         Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     42 
メタデータ構造




  VFS

 FUSE                     原則、GlusterFS経由では
                            アクセスできない。
glusterfs
                         但し、ディレクトリエントリとして
glusterfsd                 見えてしまう場合もある。

                   VFS

                  file system
             A                               B
                 block device

                          Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     43 
メタデータ構造


                    ディレクトリに付与されるxattr
                           trusted.gfid
                      trusted.glusterfs.dht
                      trusted.glusterfs.test




                  ファイルに付与されるxattr
                         trusted.gfid
           trusted.afr.<volume>-client-<number>
         trusted.afr.<volume>-client-<number++>
     trusted.<volume>-stripe-<number>.stripe-count
     trusted.<volume>-stripe-<number>.stripe-index

               Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.     44 

More Related Content

PDF
GlusterFS 技術と動向 2of2
PDF
GlusterFSとInfiniBandの小話
PDF
Linux Kernel Seminar in tripodworks
PDF
【Interop Tokyo 2015】 SP 04: シスコ サービス プロバイダー アクセス ポートフォリオ
PDF
JOSUG 9th Study
PDF
ストレージネットワーク基礎講座
PDF
Fpga local 20130322
PDF
GlusterFS Updates (and more) in 第六回クラウドストレージ研究会
GlusterFS 技術と動向 2of2
GlusterFSとInfiniBandの小話
Linux Kernel Seminar in tripodworks
【Interop Tokyo 2015】 SP 04: シスコ サービス プロバイダー アクセス ポートフォリオ
JOSUG 9th Study
ストレージネットワーク基礎講座
Fpga local 20130322
GlusterFS Updates (and more) in 第六回クラウドストレージ研究会

Viewers also liked (16)

PDF
はじめてのGlusterFS
PDF
openqrm4.9 Quick Start Guide
PDF
Quick Introduction to GlusterFS
PDF
最新技術動向 GlusterFS (仮想化DAY, Internet Week 2011)
PDF
IIJにおけるGlusterFS利用事例 GlusterFSの詳解と2年間の運用ノウハウ
 
PDF
2013年08月 夏サミ2013-A5「DevOpsってどうなのよ?」
PDF
クラウドで消耗してませんか?
 
PPTX
DevOps 101 - IBM Impact 2014
PDF
Red Hat Storage - Introduction to GlusterFS
PPTX
Jetson TK1でSemi-Global Matching
PPTX
サーバ脆弱性スキャナ Vuls を OpenStack 環境で使ってみた
PDF
10年効く分散ファイルシステム技術 GlusterFS & Red Hat Storage
PPTX
DevOpsって何?
PDF
MongoDBのはじめての運用テキスト
PPTX
今さら聞けない人のためのDevOps超入門
PDF
夏サミ2013【A1】基礎からわかるDevOps
はじめてのGlusterFS
openqrm4.9 Quick Start Guide
Quick Introduction to GlusterFS
最新技術動向 GlusterFS (仮想化DAY, Internet Week 2011)
IIJにおけるGlusterFS利用事例 GlusterFSの詳解と2年間の運用ノウハウ
 
2013年08月 夏サミ2013-A5「DevOpsってどうなのよ?」
クラウドで消耗してませんか?
 
DevOps 101 - IBM Impact 2014
Red Hat Storage - Introduction to GlusterFS
Jetson TK1でSemi-Global Matching
サーバ脆弱性スキャナ Vuls を OpenStack 環境で使ってみた
10年効く分散ファイルシステム技術 GlusterFS & Red Hat Storage
DevOpsって何?
MongoDBのはじめての運用テキスト
今さら聞けない人のためのDevOps超入門
夏サミ2013【A1】基礎からわかるDevOps
Ad

Similar to GlusterFS 技術と動向 1of2 (20)

PDF
メイカーRuby講習会2013
PDF
Fluentd Casual Talks LT #fluentd #fluentdcasual
PDF
Windows Azure Community Open Day 2012
PDF
CommunityOpenDay2012名古屋セッション資料
PDF
Flume cassandra real time log processing (日本語)
PPTX
Mashup Award 7 Caravan in Fukuoka
PPT
計算機理論入門10
PDF
GCをみればRTSが見えてくる、かも。。。
PDF
biglobedojo7
PDF
Data-Intensive Text Processing with MapReduce ch4
PDF
Ruby を用いた超絶技巧プログラミング(夏のプログラミングシンポジウム 2012)
PDF
Windows Azure Programming
PDF
MashupAward7 Microsoft Presentation
PDF
Osc2008 Opensuse Moonlinx
PDF
Build Windows ラップアップ
PPTX
自宅スケーラブル・ファイルシステムのご紹介
PDF
Solaris 11 に見る、次世代ファイルシステムZFS
PDF
Gc 擬(もどき)を js で書いてみた
PDF
FukuokaCloud_Azure
PDF
WDD2012_SC-004
メイカーRuby講習会2013
Fluentd Casual Talks LT #fluentd #fluentdcasual
Windows Azure Community Open Day 2012
CommunityOpenDay2012名古屋セッション資料
Flume cassandra real time log processing (日本語)
Mashup Award 7 Caravan in Fukuoka
計算機理論入門10
GCをみればRTSが見えてくる、かも。。。
biglobedojo7
Data-Intensive Text Processing with MapReduce ch4
Ruby を用いた超絶技巧プログラミング(夏のプログラミングシンポジウム 2012)
Windows Azure Programming
MashupAward7 Microsoft Presentation
Osc2008 Opensuse Moonlinx
Build Windows ラップアップ
自宅スケーラブル・ファイルシステムのご紹介
Solaris 11 に見る、次世代ファイルシステムZFS
Gc 擬(もどき)を js で書いてみた
FukuokaCloud_Azure
WDD2012_SC-004
Ad

More from Keisuke Takahashi (11)

PDF
Azure Database for PostgreSQL 入門 (PostgreSQL Conference Japan 2021)
PDF
パーフェクト"Elixir情報収集"
PDF
GlusterFS Masakari Talks
PDF
Trying and evaluating the new features of GlusterFS 3.5
PDF
Gluster Cloud Night in Tokyo 2013 -- Tips for getting started
PDF
Big Data入門に見せかけたFluentd入門
PDF
Gluster in Japan 2012-2013
PDF
Creating a shared storage service with GlusterFS
PDF
GlusterFS As an Object Storage
PDF
GlusterFS モジュール超概論
PDF
GlusterFS座談会テクニカルセッション
Azure Database for PostgreSQL 入門 (PostgreSQL Conference Japan 2021)
パーフェクト"Elixir情報収集"
GlusterFS Masakari Talks
Trying and evaluating the new features of GlusterFS 3.5
Gluster Cloud Night in Tokyo 2013 -- Tips for getting started
Big Data入門に見せかけたFluentd入門
Gluster in Japan 2012-2013
Creating a shared storage service with GlusterFS
GlusterFS As an Object Storage
GlusterFS モジュール超概論
GlusterFS座談会テクニカルセッション

GlusterFS 技術と動向 1of2

  • 1. 第4回クラウドストレージ研究会 GlusterFS 技術と動向 1of2 
 2011/12/8 (株)NTTPCコミュニケーションズ Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   1 
  • 2. 発表者の紹介 高橋 敬祐 (TAKAHASHI Keisuke) (個人用)Twitter ID : @keithseahus •  NTTPCコミュニケーションズ在籍 (2006年〜) – Webマイニング系開発 – 分散FS特にGlusterFSの調査,研究,それを利用した開発及びOSS活動 – 宇宙航空関連実証実験及び開発 – その他先端技術調査 •  出入りしている勉強会 –  VIOPS •  この界隈で特に関係の深い人 –  クラウドネットワーク研究会 –  伊藤氏 ( @thatsdone ) –  クラウドストレージ研究会 –  STEC 伊藤氏 ( @HarrisonIto ) –  Tokyo Erlang Workshop –  NTTPC 中冨 ( @nakacya ) –  その他 –  NTTPC 高田 ( @mikiT_T ) Google Groups: http://groups.google.com/group/gluster-ja Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   2 
  • 3. GlusterFS 技術と動向 1of2 1.  GlusterFSの概要と動向 2.  GlusterFSの技術 1.  ストレージの階層構造 2.  分散アルゴリズム 1.  分散アルゴリズム 2.  Elasticなレイアウト変更 3.  特殊なケース 3.  メタデータ構造 4.  レプリケーション 1.  レプリケーション 2.  レプリケーションのデータフロー 3.  レプリカ障害とその対応 5.  運用面での注意点 3.  FAQ 4.  まとめ Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   3 
  • 4. GlusterFSの概要と動向 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   4 
  • 5. GlusterFSの概要と動向 さんの もオススメ! @doryokujin Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   5 
  • 6. ストレージの階層構造 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   6 
  • 7. ストレージの階層構造 block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   7 
  • 8. ストレージの階層構造 GlusterFSはblock deviceを直接管理することはできません。 (カーネル空間のファイルシステムではありません。) file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   8 
  • 9. ストレージの階層構造 VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   9 
  • 10. ストレージの階層構造 GlusterFSはカーネル空間ファイルシステムの上で動作します。 下位のファイルシステムへの操作はglusterfsdが行います。 glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   10 
  • 11. ストレージの階層構造 glusterfsがglusterfsdへの命令を実行します。 glusterfs-glusterfsd間はデフォルトではTCP/IPで接続されます。 glusterfs glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   11 
  • 12. ストレージの階層構造 glusterfsにはFUSEとのI/Fがあります。 FUSE glusterfs glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   12 
  • 13. ストレージの階層構造 そのため、POSIX準拠のファイルシステムとして マウントすることができます。 VFS FUSE glusterfs glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   13 
  • 14. ストレージの階層構造 VFS FUSE glusterfs glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   14 
  • 15. 分散アルゴリズム Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   15 
  • 16. 分散アルゴリズム Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   16 
  • 17. 分散アルゴリズム ③800〜1199 ①0〜399 ②400〜799 注)ハッシュ値及びbrick名は説明のために簡略化してあります。以下同じ。 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   17 
  • 18. 分散アルゴリズム A /path/to/fileA ③800〜1199 768 ①0〜399 ②400〜799 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   18 
  • 19. 分散アルゴリズム /path/to/fileA ③800〜1199 768 ①0〜399 A ②400〜799 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   19 
  • 20. Elasticなレイアウト変更 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   20 
  • 21. Elasticなレイアウト変更 brick追加直後の状態(gluster volume add-brick ④) 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) ③800〜1199 ④900〜1199 ③600〜899 ①0〜299 ①0〜399 A ②400〜799 ②300〜599 既存データの読み書きは 古いハッシュテーブルに基づき 実行される。 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   21 
  • 22. Elasticなレイアウト変更 新規ファイルの作成には新しいハッシュテーブルを使う 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) ③800〜1199 ④900〜1199 ③600〜899 ①0〜299 ①0〜399 A ②400〜799 ②300〜599 B /path/to/fileB 1024 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   22 
  • 23. Elasticなレイアウト変更 新規ファイルの作成には新しいハッシュテーブルを使う 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) リンク先brickの書かれた B スパースファイル B ③800〜1199 ④900〜1199 ③600〜899 ①0〜299 ①0〜399 A ②400〜799 ②300〜599 /path/to/fileB 1024 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   23 
  • 24. Elasticなレイアウト変更 rebalanceを実行(gluster volume rebalance <volume> start) 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 ③600〜899 ①0〜299 ①0〜399 A ②400〜799 ②300〜599 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   24 
  • 25. Elasticなレイアウト変更 rebalanceを実行(gluster volume rebalance <volume> start) 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 A ③600〜899 ①0〜299 ①0〜399 A リンク先brickの書かれた ②400〜799 スパースファイル ②300〜599 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   25 
  • 26. Elasticなレイアウト変更 rebalanceを実行中... 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 A ③600〜899 ①0〜299 ①0〜399 A リンク先brickの書かれた ②400〜799 スパースファイル ②300〜599 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   26 
  • 27. Elasticなレイアウト変更 rebalanceを実行中... 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 A ③600〜899 ①0〜299 ①0〜399 ②400〜799 ②300〜599 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   27 
  • 28. Elasticなレイアウト変更 rebalanceを実行中... 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 A ③600〜899 ①0〜299 ①0〜399 ②400〜799 ②300〜599 C /path/to/fileC 384 rebalance中のファイル生成処理は... Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   28 
  • 29. Elasticなレイアウト変更 rebalanceを実行中... 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 A ①0〜299 C ③600〜899 ①0〜399 ②400〜799 C ②300〜599 /path/to/fileC 384 rebalance実行前と同様 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   29 
  • 30. Elasticなレイアウト変更 rebalance完了 古いハッシュテーブル 新しいハッシュテーブル (3 bricks) (4 bricks) B B ③800〜1199 ④900〜1199 A 古いハッシュテーブルを破棄 ①0〜299 C ③600〜899 ①0〜399 ②400〜799 C ②300〜599 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   30 
  • 31. Elasticなレイアウト変更 B ④900〜1199 A B C ③600〜899 ①0〜299 C ②300〜599 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   31 
  • 32. 特殊なケース Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   32 
  • 33. 特殊なケース ③800〜1199 一部brickがdisk full!! ①0〜399 ②400〜799 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   33 
  • 34. 特殊なケース そこへ新規ファイル作成 A /path/to/fileA ③800〜1199 768 ①0〜399 ②400〜799 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   34 
  • 35. 特殊なケース 実体は書き込み可能な brickへ A /path/to/fileA ③800〜1199 768 ①0〜399 A ②400〜799 リンク付きスパースファイル Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   35 
  • 36. メタデータ構造 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   36 
  • 37. メタデータ構造 Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   37 
  • 38. メタデータ構造 メタデータ (xattr) (実)データ Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   38 
  • 39. メタデータ構造 A VFS FUSE glusterfs glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   39 
  • 40. メタデータ構造 VFS glusterfsがxattrを記述 (するようにglusterfsdに命令) FUSE glusterfs A glusterfsd VFS file system block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   40 
  • 41. メタデータ構造 VFS FUSE glusterfs glusterfsd glusterfsdがfile system上に VFS xattrを記述 file system A block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   41 
  • 42. メタデータ構造 VFS glusterfsを FUSE 経由しないと xattrが付与 glusterfs されない! glusterfsd   VFS           file system A B            block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   42 
  • 43. メタデータ構造 VFS FUSE 原則、GlusterFS経由では アクセスできない。 glusterfs 但し、ディレクトリエントリとして glusterfsd 見えてしまう場合もある。   VFS           file system A B            block device Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   43 
  • 44. メタデータ構造 ディレクトリに付与されるxattr trusted.gfid trusted.glusterfs.dht trusted.glusterfs.test ファイルに付与されるxattr trusted.gfid trusted.afr.<volume>-client-<number> trusted.afr.<volume>-client-<number++> trusted.<volume>-stripe-<number>.stripe-count trusted.<volume>-stripe-<number>.stripe-index Copyright  (C)  2011,  NTTPC  Communications,  Inc.  All  Rights  Reserved.   44