CN1808394A - Soft co-standby method based on memory database - Google Patents

Soft co-standby method based on memory database Download PDF

Info

Publication number
CN1808394A
CN1808394A CN 200610038374 CN200610038374A CN1808394A CN 1808394 A CN1808394 A CN 1808394A CN 200610038374 CN200610038374 CN 200610038374 CN 200610038374 A CN200610038374 A CN 200610038374A CN 1808394 A CN1808394 A CN 1808394A
Authority
CN
China
Prior art keywords
data
memory database
machine
master server
synchronizing process
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN 200610038374
Other languages
Chinese (zh)
Other versions
CN100390747C (en
Inventor
唐诚
林锦歆
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Asialnfo Technology (Nanjing) Co., Ltd.
Original Assignee
LINKAGE SYSTEM INTEGRATION CO Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by LINKAGE SYSTEM INTEGRATION CO Ltd filed Critical LINKAGE SYSTEM INTEGRATION CO Ltd
Priority to CNB2006100383748A priority Critical patent/CN100390747C/en
Publication of CN1808394A publication Critical patent/CN1808394A/en
Application granted granted Critical
Publication of CN100390747C publication Critical patent/CN100390747C/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

Disclosed is a method for soft dual-computer based on memory database comprising: 1) each application program on host server saves business data in host server memory database via calling application interface (API), respectively writing into incremental data area and full data area; 2) data synchronizing process on the host server sends the incremental data in the memory database of the host server to data synchronizing process of backup machine with form of data flow via socket; 3) the data synchronizing process of backup machine writes the received data into the full data area of backup machine memory database; 4) above step 1 to step 3 complete data backup between host and backup machines, and the synchronization is completed when the incremental data in host server memory database is null.

Description

