官术网_书友最值得收藏!

How to do it…

In order to support your GoldenGate installation, you must ensure you have ample physical memory (RAM) available on the server. The steps for implementing the design considerations are as follows:

  1. The following command will display your available memory on the server:
    $ /usr/sbin/lsattr –El sys0 –a realmmem
    

    The output of the preceding command will be as follows:

    Realmem 16777216 Amount of usable physical memory in Kbytes False
    

    The preceding output indicates that the server has 16 GB of physical RAM, which is more than sufficient to carry on for an Online Transaction Processing (OLTP) environment.

  2. For very busy systems, you can limit the amount of RAM to your Extract and/or Replicat processes as in the following parameter file:
    cachemgr cachesize 8G
    
  3. Your OGG software distribution should have its own filesystem created by your system administrator. Our example is a 100 GB filesystem.
    hosta> $ df -g
    

    The output of the preceding command will be as follows:

    Filesystem GB blocks Free % Used Iused %Iused Mounted on
    
    /dev/oggvg 100.00 99.67 1% 270 1% /u01/app/oracle/GG
    
  4. Next we want to calculate the optimal network bandwidth in order to set the TCP Send / Receive socket buffers (TCPBUFSIZE) for data pump extracts. Use the following command to get the correct TCPBUFSIZE buffers for your data pump extract:
    hosta> $ ping -c 10 hostb
    

    The output of the preceding command will be as follows:

    PING hostb: (10.3.4.5): 56 data bytes
    64 bytes from 10.3.4.5: icmp_seq=0 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=1 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=2 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=3 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=4 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=5 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=6 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=7 ttl=255 time=0.7 ms
    64 bytes from 10.3.4.5: icmp_seq=8 ttl=255 time=0.8 ms
    64 bytes from 10.3.4.5: icmp_seq=9 ttl=255 time=0.8 ms
    
    ----hostb PING Statistics----
    10 packets transmitted, 10 packets received, 0% packet loss
    round-trip min/avg/max = 0.8/0.8/0.8 ms
    

    Now we'll calculate the buffer size based on the preceding output of 0.8 ms network latency and our 100 megabits interface card. You might have a different speed interface card such as 1 gigabit or even 10 gigabits. Check with your system administrator if you're unsure.

    Note

    0.8 seconds * 100 megabits per second = 8 megabits

    To determine the buffer size in bytes, where 8 bits = 1 byte, we perform the following calculation:

    8 megabits / 8 = 1,000,000 bytes ~ 1 MB / second = TCPBUFSIZE

  5. Create an Oracle service for OGG to connect to the Oracle database via a service name in a high availability Real Application Clusters (RAC) database as follows:
    $ srvctl add service -d sourcedb -s OGG_SRVC –r hosta1 –a hosta2
    $ srvctl start service –d sourcedb –s OGG_SRVC
    
  6. Once the OGG_SRVC service has been created from the preceding code, you must add it to your tnsnames.ora file, for example, as follows:
    OGG_SRVC =
    (DESCRIPTION =
       (ADDRESS = (PROTOCOL = TCP)(HOST = hosta1-vip)(PORT = 1521))
       (ADDRESS = (PROTOCOL = TCP)(HOST = hosta2-vip)(PORT = 1521))
       (LOAD_BALANCE = NO)
       (CONNECT_DATA =
          (SERVER = DEDICATED)
          (SERVICE_NAME = OGG_SRVC)
       )
    )
  7. For very slow networks, or networks with bandwidth limitations, you would benefit highly by enabling network compression in the data pump extract. We can do it using the following example:

    Example: enabling compression for your trail files in flight as follows:

    rmthost london mgrport 7809 tcpbufsize 1000000 compress
    
主站蜘蛛池模板: 始兴县| 紫云| 上蔡县| 乐业县| 石林| 方山县| 灌南县| 乐陵市| 郸城县| 友谊县| 慈溪市| 揭西县| 海南省| 莎车县| 吕梁市| 南开区| 海淀区| 久治县| 岳西县| 昌都县| 盘山县| 黄浦区| 东明县| 黄浦区| 米脂县| 武鸣县| 云霄县| 乌海市| 紫金县| 颍上县| 美姑县| 怀安县| 叙永县| 武定县| 运城市| 嘉峪关市| 卢氏县| 额尔古纳市| 金堂县| 大理市| 平山县|