CN1280761C - Method for realizing relation-database automatic upgrading in communication apparatus - Google Patents

Method for realizing relation-database automatic upgrading in communication apparatus Download PDF

Info

Publication number
CN1280761C
CN1280761C CN 200410027310 CN200410027310A CN1280761C CN 1280761 C CN1280761 C CN 1280761C CN 200410027310 CN200410027310 CN 200410027310 CN 200410027310 A CN200410027310 A CN 200410027310A CN 1280761 C CN1280761 C CN 1280761C
Authority
CN
China
Prior art keywords
data
tables
database
attribute
content
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.)
Expired - Fee Related
Application number
CN 200410027310
Other languages
Chinese (zh)
Other versions
CN1581165A (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.)
Global Innovation Polymerization LLC
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN 200410027310 priority Critical patent/CN1280761C/en
Publication of CN1581165A publication Critical patent/CN1581165A/en
Application granted granted Critical
Publication of CN1280761C publication Critical patent/CN1280761C/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The present invention relates to a method for realizing the automatic updating of a relation database in a communication device, which has the steps: describing the information in a data list of the database in detail; starting a new software version on a preparation machine and sending the information of request for data transmission to a host machine; sending the attribute content adding the list name and the attribute name of the data list to the preparation machine after the host machine receiving the request; putting the attribute of the data list in the corresponding attribute of a data list with a new version after the preparation machine receiving the content of the data list, and not processing the attribute of the data list, which is not in the new version. After the database completes updating, the host machine makes the data list with data change in an updating period for the database transfer to the preparation machine. The present invention does not need modification codes, is capable of realizing the automatic updating of the database, saves the manpower and force for developing and maintaining an updating tool of the database, improves the development and maintenance efficiency of the communication device, and reduces the error rate of development and maintenance work.

Description

