搜索
首页数据库mysql教程两台Oracle之间配置OGG-未配置同步DDL

环境 :数据库版本Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 VBOX虚拟机主机名、数据库实例、库名及IP规划:源

环境 :
数据库版本Oracle Database 11g Enterprise Edition Release 11.2.0.1.0
VBOX虚拟机
主机名、数据库实例、库名及IP规划:
源主机IP:192.168.1.213 HOSTNAME:bys001.oel.com
目标主机IP:192.168.1.213 HOSTNAME:bys2.oel.com
实例名和数据库名两台主机一样,两台主机的数据库结构完全一样。
采用先配置源主机,再克隆一台修改一下配置做为目标机。
其中源主机已经安装好ORACLE数据库软件并已经创建数据库。

整个配置分6步:
1.修改环境变量,创建目录
2.上传OGG软件解压并安装
3.查询数据库名、实例名并开启归档模式,,强制产生日志等
4.在数据库中为OGG创建用户
5.开始配置OGG的同步--未配置DDL的同步
6.测试test用户的test1表做DML操作能否同步
######################################
1.修改环境变量,创建目录 [oracle@bys001 ~]$ vi .bash_profile
增加这一句:
export OGG_HOME=/u01/ogg
".bash_profile" 24L, 560C written
[oracle@bys001 ~]$ source .bash_profile
[oracle@bys001 ~]$ cd /u01
[oracle@bys001 u01]$ mkdir ogg
[oracle@bys001 u01]$ ls
admin checkpoints oradata
app diag oraInventory
archbys1 flash_recovery_area
cfgtoollogs ogg
[oracle@bys001 u01]$ echo $OGG_HOME
/u01/ogg

2.上传OGG软件解压并安装 ----使用SSH SECURE SHELL上传很好用。
[oracle@bys001 ~]$ ls ogg112101_fbo_ggs_Linux_x86_ora11g_32bit.zip ogg112101_fbo_ggs_Linux_x86_ora11g_32bit.zip
[oracle@bys001 ~]$ unzip ogg112101_fbo_ggs_Linux_x86_ora11g_32bit.zip
[oracle@bys001 ~]$ ls fbo_ggs_Linux_x86_ora11g_32bit.tar
fbo_ggs_Linux_x86_ora11g_32bit.tar

[oracle@bys001 ~]$ tar -xvf fbo_ggs_Linux_x86_ora11g_32bit.tar -C $OGG_HOME

打开 ggsci时的一个错误解决:
我这里在使用ggsci遇到错误因为找不到库文件报错:
[oracle@oel-01 ogg]$ ./ggsci
./ggsci: error while loading shared libraries: libnnz11.so: cannot open shared object file: No such file or directory
建议在使用前先在OGG的目录执行:[oracle@bys001 ogg]$ ldd ggsci
如果库文件全在,可以直接执行[oracle@bys001 ogg]$ ./ggsci
如果缺少库文件,可以find / -name libnnz11.so 这样在整个/目录下查询。
根据查出的库文件位置,做一个软链接就可以了,要使用 root账户。如:
[root@oel-01 ~]# ln -s /u01/app/oracle/product/11.2.0/dbhome_1/lib/libnnz11.so /lib/libnnz11.so

创建OGG目录:要注意在OGG的安装目录下调用
[oracle@bys001 ogg]$ ./ggsci

GGSCI (bys001.oel.com) 2> create subdirs

Creating subdirectories under current directory /u01/ogg

Parameter files /u01/ogg/dirprm: already exists
Report files /u01/ogg/dirrpt: created
Checkpoint files /u01/ogg/dirchk: created
Process status files /u01/ogg/dirpcs: created
SQL script files /u01/ogg/dirsql: created
Database definitions files /u01/ogg/dirdef: created
Extract data files /u01/ogg/dirdat: created
Temporary files /u01/ogg/dirtmp: created
Stdout files /u01/ogg/dirout: created
只需要在打开的窗口写入: PORT 7809就可以了,使用是和VI一样。
GGSCI (bys001.oel.com) 4> edit param mgr
PORT 7809
GGSCI (bys001.oel.com) 7> start mgr
Manager started.

GGSCI (bys001.oel.com) 8> info all

Program Status Group Lag at Chkpt Time Since Chkpt
MANAGER RUNNING

OGG安装完成。因为后面才会克隆虚拟机,所以这里只需要做一次安装哈哈。
OGG同步的配置在第6步。
###############################################

声明
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
在MySQL中使用视图的局限性是什么?在MySQL中使用视图的局限性是什么?May 14, 2025 am 12:10 AM

mysqlviewshavelimitations:1)他们不使用Supportallsqloperations,限制DatamanipulationThroughViewSwithJoinSorsubqueries.2)他们canimpactperformance,尤其是withcomplexcomplexclexeriesorlargedatasets.3)