Soft co-standby method based on memory database
Technical field
The present invention relates to the method for two-node cluster hot backup, especially the server two-shipper is based on the soft co-standby method of memory database.
Background technology
Present server dual-locomotive heat has two kinds of typical modes, a kind of is the mode based on disk array of standard of comparison, two-server is by a shared memory device (generally being disk array or the storage area network SAN that shares), and deposit data is on the memory device of sharing.When master server is managed business, directly on memory device, read and write.After master server broke down switching, standby server read the data on this memory device too, realized two-node cluster hot backup.Another kind of mode is the mode by pure software, be commonly referred to as pure software mode or mirror image mode (Mirror), incremental data on the master server disk is copied in real time on the disk of another station server by mirror image software, just each exists a same like this data on the disk of two-server, if master server breaks down, can in time switch to standby server.
The pure software mode has the following advantages:
1. avoided the Single Point of Faliure of disk array:, itself promptly be to take precautions against, but disk array has exactly formed a new single-point again because the fault of individual equipment causes service disruption for two-node cluster hot backup.(such as, the safety factor of server is 99.9%, the safety factor of disk array is 99.95%, and then the safety factor of pure soft two-shipper is 1-99.9% * 99.9%=99.99%, then can be a little less than 99.95% based on the safety factor of the Dual-Computer Hot-Standby System of disk array.
2. save investment: need not buy expensive disk array.
3. be not subjected to the restriction of distance: two-server need not be subjected to scsi cable length restriction (disk array of optical-fibre channel is not subjected to distance limit yet, but the investment be so great that many).Like this, deployment server comprises that the distance by physical location improves security (disaster tolerance) more neatly.
More than the common drawback of disk mode of Jie Shaoing and pure software mode is exactly all can't accomplish to be equipped with mutually for the business datum in the active/standby server internal memory, and at some to the demanding business application system of handling property (as Online Charging System OCS, its response time requirement to each Pen Association's word<200ms), therefore a large amount of business processing data are stored in the internal memory, and active and standby machine hinders for some reason and must not influence current ongoing business when switching, and so just must guarantee the synchronous of active and standby machine internal storage data.
Summary of the invention
The present invention seeks to, propose a kind of method for synchronous of active and standby machine internal storage data,, can't realize the data synchronization problems in the internal memory and propose at existing double-machine standby technology especially based on the soft co-standby method of memory database.
Technical solution of the present invention is:
One, system of the present invention forms based on following parts:
1. the application aip interface on the active/standby server
2. the memory database on the active/standby server (data separation is incremental data district and full dose data field)
3. the data synchronizing process on the active/standby server
Two, technical solution of the present invention is:
Based on the soft co-standby method of memory database, 1. each application program deposits business datum in the master server memory database in by calling application api interface on master server, writes respectively in incremental data district and the full dose data field;
2. data synchronizing process sends to the form of data stream the incremental data in the master server memory database data synchronizing process of guest machine on the master server by socket;
3. the data synchronizing process of guest machine writes the data that receive in the full dose data field in the guest machine memory database.
4. the heat that above 1-3 step has been finished data between once active and standby machine is equipped with, and shows between two-server synchronous fully when the incremental data of master server memory database is sky.
This characteristic feature of an invention and main advantage are:
1. data centralization: all data that need heat be equipped with all are kept in the memory database.
2. heat is equipped with the efficient height: adopt increment storehouse scheme to guarantee real-time, heat is equipped with a time<=5ms
3. cold standby efficient height: adopt full dose storehouse scheme, time<=10s of cold standby is specifically referring to drawings and Examples.(annotate: the TimesTen that adopts ORACLE company is as memory database)
The actual use shows that the heat of finishing a business datum based on the soft two-shipper technology of memory database is equipped with time<=5ms, finishes cold standby time<=10s one time.
Description of drawings
Fig. 1 is the double machine structure synoptic diagram of memory database of the present invention.
Fig. 2 is that the present invention's heat is equipped with the processing procedure scene sequential chart under the scene
Fig. 3 is the processing procedure scene sequential chart under the cold standby scene of the present invention
Embodiment
One, heat is equipped with the processing procedure under the scene: (as shown in the figure)
1. the application process on the master server is by in the memory database that calls the api interface and business datum is write this machine (being written to respectively in incremental data district and the full dose data field)
2. the data synchronizing process on the master server reads an incremental data in this machine memory database, is sent to the data synchronizing process of guest machine, sends successfully this incremental data of back deletion.This step cycle is handled no datat to the incremental data district.
3. the data synchronizing process of guest machine writes the data that receive in the memory database of this machine (only writing in the full dose data field).This step cycle is handled to no datat and is received.
Two, the processing procedure under the cold standby scene:
1. master server breaks down, and guest machine is enabled.
2. the application process on the guest machine is by in the memory database that calls the api interface and business datum is write this machine (being written to respectively in incremental data district and the full dose data field)
3. master server is restarted successfully, and the data synchronizing process on the master server sends the data synchronizing process of a cold standby request to guest machine.
4. the data synchronizing process of guest machine is received the cold standby request, with the locking of guest machine memory database, empty incremental data, and the data file of memory database is duplicated portion, release memory database then is sent to duplicated data file the data synchronizing process of master server.
5. the data synchronizing process of master server is replaced the current data file of this machine with the data file that receives.
6. beginning heat is equipped with scene ... scene sequential chart with reference to the accompanying drawings.
The present invention adopts Socket to the invention provides abundant method and the attribute of a cover.The Socket class allows use agreement to carry out asynchronous and synchronous data transmission.The Socket class is followed the .NET Framework naming scheme of asynchronous method; Be applicable to synchronous mode of operation:
If that current use is Connection-oriented Protocol (as TCP), then server can use the Listen method to intercept connection. AcceptMethod is handled any connection request that imports into, and returns the Socket that can be used for carrying out with distance host data communication.Can use this Socket that returns to call SendOr ReceiveMethod.If specify local ip address and port numbers, please calling ListenCall earlier before the method BindMethod.If never call Bind, infrastructure service provides program to distribute these values for you.After this, can use LocalEndPointAttribute comes identification distribution to give IP address and the port numbers of Socket.Intercept main frame if want to be connected to, please call ConnectMethod.If will carry out data communication, please call SendOr ReceiveMethod.
If will use independent thread process communication in the process of implementation, adopt the method that is applicable to the asynchronous operation pattern.
If that current use is Connection-oriented Protocol (as TCP), then can use Socket, BeginConnectWith EndConnectMethod connects intercepts main frame.By using BeginSendWith EndSendMethod is perhaps used BeginReceiveWith EndReceiveMethod can be carried out asynchronous data communication.Can use BeginAcceptWith EndAcceptThe connection request that processing is imported into.If a socket is carried out a plurality of asynchronous operations, they not necessarily the order when starting finish.When data send and after Data Receiving finishes, can use ShutdownMethod is forbidden Socket.After calling Shutdown, can call CloseMethod discharges all resources related with Socket.The Socket class allows to use SetSocketOptionMethod disposes Socket.Can use GetSocketOptionMethod is retrieved these settings.