A kind of method that in communication facilities, realizes the relational database auto-update
Technical field
The present invention relates to the technology of carrying out software release upgrade on the large-scale communication facilities of active and standby master control borad, be specifically related to new and old edition database compatibling problem having.
Background technology
In the middle of the operation of communication facilities, owing to when the needs of new business being provided or revising communication equipment software version wrong, will upgrade to the software version of communication facilities usually, i.e. the old software version that is moving with new software version replacement.But because the importance of communication facilities in communication network, and the specific (special) requirements of communication network running quality, large-scale communication facilities generally requires the service impact minimum to moving when carrying out software release upgrade, even the business that can not interrupt moving.This just requires communication facilities after changing software version, and its running status is consistent basically with before changing software version.
In service in communication facilities, because database plays an important role, deposited the data message such as a large amount of command configuration, running status, performance statistics, alarm notification of communication facilities in the database, so carry out in the upgrade job of software version at communication facilities, the upgrading of database is an important step.It is make original just in operating software version the content in the record of each tables of data insert in the respective record of each tables of data in the new software version, running status and original running status of the communication facilities that more renews software version are consistent, reduce harmful effect the communication network quantity of operation.
But in database, same structure of data table might be different in different versions, and this has caused difficulty with regard to the upgrading of giving database.So that in the device software version that is moving data contents such as the various configurations in the database, statistics, alarm, note expense be synchronized to correctly, simply and easily fast in the database of the new software version after the upgrading, the professional normal operation and the maintenance work of communication network played an important role.If database can't be upgraded, bring a lot of unnecessary troubles will for the exploitation of communication facilities and maintenance.Or by the Operation and Maintenance platform all configuration orders of former operation version are re-entered one time after the software release upgrade, be consistent before making equipment running status after the upgrading and upgrading, or the modification of limit service and database, make like this in the database of each version to be consistent before and after the structure of data table, the device software version can be upgraded smoothly.
Learn by following analysis why same structure of data table different meetings in different versions cause difficulty to database upgrade.In the design of database, using more conceptual model is the E-R conceptual model, and in the E-R model, the world is divided into entity (entity) one by one, and (attribute) describes entity character by attribute, and interrelated by contact.Entity is physically or conceptive self-existent affairs or object, and entity is portrayed its character by attribute.Except entity and attribute, the third element that constitutes the E-R model is contact (relationship).Interact with related by contact between the entity.
On E-R conceptual model basis, in database was realized, one of most popular logic data model was exactly a relational model.The widely popular and great ability of relational model will be given the credit to its succinct structure, it be a kind of with bivariate table form presentation-entity data and entity between the data model of information such as concern, wherein, because bivariate table is commonly referred to as relation in mathematical formulae, therefore this model is called relational model, the row of table are called attribute (attribute).Each row is called a tuple (tuple), and the order that row or column occurs in the table is unimportant.Therefore relation is a unordered tuple-set.Table name and row name constituent relation pattern (relation schema), the set of row (or tuple) is called relationship example (relational instance).
Can seamlessly be mapped to relational model intuitively by the E-R model, each entity is mapped to an independent relation.Attributes of entities is mapped to the attribute of relation, and the contact of inter-entity also is mapped to relation.In memory database, this model is to the important effect that provides of the various functions of database.
Such as following be the example of relation, its name is called X.
X A B C D
X/1 a/1 b/1 c/1 d/1
X/2 a/2 b/2 c/2 d/2
X/3 a/3 b/3 c/3 d/3
X/4 a/4 b/4 c/4 d/4
A wherein, b, c, the attribute that d comprises for this relation.The title of relation and the property set of relation be called relation pattern X (A, B, C, D).In relation schema, except first row is the title block, other row X/1 in the relation ... be called tuple.
When carrying out the change of database, logically be equivalent to the property set of relation is changed.Such as having added an attribute E, then formed new relation schema, reducing by an attribute also is same principle.
X(A,B,C,D)
Xnew(A,B,C,D,E)
Xnew A B C D E
X/1 a/1 b/1 c/1 d/1 E/1
X/2 a/2 b/2 c/2 D/2 E/2
X/3 a/3 b/3 c/3 D/3 E/3
X/4 a/4 b/4 c/4 D/4 E/4
If being upgraded to new data, old data should satisfy following formula in principle.
X∩Xnew≠
Database upgrade is exactly the A that will concern among the X, B, and C, the content in the D attribute is put into concerning among the Xnew of new construction, and the E attribute can be sky and default value.
The upgrading of communication facilities database mainly contains two kinds of methods in the work of reality, and two kinds of methods each have the certain relative merits and the scope of application.
A kind of method is to utilize the Operation and Maintenance platform all configuration orders of the original version preserved to be configured the batch processing of order by script in the Operation and Maintenance platform of new software version, so that the tables of data content information in the database identical in the tables of data content information in the database of redaction and the early version, reach before the device software edition upgrading and the back identical purpose of operation conditions of upgrading.Script method is applicable to that relatively business function is fairly simple, configuration waits the fewer communication facilities of data content, this method is fairly simple reliable, but the data of the configuration section of can only upgrading, simultaneously because the contents such as configuration order parameter of new and old edition are not necessarily identical, so the explanation of configuration order part also will have corresponding upgrading tool to need to safeguard in the version.
Another kind method is directly with the database upgrade instrument content of the various tables of data of database in the software version to be upgraded, in the tabular database of data content new data in being transformed into redaction with legacy data form in the legacy version.The database upgrade tool method relatively is applicable to the data upgrading of the large-scale communication facilities that business realizing is many than data such as complicated and configurations, data after this upgrade method upgrading are more complete, not only comprised configuration data, all data of other classification in the database when also having comprised equipment operation.But this method realizes comparatively complicated, and the development and maintenance job requirement of data upgrading tool is than higher.
Because in physics realization, the content of two-dimentional relation data of database table all is to deposit in internal memory and the hard disk by the one dimension mode, and record and then another record saves as a memory block or file.For example tables of data X in the top example is upgraded to tables of data Xnew.If without the data upgrading tool, the complete content with Table X is taken out from internal memory or file and is put into Table X new, will in record Xnew/1 deviation appear, the content of a/1 will be deposited in the position of a/1, the content of a/2 will be deposited in the position of e/1, same deviation situation also can appear in the record of back, and this is because in memory block and file, and the tables of data record is one and connects one deposit.In existing data upgrading tool, the content that writes down X/1 is earlier put into Xnew/1, the pointer of operating the Xnew table then will point to Xnew/2, and the content of X/2 is put into operation successively realize the data upgrading.
But because the difference of version, its structure all might be different in different versions for same Table X, and the position that its different attribute occurs is also not necessarily identical, such as the position of attribute E not necessarily appears at the last of Xnew.The data upgrading tool will have different operations to same table in different versions like this.So what comprised in the database upgrade instrument that all want tables of data attribute between the upgrading software version has or not information such as the mutual difference in position.Will consider the updating operation between any two versions like this, it is huger that the data upgrading tool will become, simultaneously owing to data list structure in the version has any modification, the corresponding data upgrading tool all will make amendment and safeguard, make it to be in the change always, can not settle out, error rate is higher.Concrete upgrading principle can be referring to Fig. 1, and during database upgrade, main frame transmits data to standby host, the data upgrading tool is judged new and old edition, and whether the version on the promptly active and standby machine is identical, if identical, standby host is put into the data that receive in the redaction, if different, then will judge whether it is a certain version successively.
These two kinds of methods all can't fulfillment database auto-update, all need be before carrying out upgrade job in various degree modification maintenance upgrade instrument to adapt to the new change conditions of tables of data.
Summary is got off, and uses the upgrading of data upgrading tool fulfillment database that following shortcoming is arranged:
1, can not itself judge whether that tables of data is revised between two versions from what show, can only judge have those tables of data that modification has been arranged in the version according to the version number of version, this judgement error can occur unavoidably.The structure of data table that for example occurs between Shi Ji two versions is revised and is forgotten that in the database upgrade instrument ROMPaq with corresponding tables of data adds, then mistake will occur when database upgrade.
2, many multiple version conversion situations that arrive can appear when carrying out edition upgrading in theory, like this, rely on the version number of new and old two versions to judge that those tables carried out modification, will make the middle determining program of data upgrading tool very big growth occur, data upgrading tool maintenance workload will increase.
3, data upgrading tool itself owing to will revise at any time and safeguard that be in all the time in the variation, its stability can be affected unavoidably according to the situation of change of version.If being combined in the data upgrading tool of two kinds of version numbers that occur when edition upgrading do not consider that the database upgrade of version will be affected.The stability of the maintenance work of whole version will be affected.
Summary of the invention
The objective of the invention is for the exploitation and the maintenance work that overcome the data upgrading tool in the existing database upgrade technique more loaded down with trivial details, the shortcoming that need judge the possible combined situation of all versions, solve exist in the prior art can't fulfillment database auto-update and the non-maintaining problem of data upgrading tool, make the upgrade step of database in the software release upgrade work more convenient safe and reliable.
Technical scheme of the present invention is: earlier the tables of data information in the database is described in detail, comprises title to each tables of data, the title and the physical location of each attribute in the tables of data is described; On standby host, start new software version, and send the message of data transfer requested to main frame; Main frame adds that with the property content in the tables of data table name claims to send on the standby host with Property Name after receiving request; After standby host receives the tables of data content, the tables of data attribute is put into the attribute of new edition data table correspondence, the tables of data attribute that does not have in the redaction is disregarded.After database upgrade was finished, main frame sent the tables of data of the data change that the database upgrade phase takes place to standby host.
Adopt database automatically updating method of the present invention, compared with prior art, obtained the function that to revise the auto-update that code just can fulfillment database, reached and carried out data upgrading effect between almost any a plurality of software versions easily, the manpower and materials of exploitation and maintenance data base upgrading tool have been saved, improve the efficient of communication facilities exploitation and maintenance, reduced the error rate of exploitation and maintenance work.Simultaneously, because the upgrading of database and software version number are irrelevant, after database upgrade, need to return back in the original version if having.
Description of drawings
Fig. 1 is a kind of process flow diagram of existing database upgrade method.
Fig. 2 process flow diagram of the present invention.
Embodiment
The used upgrade method of the present invention is as follows, when the tables of data content in old software version database is transmitted in the database of new software version, be not according to existing technical scheme from internal memory or file with the unit of being recorded as according to one the record record with the tables of data delivery of content in the tables of data of redaction, but be unit with the property content, according to property content one by one with the delivery of content of tables of data in new tables of data.From the example data Table X of lifting previously, original technical scheme be with the content of 2-D data Table X according to record X/1 (a/1, b/1, c/1, d/1), X/2 (a/2, b/2, c/2, d/2) ... sequential lateral with data content delivery in new tables of data.And the present invention be with the content of 2-D data Table X according to attribute A (a/1, a/2, a/3, a/4), B (b/1, b/2, b/3, b/4) ... order vertically with data content delivery in new tables of data Xnew.
Because the equivalent representation method by relation learns that the pattern of relation and tuple all are set, is not tabulation, the order of attribute is unimportant in relation schema, no matter how putting in order between the attribute changes, concerns constant.So just draw an important conclusion: when data were upgraded, what new tables of data needed was old its each identical property value of tables of data neutralization, and did not need to know the physical arrangement information of the whole table of legacy data table.
In existing scheme of data content being upgraded with the unit of being recorded as, the data upgrading tool rearranges each property content in each record according to the difference of version number in new data list structure.So the data upgrading tool, just need be known same tables of data identical and difference structurally in the different editions to existing each software version.This method only needs each software version to know the position of each attribute in the tables of data own.
Below with reference to Fig. 2, the communication facilities that Yi Yitai has an active and standby master control borad further specifies the concrete steps of notebook data storehouse automatically updating method.
The first step at first will be described in detail the tables of data information in the software version database, comprising:
1, each tables of data in the database of software version is comprised that each attribute all will have unified accurately description.Each tables of data in the database all will have a name tag, and in different software versions, the title of same tables of data is necessarily identical, and the tables of data of two same names can not be arranged in same version simultaneously.Only in this way, when the tables of data delivery of content in the legacy version was in redaction, new software version knew that just what pass over is the content which opens tables of data.
2, each attribute all has unique name tag in the same tables of data, this name tag must be identical in different software versions, like this when the tables of data property content is delivered to redaction, new software version knows that just what pass over is the content of which attribute.
3, the database of each software version not only will be described to some extent to each Property Name in the tables of data, also will will describe to some extent the physical location of each attribute, the content of the tables of data attribute of the old software version that passes over so just can accurately be put in the tables of data of new software version.
Second step when the upgrading beginning, start redaction,
1, on the communication facilities that is moving, new software version is copied on the flash or hard disk of standby host by network management system or other approach.
2,, new version is moved with standby host restart on frame.
3, postrun version detection just sends the message of a data transfer requested to being standby host to main frame, just waits for that then main frame transmits data and comes
In the 3rd step, main frame transmits data to standby host.
1, main frame just adds the property content in the tables of data that table name claims to send on the standby host by message with Property Name after receiving the request of transmission data of standby host.Mentioned by preamble, relation database table depositing in internal memory and file is the one dimension form, and one is write down the order of following a record and deposits.The existing database upgrade method is the database that the tables of data recorded content is sent to successively new software version according to the record order.The present invention be tables of data each the record in same data attribute content transmit successively, this just need have corresponding tables of data convey program that each property content of every table is extracted in software version.
When 2, standby host receives the data-base content that main frame sends over, the attribute of corresponding data table that claims content to be put into the database of standby host by the table name in the detect-message with Property Name, owing to have the information of each Property Name and position in its data table in the standby host redaction, so standby host needn't be known the relative position of tables of data property content in the host data list structure that passes the main frame of coming.
3, in the present invention recorded content horizontal in the bivariate table is changed into according to property content longitudinally as unit of transfer as the unit of transfer of data content.When the data attribute A of tables of data delivery of content in new tables of data Xnew, the program of deal with data upgrading will vertically be put into tables of data Xnew with the content of the attribute A that passes over according to the positional information of attribute A in Table X new, equally, when data attribute B delivery of content in new tables of data Xnew, the program of deal with data upgrading will be put into tables of data Xnew with the content of the attribute B that passes over according to the positional information of attribute B in Table X new, and the like, all properties up to tables of data X all is delivered among the new tables of data Xnew, and tables of data X has just finished upgrading in new version Xnew like this.And the different and something in common of data structure that the program of deal with data upgrading does not need to know old tables of data X and new tables of data Xnew structure.Owing to do not have the data content of attribute E to send in the Table X, so attribute E just keeps initial value or default value naturally in new tables of data Xnew.If tables of data X has individual attribute to cancel in the tables of data Xnew of redaction such as B, new software version will be disregarded the content of this attribute.
4, finish when main frame all transmits all properties of a tables of data, send a message that transmits another tables of data.All forms transmission in the database will be finished after this process operation is crossed repeatedly, simultaneously, the content in the tables of data on the standby host is also arranged according to the new data list structure, and database has also just been finished upgrading.
Behind the standby host reception and the database of having upgraded, send corresponding message informing to main frame and receive ED.
If during database is upgraded, certain is opened tables of data and revises, and version will be put down in writing, and when the database upgrade process finishes, the tables of data that modification took place is transmitted again to new software version, and form is upgraded again.
At last, communication facilities carries out masterslave switchover, and new software version is normally moved.

