How to configure Enterprise Replication
Posted in 1999
Topics: High Availability & Replication, Versions, Editions & End-of-Life
1. May I know the syntax on how to configure/setup CDR primary/target scheme at the command line. I only have primary and secondary servers. 2. I'd like to replicate the whole database rather than a specific or group of tables. What's the most efficient way to do this? Thanks in advance. Platform: IDS 7.30.UC7 AIX 4.2.1 -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
7.3 provides the one stop command 'cdr' This command has many, many options. There really is no way to a database. You are stuck setting up the servers, then setting up the tables one by one(herein lies the pain in the ass(uhh flexibility of cdr). The options for the cdr command are given both in the doco aand of you type 'cdr --' Though the command help is only useful if you are familiar with cdr. Hope this helps a little, Jacque remics@my-dejanews.com wrote: > 1. May I know the syntax on how to configure/setup CDR primary/target scheme > at the command line. I only have primary and secondary servers. > > 2. I'd like to replicate the whole database rather than a specific or group of > tables. What's the most efficient way to do this? > > Thanks in advance. > > Platform: > > IDS 7.30.UC7 > AIX 4.2.1 > > -----------== Posted via Deja News, The Discussion Network ==---------- > http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
remics@my-dejanews.com wrote:
> 1. May I know the syntax on how to configure/setup CDR primary/target scheme
> at the command line. I only have primary and secondary servers.
cdr define repl -C ignore -S <row/transaction> \\"P db@cdr_serv1:owner.tab" "select
* from tab" \\ <<== Primary
"R db@cdr_serv2:owner.tab" "select * from tab" <<== Target
>
>
> 2. I'd like to replicate the whole database rather than a specific or group of
> tables. What's the most efficient way to do this?
Create a script, possibably using awk. The following might be a start:
echo "select tabname from systables where tabid > 99" | \\
dbaccess database_name 2>/dev/null | nawk 'BEGIN {
REPID=1
}
{
if (PRTSTART == 1)
{
if (length($0) > 0)
{ printf ("cdr define repl -C ignore -S row repl_%d", REPID)
printf("\\"P db@cdr_serv1:owner.%s\\" \\"select * from %s\\" ", $1, $1)
printf("\\"R db@cdr_serv2:owner.%s\\" \\"select * from %s\\" \\n", $1 $1)
printf("cdr start repl repl_%d\\n", REPID
REPID++
}
}
if ($1 == "tabname")
{ PRTSTART = 1
}
}'
>
>
> Thanks in advance.
>
> Platform:
>
> IDS 7.30.UC7
> AIX 4.2.1
>
> -----------== Posted via Deja News, The Discussion Network ==----------
> http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own
remics@my-dejanews.com wrote: > 1. May I know the syntax on how to configure/setup CDR primary/target scheme > at the command line. I only have primary and secondary servers. One other question. If you want to replicate the entire system and have only a primary server and a secondary, why not use HDR? > > > 2. I'd like to replicate the whole database rather than a specific or group of > tables. What's the most efficient way to do this? > > Thanks in advance. > > Platform: > > IDS 7.30.UC7 > AIX 4.2.1 > > -----------== Posted via Deja News, The Discussion Network ==---------- > http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own