Claims (4)

1, based on the soft co-standby method of memory database, it is characterized in that adopting following method: 1). each application program deposits business datum in the master server memory database in by calling application api interface on master server, writes respectively in incremental data district and the full dose data field; 2). data synchronizing process sends to the form of data stream the incremental data in the master server memory database data synchronizing process of guest machine on the master server by socket; 3). the data synchronizing process of guest machine writes the data that receive in the full dose data field in the guest machine memory database, 4). the heat that above 1-3 step has been finished data between once active and standby machine is equipped with, and shows between two-server synchronous fully when the incremental data of master server memory database is sky.
2. by the described soft co-standby method of claim 1 based on memory database, it is characterized in that application process on the master server is by after in the memory database that calls the api interface and business datum is write this machine, its synchronized process reads an incremental data in this machine memory database, be sent to the data synchronizing process of guest machine, send successfully this incremental data of back deletion; This step cycle is handled no datat to the incremental data district.
3. by the described soft co-standby method based on memory database of claim 2, the data synchronizing process that it is characterized in that guest machine writes the data that receive in the full dose data field of memory database of this machine; This step cycle is handled to no datat and is received.
4, by claim 1 or 2 described soft co-standby methods based on memory database, it is characterized in that master server breaks down, guest machine is enabled; Application process on the guest machine writes business datum in the memory database of this machine by calling the api interface, and is written to respectively in incremental data district and the full dose data field; Master server is restarted successfully, and the data synchronizing process on the master server sends the data synchronizing process of a cold standby request to guest machine; The data synchronizing process of guest machine is received the cold standby request, with the locking of guest machine memory database, empty incremental data, and the data file of memory database is duplicated portion, release memory database then is sent to duplicated data file the data synchronizing process of master server; The data synchronizing process of master server is replaced the current data file of this machine with the data file that receives.
CNB2006100383748A 2006-02-20 2006-02-20 Soft co-standby method based on memory database Active CN100390747C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2006100383748A CN100390747C (en) 2006-02-20 2006-02-20 Soft co-standby method based on memory database

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2006100383748A CN100390747C (en) 2006-02-20 2006-02-20 Soft co-standby method based on memory database

Publications (2)

Publication Number Publication Date
CN1808394A true CN1808394A (en) 2006-07-26
CN100390747C CN100390747C (en) 2008-05-28

Family

ID=36840303

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2006100383748A Active CN100390747C (en) 2006-02-20 2006-02-20 Soft co-standby method based on memory database

Country Status (1)

Country Link
CN (1) CN100390747C (en)