确保您的MySQL数据库:添加用户并授予特权确保您的MySQL数据库:添加用户并授予特权May 14, 2025 am 12:09 AM

porthusermanagementInmysqliscialforenhancingsEcurityAndsingsmenting效率databaseoperation.1)usecReateusertoAddusers,指定connectionsourcewith@'localhost'or@'%'。

哪些因素会影响我可以在MySQL中使用的触发器数量?哪些因素会影响我可以在MySQL中使用的触发器数量?May 14, 2025 am 12:08 AM

mysqldoes notimposeahardlimitontriggers,butacticalfactorsdeterminetheireffactective:1)serverConfiguration impactactStriggerGermanagement; 2)复杂的TriggerSincreaseSySystemsystem load; 3)largertablesslowtriggerperfermance; 4)highConconcConcrencerCancancancancanceTigrignecentign; 5); 5)

mysql:存储斑点安全吗?mysql:存储斑点安全吗?May 14, 2025 am 12:07 AM

Yes,it'ssafetostoreBLOBdatainMySQL,butconsiderthesefactors:1)StorageSpace:BLOBscanconsumesignificantspace,potentiallyincreasingcostsandslowingperformance.2)Performance:LargerrowsizesduetoBLOBsmayslowdownqueries.3)BackupandRecovery:Theseprocessescanbe

mySQL:通过PHP Web界面添加用户mySQL:通过PHP Web界面添加用户May 14, 2025 am 12:04 AM

通过PHP网页界面添加MySQL用户可以使用MySQLi扩展。步骤如下:1.连接MySQL数据库,使用MySQLi扩展。2.创建用户,使用CREATEUSER语句,并使用PASSWORD()函数加密密码。3.防止SQL注入,使用mysqli_real_escape_string()函数处理用户输入。4.为新用户分配权限,使用GRANT语句。

mysql:blob和其他无-SQL存储,有什么区别?mysql:blob和其他无-SQL存储,有什么区别?May 13, 2025 am 12:14 AM

mysql'sblobissuitableForStoringBinaryDataWithInareLationalDatabase,而alenosqloptionslikemongodb,redis和calablesolutionsoluntionsoluntionsoluntionsolundortionsolunsolunsstructureddata.blobobobsimplobissimplobisslowderperformandperformanceperformancewithlararengelitiate;

mySQL添加用户:语法,选项和安全性最佳实践mySQL添加用户:语法,选项和安全性最佳实践May 13, 2025 am 12:12 AM

toaddauserinmysql,使用:createUser'username'@'host'Indessify'password'; there'showtodoitsecurely:1)choosethehostcarecarefullytocon trolaccess.2)setResourcelimitswithoptionslikemax_queries_per_hour.3)usestrong,iniquepasswords.4)Enforcessl/tlsconnectionswith

MySQL:如何避免字符串数据类型常见错误?MySQL:如何避免字符串数据类型常见错误?May 13, 2025 am 12:09 AM

toAvoidCommonMistakeswithStringDatatatPesInMysQl,CloseStringTypenuances,chosethirtightType,andManageEngencodingAndCollat​​ionsEttingsefectery.1)usecharforfixed lengengters lengengtings,varchar forbariaible lengength,varchariable length,andtext/blobforlabforlargerdata.2 seterters seterters seterters seterters

See all articles

热AI工具

Undresser.AI Undress

Undresser.AI Undress

人工智能驱动的应用程序,用于创建逼真的裸体照片

AI Clothes Remover

AI Clothes Remover

用于从照片中去除衣服的在线人工智能工具。

Undress AI Tool

Undress AI Tool

免费脱衣服图片

Clothoff.io

Clothoff.io

AI脱衣机

Video Face Swap

Video Face Swap

使用我们完全免费的人工智能换脸工具轻松在任何视频中换脸!

热门文章

热工具

WebStorm Mac版

WebStorm Mac版

好用的JavaScript开发工具

mPDF

mPDF

mPDF是一个PHP库,可以从UTF-8编码的HTML生成PDF文件。原作者Ian Back编写mPDF以从他的网站上“即时”输出PDF文件,并处理不同的语言。与原始脚本如HTML2FPDF相比,它的速度较慢,并且在使用Unicode字体时生成的文件较大,但支持CSS样式等,并进行了大量增强。支持几乎所有语言,包括RTL(阿拉伯语和希伯来语)和CJK(中日韩)。支持嵌套的块级元素(如P、DIV),

螳螂BT

螳螂BT

Mantis是一个易于部署的基于Web的缺陷跟踪工具,用于帮助产品缺陷跟踪。它需要PHP、MySQL和一个Web服务器。请查看我们的演示和托管服务。

SublimeText3汉化版

SublimeText3汉化版

中文版,非常好用

ZendStudio 13.5.1 Mac

ZendStudio 13.5.1 Mac

功能强大的PHP集成开发环境