[db tech showcase tokyo 2014] b11: [in-memory db: sap hana]...

38
Use this title slide only with an image SAP HANA OLTP/OLAPをシングルデータイメージで実現するアーキテクチャ 花敏久([email protected]) SAPジャパン株式会社 20141111

Upload: insight-technology-inc

Post on 30-Jun-2015

1.331 views

Category:

Technology


9 download

DESCRIPTION

In-Memory DBのSAP HANAは、OLTP/OLAPを1つのデータベースで高速に処理します。これは、OLAPに強いカラムストア技術とOLTPを高速化するSAP独自のテクノロジーを採用することにより実現しています。 このセッションでは、これらテクノロジーの解説とSAP HANAのデータベースアーキテクチャについて説明します。 【主な内容】 ・カラムストア/ローストアのサポート ・インサートオンリーによる更新の完了 ・更新を遅延・集約させる仕組み ・オンザフライ集計 ・更新と参照を整合させる仕組み ・・・他

TRANSCRIPT

  • 1. SAP HANA OLTP/OLAP([email protected])SAP20141111Use this title slide only with an image

2. SAPSAPSAPSAPSAPSAP 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 2 3. SAP HANA(DRAM)VS SAPHasso PlattnerCache 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 3 4. SAP HANA SAP HANACPUI/O50MemoryI/O50,000SSDHard DISKStorage64-bit 2TB RAM100GB/s CPUMemory++++ + / / HDDDisk1000I/O5,000,000 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 4 5. OLTP OLAP OLTP OLAP OLTP OLAP 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 5 6. SAP HANA OLAP / OLTP Read/Write OLAP OLTP OLTPOLAPSAP HANA OLTPSAP HANA/ 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 6 7. SAP HANAOLTP OLTP OLAP 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 7 8. SAP HANA 9. SAP HANADictionary/Value-ID Dictionary/ValueID DictionaryValueId Value-IDValueIDRecID Inverted Index:RecIDValueIDLogical TableOrderCountryProductSales456Francecorn1000457Italywheat900458Spainrice600459Italyrice800460Denmarkcorn500461Denmarkrice600462Belgiumrice600463Italyrice1100Dictionary indexValueID RecID ValueID1Belgium2Denmark3France4Italy5SpainValueID(bit fields)1324354452627184Inverted1725,63142,4,853Dictionary53bit 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 9 10. SAP HANA Dictionary compression Advanced compression Prefix Encoding Run Length Encoding (RLE) Cluster Encoding Sparse Encoding Indirect encodingLogical Table 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 10OrderCountryProductSales456Francecorn1000457Italywheat900458Spainrice600459Italyrice800460Denmarkcorn500461Denmarkrice600462Belgiumrice600463Italyrice11001corn2wheat3rice122x313x3ProductDictinary 11. 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 11 12. 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 12 13. 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 13 14. OLAPOLTPOLTPOLAPInsert Only 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 14 15. OLTP 16. OLTPSAP HANAOLTP Insert Only Insert/Update/DeleteInsert / Terminology 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 16 17. Insert Only, InsertOnlyRead 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 17 18. Insert Only, SelectDBInsert, Update, DeleteInsert Only 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 18 19. / Valid/Invalid Read MVCC 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 19 20. New WriteReadWriteRead(New)ReadWrite(New)(New)(New) 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 20 21. OLAP 22. or HANA SQLMDX etc etc etc SAP BusinesObjects Excel 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 22 23. MDXSQLMDXSQL 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 23 24. 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 24 25. SAP HANA 26. SAP HANAXeon E7NUMA (Non Uniform Memory Access)CPU 1Core1 Core2Core3 Core4CPU 1Core1 Core2Core3 Core4localhigh-speed interconnectCPU 1Core1 Core2Core3 Core4CPU 1Core1 Core2Core3 Core4remoteRAMRAMRAMRAMRAMRAMRAMRAMRAMRAMRAMRAMSMP (Symmetric MultiProcessing))CPU 1Core1 Core2Core3 Core4CPU 1Core1 Core2Core3 Core4RAMRAMRAMSystem Bus (IMC) NUMA vs. IO (FSB / crossbar) () remoteremote 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 27 27. SAP HANA () ()JoinAggregateQuery 1:Query 2: JoinAggregate()Core 1:SortSortQuery 3: Join AggregateCore 2:Core 3:Core 4:Core 5:Core 6: (e.g. join, agg, sort) HANA (rule-based, cost-based) Jobs over time HANA 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 28 28. Parallel Job Execution Core 1:Core 2:Core 3:Core 4:Core 5:Core 6:Job = e.g. etcJobs over time CPU ( CPU HANA NUMA 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 29 29. SAP HANA HANAstart/stopSAP HANA Appliance(Master) Node(Master) Name Server(Master) Index ServerStatistics ServerPreprocessorSAP HANA Studio RepositorySAP Host AgentSoftware Update Manager(Slave) Node 1Name ServerName ServerIndex ServerPreprocessorSAP Host Agent(Slave) Node nSAP Host AgentShared storage for fail-over and recoveryIndex ServerPreprocessor 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 30 30. SAP HANA DataVolumeLogVolumeMaster nodeHDB netWorker nodeStandby node(s)DataVolumeLogVolumeTopology () Standby node (HW) HDB HANAAuto fail-over 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 31 31. SAP HANA Distributed Execution locationdataMaster Node(Master)Name ServerIndex Server BOptimizerExecutorIn-MemoryStorePersistenceIndex Server AOptimizerExecutorIn-MemoryStorePersistenceIndex Server COptimizerExecutorIn-MemoryStorePersistencelocationdata(Worker)Name Server Blocationdata(Worker)Name Server C(Distributed QueryProcessing) () DistributedTransactions SAP HANAatomicity 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 32 32. SAP HANA ( + cpu) . (select) . (runtime) = () = 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 33 33. 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 35 : SQL o : o SQLWhere : o : 34. read/ write, OLAP/OLTP SQL 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 36 35. SAP HANA HANAStep 1. SAP HANA create / alter table sys.table_groupsStep 2. master, slave, all (rev71: slave#1, all#1) () initial_partitions(), min_rows_partitioning,repartitioning_threshold SQL_sys_rt.table_placement (HANA studio SQL-console) create/alter table DDLlocation_clause, partition_clause move_clause 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 37 36. SAP HANA (Table Redistribution)1. 2. .ini SYS.REORG_PLAN_ 2014 SAP AG or an SAP affiliate company. All rights reserved. Public 38 37. HANA Cloud PlatformSAP HANASAP HANA 1.0 SPS9 etc 2014 SAP AG or an SAP affiliate company. All rights reserved. 38. 11/12 Wed.,15:00-15:50BSession5 2014 SAP AG or an SAP affiliate company. All rights reserved.