Cited By (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101242356B (en) * 2007-12-06 2010-08-18 中兴通讯股份有限公司 Realization method and IPTV system for memory database in IPTV system
CN101192214B (en) * 2006-11-27 2010-09-29 中兴通讯股份有限公司 Processing method for EMS memory data-base content variation real time notification task
CN101262325B (en) * 2008-04-21 2011-07-20 深圳南瑞科技有限公司 Switching device for monitoring dual hosts at translation station
CN102262591A (en) * 2010-05-31 2011-11-30 国际商业机器公司 Garbage collection method and system for memory copy system
CN102289518A (en) * 2011-09-13 2011-12-21 盛乐信息技术(上海)有限公司 Method and system for updating audio fingerprint search library
CN101299710B (en) * 2007-04-30 2012-10-10 中兴通讯股份有限公司 Method for synchronization of memory database data
CN102750202A (en) * 2012-06-06 2012-10-24 宇龙计算机通信科技(深圳)有限公司 Data protection method and device
CN102981777A (en) * 2012-10-29 2013-03-20 中国铁道科学研究院 Control method and system for data access
CN103020242A (en) * 2012-12-19 2013-04-03 中国人民解放军第二炮兵装备研究院第四研究所 Data synchronization method based on oracle database
CN103500130A (en) * 2013-09-11 2014-01-08 上海爱数软件有限公司 Method for backing up dual-computer hot standby data in real time
CN103532753A (en) * 2013-10-11 2014-01-22 中国电子科技集团公司第二十八研究所 Double-computer hot standby method based on memory page replacement synchronization
CN102137132B (en) * 2010-01-26 2014-06-04 腾讯科技(深圳)有限公司 System and method for synchronizing data
CN105719414A (en) * 2014-12-05 2016-06-29 航天信息股份有限公司 POS terminal invoicing method and device, and invoicing server terminal
CN103780615B (en) * 2014-01-20 2017-02-01 五八同城信息技术有限公司 Sharing method of client conversation data among multiple servers
CN107038094A (en) * 2017-04-27 2017-08-11 紫光华山信息技术有限公司 A kind of data back up method and device
CN108170768A (en) * 2017-12-25 2018-06-15 腾讯科技(深圳)有限公司 database synchronization method, device and readable medium
CN108614876A (en) * 2018-04-26 2018-10-02 武汉斗鱼网络科技有限公司 A kind of system and data processing method based on Redis databases
CN108959548A (en) * 2018-07-02 2018-12-07 阿里巴巴集团控股有限公司 The processing method and processing device of service request
CN109542690A (en) * 2018-11-30 2019-03-29 安徽继远软件有限公司 A kind of method and apparatus of backup database data
CN110297730A (en) * 2019-07-04 2019-10-01 北京谷数科技有限公司 A kind of storage dual-active solution and system for removing arbitration node
CN110727733A (en) * 2019-09-25 2020-01-24 许昌许继软件技术有限公司 Main and standby server system and data synchronization method
WO2020192311A1 (en) * 2019-03-22 2020-10-01 北京达佳互联信息技术有限公司 Master-slave server switching method and apparatus, electronic device and storage medium
CN112416656A (en) * 2020-12-08 2021-02-26 卡斯柯信号有限公司 Data offline storage method for station application server

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5721918A (en) * 1996-02-06 1998-02-24 Telefonaktiebolaget Lm Ericsson Method and system for fast recovery of a primary store database using selective recovery by data type
US5842222A (en) * 1996-10-04 1998-11-24 Taiwan Semiconductor Manufacturing Company, Ltd. Production information system enhanced for availability
US6981177B2 (en) * 2002-04-19 2005-12-27 Computer Associates Think, Inc. Method and system for disaster recovery

Cited By (31)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101192214B (en) * 2006-11-27 2010-09-29 中兴通讯股份有限公司 Processing method for EMS memory data-base content variation real time notification task
CN101299710B (en) * 2007-04-30 2012-10-10 中兴通讯股份有限公司 Method for synchronization of memory database data
CN101242356B (en) * 2007-12-06 2010-08-18 中兴通讯股份有限公司 Realization method and IPTV system for memory database in IPTV system
CN101262325B (en) * 2008-04-21 2011-07-20 深圳南瑞科技有限公司 Switching device for monitoring dual hosts at translation station
CN102137132B (en) * 2010-01-26 2014-06-04 腾讯科技(深圳)有限公司 System and method for synchronizing data
CN102262591A (en) * 2010-05-31 2011-11-30 国际商业机器公司 Garbage collection method and system for memory copy system
US10628304B2 (en) 2010-05-31 2020-04-21 International Business Machines Corporation Garbage collection in an in-memory replication system
CN102289518A (en) * 2011-09-13 2011-12-21 盛乐信息技术(上海)有限公司 Method and system for updating audio fingerprint search library
CN102750202A (en) * 2012-06-06 2012-10-24 宇龙计算机通信科技(深圳)有限公司 Data protection method and device
CN102981777B (en) * 2012-10-29 2016-04-13 中国铁道科学研究院 A kind of control method of data access and system
CN102981777A (en) * 2012-10-29 2013-03-20 中国铁道科学研究院 Control method and system for data access
CN103020242B (en) * 2012-12-19 2015-11-25 中国人民解放军第二炮兵装备研究院第四研究所 Based on the method for data synchronization of oracle database
CN103020242A (en) * 2012-12-19 2013-04-03 中国人民解放军第二炮兵装备研究院第四研究所 Data synchronization method based on oracle database
CN103500130A (en) * 2013-09-11 2014-01-08 上海爱数软件有限公司 Method for backing up dual-computer hot standby data in real time
CN103500130B (en) * 2013-09-11 2015-07-29 上海爱数软件有限公司 A kind of method that two-node cluster hot backup data are backed up in realtime
CN103532753A (en) * 2013-10-11 2014-01-22 中国电子科技集团公司第二十八研究所 Double-computer hot standby method based on memory page replacement synchronization
CN103532753B (en) * 2013-10-11 2016-08-17 中国电子科技集团公司第二十八研究所 A kind of double hot standby method of synchronization of skipping based on internal memory
CN103780615B (en) * 2014-01-20 2017-02-01 五八同城信息技术有限公司 Sharing method of client conversation data among multiple servers
CN105719414A (en) * 2014-12-05 2016-06-29 航天信息股份有限公司 POS terminal invoicing method and device, and invoicing server terminal
CN107038094A (en) * 2017-04-27 2017-08-11 紫光华山信息技术有限公司 A kind of data back up method and device
CN108170768A (en) * 2017-12-25 2018-06-15 腾讯科技(深圳)有限公司 database synchronization method, device and readable medium
CN108614876A (en) * 2018-04-26 2018-10-02 武汉斗鱼网络科技有限公司 A kind of system and data processing method based on Redis databases
CN108959548A (en) * 2018-07-02 2018-12-07 阿里巴巴集团控股有限公司 The processing method and processing device of service request
CN108959548B (en) * 2018-07-02 2023-04-18 创新先进技术有限公司 Service request processing method and device
CN109542690A (en) * 2018-11-30 2019-03-29 安徽继远软件有限公司 A kind of method and apparatus of backup database data
WO2020192311A1 (en) * 2019-03-22 2020-10-01 北京达佳互联信息技术有限公司 Master-slave server switching method and apparatus, electronic device and storage medium
US11500744B2 (en) 2019-03-22 2022-11-15 Beijing Dajia Internet Information Technology Co., Ltd. Method for primary-backup server switching, and control server
CN110297730A (en) * 2019-07-04 2019-10-01 北京谷数科技有限公司 A kind of storage dual-active solution and system for removing arbitration node
CN110727733A (en) * 2019-09-25 2020-01-24 许昌许继软件技术有限公司 Main and standby server system and data synchronization method
CN112416656A (en) * 2020-12-08 2021-02-26 卡斯柯信号有限公司 Data offline storage method for station application server
CN112416656B (en) * 2020-12-08 2022-08-26 卡斯柯信号有限公司 Data offline storage method for station application server

Also Published As

Publication number Publication date
CN100390747C (en) 2008-05-28

Similar Documents

Publication Publication Date Title
CN1808394A (en) Soft co-standby method based on memory database
CN101944114B (en) Data synchronization method between memory database and physical database
CN102662751B (en) A kind of method improving based on thermophoresis dummy machine system availability
CN103875229B (en) asynchronous replication method, device and system
CN104361030A (en) Distributed cache architecture with task distribution function and cache method
CN104506950A (en) Multithread download method and download device in network streaming media play, and download equipment
CN105808643A (en) Redis memory database refreshing method
CN102024016A (en) Rapid data restoration method for distributed file system (DFS)
CN101231619A (en) Method for managing dynamic internal memory base on discontinuous page
US7860828B2 (en) System and method for transfering data from a source machine to a target machine
CN106301938A (en) A kind of high availability and the data base cluster system of strong consistency and node administration method thereof
CN102117287A (en) Distributed file system access method, a metadata server and client side
KR101966201B1 (en) Big data archiving and searching stsrem
CN1852455A (en) Data disaster-tolerance system and method
CN100581165C (en) Client system and service system data synchronizing method and system
CN111400312A (en) Edge storage database based on improved L SM tree
CN103514258A (en) Centralized recording, preprocessing and replaying method based on offline cache file operation
CN103617195A (en) Data synchronization system and data synchronization method used for MySQL database
CN112799881A (en) Backup and recovery device and method for cloud file storage system
CN103139607A (en) Real-time network monitoring system and method thereof
CN1862504A (en) Method of multi-computer back-up
CN101137045A (en) Video communication method, video service device and system
CN106131186A (en) A kind of power information acquisition interface adjustment method based on Redis distributed caching
CN112667698B (en) MongoDB data synchronization method based on converged media platform
CN1255731C (en) Data management system in the internet storage system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
EE01 Entry into force of recordation of patent licensing contract

Assignee: LIAN Technology (Nanjing) Co., Ltd.

Assignor: Linkage System Integration Co., Ltd.

Contract fulfillment period: 2008.11.4 to 2026.11.29 contract change

Contract record no.: 2008320001106

Denomination of invention: Soft co-standby method based on memory database

Granted publication date: 20080528

License type: exclusive license

Record date: 20081124

LIC Patent licence contract for exploitation submitted for record

Free format text: EXCLUSIVE LICENSE; TIME LIMIT OF IMPLEMENTING CONTACT: 2008.11.4 TO 2026.11.29; CHANGE OF CONTRACT

Name of requester: LIANCHUANG SCIENCE ( NANJING ) CO., LTD.

Effective date: 20081124

ASS Succession or assignment of patent right

Owner name: LIANCHUANG SCIENCE ( NANJING ) CO., LTD.

Free format text: FORMER OWNER: NANJING LIANCHUANG SCIENCE CO., LTD.

Effective date: 20091127

C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20091127

Address after: Building 16, world window software park, No. 12 Huai gate, Jiangsu, Nanjing

Patentee after: LIAN Technology (Nanjing) Co., Ltd.

Address before: 16 floor, No. 12 Huai gate, Nanjing, Jiangsu

Patentee before: Linkage System Integration Co., Ltd.

C56 Change in the name or address of the patentee

Owner name: LINKAGE-ASIAINFO TECHNOLOGY (NANJING) CO., LTD.

Free format text: FORMER NAME: LINKAGE TECHNOLOGY (NANJING) CO., LTD.

CP01 Change in the name or title of a patent holder

Address after: 210013 No. 16 building, world window software park, No. 12 Huai gate, Jiangsu, Nanjing

Patentee after: LINKAGE-ASIAINFO TECHNOLOGIES (NANJING), INC.

Address before: 210013 No. 16 building, world window software park, No. 12 Huai gate, Jiangsu, Nanjing

Patentee before: Linkage System Integration Co., Ltd.

C56 Change in the name or address of the patentee

Owner name: ASIALNFO TECHNOLOGY (NANJING) CO., LTD.

Free format text: FORMER NAME: LINKAGE-ASIAINFO TECHNOLOGY (NANJING) CO., LTD.

CP01 Change in the name or title of a patent holder

Address after: 210013 No. 16 building, world window software park, No. 12 Huai gate, Jiangsu, Nanjing

Patentee after: Asialnfo Technology (Nanjing) Co., Ltd.

Address before: 210013 No. 16 building, world window software park, No. 12 Huai gate, Jiangsu, Nanjing

Patentee before: LINKAGE-ASIAINFO TECHNOLOGIES (NANJING), INC.