XtreemFSをFreeBSDで動かす(3)

FreeBSD向けのバグもいろいろ直したので、今回は冗長構成にしてみる。

packaging/freebsd/make-package.shでpkg用パッケージも作れるようにしておいた。
GlusterFSのときに作ったものを流用して作ったけど、manifestの書き方がどうも間違ってる気がする。けど今のところ動いてるので放っておく。

あ、xtfsutilが動かないバグはまだ直してないよ。

MRC, DIR, OSDをそれぞれ冗長構成にしてみる。
テスト用ノードは3台で、xtfs1/2/3。

まず/etc/hostsに以下を書いておく。これは(冗長構成とかになってれば)DNS任せでも(きっと)いいところ。

10.0.0.1 xtfs1
10.0.0.2 xtfs2
10.0.0.3 xtfs3

次に設定ファイルを変更していく。

  • /usr/local/etc/xos/xtreemfs/dirconfig.properties:
    babudb.plugin.0 = /usr/local/etc/xos/xtreemfs/server-repl-plugin/dir.properties
    

    コメントアウトをはずす。

  • /usr/local/etc/xos/xtreemfs/mrcconfig.properties:
    # Directory Service endpoint
    #dir_service.host = localhost
    #dir_service.port = 32638
    dir_service.host = xtfs1
    dir_service.port = 32638
    dir_service1.host = xtfs2
    dir_service1.port = 32638
    dir_service2.host = xtfs3
    dir_service2.port = 32638
    

    dir_servicelocalhostから変更して、dir_service1dir_service2を追加。

    #babudb.sync = ASYNC
    babudb.sync = FDATASYNC
    

    ASYNCFDATASYNCにする。

    babudb.plugin.0 = /usr/local/etc/xos/xtreemfs/server-repl-plugin/mrc.properties
    

    コメントアウトをはずす。

  • /usr/local/etc/xos/xtreemfs/osdconfig.properties
    mrcconfig.propertiesと同様にしてdir_serviceの定義を変更・追加する。
  • /usr/local/etc/xos/xtreemfs/server-repl-plugin/dir.properties
    babudb.repl.participantsを変更する。

    babudb.repl.participant.0 = xtfs1
    babudb.repl.participant.0.port = 35678
    babudb.repl.participant.1 = xtfs2
    babudb.repl.participant.1.port = 35678
    babudb.repl.participant.2 = xtfs3
    babudb.repl.participant.2.port = 35678
    
  • /usr/local/etc/xos/xtreemfs/server-repl-plugin/mrc.properties
    dir.propertiesと同様にしてbabudb.repl.participantsを変更する。

あとはサービスを(再)起動してあげればいい。

無事つながればhttp://10.0.0.1:30638でDIRの状態を見たときにほかのノードが見えるはず。
Service Registryに3台分のMRC/DIR/OSD、つまり9個のエントリが見えていればOK。

ちなみにstatus_page_urlがlocalhostになるけど原因不明。
きっとまだどこか変えるべきところが残っている……のかも。