Claims (2)

1, a kind of method that realizes the relational database auto-update in communication facilities may further comprise the steps:
1.1 the tables of data information in the database in the old software version is described in detail, comprises title, the title and the physical location of each attribute in the tables of data is described to each tables of data;
1.2 on standby host, start new software version, and send the message of data transfer requested to main frame;
1.3 use the tables of data convey program that each property content of every table is extracted, be that unit transmits successively with the property content with data; Main frame adds that with the property content in the tables of data table name claims to send on the standby host with Property Name;
1.4 after standby host receives the tables of data content, the tables of data attribute is put into the attribute of new edition data table correspondence, the tables of data attribute that does not have in the redaction is disregarded.
2, the described method that realizes the relational database auto-update in communication facilities of claim 1 is characterized in that, after database upgrade was finished, main frame sent the tables of data of the data change that the database upgrade phase takes place to standby host.
CN 200410027310 2004-05-18 2004-05-18 Method for realizing relation-database automatic upgrading in communication apparatus Expired - Fee Related CN1280761C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 200410027310 CN1280761C (en) 2004-05-18 2004-05-18 Method for realizing relation-database automatic upgrading in communication apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 200410027310 CN1280761C (en) 2004-05-18 2004-05-18 Method for realizing relation-database automatic upgrading in communication apparatus

