Equnix Business Solutions (Equnix) is an IT Solution provider in Indonesia, providing comprehensive solution services especially on the infrastructure side for corporate business needs based on research and Open Source. Equnix has 3 (three) main services known as the Trilogy of Services: Support (Maintenance/Managed), World class level of Software Development, and Expert Consulting and Assessment for High Performance Transactions System. Equnix is customer oriented, not product or principal. Equal opportunity based on merit is our credo in managing HR development.
Oracle to PostgreSQL, Challenges to Opportunity.pdf
1. EQUNIX PostgreSQL Professional Gathering
Plaza Semanggi 9 Fl, Unit 9
Jl. Jend Sudirman Kav 50, Jakarta - 12930 Indonesia
8 Eu Tong Street, #14-94, THE CENTRAL Singapore
+6221-22866662 | info@equnix.asia
Oracle to PostgreSQL,
A Challenge or Opportunity?
3. We are EQUNIX.ASIA, we are:
info@equnix.asia | http://equnix.asia
Mission
Critical
Services
World Class
Software
Development
System
Optimization
Expertise
7. RDBMS - L'histoire de development
A relational database management system (RDBMS) is a database management
system (DBMS) that is based on the relational model as introduced by E. F. Codd in
1970, of IBM's San Jose Research Laboratory. Many popular databases currently in
use are based on the relational database model.
8. RDBMS - A.C.I.D
Atomicity
Either all of transaction happens or nothing
Consistency
Database is brought from one consistent state to
another
Durability
After commit, the transaction is permanent/durable.
No data lost potential
Isolation
The effects of transaction may not be visible to other
transactions until the transaction committed
11. The Compatibility
SQL ANSI Coverage
Full Core conformance = 179 features on Core SQL 2011 (and 2008)
PostgreSQL conforms to at least 160.
Features Oracle PostgreSQL
Parallelism Requires Hint Automatically Loaded on
SELECT
Table Partitioning Supported Supported
Tablespace Supported Supported
Stored Procedures &
Functions
Supported Supported
Online Backup Active
DataGuard/GoldenGate
Natively
12. PostgreSQL ENTERPRISE Features
Reliability:
Secure Data Access;
Financial Cryptography;
100% Ensure Durability
Availability:
Replication;
Advanced Recovery;
High Availability;
Uptime warranty up to: 99,99%
Scalability:
Hi Perf Tuning;
Scale Up/Scale Out;
Clustering;
17. 1. Cold Backup (Offline mode)
Stores data into a offline mode (file dump). There are 2 kinds of cold backup:
a. Full Backup,
Use SQL dump, or just copy the whole datadir
b. Incremental Backup.
Logs the archive and play back later.
2. Warm Backup
The backup machine is up and running, but the service is not ready yet, usually
caused by the disk synchronization (PPRC service or DRBD). So the backup is done by 3rd party other than
database itself.
3. Hot Backup
The backup is on-line, and the service is also ready to serve. It is already hot, as hot as the Master / Main
server. There are some kind of Hot backup:
a. Synchronous Replication,
b. Asynchronous Replication,
c. Multi Master Replication
Multi-tier Backup Features
18. A Backup is not a “backup” if cannot be restored
Point-in-Time Recovery mechanism, allows you to go “Back to the Future” to timeline you
decide
Recovering an accidentally dropped data? Auditing a suspicious event on your database?
Can be used to replay transactions from last week until a specific day.
Point-in-Time Recovery
19. High Availability amongst PostgreSQL
Enterprise Level High Availability
configuration without hassle
Keep It Simple, SUCCESS!
20. Winning Stories - EDII
Oracle Migration
From 4 Servers Oracle RAC
System
Into 1 Server Intel
PostgreSQL
23. Migration STAGES
Migration Stages
A. Migration Assessment
a. Preliminary
b. Comprehensive
B. Report and Brainstorming
C. Migration Preparation
a. Schematic Migration
b. Data Migration (Test and clean up)
c. Logic Migration
~To win the battle, you must understand your
enemy~ Sun Tzu.
D. System Migration
a. Finalization Rundown
b. 1st Rehearsal
c. Evaluation
d. 2nd Rehearsal (if needed)
e. Evaluation
f. Migration!
24. Migration Assessment
Preliminary Assessment
Given a couple of days (2 days) to
analyze all the database Objects briefly
to get some ideas on how long it take to
do such Comprehensive Assessment.
Look for potential Stopper: System
Functions, Customization possibility,
Specific Function/Datatype, Allowable
Downtime, Any potential copyright
infringement, etc. Develop Mitigation,
solution and possibility workaround.
Comprehensive Assessment
Assess all the object mentioned in the
scope of work, very detailed. Produce
Comprehensive Assessment Report,
consist:
1. Level of Difficulties
2. How many Mandays Effort
3. Migration Schedules
4. Proposed Migration Rundown
5. Analysis Report
(This is Commercial Effort)
25. Schematic Migration
Most of the Structures are compatible with PostgreSQL (even not 100%).
Prepare the “bucket” first, then the “water”
❖ Dump all database object structures (tables, sequences, views, etc.)
❖ Check whether specific data types should be converted
❖ User Defined Types should be deeply examined
❖ Constraints (PK, FK, Uniqueness, Indices) will be recreated in
PostgreSQL, as long as Database Object Relationship is kept consistent
26. Data Migration - Analysis
Migration Data from Oracle to PostgreSQL is dealing with downtime and
ETL, and somehow it needs very fast.
❖ How much is the Downtime tolerance
❖ Housekeep data from Oracle Source Database
❖ Doing Stress Test to the pre-migrated data
❖ Using FDW/ETL Tools, it is possible to start synchronizing data without
interrupting current Transactional Process on Source Database
27. Logic Migration - Analysis
Logic conversion is the PAIN, when doing migration.
Requires a deep understanding on how the function works.
❖ Streamline the Logic
❖ How many total line of codes used on Stored
Procedures/Functions/Packages
❖ Is there any Oracle specific functions used?
❖ Create a mimic for called functions, as long as output is the same
❖ PostgreSQL is highly extensible platform, if not supported yet, we can
create it as long as we have the expertise
❖ Do System Integration and Regression Test with application
28. System Migration - Analysis
1. How long downtime can be tolerate by
Management?
2. Based on the finding from Data
Migration, we can understand how long
it take to migration the live data, this is
the main consideration to develop
Rundown System Migration
3. How many Instance Application involve
in the System Migration?
4. How many party involved in System
Migration?
Goal:
1. Develop Rundown System Migration
2. Develop fallback scenario
3. Rehearse Rundown System
Migration smoothly
4. Develop rock solid Rundown and its
fallback plan.
5. Ensure it can be run within
constraints
6. RUN SYSTEM MIGRATION
29. Case Study 1 (by Chris Travers)
Bioprospecting platform by a Danish biotech company
❖ 12TB of genome and protein data
❖ 100 million transactions a day
❖ 12TB of genome and protein data
❖ 100 million transactions a day or more
❖ Main workload similar to most line of business or financial applications
❖ Single PostgreSQL server backing 1000 core scientific computing cluster
running 24x7
30. Case Study 2 (by Chris Travers)
Advertising Analytics Platform by German Ad
❖ 1PB of mobile event data
❖ 1-300000 requests a second
❖ Near-real-time analytics
❖ Queries similar to data warehouses
❖ Distributed, “Big Data” environment
31. Technology - Foreign Data Wrapper (FDW)
PostgreSQL has a useful feature called Foreign Data Wrapper, which lets you
create foreign tables in a PostgreSQL database from other data source.
When you make a query against a foreign table, the Foreign Data Wrapper
will query the external data source and return the results as if they were
coming from a table in your database.
34. DATABASE AGGREGATION
Head Office
TABLE A
(Subscriber)
DATABASE
Medan
TABLE A
(Publisher)
DATABASE
Bandung
TABLE A
(Publisher)
TABLE C
(Subscriber)
TABLE D
(Subscriber)
TABLE B
(Subscriber)
DATABASE
Surabaya
TABLE A
(Publisher)
DATABASE
Jakarta
TABLE A
(Publisher)
Table Replication (Realtime)
38. Financial
Services
Factory Oil & Gas Retail Insurance
Training Research
Contributor Developer Professional
Industries
Education
Certification
Community
Provider
50. PGConf ASIA - Indonesia Bali 2019
We will held an International Event in Sept
2019, it is PostgreSQL Conference Asia in Bali
2019.
Please come there, meet and greet with
Developers, Architects, Geeks, Hackers,
Beaches, Suns, etc