PITRTools
发布时间:2020-12-13 17:26:45 所属栏目:百科 来源:网络整理
导读:?? pitrtools is a Python + PostgreSQL application that assists in the provisioning of Hot Standby,Warm Standby,Cold Standby,Streaming Replication clusters and multiple standbys (slaves). It supports all PostgreSQL versions from 8.2+ includ
??
pitrtools is a Python + PostgreSQL application that assists in the provisioning of Hot Standby,Warm Standby,Cold Standby,Streaming Replication clusters and multiple standbys (slaves). It supports all PostgreSQL versions from 8.2+ including 9.2.
Requirements: Rsync Python >= 2.6 SSH PostgreSQL 8.2+
#rpm-qa|greprsync rsync-3.0.6-9.el6_4.1.x86_64 #python-V Python2.6.6 $pg_config--version PostgreSQL9.3.4
编译安装: pg_standby pg_archivecleanup
[root@masterdb~]#mkdir/opt/pg93/archive [root@masterdb~]#chownpostgres:postgres/opt/pg93/archive/ $cd/opt/pitrtools-1.3/etc/ $cpcmd_archiver.ini.samplecmd_archiver.ini $cpcmd_standby.ini.samplecmd_standby.ini
cmd_standbyThecmd_standbyscriptisautilitythatallowseasymanagementofalltypesof standbyPostgreSQLservers,fromcoldtowarmandstreamingrepliaction. Itcurrentlyhasthefollowingcapabilities: *Easilytakeabasebackup,includingtablespaces *Restorearchives *Automaticallypurgeoldarchives(ifPostgreSQL>8.3) *Alertbasedonfailures *StopandstartPostgreSQLstandby *Failovertothelatestrestorepointandpoint-in-timerecovery Usage: cmd_standby[options]arg1arg2 Options: -h,--helpshowthishelpmessageandexit -Astart|stop,--action=start|stop StartorStopPostgreSQL -B,--basebackupStart/Stopabasebackup -CFILE,--config=FILE thenameofthestandbyconfigfile -FVALUE,--failover=VALUE Valueisa3digitnumber999 -I,--dbinitUsebefore-B -P,--pingIsmymasteralive? -RTIMESTAMP,--recovertotime=TIMESTAMP Ifyouneedtorestoretoaspecificpointintime -S,--standbyEnterstandbymode
cmd_archivercmd_archiverscriptisusedinconjunctionwithPostgreSQL'snative archivemodefunctionalitytoshipWALsegmentstoconfiguredstandby servertoreplaythem. *Automaticallyshiplogfilestoconfiguredstandbyserver *Enable/disablearchivingwithouttheneedtorestartPostgreSQL *Alertbasedonfailures Usage: cmd_archiver[options]arg1arg2 Options: -h,--helpShowthishelpmessageandexit -FFILE,--file=FILEArchivefile -CFILE,--config=FILE Thenameofthearchiverconfigfile -f,--flushFlushallremainingarchivestoslave -I,--initInitializemasterenvironment (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |