Guide to IBM Informix Enterprise .iv Guide to IBM Informix Enterprise Replication Section I Introducing

Embed Size (px)

Text of Guide to IBM Informix Enterprise .iv Guide to IBM Informix Enterprise Replication Section I...

  • Guide to IBM InformixEnterprise Replication

    Version 9.3August 2001Part No. 000-8334

  • ii Guide to IBM Informix

    Copyright International Business Machines Corporation 2001. All rights reserved.

    Trademarks

    AIX; DB2; DB2 Universal Database; Distributed Relational Database Architecture; NUMA-Q; OS/2, OS/390, andOS/400; IBM Informix; C-ISAM; Foundation.2000TM; IBM Informix 4GL; IBM Informix DataBlade Module;Client SDKTM; CloudscapeTM; CloudsyncTM; IBM Informix Connect; IBM Informix Driver for JDBC; DynamicConnectTM; IBM Informix Dynamic Scalable ArchitectureTM (DSA); IBM Informix Dynamic ServerTM; IBMInformix Enterprise Gateway Manager (Enterprise Gateway Manager); IBM Informix Extended ParallelServerTM; i. Financial ServicesTM; J/FoundationTM; MaxConnectTM; Object TranslatorTM; Red BrickDecision ServerTM; IBM Informix SE; IBM Informix SQL; InformiXMLTM; RedBack; SystemBuilderTM; U2TM;UniData; UniVerse; wintegrate are trademarks or registered trademarks of International BusinessMachines Corporation.

    Java and all Java-based trademarks and logos are trademarks or registered trademarks of Sun Microsystems,Inc. in the United States and other countries.

    Windows, Windows NT, and Excel are either registered trademarks or trademarks of Microsoft Corporation inthe United States and/or other countries.

    UNIX is a registered trademark in the United States and other countries licensed exclusively through X/OpenCompany Limited.

    Other company, product, and service names used in this publication may be trademarks or service marks ofothers.

    Documentation Team: Diane Kirsten-Martin, Karin Moore, Hanna Nelson

    Enterprise Replication

  • Table of Contents

    Table ofContents

    IntroductionIn This Introduction . . . . . . . . . . . . . . . . . 3About This Manual . . . . . . . . . . . . . . . . . . 3

    Types of Users . . . . . . . . . . . . . . . . . . 3Software Dependencies . . . . . . . . . . . . . . . 4Assumptions About Your Locale. . . . . . . . . . . . 4Demonstration Databases . . . . . . . . . . . . . . 5

    New Features in Dynamic Server, Version 9.3 . . . . . . . . . 5Extensibility Enhancements . . . . . . . . . . . . . 6Performance Improvements . . . . . . . . . . . . . 7Functionality Enhancements . . . . . . . . . . . . . 8Command-Line Changes . . . . . . . . . . . . . . 9

    Documentation Conventions . . . . . . . . . . . . . . 10Typographical Conventions . . . . . . . . . . . . . 10Icon Conventions . . . . . . . . . . . . . . . . . 11Command-Line Conventions . . . . . . . . . . . . . 12Sample-Code Conventions . . . . . . . . . . . . . . 14

    Additional Documentation . . . . . . . . . . . . . . . 15Related Reading . . . . . . . . . . . . . . . . . . . 17Compliance with Industry Standards . . . . . . . . . . . 18Informix Welcomes Your Comments . . . . . . . . . . . . 18

  • iv Guide

    Section I Introducing Enterprise Replication

    Chapter 1 About Informix Enterprise ReplicationIn This Chapter . . . . . . . . . . . . . . . . . . . 1-3Informix Enterprise Replication . . . . . . . . . . . . . 1-3

    Asynchronous Data Replication. . . . . . . . . . . . 1-4Log-Based Data Capture . . . . . . . . . . . . . . 1-5High Performance . . . . . . . . . . . . . . . . 1-6High Availability . . . . . . . . . . . . . . . . . 1-6Consistent Information Delivery . . . . . . . . . . . 1-6Flexible Architecture . . . . . . . . . . . . . . . 1-7Centralized Administration . . . . . . . . . . . . . 1-8

    How Enterprise Replication Replicates Data . . . . . . . . . 1-8Capture Transactions . . . . . . . . . . . . . . . 1-9Evaluate Data for Replication . . . . . . . . . . . . 1-9Distribute Data . . . . . . . . . . . . . . . . . 1-17Apply Replicated Data . . . . . . . . . . . . . . . 1-17

    Chapter 2 Overview of Enterprise Replication AdministrationIn This Chapter . . . . . . . . . . . . . . . . . . . 2-3Overview of Enterprise Replication Administration . . . . . . 2-3Enterprise Replication Server Administrator . . . . . . . . . 2-4Enterprise Replication Terminology . . . . . . . . . . . . 2-4

    Enterprise Replication Server . . . . . . . . . . . . 2-5Replicate. . . . . . . . . . . . . . . . . . . . 2-5Participant . . . . . . . . . . . . . . . . . . . 2-5Replicate Set . . . . . . . . . . . . . . . . . . 2-6Global Catalog . . . . . . . . . . . . . . . . . 2-6Operational Considerations . . . . . . . . . . . . . 2-8Backup and Restore Considerations . . . . . . . . . . 2-9Database and Table Design Considerations . . . . . . . . 2-9Transaction Processing Considerations . . . . . . . . . 2-14Replication Environment Considerations . . . . . . . . 2-17Enterprise Replication Data Types . . . . . . . . . . . 2-19

    to IBM Informix Enterprise Replication

  • Section II Setting Up and Managing Enterprise Replication

    Chapter 3 Selecting the Enterprise Replication System and Network TopologyIn This Chapter . . . . . . . . . . . . . . . . . . 3-3Selecting the Enterprise Replication System . . . . . . . . 3-3

    Primary-Target Replication System . . . . . . . . . . 3-3Update-Anywhere Replication System . . . . . . . . . 3-10Conflict Resolution . . . . . . . . . . . . . . . 3-11

    Choosing a Replication Network Topology . . . . . . . . . 3-19Fully Connected Topology . . . . . . . . . . . . . 3-20Hierarchical Replication Topologies . . . . . . . . . . 3-21

    Chapter 4 Preparing the Replication EnvironmentIn This Chapter . . . . . . . . . . . . . . . . . . 4-3Preparing the Network Environment . . . . . . . . . . . 4-3

    Setting Up the Hosts File . . . . . . . . . . . . . 4-4Setting Up the Services File. . . . . . . . . . . . . 4-4Setting Up the Trusted Environment . . . . . . . . . 4-5Verifying SQLHOSTS. . . . . . . . . . . . . . . 4-5Testing the Network Environment . . . . . . . . . . 4-8

    Preparing the Disk . . . . . . . . . . . . . . . . . 4-9Planning for Disk Space Requirements . . . . . . . . . 4-9Setting Up Send and Receive Queue Spool Areas . . . . . 4-11Creating ATS and RIS Directories . . . . . . . . . . 4-15

    Preparing the Database Server Environment . . . . . . . . 4-16Preparing Data for Replication . . . . . . . . . . . . . 4-18

    Preparing Consistent Data . . . . . . . . . . . . . 4-18Blocking Replication . . . . . . . . . . . . . . . 4-18Preparing to Replicate Opaque User-Defined Types . . . . 4-21Preparing Tables for Conflict Resolution . . . . . . . . 4-21Preparing Logging Databases . . . . . . . . . . . . 4-22

    Loading and Unloading Data . . . . . . . . . . . . . 4-22Data Preparation Example . . . . . . . . . . . . . . 4-24

    Table of Contents v

  • vi Guide

    Chapter 5 Defining and Modifying Replication Servers, Replicates, andParticipantsIn This Chapter . . . . . . . . . . . . . . . . . . . 5-3Initializing Database Servers . . . . . . . . . . . . . . 5-4Defining Replication Servers . . . . . . . . . . . . . . 5-5

    Customizing the Replication Server Definition . . . . . . 5-6Defining Replicates . . . . . . . . . . . . . . . . . 5-7

    Defining Participants . . . . . . . . . . . . . . . 5-8Specifying Conflict Resolution Rules and Scope . . . . . . 5-10Specifying Replication Frequency . . . . . . . . . . . 5-10Setting Up Error Logging . . . . . . . . . . . . . . 5-11Replicating Only Changed Columns . . . . . . . . . . 5-11Using the IEEE Floating Point or Canonical Format . . . . . 5-13Enabling Triggers . . . . . . . . . . . . . . . . 5-14

    Modifying Replication Servers . . . . . . . . . . . . . 5-14Modifying Replicates . . . . . . . . . . . . . . . . . 5-15

    Adding or Deleting Participants . . . . . . . . . . . 5-15Changing Replicate Attributes . . . . . . . . . . . . 5-16

    Resynchronizing Replication Servers . . . . . . . . . . . 5-17

    Chapter 6 Managing Replication Servers and ReplicatesIn This Chapter . . . . . . . . . . . . . . . . . . . 6-3Managing Replication Servers . . . . . . . . . . . . . . 6-3

    Viewing Replication Server Attributes . . . . . . . . . 6-3Connecting to Another Replication Server . . . . . . . . 6-4Stopping Replication on a Server . . . . . . . . . . . 6-4Restarting Replication on a Stopped Server . . . . . . . . 6-5Suspending Replication for a Server . . . . . . . . . . 6-5Resuming a Suspended Replication Server . . . . . . . . 6-6Deleting a Replication Server . . . . . . . . . . . . 6-6

    Managing Replicates . . . . . . . . . . . . . . . . . 6-7Viewing Replicate Properties. . . . . . . . . . . . . 6-7Starting a Replicate . . . . . . . . . . . . . . . . 6-7Stopping a Replicate . . . . . . . . . . . . . . . 6-8Suspending a Replicate. . . . . . . . . . . . . . . 6-9Resuming a Suspended Replicate . . . . . . . . . . . 6-9Deleting a Replicate . . . . . . . . . . . . . . . . 6-9

    to IBM Informix Enterprise Replication

  • Managing Replication Server Network Connections . . . . . 6-10Viewing Network Connection Status . . . . . . . . . 6-10Dropping the Network Connection . . . . . . . . . . 6-10Reestablishing the Network Connection . . . . . . . . 6-11

    Chapter 7 Creating and Managing Replicate SetsIn This Chapter . . . . . . . . . . . . . . . . . . 7-3Creating Replicate Sets . . . . . . . . . . . . . . . . 7-4

    Exclusive Replicate Sets . . . . . . . . . . . . . . 7-4Non-Exclusive Replicate Sets . . . . . . . . . . . . 7-5Customizing the Replicate Set Definition . . . . . . . . 7-5

    Viewing Replicate Set Properties . . . . . . . . . . . . 7-6Managing Replicate Sets . . . . . . . . . . . . . . . 7-6

    Starting a Replicate Set . . . . . . . . . . . . . . 7-7Stopping a Replicate Set . . . . . . . . . . . . . . 7-7Suspending a Replicate Set . . . . . . . . . . . . . 7-7Resuming a Replicate Set . . . . . . . . . . . . . 7-8Deleting a Replicate Set . . . . . . . . . . . . . . 7-8

    Modifying Replicate Sets . . . . . . . . . . . . . . . 7-9Adding or Del