SlideShare ist ein Scribd-Unternehmen logo
1 von 21
Downloaden Sie, um offline zu lesen
2007.DB
                         http://www.ospn.jp/osc2007.db/




PostgreSQL 8.3 Update
      8.3


    PostgreSQL       / NTT OSS



             2007.6.23

                                                             1
8.1 8.3


                                    autovacuum
8.1

                fillfactor   GIN
8.2

                 HOT         XML   autovacuum
8.3



                                                2
8.1 8.2


                                    autovacuum
8.1

                fillfactor   GIN
8.2

                 HOT         XML   autovacuum
8.3



                                                3
CPU
バ                                         TPC-C(OLTP)           CPU
ー       5
ジ                                                        8.2
ョ                      8.0
ン                                                       8CPU
ご       4              8.1
と                      8.2                                                        NUMA
の
、
C       3
P
U
1
個       2                                      8.1              SMP
に                                             4CPU
対                                                               (8CPU   )
す       1
る                                 8.0
相                                2CPU
対
性       0
能                 1          2          4           8      12     16    20   24    28    32
                                                                                              core
    Scaling PostgreSQL on SMP Architectures
    Doug Tolbert (Unisys), PGCon 2007, Ottawa, 2007-05-24                                 4
    http://www.pgcon.org/2007/schedule/events/16.en.html
• tsearch2
    : SELECT isbn,title FROM books
        WHERE fts @@ to_tsquery(‘word1 & word2’);
        – GiST, GIN:                               2
        –                                  ,

          tsearch2 GiST               GIN


      GiST       112ms          280ms             176s 146MB
                                                               •   → GiST
      GIN          39ms 3344ms                    532s 306MB
                                                               •   → GIN
                 ×0.35 ×11.94                  ×3.02 ×2.10


  •
Full-Text Search in PostgreSQL
Oleg Bartunov PGCon 2007, Ottawa, 2007/5/23                             5
http://www.pgcon.org/2007/schedule/events/13.en.html
VACUUM
•       UPDATE
    –
    –




                  VACUUM




                           6
PostgreSQL 8.3
1.
     –   HOT OLTP

2.
     –

3.
     –              WAL

4. VACUUM
     –   VACUUM      autovacuum


                                  7
(1) 8.3
•          HOT                         FillFactor
                                      Fill Factor           TPS
                                TPS
    –                           280
    – pgbench
                                260
                   40%
                                240
•
                                220                         40%UP!
    –
                                200
    – VACUUM
       • VACUUM                 180
                                160
                                                   HOT
•           FillFactor          140
    –                           120                HOT
    – 100%(           )         100
      90~95%                          70    75     80 85 90 95 100
       • ALTER TABLE name                          Fill Factor (%)
         SET (fillfactor=95);
                                           pgbench -s400 (5GB)
                                           NTT OSS Center
                                                                     8
HOT                   (1)
• 8.2   UPDATE

              ID
              001   A    10         …

              002   B   8→7
              003   C    20
              004   D    12




                                        9
HOT                     (2)
• 8.2        UPDATE

                 ID
                 001   A   10
                 002   B   8
                 003   C   20   UPDATE
                 004   D   12
        ×2       002   B   7
(CPU)


        ×3
(I/O)

                                         10
HOT                          (3)
• 8.3 HOT UPDATE

        →           ID
                                     1
                    001   A   10
                    002   B   8
                                   UPDATE
            Heap    002   B   7
            Only    003   C   20
            Tuple
                    004   D   12
 HOT
            ×1
(CPU)
                               1/2
            ×1
(I/O)                                1/3
                                               11
HOT                   (4)
• 8.3 HOT UPDATE
                              HOT
              ID             VACUUM

              001   A   10
              002   B   6
                             UPDATE
              002   B   7
              003   C   20
              004   D   12
HOT
        ×1
(CPU)

        ×1     VACUUM
(I/O)
                                      12
HOT
• UPDATE
    – DELETE+INSERT
•
    –
    –
•
    – FillFactor
    –      VACUUM


                    VACUUM   13
PostgreSQL 8.3
1.
     –   HOT OLTP

2.
     –

3.
     –              WAL

4. VACUUM
     –   VACUUM      autovacuum


                                  14
(2) 8.3
 •                                       (LDC)




EnterpriseDB Performance Testing                 15
http://community.enterprisedb.com/ldc/
•
    –                  (write)
    –                   (fsync)

    8.2

    8.3


          PostgreSQL
               I/O
           I/O
                                  16
PostgreSQL 8.3
1.
     –   HOT OLTP

2.
     –

3.
     –              WAL

