Oracle TimesTen IMDB - An Introduction
Who am I 12+ years as an Oracle DBA Working as Vice President with an Investment Bank Member of AIOUG Since 2009 Cer$fied ITIL V3 Founda$on IT Service Management Cer1fied ScrumMaster Cer$fied EXIN Cloudf Blogger www.xsmohitsharma.blogspot.com FB https://www.facebook.com/xsmohitsharma FB Groups - ORACLE DBA Solution Center - Admin AIOUG Bengaluru Chapter - Admin Oracle Solution Hub - Share and Learn ORACLE-DBA REAL TIME SCENARIO'S Oracle Performance Tuning Oracle DBA Expertzz. and lot more.
Enabling a Real-Time World Over 1,500 companies worldwide use Oracle TimesTen In Networks In Telecom On Wall Street In the Enterprise Real-Time Billing Service Authorization Order Matching SOAs Call Processing Revenue Assurance Risk Management Call Centers Value Added Services Network & QOS Mgmt Real-Time Analytics Business Intelligence
The Quest for Response Time Why is Response Time Important? Failure to meet service level agreements (SLA) Due to long response time Customer churns Competitive products offer better response time Decreased user productivity and decreased customer satisfaction Unhappy customers Loss of revenue and decreased profitability Effect of lost business and opportunities
Improving Response Time Understanding Latency Requirements Magnetic Disks Slower Disk Cache Array Flash Storage, SSD Network round trips L A T E N C Y Result- set Cache (Client/Server) Buffer Cache Faster Define business requirements for latency Evaluate solutions In- Memory Database
What is Oracle TimesTen In-Memory Database Memory Optimized Relational Database Client/ Server Client- Server TimesTen Client Lib Direct- Linked TimesTen Libraries JDBC / ODBC / ADO.NET / OCI / PLSQL Memory- Resident Database Fast data access Checkpoint Files Transaction Log Files Extremely fast Entire database in memory Microsecond response time Compatible with Oracle Database Standard SQL and PL/SQL, Datatypes JDBC, ODBC, ODP.NET, OCI, Pro*C Persistent and Recoverable Transactional logging and checkpointing Easy to use and deploy
Lightning Fast Response Time 1.78 Millionths of a second 7 Millionths of a second Oracle TimesTen In- Memory Database 11.2.2.0 - Intel Xeon 5670 2.93Ghz, 2 CPUs, 6 cores/cpu - Oracle Linux 5.6
Why is TimesTen In-Memory Database so fast? Client/ Server Client- Server TimesTen Client Lib Direct- Linked TimesTen Libraries JDBC / ODBC / ADO.NET / OCI / PLSQL Memory- Resident Database Fast data access Checkpoint Files Transaction Log Files In-Memory Optimizations Database in shared memory Memory optimized access methods Faster than fully-cached disk-based databases Direct-link for best performance Shared memory mapped into application process Eliminates networking overhead
Development ADO.NET SQL PL/SQL ODBC OCI, Pro*C ttclasses Languages C/C++/C# Java/JDBC J2EE App Servers OR Mapping
Minimal Changes PL/SQL support PL/SQL engine implemented inside TimesTen database Same Oracle PL/SQL language; subset of packages C/C++ support Standard ODBC interface Java support Standard JDBC interface Oracle APIs: ODP.NET, OCI, Pro*C/C++ Support identical API signatures as used for the Oracle Database; subset of functions Minimal application changes
Oracle Timesten vs Oracle Database Comparison TimesTen Oracle Database Checkpoint Checkpoint process DBWR Connections ttserver process Listener Logical files N/A Tablespace Parameter file Sys.odbc.ini initsid.ora Database information N/A Controlfile instance One/more can be running on same daemon No Daemon, each instance has its own processes
Oracle In-Memory Database Cache Telco Services Financial Services ecommerce, Personalisation IMDB Cache Grid Real- Time Analytics Dashboard, Scorecard Data Mart - tier In- memory RDBMS Accelerates applications Uses standard SQL and PL/SQL Caches Oracle Database tables Read- write caching Dynamic and static Automatic synchronization Scales up and scales out Built- in high availability
In-Memory Database Cache Flexible Cache Group Configurations Transactions Cache Groups Automatic Data Synchronization Cache Group describes the data in the Oracle database to cache Collection of related tables All or subset of rows and columns Defined via SQL clause CREATE CACHE GROUP name FROM owner.tab1 (col1, col2), owner.tab2 (col1, col4) WHERE <predicate> Cache tables are regular database tables in TimesTen Joins/search, insert/update/delete
In-Memory Database Caching Automatic Data Synchronization Data Synchronization Reads/Write transactions Reads/Write transactions Reads/Write transactions Read- Write caching Transactions committed in TimesTen cache Parallel write- through of committed transactions to Oracle Database Read- only caching Transactions committed in Oracle Database Multi- stream refresh of committed transactions to TimesTen
In-Memory Database Cache Grid Incremental Scalability Location transparency Usage- driven, adaptive redistribution of cached data Online addition/removal of cache nodes Scale out with growth Parallel searches Transactional consistency
Flexible Caching Options Read-Write and Read-only Pre-loading of cache Data set pre-determined On-demand loading of cache Data set not pre-determined or too large Performance driven Locality optimized for consistent response time Globally shared across all nodes for application transparency Scale-out horizontally with processing capacity
Timesten Installation Steps/ Linux To install TimesTen on Linux System you have to perform these steps:- Shared memory, Semaphores (Kernel Parameters). Depend on server memory. Oracle provide equation to calculate size of segments PermSize + TempSize + LogBufMB + 64 MB Large pages/huge pages (Optional). It s advisable to configure large pages. Use of HugePages is required if the size of the TimesTen main shared memory segment is greater than 256 GB. If there is support for Huge Pages you can check value from cat /proc/meminfo IPC Client/Server (Daemon Ports).
Cont d On Linux/Unix Operating system No GUI provided to install Oracle TimesTen. Download TimesTen Software From OTN: http://www.oracle.com/technetwork/database/database-technologies/ timesten/downloads/index.html To start installation Run the following Command./setup.sh
Installation Time Please choose an instance name for this installation? [ tt1122 ] Instance name will be 'tt1122'. Is this correct? [ yes ] Of the three components: [1] Client/Server and Data Manager [2] Data Manager Only [3] Client Only Which would you like to install? [ 1 ] 1 Where would you like to install the tt1122 instance of TimesTen? [ 1 ] /u01/app/ TimesTen The daemon logs will be located in /u01/app/timesten/tt1122/info Would you like to specify a different location for the daemon logs? [ no ] Installing into /u01/app/timesten/tt1122... Uncompressing...
Installation Time Do you want to use the default port number for the TimesTen daemon? [ yes ] The daemon will run on the default port number (53396). Restrict access to the the TimesTen installation to the group 'oinstall'? [ yes ] Please enter a value for TNS_ADMIN (s=skip)? [ ] /u01/app/db_1/network/admin What is the TCP/IP port number that you want the TimesTen Server to listen on? [ 53397 ] Do you want to install QuickStart and the TimesTen Documentation? [ no ] yes Where would you like to install the quickstart and doc directories (s=skip)? [ /u01/app/timesten/tt1122 ] Where would you like to create the DemoDataStore directory? [ [u01/app/timesten/tt1122/info ] Creating /u01/app/timesten/tt1122/info/demodatastore... Would you like to use TimesTen Replication with Oracle Clusterware? [ no ]
Installation Hints After the installation the Daemon will be started without any DataStore. Creating sys.odbc.ini file needed for DataStore and connections (Direct, Client/Server, or IPC #located at $TT_HOME/info/sys.odbc.ini [TEST_DSN] Driver=/u01/app/oracle/TimesTen/tt11.2/lib/libtten.so DataStore=/u01/app/oracle/info/TEST_DSN LogDir=/opt/oracle/info/TEST_DSN/log PermSize=32 TempSize=32 PLSQL=1 DatabaseCharacterSet=AL32UTF8 OracleNetServiceName=orcl [ODBC Data Sources] MYDS=TimesTen 11.2.1 Driver
Installation Hints After creating the above DataStore Daemon should be restart to load DataStore. ttdaemonadmin restart To test TimesTen Using this DataStore ttisql TEST_DSN Till this step we only configure Timesten Without caching.
For More Information http://www.oracle.com/technetwork/database/timesten Technology white papers Quick Start Guide and tutorials Discussion Forum And more..
xsmohitsharma@gmail.com @xsmohitsharma xsmohitsharam.blogspot.com in.linkedin.com/in/xsmohit