Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Rook v1.1を使おう!新機能の紹介
Search
tzkoba
November 26, 2019
Technology
2
440
Rook v1.1を使おう!新機能の紹介
【前夜祭】CloudNative Days Kansai 2019 MeetupのLT用スライドです。
tzkoba
November 26, 2019
Tweet
Share
More Decks by tzkoba
See All by tzkoba
The State of Distibuted Database In Japan
tzkoba
1
850
#CloudNativeDB NewSQLへの誘い
tzkoba
4
3k
Cloud Native時代のデータベース
tzkoba
12
14k
2020年DBプラットフォーム (超個人的)5大ニュース
tzkoba
0
1k
PostgreSQLプラットフォームの徹底比較(コンテナからクラウドまで)
tzkoba
6
8.7k
Kubernetesでストレージ?そもそも何に使えるの?
tzkoba
0
1k
データ損失を回避しよう 各DBの機能比較
tzkoba
3
1.5k
昨今のデータデバイス(アーカイブ編)
tzkoba
3
1.5k
理解して拡げる分散システムの基礎知識
tzkoba
19
9.6k
Other Decks in Technology
See All in Technology
エンジニアのキャリアをちょっと楽しくする3本の軸/Three Pillars to Make an Engineer's Career More Enjoyable
kwappa
0
2.7k
反実仮想機械学習とは何か
usaito
PRO
11
4.6k
require(ESM)とECMAScript仕様
uhyo
3
630
ChatworkのSRE部って実は 半分くらいPlatform Engineering部かもしれない
saramune
0
160
VSCodeの拡張機能を作っている話
ebarakazuhiro
1
390
Google Cloud Next '24でブログを10本書いた方法と勉強会を沸かせた方法
yasumuusan
0
290
Google Cloud Next '24 Recap(Cloud Run/k8s)
mokocm
0
190
Reducing Cross-Zone Egress at Spotify with Custom gRPC Load Balancing Recap
koh_naga
0
200
プラットフォームってつくることより計測することが重要なんじゃないかという話 / Platform Engineering Meetup #8
taishin
1
360
開発生産性向上サービスを作るFindyが自分たちで開発生産性を爆上げした組織づくりの歩み / Findy's path to boosting its own development productivity 2024-04-17
ma3tk
3
660
KubeConにproposalを送りたい人へのアドバイス
sat
PRO
3
250
オーナーシップを持つ領域を明確にする
konifar
13
3.2k
Featured
See All Featured
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
14
1.5k
Visualization
eitanlees
136
14k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
322
20k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
17
1.4k
A Tale of Four Properties
chriscoyier
151
22k
Robots, Beer and Maslow
schacon
PRO
155
7.9k
GraphQLとの向き合い方2022年版
quramy
32
12k
It's Worth the Effort
3n
180
27k
Designing for humans not robots
tammielis
248
25k
Design by the Numbers
sachag
274
18k
Documentation Writing (for coders)
carmenintech
60
3.9k
Building Your Own Lightsaber
phodgson
99
5.7k
Transcript
@tzkb Rook v1.1を使おう! 新機能の紹介 CloudNative Days Kansai 2019 Meetup ,
2019/11/27
2 最近やっていること • Cloud Native Days Tokyo 2019 “Cloud Native
Storageが拓く Database on Kubernetesの未来” • PGConf.Asia 2019 “Building PostgreSQL as a Service with Kubernetes” + =∞
3 知ってますか?
4 (念のため)Rookとは • マルチなストレージ・プロバイダに対応した、データストア・ オーケストレータ。 Storage Provider 種別 ステータス 概要
Ceph ストレージ Stable 分散ストレージ (Block/File/Object) Cockroach DB DB Alpha OSS版Spannerを目指す分散DB Minio ストレージ Alpha 簡素なオブジェクトストレージ EdgeFS ストレージ Stable Gitに似たGeoスケールのFS Cassandra KVS Alpha NoSQLの代表格、分散KVS NFS FS Alpha 共有ファイルシステム Yugabyte DB DB Alpha PostgreSQL互換の分散DB
5 :Ceph(RBD)をdeployした際の構成例 • Rookは以下の3つのレイヤで構成される。 operator agent/discover agent/discover agent/discover osd osd
osd mon mon mon CSI csi-provisioner csi-rbdplugin csi-rbdplugin csi-rbdplugin Rook [Orchestration] • Storage Providerの管理 [Storage Provisioning] • CSIドライバが、Podとスト レージの接続を媒介 [Storage Provider] • Block/File/Objectストレージ やデータベースを構成
6 9/13、Rook v1.1がリリース! 以下の新機能が追加された。 • PVC-based OSDs/MONs • external Ceph
cluster • Dynamic Bucket Provisioning • EdgeFS to v1 stable • YugaByte DB 現在、最新版はv1.1.7
7 (新機能①)PVC-basedとはどういうことか? Node Node (右) PVC-based • v1.1から。 • MON/OSDは
PVC経由で外部 ストレージを アタッチ。 • 特別なNodeは 不要になる。 • Pod移動時にPVが 追随できる。 OSD MON OSD MON operator agent/discover operator agent/discover (左) Host-based • 従来型。 • MON/OSDは Node上のdirを 参照。 • Workerに RAWデバイスが 必要。 • dirは移動できず、 Podも移動不可。
9 やってみた、PVC-based Rook/Ceph(1) $ kubectl get -n rook-ceph pvc NAME
STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS AGE rook-ceph-mon-a Bound pvc-54e63d13-d0b5-XXX 10Gi RWO gp2 2d rook-ceph-mon-b Bound pvc-42a7bdb4-5caf-XXX 10Gi RWO gp2 2d rook-ceph-mon-c Bound pvc-b1c81bca-000f-XXX 10Gi RWO gp2 2d set1-0-data-mfp9t Bound pvc-7942ac5e-765a-XXX 10Gi RWO gp2 2d set1-1-data-2shjq Bound pvc-1042ebf7-c194-XXX 10Gi RWO gp2 2d set1-2-data-pcjqd Bound pvc-586ae884-d853-XXX 10Gi RWO gp2 2d • MONで3つ、OSDで3つのPV/PVCが作成される。
10 やってみた、PVC-based Rook/Ceph(2) $ kubectl describe -n rook-ceph pvc set1-0-data-mfp9t
Name: set1-0-data-mfp9t Namespace: rook-ceph StorageClass: gp2 Status: Bound Volume: pvc-7942ac5e-765a-409f-xxx Labels: ceph.rook.io/DeviceSet=set1 ceph.rook.io/DeviceSetPVCId=set1-0 ceph.rook.io/setIndex=0 Annotations: pv.kubernetes.io/bind-completed: yes pv.kubernetes.io/bound-by-controller: yes volume.beta.kubernetes.io/storage-provisioner: kubernetes.io/aws-ebs Finalizers: [kubernetes.io/pvc-protection] Capacity: 10Gi Access Modes: RWO VolumeMode: Block Mounted By: rook-ceph-osd-1-5dd48685fd-48tj8 rook-ceph-osd-prepare-set1-0-data-mfp9t-nw48q • Raw Block Volumeが使われている。 普通はここがFileSystem
11 (参考)Raw Block Volumeとは https://qiita.com/tzkoba/items/fb9ccab311b8d7956a6f
12 PVC-basedなRook/Cephのユースケース • KubernetesによるStorage as a Serviceの実現に近づく。 • Storageを抽象化、CSIで外部 へVolumeを提供。
• STaaS内ではNodeとVolumeが 分離され、復元力が高い。 << 課題 >> • Storageが機能過多(=高コスト) • コントローラはCephが担当、 データを冗長化&分散。 STaaS
13 (新機能②)Yugabyte DBとは? • ACIDなトランザクションをサポートし、Geoスケールに分散が 可能な、スケールアウト型のデータベース。 tablet3 tablet2 tablet1 tablet4
tablet2 tablet1 tablet4 tablet3 tablet1 tablet4 tablet3 tablet1 Distrbuted Txn Mgr Distrbuted Txn Mgr Distrbuted Txn Mgr Distrbuted Txn Mgr syscatalog syscatalog syscatalog [yb-tserver] • Spanner Serverと同義と 考えて良さそう。 • データはtablet単位で冗長 化され、Raftでリーダ選出。 [yb-master] • メタデータの管理。 • 3重に冗長化、Raftでリー ダ選出。
14 (さらに詳しく)YugaByte DBのアーキテクチャ • YugaByte DBは階層化された分散データストアとなっている。 クエリレイヤと分散ドキュメントストア に分かれている。 • クエリレイヤは2つのAPIを提供。
– PostgreSQL互換のSQLを介するAPI – Cassandra起源の独自API • DocDBにデータを格納。 – RocksDBを拡張したLSM(Log Structured Merged Tree)のストレージエンジン。 – ShardingやReplicationなどの機能を提供、 トランザクション機能を実装。
15 (告知) Japan Rook Meetup、やります!!