4. VACUUM
     –   VACUUM      autovacuum


                                  17
(3) 8.3
•
    – WAL                               I/O                 1/2

                                                                  BEGIN;
                                                                  TRUNCATE t;
                                        35%
                                                                  COPY t FROM …;
          0       20        40   60          80                   COMMIT;
        pgbench -i -s30 (             COPY              )
                                         NTT OSS Center


•                           (                       )
    –
          • InfoFrame DB Maintenance (NEC)
          • pg_bulkload (           , pgFoundry)                   8.3

                                                                              18
(4) 8.3      VACUUM
• autovacuum           VACUUM
  –                         (autovacuum_max_workers)

          1
  8.2   → VACUUM
                            8.3
                                A           B

              VACUUM




                                                19
autovacuum
8.1

      fillfactor   GIN
8.2

       HOT         XML   autovacuum
8.3



                                  20
PostgreSQL 8.3
 –
     • HOT               OLTP
 –
     • VACUUM, Background Writer (            )
 –
     • SQL/XML,                      ,   , etc.




                                                  21

Weitere ähnliche Inhalte

Ähnlich wie PostgreSQL 8.3 Update

BFS Distribution Via DCM
BFS Distribution Via DCMBFS Distribution Via DCM
BFS Distribution Via DCMowenlin
 
Adaptive Query Execution: Speeding Up Spark SQL at Runtime
Adaptive Query Execution: Speeding Up Spark SQL at RuntimeAdaptive Query Execution: Speeding Up Spark SQL at Runtime
Adaptive Query Execution: Speeding Up Spark SQL at RuntimeDatabricks
 
110604 2nd SyoueneIT Workshop
110604 2nd SyoueneIT Workshop110604 2nd SyoueneIT Workshop
110604 2nd SyoueneIT WorkshopKensuke SAEKI
 
customization of a deep learning accelerator, based on NVDLA
customization of a deep learning accelerator, based on NVDLAcustomization of a deep learning accelerator, based on NVDLA
customization of a deep learning accelerator, based on NVDLAShien-Chun Luo
 
Top500 11/2011 BOF Slides
Top500 11/2011 BOF SlidesTop500 11/2011 BOF Slides
Top500 11/2011 BOF Slidestop500
 
Thermal modeling and management of cluster storage systems xunfei jiang 2014
Thermal modeling and management of cluster storage systems xunfei jiang 2014Thermal modeling and management of cluster storage systems xunfei jiang 2014
Thermal modeling and management of cluster storage systems xunfei jiang 2014Xiao Qin
 
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On SemiconductorOriginal PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductorauthelectroniccom
 
Cuda 6 performance_report
Cuda 6 performance_reportCuda 6 performance_report
Cuda 6 performance_reportMichael Zhang
 
The Data Center and Hadoop
The Data Center and HadoopThe Data Center and Hadoop
The Data Center and HadoopDataWorks Summit
 
計算力学シミュレーションに GPU は役立つのか?
計算力学シミュレーションに GPU は役立つのか?計算力学シミュレーションに GPU は役立つのか?
計算力学シミュレーションに GPU は役立つのか?Shinnosuke Furuya
 
Exploring the Huawei HG8010H GPON ONT
Exploring the Huawei HG8010H GPON ONTExploring the Huawei HG8010H GPON ONT
Exploring the Huawei HG8010H GPON ONTMarco d'Itri
 
Oracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby databaseOracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby databaseuzzal basak
 
Researching postgresql
Researching postgresqlResearching postgresql
Researching postgresqlFernando Ike
 
コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!Takahiro Itagaki
 

Ähnlich wie PostgreSQL 8.3 Update (20)

PostgreSQL 8.4 Update
PostgreSQL 8.4 UpdatePostgreSQL 8.4 Update
PostgreSQL 8.4 Update
 
8051 MICROCONTROLLER
8051 MICROCONTROLLER 8051 MICROCONTROLLER
8051 MICROCONTROLLER
 
BFS Distribution Via DCM
BFS Distribution Via DCMBFS Distribution Via DCM
BFS Distribution Via DCM
 
Adaptive Query Execution: Speeding Up Spark SQL at Runtime
Adaptive Query Execution: Speeding Up Spark SQL at RuntimeAdaptive Query Execution: Speeding Up Spark SQL at Runtime
Adaptive Query Execution: Speeding Up Spark SQL at Runtime
 
110604 2nd SyoueneIT Workshop
110604 2nd SyoueneIT Workshop110604 2nd SyoueneIT Workshop
110604 2nd SyoueneIT Workshop
 