Publications (2)

Publication Number Publication Date
CN1581165A CN1581165A (en) 2005-02-16
CN1280761C true CN1280761C (en) 2006-10-18

Family

ID=34582042

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 200410027310 Expired - Fee Related CN1280761C (en) 2004-05-18 2004-05-18 Method for realizing relation-database automatic upgrading in communication apparatus

Country Status (1)

Country Link
CN (1) CN1280761C (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100426291C (en) * 2005-11-26 2008-10-15 华为技术有限公司 System and method to realize database upgrading in background management system
CN101252464B (en) * 2008-03-17 2011-04-13 华为技术有限公司 Dual system and dual system online upgrading method
CN101582064B (en) * 2008-05-15 2011-12-21 阿里巴巴集团控股有限公司 Method and system for processing enormous data
CN101908064A (en) * 2010-07-20 2010-12-08 中兴通讯股份有限公司 Data base backup recovery method and device
CN102495739B (en) * 2011-11-03 2017-05-24 中兴通讯股份有限公司 Data compatible method and system as well as inter-plate message method and system
CN102662694B (en) * 2012-03-22 2016-03-30 福建星网视易信息系统有限公司 The batch processing upgrade method of database script and upgrading device
CN103324716B (en) * 2013-06-25 2016-08-10 四川九洲电器集团有限责任公司 A kind of application database update method based on Android system

Also Published As

Publication number Publication date
CN1581165A (en) 2005-02-16

Similar Documents

Publication Publication Date Title
CN101499069B (en) Internal memory database file updating method and apparatus
CN1264107C (en) Integrating tablespaces with different block sizes
CN1277231C (en) Data loading from remote data source
CN1292370C (en) Method and apparatus for data processing
CN102741843B (en) Method and apparatus for reading data from database
CN1977265A (en) State based synchronization
CN1864137A (en) Database management system with efficient version control
CN1755676A (en) System and method for batched indexing of network documents
CN101046821A (en) Generic database manipulator
CN101067814A (en) Mapping conversion method between data access level Xml format data and relational data
CN1694073A (en) Method and system for synchronizing data between electronic devices
CN102567399B (en) Method and device for accessing database
CN1280761C (en) Method for realizing relation-database automatic upgrading in communication apparatus
CN1975731A (en) System and method for managing access to data in a database
CN1848849A (en) Method and device for replicating modifications of a directory
CN100517229C (en) Data version upgrading method
CN100392651C (en) Universal constraining realizing method for real-time internal memory database
US20070261063A1 (en) Work item event procession
CN1821999A (en) Object integrated management system
CN115905628A (en) Dynamic resource directory construction method, device, equipment and storage medium
CN1633080A (en) Method for implementing log in network management system
CN101174204A (en) Device for upgrading data version
CN1577309A (en) System and method for equipment automation program refresh and computer readable memory medium
EP2662783A1 (en) Data archiving approach leveraging database layer functionality
CN1975701A (en) Master machine driving external equipment method and 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
TR01 Transfer of patent right

Effective date of registration: 20180711

Address after: California, USA

Patentee after: Global innovation polymerization LLC

Address before: 518057, Nanshan District high tech Industrial Park, Guangdong province Shenzhen science and technology south road Zhongxing building A block 6

Patentee before: ZTE Corp.

TR01 Transfer of patent right
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20061018

CF01 Termination of patent right due to non-payment of annual fee