CN104468419A - Method and system for recovering configuration of interchanger and interchanger - Google Patents
Method and system for recovering configuration of interchanger and interchanger Download PDFInfo
- Publication number
- CN104468419A CN104468419A CN201410821521.3A CN201410821521A CN104468419A CN 104468419 A CN104468419 A CN 104468419A CN 201410821521 A CN201410821521 A CN 201410821521A CN 104468419 A CN104468419 A CN 104468419A
- Authority
- CN
- China
- Prior art keywords
- configuration data
- switch
- switch configuration
- internal memory
- interchanger
- 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.)
- Pending
Links
Landscapes
- Retry When Errors Occur (AREA)
Abstract
The invention provides a method and system for recovering configuration of an interchanger and the interchanger. The method for recovering configuration of the interchanger comprises the steps that configuration data of the interchanger in a memory are stored in a nonvolatile storage in a preset format; when the interchanger is restarted, the configuration data of the interchanger are read from the nonvolatile storage and recovered to the memory. The system for recovering configuration of the interchanger comprises a configuration data storage module and a configuration data recovery module, wherein the configuration data storage module is used for storing the configuration data of the interchanger in the memory in the nonvolatile storage in a preset format, and the configuration data recovery module is used for reading the configuration data of the interchanger from the nonvolatile storage when the interchanger is restarted and recovering the data to the memory. According to the method and the system for recovering configuration of the interchanger, the configuration data of the interchanger system can be recovered within a short period, and the needed configuration recovery time of the interchanger system is effectively shortened.
Description
Technical field
The present invention relates to a kind of switch technology, particularly relate to a kind of switch configuration restoration methods, system and switch.
Background technology
Switch (English: Switch, means " switch ") is a kind of network equipment forwarded for the signal of telecommunication.It can provide for any two network nodes of access switch the pathway for electrical signals exclusively enjoyed.Modal switch is Ethernet switch.What other were common also has call voice switch, optical fiber switch etc.
Switch configuration refers to before switch recovers power-off after power-off restarting and configures.Current switch great majority adopt the configuration file of text formatting to recover switch configuration.The configuration order of switch is saved in switch configuration file.Read configuration file after switch power-off restarting, parse each configuration order in configuration file, then perform configuration.Execution due to each configuration order of switch system generally all needs to be saved in the process such as internal memory through command analysis, parameter validity checking, characteristic mutual exclusion inspection, data.Here inside process, some may call the interface relating to I/O operation etc. and cause task blocking again.All of these factors taken together all can badly influence the time of implementation of an order.Therefore, the method for this recovery system configuration is consuming time long when configuration is many.
Given this, how to find one quickly and easily switch configuration data reconstruction method become those skilled in the art's problem demanding prompt solution.
Summary of the invention
The shortcoming of prior art in view of the above, the object of the present invention is to provide a kind of switch configuration restoration methods, system and switch, for solving switch long problem consuming time in recovery system layoutprocedure in prior art.
For achieving the above object and other relevant objects, the invention provides a kind of switch configuration restoration methods, described switch configuration restoration methods comprises: the switch configuration data in internal memory preserved in the nonvolatile memory with preset format; When switch is restarted, from described nonvolatile memory, read described switch configuration data, and return in internal memory.
Alternatively, described nonvolatile memory comprises FLASH.
Alternatively, the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.
Alternatively, the preset format of described switch configuration data comprises table format, described in the specific implementation returned in internal memory comprise the switch configuration data of resolving described table format and storing.
Alternatively, switch configuration data described in each correspond to a switch configuration order.
The present invention also provides a kind of switch configuration recovery system, and described switch configuration recovery system comprises: configuration data preserves module, for the switch configuration data in internal memory being preserved in the nonvolatile memory with preset format; Allocation data recovering module, for when switch is restarted, reads described switch configuration data, and returns in internal memory from described nonvolatile memory.
Alternatively, described nonvolatile memory comprises FLASH.
Alternatively, the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.
Alternatively, the preset format of described switch configuration data comprises table format, described in the specific implementation returned in internal memory comprise the switch configuration data of resolving described table format and storing.
Alternatively, switch configuration data described in each correspond to a switch configuration order.
Alternatively, described configuration data preserves module also for when switch configuration data change, the configuration data in nonvolatile memory described in real-time update.
The present invention also provides a kind of switch, and described switch comprises switch configuration recovery system as above.
As mentioned above, a kind of switch configuration restoration methods of the present invention, system and switch, there is following beneficial effect: by directly reading switch configuration data and return in internal memory when system reboot, thus realize the configuration data recovering switch system in the short time, effectively reduce the time required for configuration restore of switch system, substantially increase the efficiency configured before switch recovers power-off after power-off restarting.
Accompanying drawing explanation
Fig. 1 is shown as the schematic flow sheet of an embodiment of switch configuration restoration methods of the present invention.
Fig. 2 is shown as the schematic flow sheet of an embodiment of switch configuration restoration methods of the present invention.
Fig. 3 is shown as the schematic flow sheet of an embodiment of switch configuration restoration methods of the present invention.
Fig. 4 is shown as the module diagram of an embodiment of switch configuration recovery system of the present invention.
Element numbers explanation
1 switch configuration recovery system
11 configuration datas preserve module
12 allocation data recovering modules
S1 ~ S2 step
Embodiment
Below by way of specific instantiation, embodiments of the present invention are described, those skilled in the art the content disclosed by this specification can understand other advantages of the present invention and effect easily.The present invention can also be implemented or be applied by embodiments different in addition, and the every details in this specification also can based on different viewpoints and application, carries out various modification or change not deviating under spirit of the present invention.
It should be noted that, the diagram provided in the present embodiment only illustrates basic conception of the present invention in a schematic way, then only the assembly relevant with the present invention is shown in graphic but not component count, shape and size when implementing according to reality is drawn, it is actual when implementing, and the kenel of each assembly, quantity and ratio can be a kind of change arbitrarily, and its assembly layout kenel also may be more complicated.
The invention provides a kind of switch configuration restoration methods.In one embodiment, as shown in Figure 1, described switch configuration restoration methods comprises:
Switch configuration data in internal memory are preserved in the nonvolatile memory with preset format by step S1.In one embodiment, described nonvolatile memory comprises FLASH.In one embodiment, the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.In one embodiment, switch configuration data described in each correspond to a switch configuration order.In one embodiment, as shown in Figure 2, the preset format of described switch configuration data comprises table format.Switch normally carries out switch configuration by order, as fill order ip address192.168.2.1/24.By the parsing to this order, parameter validity checking; Finally data are saved in internal memory.The configuration data be kept in internal memory is saved in FLASH by preset format (forms mode) by method of the present invention.Flash memory (FlashMemory) is the memory of a kind of long-life non-volatile (still can keep stored data message under powering-off state), and it is not (note: NOR Flash is for bytes store in units of single byte but in units of fixing block that data are deleted.), block size is generally 256KB to 20MB.Flash memory is the mutation of Electrical Erasable read-only memory (EEPROM), flash memory and EEPROM can carry out deleting and rewrite in byte-level unlike, EEPROM instead of whole chip erasable, and most of chip of flash memory needs block to wipe.Still can preserve data due to during its power-off, flash memory is usually used to preserve configuration information, as preservation data etc. in BIOS (base program), the PDA (personal digital assistant), digital camera of computer.
Step S2, when switch is restarted, reads described switch configuration data, and returns in internal memory from described nonvolatile memory.Particularly, when switch is restarted, will reconfigure switch, process common at present by reading configuration file, the configuration order performed in configuration file recovers the configuration to switch.Comprise the configuration order read in configuration file, to parsing, the parameter validity checking of configuration order; Finally data are saved in internal memory.In the method for the invention, directly will read described switch configuration data from described nonvolatile memory, and return in internal memory.In one embodiment, as shown in Figure 3, when switch is restarted, described switch configuration data will be read from FLASH, and return in internal memory.Because the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.So only read described switch configuration data and copy the assigned address of internal memory to from FLASH, just can by switch configuration date restoring in internal memory.In one embodiment, the preset format of described switch configuration data comprises table format, described in the specific implementation returned in internal memory comprise the switch configuration data of resolving described table format and storing.
The present invention also provides a kind of switch configuration recovery system.In one embodiment, as shown in Figure 4, described switch configuration recovery system 1 comprises configuration data and preserves module 11 and allocation data recovering module 12, wherein:
Configuration data preserves module 11 for the switch configuration data in internal memory being preserved in the nonvolatile memory with preset format.In one embodiment, the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.In one embodiment, switch configuration data described in each correspond to a switch configuration order.In one embodiment, the configuration data be kept in internal memory is saved in FLASH by preset format (forms mode) by configuration data preservation module 11.Described configuration data can be by ordering the configuration data carrying out switch configuration and obtain, as fill order ip address 192.168.2.1/24.By the parsing to this order, parameter validity checking; Finally configuration data is saved in internal memory.In one embodiment, the preset format of described switch configuration data comprises table format.
In one embodiment, described configuration data preserves module 11 also for when switch configuration data change, the configuration data in nonvolatile memory described in real-time update.User can be changed switch configuration data by configuration order, when switch configuration data change, described configuration data preserves module 11 will upgrade configuration data in described nonvolatile memory according to described change, ensure the configuration data in described nonvolatile memory and the configuration data in internal memory completely the same.
Allocation data recovering module 12, for when switch is restarted, reads described switch configuration data, and returns in internal memory from described nonvolatile memory.Particularly, described nonvolatile memory comprises FLASH.In one embodiment, when switch is restarted, allocation data recovering module 12 will read described switch configuration data from FLASH, and return in internal memory.In one embodiment, the preset format due to described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.So only read described switch configuration data and copy the assigned address of internal memory to from FLASH, just can by switch configuration date restoring in internal memory.In one embodiment, the preset format of described switch configuration data comprises table format, described in the specific implementation returned in internal memory comprise the switch configuration data of resolving described table format and storing.Allocation data recovering module 12 is for when switch is restarted, the switch configuration data that described form stores are read from described nonvolatile memory, and resolve the switch configuration data of described table format storage, the switch configuration date restoring stored by described table format is in internal memory.
The present invention also provides a kind of switch, and described switch comprises switch configuration recovery system 1 as above.Described switch can realize the switch configuration data in internal memory to preserve in the nonvolatile memory with preset format; And when switch is restarted, from described nonvolatile memory, read described switch configuration data, and return in internal memory.
In sum, a kind of switch configuration restoration methods of the present invention, system and switch are by directly reading switch configuration data when system reboot and returning in internal memory, thus realize the configuration data recovering switch system in the short time, effectively reduce the time required for configuration restore of switch system, substantially increase the efficiency configured before switch recovers power-off after power-off restarting.So the present invention effectively overcomes various shortcoming of the prior art and tool high industrial utilization.
Above-described embodiment is illustrative principle of the present invention and effect thereof only, but not for limiting the present invention.Any person skilled in the art scholar all without prejudice under spirit of the present invention and category, can modify above-described embodiment or changes.Therefore, such as have in art usually know the knowledgeable do not depart from complete under disclosed spirit and technological thought all equivalence modify or change, must be contained by claim of the present invention.
Claims (10)
1. a switch configuration restoration methods, is characterized in that, described switch configuration restoration methods comprises:
Switch configuration data in internal memory are preserved in the nonvolatile memory with preset format;
When switch is restarted, from described nonvolatile memory, read described switch configuration data, and return in internal memory.
2. switch configuration restoration methods according to claim 1, is characterized in that: described nonvolatile memory comprises FLASH.
3. switch configuration restoration methods according to claim 1, is characterized in that: the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.
4. switch configuration restoration methods according to claim 1, it is characterized in that: the preset format of described switch configuration data comprises table format, described in the specific implementation returned in internal memory comprise the switch configuration data of resolving described table format and storing.
5. a switch configuration recovery system, is characterized in that: described switch configuration recovery system comprises:
Configuration data preserves module, for the switch configuration data in internal memory being preserved in the nonvolatile memory with preset format;
Allocation data recovering module, for when switch is restarted, reads described switch configuration data, and returns in internal memory from described nonvolatile memory.
6. switch configuration recovery system according to claim 5, is characterized in that: described nonvolatile memory comprises FLASH.
7. switch configuration recovery system according to claim 5, is characterized in that: the preset format of described switch configuration data is identical with the configuration data form of switch configuration data in internal memory.
8. switch configuration recovery system according to claim 5, it is characterized in that: the preset format of described switch configuration data comprises table format, described in the specific implementation returned in internal memory comprise the switch configuration data of resolving described table format and storing.
9. switch configuration recovery system according to claim 5, is characterized in that: described configuration data preserves module also for when switch configuration data change, the configuration data in nonvolatile memory described in real-time update.
10. a switch, is characterized in that: described switch comprises as the switch configuration recovery system in claim 5 to 9 as described in any one.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410821521.3A CN104468419A (en) | 2014-12-22 | 2014-12-22 | Method and system for recovering configuration of interchanger and interchanger |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410821521.3A CN104468419A (en) | 2014-12-22 | 2014-12-22 | Method and system for recovering configuration of interchanger and interchanger |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104468419A true CN104468419A (en) | 2015-03-25 |
Family
ID=52913813
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410821521.3A Pending CN104468419A (en) | 2014-12-22 | 2014-12-22 | Method and system for recovering configuration of interchanger and interchanger |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104468419A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105933253A (en) * | 2016-04-13 | 2016-09-07 | 浪潮集团有限公司 | Switch configuration recovery method under SDN network |
CN105939219A (en) * | 2016-04-15 | 2016-09-14 | 杭州迪普科技有限公司 | Configuration recovery method and device |
CN106301858A (en) * | 2015-06-09 | 2017-01-04 | 中兴通讯股份有限公司 | Packet Transport Network equipment and resource recovery method, device |
CN106453099A (en) * | 2016-10-21 | 2017-02-22 | 杭州华三通信技术有限公司 | Flow table information recovery method and device |
CN108108314A (en) * | 2016-11-24 | 2018-06-01 | 英业达科技有限公司 | Exchanger system |
CN110719205A (en) * | 2019-10-17 | 2020-01-21 | 深圳市信锐网科技术有限公司 | Access switch, online recovery method, system and computer storage medium |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040123091A1 (en) * | 2002-12-20 | 2004-06-24 | Nokia Inc. | Automated bulk configuration of network devices |
CN1725695A (en) * | 2004-11-25 | 2006-01-25 | 杭州华为三康技术有限公司 | Exchange configuration method and system |
CN1881891A (en) * | 2005-06-17 | 2006-12-20 | 华为技术有限公司 | Method for storing configuration data of communication equipment |
CN101083684A (en) * | 2007-07-24 | 2007-12-05 | 华为技术有限公司 | Communication apparatus batch configuration managerial approach and apparatus |
CN102831034A (en) * | 2012-08-14 | 2012-12-19 | 中国电力科学研究院 | Multimode backup and quick recovery method based on embedded Linux device |
CN103220192A (en) * | 2013-05-10 | 2013-07-24 | 上海斐讯数据通信技术有限公司 | Testing method of switch configuration |
CN103514013A (en) * | 2013-09-11 | 2014-01-15 | 深圳市共进电子股份有限公司 | Gateway product FLASH configuration loss processing method |
-
2014
- 2014-12-22 CN CN201410821521.3A patent/CN104468419A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20040123091A1 (en) * | 2002-12-20 | 2004-06-24 | Nokia Inc. | Automated bulk configuration of network devices |
CN1725695A (en) * | 2004-11-25 | 2006-01-25 | 杭州华为三康技术有限公司 | Exchange configuration method and system |
CN1881891A (en) * | 2005-06-17 | 2006-12-20 | 华为技术有限公司 | Method for storing configuration data of communication equipment |
CN101083684A (en) * | 2007-07-24 | 2007-12-05 | 华为技术有限公司 | Communication apparatus batch configuration managerial approach and apparatus |
CN102831034A (en) * | 2012-08-14 | 2012-12-19 | 中国电力科学研究院 | Multimode backup and quick recovery method based on embedded Linux device |
CN103220192A (en) * | 2013-05-10 | 2013-07-24 | 上海斐讯数据通信技术有限公司 | Testing method of switch configuration |
CN103514013A (en) * | 2013-09-11 | 2014-01-15 | 深圳市共进电子股份有限公司 | Gateway product FLASH configuration loss processing method |
Cited By (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106301858A (en) * | 2015-06-09 | 2017-01-04 | 中兴通讯股份有限公司 | Packet Transport Network equipment and resource recovery method, device |
CN105933253A (en) * | 2016-04-13 | 2016-09-07 | 浪潮集团有限公司 | Switch configuration recovery method under SDN network |
CN105933253B (en) * | 2016-04-13 | 2018-09-04 | 浪潮集团有限公司 | Switch configuration recovery method under SDN network |
CN105939219A (en) * | 2016-04-15 | 2016-09-14 | 杭州迪普科技有限公司 | Configuration recovery method and device |
CN106453099A (en) * | 2016-10-21 | 2017-02-22 | 杭州华三通信技术有限公司 | Flow table information recovery method and device |
CN106453099B (en) * | 2016-10-21 | 2021-05-14 | 新华三技术有限公司 | Flow table information recovery method and device |
CN108108314A (en) * | 2016-11-24 | 2018-06-01 | 英业达科技有限公司 | Exchanger system |
CN108108314B (en) * | 2016-11-24 | 2020-05-19 | 英业达科技有限公司 | Exchanger system |
CN110719205A (en) * | 2019-10-17 | 2020-01-21 | 深圳市信锐网科技术有限公司 | Access switch, online recovery method, system and computer storage medium |
CN110719205B (en) * | 2019-10-17 | 2023-03-14 | 深圳市信锐网科技术有限公司 | Access switch, online recovery method, system and computer storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN104468419A (en) | Method and system for recovering configuration of interchanger and interchanger | |
CN108536745B (en) | Shell-based data table extraction method, terminal, equipment and storage medium | |
CN103399840A (en) | Out-of-band altering method of configuration file of computer and computer | |
CN104932955A (en) | Method for backing up data during factory setting restoring of mobile terminal, and mobile terminal | |
CN111273872A (en) | Data migration method, device, equipment and medium | |
CN105320578A (en) | Method and apparatus for backing up and recovering APP | |
US20150370653A1 (en) | Replacement of a corrupt driver variable record | |
CN103207830B (en) | Emulator with software breakpoint | |
CN111309424A (en) | Page restoration method and related equipment | |
CN104461621A (en) | Attribute information updating method and device | |
CN106020735A (en) | Data storage method and device | |
CN109582248A (en) | Wiring method, device and the computer readable storage medium of flash data | |
CN103777979A (en) | Method and device for recovering BIOD through cloud end | |
CN108037932B (en) | SPI-NAND configuration file acquisition method and device | |
CN109558145B (en) | Installation package volume optimization method and device for android application | |
CN105573913A (en) | Program debugging method and program debugging system in optical network unit (ONU) system | |
CN112148337A (en) | Firmware upgrading method and device | |
CN105005491B (en) | The upgrade method and system of a kind of linux kernel and application program | |
CN105207830A (en) | Detection method and apparatus for terminal information, and terminal | |
CN103677940A (en) | Method and system for updating operating system of T cards in trans-partition mode | |
CN105335095B (en) | The processing method and processing device of flash memory file system | |
CN103713922A (en) | Method and system for dynamically replacing driver codes of modules of Android device | |
CN112069189A (en) | Method and system for updating multi-level mapping table, terminal device and storage medium | |
CN100450013C (en) | Method for storing configuration data of communication equipment | |
CN107133077A (en) | A kind of page end calls the method and device of locally applied function |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
EXSB | Decision made by sipo to initiate substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20150325 |
|
RJ01 | Rejection of invention patent application after publication |