customization of a deep learning accelerator, based on NVDLA
customization of a deep learning accelerator, based on NVDLAcustomization of a deep learning accelerator, based on NVDLA
customization of a deep learning accelerator, based on NVDLA
 
Example Application of GPU
Example Application of GPUExample Application of GPU
Example Application of GPU
 
67WS Event FIO Primer
67WS Event FIO Primer67WS Event FIO Primer
67WS Event FIO Primer
 
microprocessor
microprocessormicroprocessor
microprocessor
 
Top500 11/2011 BOF Slides
Top500 11/2011 BOF SlidesTop500 11/2011 BOF Slides
Top500 11/2011 BOF Slides
 
25l8005
25l800525l8005
25l8005
 
Thermal modeling and management of cluster storage systems xunfei jiang 2014
Thermal modeling and management of cluster storage systems xunfei jiang 2014Thermal modeling and management of cluster storage systems xunfei jiang 2014
Thermal modeling and management of cluster storage systems xunfei jiang 2014
 
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On SemiconductorOriginal PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
Original PNP Transistors PZT2907A PZT2907 2907 P2F SOT22-3 New On Semiconductor
 
Cuda 6 performance_report
Cuda 6 performance_reportCuda 6 performance_report
Cuda 6 performance_report
 
The Data Center and Hadoop
The Data Center and HadoopThe Data Center and Hadoop
The Data Center and Hadoop
 
計算力学シミュレーションに GPU は役立つのか?
計算力学シミュレーションに GPU は役立つのか?計算力学シミュレーションに GPU は役立つのか?
計算力学シミュレーションに GPU は役立つのか?
 
Exploring the Huawei HG8010H GPON ONT
Exploring the Huawei HG8010H GPON ONTExploring the Huawei HG8010H GPON ONT
Exploring the Huawei HG8010H GPON ONT
 
Oracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby databaseOracle goldengate 11g schema replication from standby database
Oracle goldengate 11g schema replication from standby database
 
Researching postgresql
Researching postgresqlResearching postgresql
Researching postgresql
 
コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!
 

Mehr von Takahiro Itagaki

PostgreSQL 9.0 in OSC@Tokyo,Okinawa
PostgreSQL 9.0 in OSC@Tokyo,OkinawaPostgreSQL 9.0 in OSC@Tokyo,Okinawa
PostgreSQL 9.0 in OSC@Tokyo,OkinawaTakahiro Itagaki
 
問合せ最適化インサイド
問合せ最適化インサイド問合せ最適化インサイド
問合せ最適化インサイドTakahiro Itagaki
 
Wish list from PostgreSQL - Linux Kernel Summit 2009
Wish list from PostgreSQL - Linux Kernel Summit 2009Wish list from PostgreSQL - Linux Kernel Summit 2009
Wish list from PostgreSQL - Linux Kernel Summit 2009Takahiro Itagaki
 
PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~
PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~
PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~Takahiro Itagaki
 
PostgreSQLのこれまで、9.0、そしてこれから
PostgreSQLのこれまで、9.0、そしてこれからPostgreSQLのこれまで、9.0、そしてこれから
PostgreSQLのこれまで、9.0、そしてこれからTakahiro Itagaki
 

Mehr von Takahiro Itagaki (6)

textsearch groonga v0.1
textsearch groonga v0.1textsearch groonga v0.1
textsearch groonga v0.1
 
PostgreSQL 9.0 in OSC@Tokyo,Okinawa
PostgreSQL 9.0 in OSC@Tokyo,OkinawaPostgreSQL 9.0 in OSC@Tokyo,Okinawa
PostgreSQL 9.0 in OSC@Tokyo,Okinawa
 
問合せ最適化インサイド
問合せ最適化インサイド問合せ最適化インサイド
問合せ最適化インサイド
 
Wish list from PostgreSQL - Linux Kernel Summit 2009
Wish list from PostgreSQL - Linux Kernel Summit 2009Wish list from PostgreSQL - Linux Kernel Summit 2009
Wish list from PostgreSQL - Linux Kernel Summit 2009
 
PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~
PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~
PostgreSQL 9.0 Update ~ホット・スタンバイがやってきた!~
 
PostgreSQLのこれまで、9.0、そしてこれから
PostgreSQLのこれまで、9.0、そしてこれからPostgreSQLのこれまで、9.0、そしてこれから
PostgreSQLのこれまで、9.0、そしてこれから
 

Kürzlich hochgeladen

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusZilliz
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024The Digital Insurer
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 

Kürzlich hochgeladen (20)

2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 

PostgreSQL 8.3 Update

  • 1. 2007.DB http://www.ospn.jp/osc2007.db/ PostgreSQL 8.3 Update 8.3 PostgreSQL / NTT OSS 2007.6.23 1
  • 2. 8.1 8.3 autovacuum 8.1 fillfactor GIN 8.2 HOT XML autovacuum 8.3 2
  • 3. 8.1 8.2 autovacuum 8.1 fillfactor GIN 8.2 HOT XML autovacuum 8.3 3
  • 4. CPU バ TPC-C(OLTP) CPU ー 5 ジ 8.2 ョ 8.0 ン 8CPU ご 4 8.1 と 8.2 NUMA の 、 C 3 P U 1 個 2 8.1 SMP に 4CPU 対 (8CPU ) す 1 る 8.0 相 2CPU 対 性 0 能 1 2 4 8 12 16 20 24 28 32 core Scaling PostgreSQL on SMP Architectures Doug Tolbert (Unisys), PGCon 2007, Ottawa, 2007-05-24 4 http://www.pgcon.org/2007/schedule/events/16.en.html
  • 5. • tsearch2 : SELECT isbn,title FROM books WHERE fts @@ to_tsquery(‘word1 & word2’); – GiST, GIN: 2 – , tsearch2 GiST GIN GiST 112ms 280ms 176s 146MB • → GiST GIN 39ms 3344ms 532s 306MB • → GIN ×0.35 ×11.94 ×3.02 ×2.10 • Full-Text Search in PostgreSQL Oleg Bartunov PGCon 2007, Ottawa, 2007/5/23 5 http://www.pgcon.org/2007/schedule/events/13.en.html
  • 6. VACUUM • UPDATE – – VACUUM 6
  • 7. PostgreSQL 8.3 1. – HOT OLTP 2. – 3. – WAL 4. VACUUM – VACUUM autovacuum 7
  • 8. (1) 8.3 • HOT FillFactor Fill Factor TPS TPS – 280 – pgbench 260 40% 240 • 220 40%UP! – 200 – VACUUM • VACUUM 180 160 HOT • FillFactor 140 – 120 HOT – 100%( ) 100 90~95% 70 75 80 85 90 95 100 • ALTER TABLE name Fill Factor (%) SET (fillfactor=95); pgbench -s400 (5GB) NTT OSS Center 8
  • 9. HOT (1) • 8.2 UPDATE ID 001 A 10 … 002 B 8→7 003 C 20 004 D 12 9
  • 10. HOT (2) • 8.2 UPDATE ID 001 A 10 002 B 8 003 C 20 UPDATE 004 D 12 ×2 002 B 7 (CPU) ×3 (I/O) 10
  • 11. HOT (3) • 8.3 HOT UPDATE → ID 1 001 A 10 002 B 8 UPDATE Heap 002 B 7 Only 003 C 20 Tuple 004 D 12 HOT ×1 (CPU) 1/2 ×1 (I/O) 1/3 11
  • 12. HOT (4) • 8.3 HOT UPDATE HOT ID VACUUM 001 A 10 002 B 6 UPDATE 002 B 7 003 C 20 004 D 12 HOT ×1 (CPU) ×1 VACUUM (I/O) 12
  • 13. HOT • UPDATE – DELETE+INSERT • – – • – FillFactor – VACUUM VACUUM 13
  • 14. PostgreSQL 8.3 1. – HOT OLTP 2. – 3. – WAL 4. VACUUM – VACUUM autovacuum 14
  • 15. (2) 8.3 • (LDC) EnterpriseDB Performance Testing 15 http://community.enterprisedb.com/ldc/
  • 16. – (write) – (fsync) 8.2 8.3 PostgreSQL I/O I/O 16
  • 17. PostgreSQL 8.3 1. – HOT OLTP 2. – 3. – WAL 4. VACUUM – VACUUM autovacuum 17
  • 18. (3) 8.3 • – WAL I/O 1/2 BEGIN; TRUNCATE t; 35% COPY t FROM …; 0 20 40 60 80 COMMIT; pgbench -i -s30 ( COPY ) NTT OSS Center • ( ) – • InfoFrame DB Maintenance (NEC) • pg_bulkload ( , pgFoundry) 8.3 18
  • 19. (4) 8.3 VACUUM • autovacuum VACUUM – (autovacuum_max_workers) 1 8.2 → VACUUM 8.3 A B VACUUM 19
  • 20. autovacuum 8.1 fillfactor GIN 8.2 HOT XML autovacuum 8.3 20
  • 21. PostgreSQL 8.3 – • HOT OLTP – • VACUUM, Background Writer ( ) – • SQL/XML, , , etc. 21