WO2015154578A1 - Remote upgrade method, device and system of boot program of single board - Google Patents

Remote upgrade method, device and system of boot program of single board Download PDF

Info

Publication number
WO2015154578A1
WO2015154578A1 PCT/CN2015/071819 CN2015071819W WO2015154578A1 WO 2015154578 A1 WO2015154578 A1 WO 2015154578A1 CN 2015071819 W CN2015071819 W CN 2015071819W WO 2015154578 A1 WO2015154578 A1 WO 2015154578A1
Authority
WO
WIPO (PCT)
Prior art keywords
board
boot program
area
new version
spare area
Prior art date
Application number
PCT/CN2015/071819
Other languages
French (fr)
Chinese (zh)
Inventor
罗秀福
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2015154578A1 publication Critical patent/WO2015154578A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating

Definitions

  • the present invention relates to the field of communications technologies, and in particular, to a BOOT remote program upgrade method, apparatus, and system for a single board.
  • the main purpose of the embodiment of the present invention is to solve the technical problem that the BOOT program upgrade of the board requires manual operation on site.
  • a method for remotely upgrading a BOOT program of a single board includes the following steps:
  • the storage area in the board is initialized to divide the storage area to obtain the primary area and the spare area.
  • the board runs the BOOT program in the main area
  • the board When detecting the remote upgrade command sent by the remote client through the network element main control board, the board obtains a new version of the BOOT program from the network element main control board, and stores the new version of the BOOT program to the spare area. ;
  • the board runs a new version of the BOOT program in the spare area
  • the board uses the spare area as a new primary area and uses the primary area as a new spare area.
  • the board includes:
  • the board resets and runs the BOOT program in the active area when the new version of the BOOT program is unsuccessful.
  • the step of the board running a new version of the BOOT program in the spare area includes:
  • the board sets the trial run ID and the test run timing indicator
  • the board resets and runs the new version of the BOOT program
  • the board clears the trial run identifier and retains the trial run timing indicator.
  • the step of the board running a new version of the BOOT program in the spare area is replaced by:
  • the board determines whether the spare area is in a trial running state
  • the board determines that the spare area is not in the trial running state, the board runs a new version of the BOOT program in the spare area.
  • the board replaces the spare area as a new primary area when the new version of the BOOT program runs successfully, and replaces the primary area as a new spare area with:
  • the board detects whether the remote area is in a trial running state when the remote client sends an activation command sent by the network element main control board.
  • the board clears the trial running timing identifier, uses the spare area as a new primary area, and uses the primary area as a new spare area;
  • the board clears the trial running timing identifier.
  • the step of obtaining a new version of the BOOT program from the network element main control board includes:
  • the board determines whether the board is in the trial running state when receiving the remote upgrade command sent by the remote client through the NE main control board.
  • the board determines that the board is not in the trial running state, it sends a remote upgrade response to the NE main control board.
  • the board receives the new version of the BOOT program forwarded by the remote client to the network element main control board forwarded by the network element main control board.
  • the embodiment of the present invention further provides a BOOT remote upgrade device of a single board, and the BOOT remote upgrade device of the single board includes:
  • the initialization module is configured to: when the board is started, initialize the storage area in the board to divide the storage area to obtain the primary area and the spare area;
  • Running the module set to: run the BOOT program in the main area;
  • the download module is configured to: when detecting a remote upgrade command sent by the remote client via the network element main control board, obtain a new version of the BOOT program from the network element main control board, and store the new version of the BOOT program to The spare area;
  • the trial run module is set to: run a new version of the BOOT program in the spare area;
  • the activation module is configured to: when the new version of the BOOT program runs successfully, use the spare area as a new primary area, and use the primary area as a new spare area.
  • the remote upgrade device of the BOOT program of the board includes:
  • a reset module configured to reset the board and run the BOOT program in the active area when the new version of the BOOT program is unsuccessful.
  • the trial running module includes:
  • Set the unit set to: set the trial run ID and test run timing indicator
  • the commissioning unit is configured to: reset the board and run the new version of the BOOT program
  • a clearing unit configured to: clear the trial run identifier and retain the trial run timing identifier.
  • the trial run module is set to:
  • the activation module is set to:
  • the trial running timing identifier is cleared.
  • the downloading module includes:
  • the judging unit is configured to: receive a remote upgrade sent by the remote client via the network element main control board When the command is executed, it is determined whether the board is in the trial running state;
  • the response unit is configured to: send a remote upgrade response to the network element main control board when it is determined that the board is not in the trial running state;
  • the receiving unit is configured to: receive the new version of the BOOT program forwarded by the remote client to the network element main control board and forwarded by the remote control board.
  • the embodiment of the present invention further provides a BOOT program remote upgrade system for a board, including a board, a network element main control board, and a remote client;
  • the remote client is configured to: send a new version of the BOOT program to the network element main control board; after the board is started, send a remote upgrade command to the network element main control board, where the network element is controlled.
  • the board forwards the remote upgrade command to the board;
  • the network element control board is configured to: receive the new version of the BOOT program sent by the remote client, and forward the remote upgrade command sent by the remote client to the board;
  • the board is configured to: when the board is started, initialize a storage area in the board to divide the storage area to obtain a main area and a spare area; and run the BOOT program in the main area;
  • the remote client sends the remote upgrade command sent by the network element main control board
  • the new version of the BOOT program is obtained from the network element main control board, and the new version of the BOOT program is stored in the spare area;
  • the embodiment of the invention further provides a computer readable storage medium storing program instructions, which can be implemented when the program instructions are executed.
  • the BOOT program of the board is remotely upgraded, and the technician is not required to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area.
  • Figure 1 is a partition diagram of a single board storage area
  • FIG. 2 is a schematic flowchart of a first embodiment of a remote upgrade method of a BOOT program of a board according to the present invention
  • FIG. 3 is a schematic flowchart of a second embodiment of a remote upgrade method of a BOOT program of a board according to the present invention
  • FIG. 4 is a schematic flowchart of a third embodiment of a remote upgrade method of a BOOT program of a board according to the present invention.
  • FIG. 5 is a schematic diagram of an alternative flow of the step of using the spare area as a new primary area and using the primary area as a new spare area when the new version of the BOOT program runs successfully in the board shown in FIG. 1;
  • FIG. 6 is a board in which the board in FIG. 1 obtains a new version of the BOOT program from the network element main control board when detecting a remote upgrade command sent by the remote client through the network element main control board, and the new version is A detailed flow diagram of the steps of the BOOT program storing to the spare area;
  • FIG. 7 is a schematic diagram of functional modules of a first embodiment of a BOOT program remote upgrade apparatus of a board according to the present invention.
  • FIG. 8 is a schematic diagram of functional modules of a second embodiment of a remote upgrade device for a BOOT of a board according to the present invention.
  • FIG. 9 is a schematic diagram of functional modules of a third embodiment of a remote upgrade device for a BOOT program of a board according to the present invention.
  • FIG. 10 is a schematic diagram of a refinement function module of the download module in FIG. 6;
  • FIG. 11 is a schematic diagram of functional modules of a first embodiment of a BOOT program remote upgrade system of a board according to the present invention.
  • Figure 12 is a schematic diagram of interaction between the remote upgrade system of the BOOT program of the board.
  • At least one separate storage area is preset for storing and running the BOOT program.
  • the storage area is at least divided into a primary area and a spare area; the primary area is a partition that preferentially enables the BOOT program to run.
  • the standby area does not run the BOOT program.
  • FIG. 1 is a partition diagram of a single board storage area.
  • the information area and the reserved area are set in the area, and the information area is used to store the BOOT status information, and the status information includes a BOOT version number, a CRC (Cyclic Redundancy Check) value, and the status information may include other information as needed.
  • Information; reserved areas are used to reserve space for subsequent development and utilization. It should be noted that setting the information area in the storage area is only an optional technical solution of the present invention, and is not intended to limit the present invention.
  • the invention provides a remote upgrade method for a BOOT program of a single board.
  • FIG. 2 is a schematic flowchart diagram of a first embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
  • the method includes:
  • Step S10 When the board is started, the storage area in the board is initialized to divide the storage area to obtain the primary area and the spare area.
  • the method for dividing the storage into the main area and the spare area may be: dividing the storage address in the storage area, the main area corresponding to a part of the storage address, the spare area corresponding to a part of the storage address, and the data stored in the storage address is not Changed due to initialization.
  • Step S20 The board runs the BOOT program in the active area.
  • the method for starting the main area of the board may be: the EPLD (Erasable Programmable Logic Device) in the board is started first, and the EPLD identifies and starts the main use according to the preset startup identifier in the internal memory. Area.
  • the startup identifier is preset according to the status information of the BOOT, and the startup identifier may also be stored in other locations.
  • Step S30 The board obtains a new version of the BOOT program from the network element main control board when detecting the remote upgrade command sent by the remote client through the network element main control board, and stores the new version of the BOOT program to the Spare area
  • the process of obtaining the new version of the BOOT program sent by the remote client to the network element main control board (NCP) is performed by the BOOT layer of the board.
  • the method may be: when the user needs to update the BOOT program of the board, firstly through the remote client. And use the File Transfer Protocol (FTP) to send a new version of the BOOT program to the NE main control board, and then remotely log in to the NE main control board through Telnet.
  • FTP File Transfer Protocol
  • the user uses the client to send a remote upgrade through the NE main control board.
  • the command is sent to the BOOT layer of the board.
  • the main control board of the control network element directly sends the new version of the BOOT program to the BOOT layer of the board in the board through the S-port (Serial Communication Port), or the NE main control board.
  • a new version can be sent via the S port when receiving a request for a new version of the BOOT program sent by the BOOT layer of the board.
  • the BOOT program goes to the BOOT layer of the board.
  • the board BOOT layer performs the step of acquiring the new version of the BOOT program from the network element main control board, and storing the new version of the BOOT program to the spare area, thereby guiding the board application layer in the board to execute the running spare area.
  • Step S40 The board runs a new version of the BOOT program in the spare area
  • the board application layer stops the BOOT program in the main area by hanging the dog reset, and tries to run the new version of the BOOT program in the spare area and monitors the trial operation.
  • step S50 when the new version of the BOOT program runs successfully, the board uses the spare area as the new main area and the main area as the new spare area.
  • the board application layer determines whether the new version of the BOOT program runs successfully. It can be: determined by the corresponding identifier set when the new version of the BOOT program runs successfully, in this embodiment.
  • the method in which the board application layer can determine whether the BOOT program runs successfully is similar to the method in the related art, and details are not described herein.
  • the board application layer can automatically use the spare area as the new primary area and the primary area as the new spare area when the new version of the BOOT program runs successfully.
  • the board application layer can be used in the new version of the BOOT program.
  • the board application layer uses the spare area as the new primary area, and the method of using the primary area as the new spare area may be: switching the primary area and the spare area by setting the boot identifier preferentially enabled by the mark partition; or, by setting The active and standby status IDs mark the active area and the standby area.
  • the active and standby status indicators are used to switch between the active area and the standby area.
  • the board application layer returns the step of re-executing the running of the new version of the BOOT program when the new version of the BOOT program is unsuccessful. Alternatively, the board application layer resets and enables the active area when the new version of the BOOT program fails. Run the BOOT program in the main area.
  • the BOOT program of the board is upgraded remotely, and no technician is required to perform on-site operations.
  • the upgrade efficiency is improved, the manpower and material resources are saved, and the cost is reduced.
  • the new version of the BOOT program in the spare area the problem that the board cannot be successfully operated due to the installation error of the new version of the BOOT program is prevented. , to ensure the reliability of the upgrade BOOT program.
  • FIG. 3 is a schematic flowchart diagram of a second embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
  • the present embodiment is based on the first embodiment, and after the step S40, the step S40 includes:
  • Step S60 The board resets and starts the main area to run the BOOT program in the main area when the new version of the BOOT program is unsuccessful.
  • the board in this embodiment resets and starts the BOOT program in the active area of the main area. Therefore, when the new version of the BOOT program fails, the main area can be quickly started. , so that the board continues to run in the original way.
  • FIG. 4 is a schematic flowchart diagram of a third embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
  • the step S40 includes:
  • Step S41 the board sets the trial running identifier and the trial running timing identifier
  • the trial run ID is used to mark the situation where the spare area needs to run a new version of the BOOT program.
  • the test run timing indicator is used to time when the new version of the BOOT program runs successfully.
  • Step S42 the board resets and runs the new version of the BOOT program
  • the board application layer resets the board and runs the new version of the BOOT program.
  • the board application layer setting preferentially starts the spare area.
  • the backup area is activated in advance, so the standby area is started to run the new version of the BOOT program.
  • the board application layer needs to set the priority to start the main area, so that when the new version of the BOOT program fails, the main area can be restarted.
  • step S43 the board clears the trial run identifier and retains the trial run timing identifier.
  • the board application layer clears the trial run identifier and keeps the trial run timing identifier for timing the running of the new version of the BOOT program.
  • the replacement step of the step S40 is based on the first embodiment, the second embodiment, and the third embodiment.
  • the board determines whether the spare area is in a trial running state
  • the board determines that the spare area is not in the trial running state, the board runs a new version of the BOOT program in the spare area.
  • the trial running state refers to a new version of the BOOT program running in the spare area.
  • the running of the new version of the BOOT program is started according to the trial running command sent by the remote client.
  • the running of the new version of the BOOT program can also be automatically started by the board application layer.
  • the operation of the new version of the BOOT program in this embodiment is started according to the trial run command sent by the remote client, and meets the personalized requirement of the user; in addition, the new version of the BOOT program in the spare area is run when the spare area is not in the trial run state. This avoids the operation of the new version of the BOOT program due to repeated transmission of the test run command.
  • FIG. 5 is a schematic flowchart diagram of a fifth embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
  • step S50 is replaced by:
  • Step S51 the board detects that the remote client is in the trial running state when the activation command sent by the network element main control board is sent by the remote client.
  • Step S52 when the spare area is in the trial running state, clearing the trial running timing identifier, using the spare area as a new primary area, and using the primary area as a new spare area;
  • Step S53 When the spare area is not in the trial running state, and the trial running timing identifier exists, the trial running timing identifier is cleared.
  • the spare area is not in the trial running state, it may be that the trial operation of the spare area is successful and is set as the new main area, and the trial operation timing indicator has been cleared; or the previous trial operation of the spare area fails,
  • the board application layer has already controlled the board reset and starts the BOOT program in the active area of the active area. However, only when the board detects the activation command sent by the remote client through the network element main control board, The board application layer will clear the trial run timing indicator. Therefore, if the standby area trial fails, the trial run timing indicator will not be cleared.
  • FIG. 6 is a schematic flowchart diagram of a sixth embodiment of a BOOT program remote upgrade method for a board according to the present invention.
  • Step S30 includes:
  • step S31 the board determines whether the board is in the trial running state when receiving the remote upgrade command sent by the remote client through the network element main control board.
  • the remote control board sends a remote upgrade command to the BOOT layer of the board.
  • the BOOT layer receives the response to the remote upgrade command to determine whether the board is in the trial running state.
  • the judgment method can be: determining the board software, logic, and EPLD. If the BOOT is in the trial running state, if the board software, logic, EPLD, and BOOT are in the trial running state, the identification mark trial running status will exist. As long as one or more of the board software, logic, EPLD, and BOOT are in the trial running state, it is determined that the board is in the trial running state.
  • step S32 the board sends the remote upgrade response to the network element main control board when it is determined that the board is not in the trial running state;
  • the download identifier is set to identify the new version of the BOOT program, and the remote upgrade response is sent to the NE main control board.
  • Step S33 The board receives the new version of the BOOT program forwarded by the remote client to the network element main control board forwarded by the network element main control board.
  • the NE main control board sends a new version of the BOOT program sent by the remote client to the main control board of the NE to the BOOT layer of the board.
  • the BOOT layer receives the data packet of the new version of the BOOT program in sequence, and simultaneously determines the received packet. Whether the data packet is the last packet, after determining that the received data packet is the last packet, the received BOOT program is verified, for example, the CRC check method. After the verification succeeds, the feedback network element main control board completes receiving the new version of the BOOT program.
  • the BOOT layer of the board After the BOOT layer of the board completes the reception of the new version of the BOOT program, the BOOT layer of the board updates the status information of the BOOT according to the new version of the BOOT program according to the download identifier.
  • the invention also provides a remote upgrade device for a BOOT program of a single board.
  • FIG. 7 is a schematic diagram of functional modules of a first embodiment of a BOOT program remote upgrade apparatus for a board according to the present invention.
  • the device includes:
  • the initialization module 10 is configured to: when the board is started, initialize a storage area in the board to divide the storage area to obtain a primary area and a spare area;
  • the running module 20 is configured to: run the BOOT program in the main area;
  • the downloading module 30 is configured to: when detecting a remote upgrade command sent by the remote client via the network element main control board, obtain a new version of the BOOT program from the network element main control board, and store the new version of the BOOT program. To the spare area;
  • the trial running module 40 is configured to: run a new version of the BOOT program in the spare area;
  • the activation module 50 is configured to: when the new version of the BOOT program runs successfully, use the spare area as a new primary area, and use the primary area as a new spare area.
  • the method for dividing the storage into the main area and the spare area by the initialization module 10 may be: dividing the storage address in the storage area, the main area corresponding to a part of the storage address, the spare area corresponding to a part of the storage address, and the data stored in the storage address is not Will change due to initialization.
  • the method for starting the main area by the running module 20 may be: the EPLD in the board is first started, and the EPLD identifies and activates the main area according to the startup identifier preset in the internal memory.
  • the startup identifier is preset according to the status information of the BOOT, and the startup identifier may also be stored in other locations.
  • the step of obtaining the new version of the BOOT program sent by the remote client to the network element main control board is performed by the downloading module 30.
  • the method may be: when the user needs to update the BOOT program of the board, first send the remote client through the FTP client. After the new version of the BOOT program is sent to the main control board of the NE, the Telnet is used to remotely log in to the main control board of the NE. The user sends a remote upgrade command to the board through the main control board of the NE to control the main control board of the NE.
  • the S port sends a new version of the BOOT program to the download module 30, or the network element main control board can send a new version of the BOOT program to the S through the S port upon receiving the request for the new version of the BOOT program sent by the download module 30.
  • Board BOOT layer
  • the trial run module 40 stops running the BOOT program in the main area by hanging the dog reset, and tries to run the new version of the BOOT program in the spare area, and monitors the trial operation.
  • the activation module 50 when the new version of the BOOT program runs successfully, uses the spare area as the new primary area, and uses the primary area as the new spare area, and the activation module 50 determines that the new version of the BOOT program is running.
  • the successful method may be: determining, by using the corresponding identifier set when the new version of the BOOT program runs successfully.
  • the activation module 50 may determine whether the BOOT program runs successfully by using a method similar to the related art, and no further description is provided herein.
  • the activation module 50 can automatically use the spare area as a new primary area and the primary area as a new spare area when the new version of the BOOT program runs successfully; or the activation module 50 can successfully run in the new version of the BOOT program. And receiving the activation command sent by the remote client via the network element main control board, then using the spare area as a new primary area and the primary area as a new spare area. When the board is restarted, the new main area is preferentially started to run the BOOT program in the new main area, that is, the new version of the BOOT program.
  • the activation module 50 uses the spare area as a new primary area, and the method of using the primary area as a new spare area may be: switching the primary area and the spare area by setting a boot identifier preferentially enabled by the mark partition; or, by setting the primary The standby status indicator marks the primary area and the standby area.
  • the primary and backup areas are switched by setting the primary and secondary status indicators.
  • the activation module 50 returns to the trial operation module 40 to re-execute the step of running the new version of the BOOT program; or, the board application layer resets and enables the main when the new version of the BOOT program fails to run. Use the zone to run the BOOT program in the main zone.
  • the technician does not need to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area, The problem of preventing the board from running successfully due to the installation error of the new version of the BOOT program, thus ensuring the reliability of the upgrade BOOT program.
  • FIG. 8 is a schematic diagram of functional modules of a second embodiment of a BOOT program remote upgrade apparatus for a board according to the present invention.
  • the remote upgrade apparatus of the BOOT program of the board includes:
  • the reset module 60 is configured to: when the new version of the BOOT program is unsuccessful, reset the board and start the main area to run the BOOT program in the main area.
  • the reset module 60 resets and starts the main area when the new version of the BOOT program is unsuccessful, and runs the BOOT program in the main area. Therefore, when the new version of the BOOT program fails, the main program can be quickly started. Use the zone to continue the board in the original mode.
  • FIG. 9 is a schematic diagram of functional modules of a third embodiment of a BOOT program remote upgrade apparatus for a single board according to the present invention.
  • the trial running module 40 includes:
  • the setting unit 41 is configured to: the board sets the trial running identifier and the trial running timing identifier;
  • the commissioning unit 42 is configured to: reset the board and run the new version of the BOOT program
  • the clearing unit 43 is configured to: clear the trial run identifier and retain the trial run timing identifier.
  • the trial run ID is used to mark the situation where the spare area needs to run a new version of the BOOT program.
  • the test run timing indicator is used to time when the new version of the BOOT program runs successfully.
  • the test operation unit 42 may set the priority start backup area.
  • the backup area is activated in advance, so the standby area is started to run the new version of the BOOT program.
  • the trial operation unit 42 also needs to set the priority to start the main area, so that when the new version of the BOOT program fails, the main area can be restarted.
  • the clearing unit 43 clears the trial run identifier and retains the trial run timing indicator for timing the operation of the new version of the BOOT program.
  • the present embodiment is based on the first embodiment, the second embodiment, and the third embodiment, and the trial running module 40 is configured to:
  • the trial running state refers to a new version of the BOOT program running in the spare area.
  • the running of the new version of the BOOT program is started according to the trial running command sent by the remote client.
  • the running of the new version of the BOOT program can also be automatically started by the board application layer.
  • the running of the new version of the BOOT program in this embodiment is started according to the trial running instruction sent by the remote client, and meets the personalized requirement of the user; in addition, the standby area is not in the trial running state.
  • a new version of the BOOT program in the spare area which avoids the operation of the new version of the BOOT program due to repeated transmission of the test run command.
  • the activation module 50 is configured to:
  • the trial running timing identifier is cleared.
  • the spare area is not in the trial running state, it may be that the trial operation of the spare area is successful and is set as the new main area, and the test run timing indicator has been cleared; or the previous test run of the spare area fails, reset
  • the module 60 has already controlled the board reset and starts the BOOT program in the main area running main area, and the clearing unit 43 is only used when the activation module 50 detects the activation command sent by the remote client via the network element main control board.
  • the trial run timing indicator is cleared, so the trial run timing indicator will not be cleared if the spare zone trial run fails.
  • FIG. 10 is a schematic diagram of functional modules of a sixth embodiment of a remote upgrade apparatus for a BOOT of a board according to the present invention.
  • the download module 30 includes:
  • the determining unit 31 is configured to: determine whether the board is in a trial running state when receiving the remote upgrade command sent by the remote client through the network element main control board;
  • the response unit 32 is configured to: send the remote upgrade response to the network element main control board when determining that the board is not in the trial running state;
  • the receiving unit 33 is configured to: receive the BOOT program that is forwarded by the network element main control board and sent by the remote client to the new version of the network main control board.
  • the NE main control board sends a remote upgrade command to the BOOT layer of the board, and the determining unit 31 receives the response.
  • the remote upgrade command determines whether the board is in a trial running state.
  • the determining method may be: determining whether the software, logic, EPLD, and BOOT of the board are in a trial running state, and the software, logic, EPLD, and BOOT of the board are in a trial running state. , there will be a logo test run status. As long as one or more of the board software, logic, EPLD, and BOOT are in the trial running state, it is determined that the board is in the trial running state.
  • the downloading identifier is set to identify that the new version of the BOOT program exists, and the remote upgrade response is sent to the network element main control board.
  • the NE main control board sends a new version of the BOOT program sent by the remote client to the network element main control board to the receiving unit 33.
  • the receiving unit 33 sequentially receives the data packet of the new version of the BOOT program, and simultaneously determines the received data packet. Whether it is the last packet, after determining that the received packet is the last packet, the received BOOT program is verified, for example, the CRC check method. After the verification succeeds, the feedback network element main control board completes receiving the new version of the BOOT program.
  • the receiving unit 33 After the receiving unit 33 completes the reception of the new version of the BOOT program, the receiving unit 33 updates the status information of the BOOT according to the new version of the BOOT program according to the download identifier.
  • the present invention further provides a remote upgrade system for a BOOT program of a single board.
  • FIG. 11 is a schematic diagram of functional modules of a first embodiment of a remote upgrade system for a BOOT program of a board according to the present invention.
  • the remote upgrade system of the BOOT program of the board of the present invention includes the board 01, the network element main control board 02 and the remote client 03;
  • the remote client 03 is configured to: send a new version of the BOOT program to the network element main control board 02; after the board 01 is started, send a remote upgrade command to the network element main control board 02 for the The NE main control board 02 forwards the remote upgrade command to the board 01;
  • the network main control board 02 is configured to: receive the new version of the BOOT program sent by the remote client 03; and forward the remote upgrade command sent by the remote client 03 to the board 01;
  • the board 01 is configured to: when the board 01 is started, initialize the storage area in the board 01 to divide the storage area to obtain the main area and the spare area; and run the BOOT program in the main area; When detecting the remote upgrade command sent by the remote client 03 via the network element control board 02, the new version of the BOOT program is obtained from the network element main control board 02, and the new version of the BOOT program is stored to The spare area; running a new version of the BOOT program in the spare area; when the new version of the BOOT program runs successfully, the spare area is used as a new main area, and the main area is used as a new Spare area.
  • FIG. 12 is a schematic diagram of interaction of a remote upgrade system of a BOOT program of a single board.
  • the method of the step of obtaining the new version of the BOOT program sent by the remote client 03 to the network element control board 02 may be: when the user needs to update the BOOT program of the board 01, first through the remote client 03 and using FTP. Send a new version of the BOOT program to the NE main control board 02, and then log in to the NE main control board 02 through Telnet. The user sends a remote upgrade command to the board 01 through the NE main control board 02 to control the network element.
  • the main control board 02 directly sends a new version of the BOOT program to the board 01 through the S port, or the network element main control board 02 can send the S-port by receiving the request of the new version of the BOOT program sent by the board 01.
  • the new version of the BOOT program goes to the board 01.
  • the board 01 stops the dog running in the main area by running the dog reset, and tries to run the new version of the BOOT program in the spare area and monitors the trial operation.
  • the board uses the spare area as the new primary area and uses the active area as the new spare area.
  • the method for the board 01 to determine whether the new version of the BOOT program is successful may be The board can be judged by the method similar to the related art to determine whether the running of the new version of the BOOT program is successful, and the details are not described herein.
  • the board 01 can automatically use the spare area as the new main area and the main area as the new spare area when the new version of the BOOT program runs successfully. Alternatively, the board 01 can run successfully in the new version of the BOOT program. And receiving the activation command sent by the remote client 03 via the network element control board 02, then using the spare area as a new primary area and the primary area as a new spare area. When the board 01 is restarted, the new main area is preferentially started to run the BOOT program in the new main area, that is, the new version of the BOOT program.
  • the board 01 uses the spare area as the new primary area, and the method of using the primary area as the new spare area may be: switching the primary area and the spare area by setting the boot identifier preferentially enabled by the mark partition; or, by setting the primary The standby status indicator marks the primary area and the standby area.
  • the primary and backup areas are switched by setting the primary and secondary status indicators.
  • the board returns to the step of re-executing the running of the new version of the BOOT program; or, when the new version of the BOOT program fails to run, Reset and enable the main area to run the BOOT program in the main area.
  • the technician does not need to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area. To prevent the problem that the board 01 cannot run successfully due to the installation error of the new version of the BOOT program, therefore, the reliability of the upgrade BOOT program is guaranteed.
  • the board 01 is set as follows:
  • the trial run identifier is cleared and the trial run timing indicator is retained.
  • the present embodiment is based on the first embodiment and the second embodiment.
  • the remote client 03 is further configured to: send a trial run command to the network element control board 02, and the network element main control board 02 forwards the test run command to the board 01;
  • the network element control board 02 is further configured to: receive the test run command sent by the remote client 03, and forward the test run command to the board 01;
  • the board 01 is further configured to: determine, when the remote client 03 receives the trial operation command sent by the network element main control board 02, whether the spare area is in a trial running state; When the spare area is not in the trial running state, the new version of the BOOT program in the spare area is run.
  • the embodiment is based on the third embodiment.
  • the remote client 03 is further configured to: send an activation command to the network element control board 02, and the network element main control board 02 forwards the activation instruction to the board 01;
  • the network element control board 02 is further configured to: receive the activation command sent by the remote client 03, and forward the test activation command to the board 01;
  • the board 01 is further configured to: when detecting the activation command sent by the remote client 03 via the network element control board 02, identify whether the spare area is in a trial running state; when the spare area is in trial operation In the row state, the board 01 clears the trial operation timing identifier, uses the spare area as a new primary area, and uses the primary area as a new spare area; when the spare area is not in trial operation When the test run timing indicator exists, the board 01 clears the test run timing indicator.
  • the present embodiment is based on the first embodiment, the second embodiment, the third embodiment, and the fourth embodiment.
  • the board 01 is further configured to: determine that the board 01 is in a trial running state when receiving the remote upgrade command sent by the remote client 03 via the network element control board 02; and determine that the board 01 is not in the trial running state. Sending the remote upgrade response to the network element control board 02; receiving the new version of the BOOT program forwarded by the remote source terminal 03 to the network element main control board 02 forwarded by the network element control board 02;
  • the network element control board 02 is further configured to: before receiving the remote upgrade response sent by the board 01, the forwarded version is sent by the remote client 03 to the new version of the network element control board 02. BOOT program.
  • all or part of the steps of the above embodiments may also be implemented by using an integrated circuit. These steps may be separately fabricated into individual integrated circuit modules, or multiple modules or steps may be fabricated into a single integrated circuit module. achieve. Thus, the invention is not limited to any specific combination of hardware and software.
  • the devices/function modules/functional units in the above embodiments may be implemented by a general-purpose computing device, which may be centralized on a single computing device or distributed over a network of multiple computing devices.
  • each device/function module/functional unit in the above embodiment When each device/function module/functional unit in the above embodiment is implemented in the form of a software function module and sold or used as a stand-alone product, it can be stored in a computer readable storage medium.
  • the above mentioned computer readable storage medium may be a read only memory, a magnetic disk or an optical disk or the like.
  • the BOOT program of the board is remotely upgraded, and the technician is not required to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Stored Programmes (AREA)

Abstract

A remote upgrade method, device and system of a BOOT program of a single board. The method includes: when a single board detects a remote upgrade command transmitted by a remote client via a network element main control board, obtaining a new version of the BOOT program from a network element and storing the new version of the BOOT program into a spare area; running the new version of the BOOT program in the spare area; when the new version of the BOOT program of the single board runs successfully, taking the spare area as a new main area and the original main area as a new spare area.

Description

单板的BOOT程序远程升级方法、装置及系统BOOT program remote upgrade method, device and system for single board 技术领域Technical field
本发明涉及通信技术领域,尤其涉及单板的BOOT远程程序升级方法、装置及系统。The present invention relates to the field of communications technologies, and in particular, to a BOOT remote program upgrade method, apparatus, and system for a single board.
背景技术Background technique
当一个单板的BOOT程序需要升级时,通常都是技术人员通过LPC(Low Pin Count,低脚位数)总线下载BOOT(系统引导)程序,并将该BOOT程序直接烧写至单板中。这就要求技术人员必须到现场进行操作,而当分布在全球各个地方的多个单板均需要升级BOOT程序时,则需消耗大量的人力物力,手动进行单板的BOOT程序升级操作容易因操作不当而造成升级失败。When a board's BOOT program needs to be upgraded, the technician usually downloads the BOOT (system boot) program through the LPC (Low Pin Count) bus and directly burns the BOOT program to the board. This requires the technician to go to the site to operate. When multiple boards in different parts of the world need to upgrade the BOOT program, it will consume a lot of manpower and material resources. Manually upgrading the BOOT program of the board is easy to operate. Improperly caused the upgrade to fail.
上述内容仅用于辅助理解本发明的技术方案,并不代表承认上述内容是现有技术。The above content is only used to assist in understanding the technical solutions of the present invention, and does not constitute an admission that the above is prior art.
发明内容Summary of the invention
本发明实施例的主要目的在于解决单板的BOOT程序升级需要现场手动操作的技术问题。The main purpose of the embodiment of the present invention is to solve the technical problem that the BOOT program upgrade of the board requires manual operation on site.
为实现上述目的,本发明实施例提供的一种单板的BOOT程序远程升级方法,包括以下步骤:To achieve the above objective, a method for remotely upgrading a BOOT program of a single board according to an embodiment of the present invention includes the following steps:
单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;When the board is started, the storage area in the board is initialized to divide the storage area to obtain the primary area and the spare area.
单板运行所述主用区中的BOOT程序;The board runs the BOOT program in the main area;
单板在侦测到远程客户端经网元主控板发送的远程升级指令时,从网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;When detecting the remote upgrade command sent by the remote client through the network element main control board, the board obtains a new version of the BOOT program from the network element main control board, and stores the new version of the BOOT program to the spare area. ;
单板运行所述备用区中新版本的BOOT程序;The board runs a new version of the BOOT program in the spare area;
单板在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。 When the new version of the BOOT program runs successfully, the board uses the spare area as a new primary area and uses the primary area as a new spare area.
可选地,所述单板运行所述备用区中新版本的BOOT程序的步骤之后包括:Optionally, after the step of running the new version of the BOOT program in the spare area, the board includes:
单板在所述新版本的BOOT程序运行不成功时,复位并运行所述主用区中的BOOT程序。The board resets and runs the BOOT program in the active area when the new version of the BOOT program is unsuccessful.
可选地,所述单板运行所述备用区中新版本的BOOT程序的步骤包括:Optionally, the step of the board running a new version of the BOOT program in the spare area includes:
单板设置试运行标识及试运行计时标识;The board sets the trial run ID and the test run timing indicator;
单板复位并运行所述新版本的BOOT程序;The board resets and runs the new version of the BOOT program;
单板清除所述试运行标识且保留所述试运行计时标识。The board clears the trial run identifier and retains the trial run timing indicator.
可选地,所述单板运行所述备用区中新版本的BOOT程序的步骤替换为:Optionally, the step of the board running a new version of the BOOT program in the spare area is replaced by:
单板在接收到远程客户端经网元主控板发送的试运行指令时,判断所述备用区是否处于试运行状态;When receiving the trial operation command sent by the remote client via the network element main control board, the board determines whether the spare area is in a trial running state;
单板在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。When the board determines that the spare area is not in the trial running state, the board runs a new version of the BOOT program in the spare area.
可选地,所述单板在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区的步骤替换为:Optionally, the board replaces the spare area as a new primary area when the new version of the BOOT program runs successfully, and replaces the primary area as a new spare area with:
单板侦测到远程客户端经网元主控板发送的激活指令时,识别所述备用区是否处于试运行状态;The board detects whether the remote area is in a trial running state when the remote client sends an activation command sent by the network element main control board.
当所述备用区处于试运行状态时,单板则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;When the spare area is in the trial running state, the board clears the trial running timing identifier, uses the spare area as a new primary area, and uses the primary area as a new spare area;
当所述备用区不处于试运行状态,且存在所述试运行计时标识时,单板则清除所述试运行计时标识。When the spare area is not in the trial running state, and the trial running timing identifier exists, the board clears the trial running timing identifier.
可选地,所述从网元主控板获取新版本的BOOT程序的步骤包括:Optionally, the step of obtaining a new version of the BOOT program from the network element main control board includes:
单板在接收到远程客户端经网元主控板发送的远程升级指令时,判断单板是否处于试运行状态;The board determines whether the board is in the trial running state when receiving the remote upgrade command sent by the remote client through the NE main control board.
单板在判定单板不处于试运行状态时,向网元主控板发送远程升级响应;When the board determines that the board is not in the trial running state, it sends a remote upgrade response to the NE main control board.
单板接收网元主控板转发的由远程客户端预先发送至网元主控板的所述新版本的BOOT程序。The board receives the new version of the BOOT program forwarded by the remote client to the network element main control board forwarded by the network element main control board.
此外,为实现上述目的,本发明实施例还提供一种单板的BOOT远程升级装置,所述单板的BOOT远程升级装置包括: In addition, in order to achieve the above object, the embodiment of the present invention further provides a BOOT remote upgrade device of a single board, and the BOOT remote upgrade device of the single board includes:
初始化模块,设置为:单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;The initialization module is configured to: when the board is started, initialize the storage area in the board to divide the storage area to obtain the primary area and the spare area;
运行模块,设置为:运行所述主用区中的BOOT程序;Running the module, set to: run the BOOT program in the main area;
下载模块,设置为:在侦测到远程客户端经网元主控板发送的远程升级指令时,从网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;The download module is configured to: when detecting a remote upgrade command sent by the remote client via the network element main control board, obtain a new version of the BOOT program from the network element main control board, and store the new version of the BOOT program to The spare area;
试运行模块,设置为:运行所述备用区中新版本的BOOT程序;The trial run module is set to: run a new version of the BOOT program in the spare area;
激活模块,设置为:在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。The activation module is configured to: when the new version of the BOOT program runs successfully, use the spare area as a new primary area, and use the primary area as a new spare area.
可选地,所述单板的BOOT程序远程升级装置包括:Optionally, the remote upgrade device of the BOOT program of the board includes:
复位模块,用于在所述新版本的BOOT程序运行不成功时,复位单板并运行所述主用区中的BOOT程序。And a reset module, configured to reset the board and run the BOOT program in the active area when the new version of the BOOT program is unsuccessful.
可选地,所述试运行模块包括:Optionally, the trial running module includes:
设置单元,设置为:设置试运行标识及试运行计时标识;Set the unit, set to: set the trial run ID and test run timing indicator;
试运行单元,设置为:复位单板并运行所述新版本的BOOT程序;The commissioning unit is configured to: reset the board and run the new version of the BOOT program;
清除单元,设置为:清除所述试运行标识且保留所述试运行计时标识。And a clearing unit, configured to: clear the trial run identifier and retain the trial run timing identifier.
可选地,所述试运行模块设置为:Optionally, the trial run module is set to:
在接收到远程客户端经网元主控板发送的试运行指令时,判断所述备用区是否处于试运行状态;When receiving the trial run command sent by the remote client via the network element main control board, determining whether the spare area is in a trial running state;
在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。When it is determined that the spare area is not in the trial running state, the new version of the BOOT program in the spare area is run.
可选地,所述激活模块设置为:Optionally, the activation module is set to:
侦测到远程客户端经网元主控板发送的激活指令时,识别所述备用区是否处于试运行状态;Detecting whether the remote area is in a trial running state when detecting an activation command sent by the remote client through the network element main control board;
当所述备用区处于试运行状态时,则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;When the spare area is in a trial running state, clearing the trial running timing identifier, using the spare area as a new primary area, and using the primary area as a new spare area;
当所述备用区不处于试运行状态,且存在所述试运行计时标识时,则清除所述试运行计时标识。When the spare area is not in the trial running state, and the trial running timing identifier exists, the trial running timing identifier is cleared.
可选地,所述下载模块包括:Optionally, the downloading module includes:
判断单元,设置为:在接收到远程客户端经网元主控板发送的远程升级 指令时,判断单板是否处于试运行状态;The judging unit is configured to: receive a remote upgrade sent by the remote client via the network element main control board When the command is executed, it is determined whether the board is in the trial running state;
响应单元,设置为:在判定单板不处于试运行状态时,向网元主控板发送远程升级响应;The response unit is configured to: send a remote upgrade response to the network element main control board when it is determined that the board is not in the trial running state;
接收单元,设置为:接收网元主控板转发的由远程客户端预先发送至网元主控板的所述新版本的BOOT程序。The receiving unit is configured to: receive the new version of the BOOT program forwarded by the remote client to the network element main control board and forwarded by the remote control board.
此外,为实现上述目的,本发明实施例还提供一种单板的BOOT程序远程升级系统,包括单板、网元主控板及远程客户端;In addition, in order to achieve the above object, the embodiment of the present invention further provides a BOOT program remote upgrade system for a board, including a board, a network element main control board, and a remote client;
所述远程客户端,设置为:发送新版本的BOOT程序至所述网元主控板;在单板启动后,发送远程升级指令至所述网元主控板,供所述网元主控板转发所述远程升级指令至所述单板;The remote client is configured to: send a new version of the BOOT program to the network element main control board; after the board is started, send a remote upgrade command to the network element main control board, where the network element is controlled. The board forwards the remote upgrade command to the board;
所述网元主控板,设置为:接收所述远程客户端发送的所述新版本的BOOT程序;转发所述远程客户端发送的所述远程升级指令至所述单板;The network element control board is configured to: receive the new version of the BOOT program sent by the remote client, and forward the remote upgrade command sent by the remote client to the board;
所述单板,设置为:单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;运行所述主用区中的BOOT程序;在侦测到远程客户端经网元主控板发送的远程升级指令时,从网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;运行所述备用区中新版本的BOOT程序;在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。The board is configured to: when the board is started, initialize a storage area in the board to divide the storage area to obtain a main area and a spare area; and run the BOOT program in the main area; When the remote client sends the remote upgrade command sent by the network element main control board, the new version of the BOOT program is obtained from the network element main control board, and the new version of the BOOT program is stored in the spare area; A new version of the BOOT program in the zone; when the new version of the BOOT program runs successfully, the spare zone is used as a new primary zone, and the primary zone is used as a new spare zone.
本发明实施例还提供一种计算机可读存储介质,存储有程序指令,当该程序指令被执行时可实现上面所述的方法。The embodiment of the invention further provides a computer readable storage medium storing program instructions, which can be implemented when the program instructions are executed.
本发明实施例通过远程升级单板的BOOT程序,不需技术人员进行现场操作,提高了升级效率,且节省了人力物力,降低了成本;此外,通过将新版本的BOOT程序在备用区中运行,防止因新版本的BOOT程序安装出错而使得单板无法成功运行的问题,因此,保证了升级BOOT程序的可靠性。In the embodiment of the present invention, the BOOT program of the board is remotely upgraded, and the technician is not required to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area. The problem of preventing the board from running successfully due to the installation error of the new version of the BOOT program, thus ensuring the reliability of the upgrade BOOT program.
附图概述BRIEF abstract
图1为单板存储区的分区图;Figure 1 is a partition diagram of a single board storage area;
图2为本发明单板的BOOT程序远程升级方法第一实施例的流程示意图; 2 is a schematic flowchart of a first embodiment of a remote upgrade method of a BOOT program of a board according to the present invention;
图3为本发明单板的BOOT程序远程升级方法第二实施例的流程示意图;3 is a schematic flowchart of a second embodiment of a remote upgrade method of a BOOT program of a board according to the present invention;
图4为本发明单板的BOOT程序远程升级方法第三实施例的流程示意图;4 is a schematic flowchart of a third embodiment of a remote upgrade method of a BOOT program of a board according to the present invention;
图5为图1中所述单板在新版本的BOOT程序运行成功时,将备用区作为新的主用区,且将主用区作为新的备用区的步骤的替换流程示意图;5 is a schematic diagram of an alternative flow of the step of using the spare area as a new primary area and using the primary area as a new spare area when the new version of the BOOT program runs successfully in the board shown in FIG. 1;
图6为图1中所述单板在侦测到远程客户端经网元主控板发送的远程升级指令时,从网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区的步骤的细化流程示意图;6 is a board in which the board in FIG. 1 obtains a new version of the BOOT program from the network element main control board when detecting a remote upgrade command sent by the remote client through the network element main control board, and the new version is A detailed flow diagram of the steps of the BOOT program storing to the spare area;
图7为本发明单板的BOOT程序远程升级装置第一实施例的功能模块示意图;7 is a schematic diagram of functional modules of a first embodiment of a BOOT program remote upgrade apparatus of a board according to the present invention;
图8为本发明单板的BOOT程序远程升级装置第二实施例的功能模块示意图;8 is a schematic diagram of functional modules of a second embodiment of a remote upgrade device for a BOOT of a board according to the present invention;
图9为本发明单板的BOOT程序远程升级装置第三实施例的功能模块示意图;9 is a schematic diagram of functional modules of a third embodiment of a remote upgrade device for a BOOT program of a board according to the present invention;
图10为图6中下载模块的细化功能模块示意图;10 is a schematic diagram of a refinement function module of the download module in FIG. 6;
图11为本发明单板的BOOT程序远程升级系统第一实施例的功能模块示意图;11 is a schematic diagram of functional modules of a first embodiment of a BOOT program remote upgrade system of a board according to the present invention;
图12为单板的BOOT程序远程升级系统的交互示意图。Figure 12 is a schematic diagram of interaction between the remote upgrade system of the BOOT program of the board.
本发明目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。The implementation, functional features, and advantages of the present invention will be further described in conjunction with the embodiments.
本发明的较佳实施方式Preferred embodiment of the invention
应当理解,此处所描述的具体实施例仅仅用以解释本发明,并不用于限定本发明。It is understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
本领域技术人员可以理解的,本发明单板的BOOT程序远程升级方法、系统及单板的下述实施例中,单板均已预置至少一个单独的存储区用于存储并运行BOOT程序,其中,存储区至少被划分为主用区和备用区;主用区为优先启用运行BOOT程序的分区,当主用区在运行BOOT程序时,备用区不运行该BOOT程序。It can be understood by those skilled in the art that in the following embodiments of the BOOT program remote upgrade method, system, and board of the board of the present invention, at least one separate storage area is preset for storing and running the BOOT program. The storage area is at least divided into a primary area and a spare area; the primary area is a partition that preferentially enables the BOOT program to run. When the primary area is running the BOOT program, the standby area does not run the BOOT program.
参照图1,图1为单板存储区的分区图。本发明实施例中,可以在存储 区中设置信息区和保留区,信息区用于存储BOOT状态信息,状态信息包括BOOT版本号、CRC(Cyclic Redundancy Check,循环冗余校验码)值等,根据需要,状态信息还可包括其他信息;保留区用于留取空间供后续开发利用。需要注意的是,存储区中设置信息区仅是本发明一可选技术方案,并不用于限制本发明。Referring to FIG. 1, FIG. 1 is a partition diagram of a single board storage area. In the embodiment of the present invention, it can be stored The information area and the reserved area are set in the area, and the information area is used to store the BOOT status information, and the status information includes a BOOT version number, a CRC (Cyclic Redundancy Check) value, and the status information may include other information as needed. Information; reserved areas are used to reserve space for subsequent development and utilization. It should be noted that setting the information area in the storage area is only an optional technical solution of the present invention, and is not intended to limit the present invention.
本发明提供一种单板的BOOT程序远程升级方法。The invention provides a remote upgrade method for a BOOT program of a single board.
参照图2,图2为本发明单板的BOOT程序远程升级方法第一实施例的流程示意图。Referring to FIG. 2, FIG. 2 is a schematic flowchart diagram of a first embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
本发明单板的BOOT程序远程升级方法第一实施例中,该方法包括:In the first embodiment of the remote upgrade method of the BOOT program of the board of the present invention, the method includes:
步骤S10,单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;Step S10: When the board is started, the storage area in the board is initialized to divide the storage area to obtain the primary area and the spare area.
单板将存储划分为主用区和备用区的方法可以是:将存储区中的存储地址进行划分,主用区对应一部分存储地址,备用区对应一部分存储地址,存储在存储地址的数据不会因初始化而改变。The method for dividing the storage into the main area and the spare area may be: dividing the storage address in the storage area, the main area corresponding to a part of the storage address, the spare area corresponding to a part of the storage address, and the data stored in the storage address is not Changed due to initialization.
步骤S20,单板运行所述主用区中的BOOT程序;Step S20: The board runs the BOOT program in the active area.
单板启动主用区的方法可以是:单板中的EPLD(Erasable Programmable Logic Device,可擦除可编辑逻辑器件)首先启动,EPLD根据其内部的存储器中预先设置的启动标识识别并启动主用区。其中启动标识是根据BOOT的状态信息预先设置的,启动标识也可存储在其他位置。The method for starting the main area of the board may be: the EPLD (Erasable Programmable Logic Device) in the board is started first, and the EPLD identifies and starts the main use according to the preset startup identifier in the internal memory. Area. The startup identifier is preset according to the status information of the BOOT, and the startup identifier may also be stored in other locations.
步骤S30,单板在侦测到远程客户端经网元主控板发送的远程升级指令时,从网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;Step S30: The board obtains a new version of the BOOT program from the network element main control board when detecting the remote upgrade command sent by the remote client through the network element main control board, and stores the new version of the BOOT program to the Spare area
获取远程客户端发送至网元主控板(NCP)的新版本的BOOT程序的步骤由单板BOOT层执行,其方法可以是:在用户需要更新单板的BOOT程序时,首先通过远程客户端并利用FTP(File Transfer Protocol,文件传输协议)发送新版本的BOOT程序至网元主控板,然后通过Telnet远程登录至网元主控板,用户利用客户端经网元主控板发送远程升级指令至单板BOOT层,控制网元主控板直接经S口(Serial Communication Port,串行通信口)发送新版本的BOOT程序至单板中的单板BOOT层,或者,网元主控板可在接收到单板BOOT层发送的获取新版本的BOOT程序的请求时,经S口发送新版本 的BOOT程序至单板BOOT层。The process of obtaining the new version of the BOOT program sent by the remote client to the network element main control board (NCP) is performed by the BOOT layer of the board. The method may be: when the user needs to update the BOOT program of the board, firstly through the remote client. And use the File Transfer Protocol (FTP) to send a new version of the BOOT program to the NE main control board, and then remotely log in to the NE main control board through Telnet. The user uses the client to send a remote upgrade through the NE main control board. The command is sent to the BOOT layer of the board. The main control board of the control network element directly sends the new version of the BOOT program to the BOOT layer of the board in the board through the S-port (Serial Communication Port), or the NE main control board. A new version can be sent via the S port when receiving a request for a new version of the BOOT program sent by the BOOT layer of the board. The BOOT program goes to the BOOT layer of the board.
单板BOOT层通过执行所述从网元主控板获取新版本的BOOT程序,且将新版本的BOOT程序存储至备用区的步骤从而引导单板中的单板应用层执行所述运行备用区中新版本的BOOT程序的步骤及所述在新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区的步骤。The board BOOT layer performs the step of acquiring the new version of the BOOT program from the network element main control board, and storing the new version of the BOOT program to the spare area, thereby guiding the board application layer in the board to execute the running spare area. The step of the new version of the BOOT program and the step of using the spare area as a new primary area and the primary area as a new spare area when the new version of the BOOT program runs successfully.
步骤S40,单板运行所述备用区中新版本的BOOT程序;Step S40: The board runs a new version of the BOOT program in the spare area;
单板应用层通过挂狗复位,停止在主用区中运行BOOT程序,而在备用区中尝试运行新版本的BOOT程序,并监控试运行的情况。The board application layer stops the BOOT program in the main area by hanging the dog reset, and tries to run the new version of the BOOT program in the spare area and monitors the trial operation.
步骤S50,单板在新版本的BOOT程序运行成功时,将备用区作为新的主用区,且将主用区作为新的备用区。In step S50, when the new version of the BOOT program runs successfully, the board uses the spare area as the new main area and the main area as the new spare area.
单板应用层在新版本的BOOT程序运行成功时,将备用区作为新的主用区,且将主用区作为新的备用区,单板应用层判断新版本的BOOT程序运行是否成功的方法可以是:通过新版本的BOOT程序运行成功时设置的相应标识判断,本实施例中。单板应用层可以采用与相关技术类似的方法判断BOOT程序是否成功运行的方法相似,在此不做赘述。When the new version of the BOOT program runs successfully, the standby area is used as the new primary area, and the active area is used as the new spare area. The board application layer determines whether the new version of the BOOT program runs successfully. It can be: determined by the corresponding identifier set when the new version of the BOOT program runs successfully, in this embodiment. The method in which the board application layer can determine whether the BOOT program runs successfully is similar to the method in the related art, and details are not described herein.
单板应用层可在新版本的BOOT程序运行成功时,自动将备用区作为新的主用区,且将主用区作为新的备用区;或者,单板应用层可在新版本的BOOT程序运行成功,且接收到远程客户端经网元主控板发送的激活指令时,再将备用区作为新的主用区,将主用区作为新的备用区。单板再启动时,优先启动该新的主用区以运行该新的主用区中的BOOT程序,即新版本的BOOT程序The board application layer can automatically use the spare area as the new primary area and the primary area as the new spare area when the new version of the BOOT program runs successfully. Alternatively, the board application layer can be used in the new version of the BOOT program. After the operation succeeds, and the remote client receives the activation command sent by the network element main control board, the spare area is used as the new primary area, and the primary area is used as the new spare area. When the board is restarted, the new main area is preferentially started to run the BOOT program in the new main area, that is, the new version of the BOOT program.
单板应用层将备用区作为新的主用区,且将主用区作为新的备用区的方法可以是:通过设置标记分区优先启用的启动标识切换主用区和备用区;或者,通过设置主备状态标识标记主用区和备用区,通过设置主备状态标识切换主用区和备用区。The board application layer uses the spare area as the new primary area, and the method of using the primary area as the new spare area may be: switching the primary area and the spare area by setting the boot identifier preferentially enabled by the mark partition; or, by setting The active and standby status IDs mark the active area and the standby area. The active and standby status indicators are used to switch between the active area and the standby area.
单板应用层在新版本的BOOT程序运行不成功时,返回重新执行运行新版本的BOOT程序的步骤;或者,单板应用层在新版本的BOOT程序运行失败时,复位并启用主用区以运行主用区中的BOOT程序。The board application layer returns the step of re-executing the running of the new version of the BOOT program when the new version of the BOOT program is unsuccessful. Alternatively, the board application layer resets and enables the active area when the new version of the BOOT program fails. Run the BOOT program in the main area.
本实施例通过远程升级单板的BOOT程序,不需技术人员进行现场操作, 提高了升级效率,且节省了人力物力,降低了成本;此外,通过将新版本的BOOT程序在备用区中运行,防止因新版本的BOOT程序安装出错而使得单板无法成功运行的问题,因此,保证了升级BOOT程序的可靠性。In this embodiment, the BOOT program of the board is upgraded remotely, and no technician is required to perform on-site operations. The upgrade efficiency is improved, the manpower and material resources are saved, and the cost is reduced. In addition, by running the new version of the BOOT program in the spare area, the problem that the board cannot be successfully operated due to the installation error of the new version of the BOOT program is prevented. , to ensure the reliability of the upgrade BOOT program.
参照图3,图3为本发明单板的BOOT程序远程升级方法第二实施例的流程示意图。Referring to FIG. 3, FIG. 3 is a schematic flowchart diagram of a second embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
本发明单板的BOOT程序远程升级方法第二实施例中,本实施例在第一实施例的基础上,所述步骤S40之后包括:In the second embodiment of the BOOT program remote upgrade method of the board of the present invention, the present embodiment is based on the first embodiment, and after the step S40, the step S40 includes:
步骤S60,单板在所述新版本的BOOT程序运行不成功时,复位并启动所述主用区以运行所述主用区中的BOOT程序。Step S60: The board resets and starts the main area to run the BOOT program in the main area when the new version of the BOOT program is unsuccessful.
本实施例单板在新版本的BOOT程序运行不成功时,复位并启动主用区运行主用区中的BOOT程序,因此,在新版本的BOOT程序运行失败时,可快速的启动主用区,使单板继续按原有的方式继续运行。When the new version of the BOOT program is unsuccessful, the board in this embodiment resets and starts the BOOT program in the active area of the main area. Therefore, when the new version of the BOOT program fails, the main area can be quickly started. , so that the board continues to run in the original way.
参照图4,图4为本发明单板的BOOT程序远程升级方法第三实施例的流程示意图。Referring to FIG. 4, FIG. 4 is a schematic flowchart diagram of a third embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
本发明单板的BOOT程序远程升级方法第三实施例中,本实施例在第一实施例、第二实施例的基础上,所述步骤S40包括:In the third embodiment of the BOOT program remote upgrade method of the board of the present invention, in the embodiment, based on the first embodiment and the second embodiment, the step S40 includes:
步骤S41,单板设置试运行标识及试运行计时标识;Step S41, the board sets the trial running identifier and the trial running timing identifier;
试运行标识用于标记备用区需要运行新版本的BOOT程序的情况。The trial run ID is used to mark the situation where the spare area needs to run a new version of the BOOT program.
试运行计时标识用于在新版本的BOOT程序运行成功时进行计时。The test run timing indicator is used to time when the new version of the BOOT program runs successfully.
步骤S42,单板复位并运行所述新版本的BOOT程序;Step S42, the board resets and runs the new version of the BOOT program;
单板应用层复位单板并运行新版本的BOOT程序的步骤之前可包括:单板应用层设置优先启动备用区。The board application layer resets the board and runs the new version of the BOOT program. The board application layer setting preferentially starts the spare area.
单板复位后由于预先设置了优先启动备用区,因此,启动备用区运行新版本的BOOT程序。此时,单板应用层还需设置优先启动主用区,以使在运行新版本的BOOT程序失败时,可以重新启动主用区。After the board is reset, the backup area is activated in advance, so the standby area is started to run the new version of the BOOT program. At this time, the board application layer needs to set the priority to start the main area, so that when the new version of the BOOT program fails, the main area can be restarted.
步骤S43,单板清除所述试运行标识且保留所述试运行计时标识。In step S43, the board clears the trial run identifier and retains the trial run timing identifier.
在备用区运行新版本的BOOT程序时,单板应用层清除试运行标识,且保留试运行计时标识,以用于对新版本的BOOT程序的运行进行计时。 When the new version of the BOOT program is run in the standby area, the board application layer clears the trial run identifier and keeps the trial run timing identifier for timing the running of the new version of the BOOT program.
本发明单板的BOOT程序远程升级方法第四实施例中,本实施例在第一实施例、第二实施例、第三实施例的基础上,所述步骤S40的替换步骤为:In the fourth embodiment of the remote upgrade method of the BOOT program of the board of the present invention, the replacement step of the step S40 is based on the first embodiment, the second embodiment, and the third embodiment.
单板在接收到远程客户端经网元主控板发送的试运行指令时,判断所述备用区是否处于试运行状态;When receiving the trial operation command sent by the remote client via the network element main control board, the board determines whether the spare area is in a trial running state;
单板在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。When the board determines that the spare area is not in the trial running state, the board runs a new version of the BOOT program in the spare area.
其中,试运行状态是指备用区中存在运行的新版本的BOOT程序。Among them, the trial running state refers to a new version of the BOOT program running in the spare area.
本实施例中,新版本的BOOT程序的运行是根据远程客户端发送的试运行指令启动的,在一些实施例中,新版本的BOOT程序的运行也可以由单板应用层自动启动。In this embodiment, the running of the new version of the BOOT program is started according to the trial running command sent by the remote client. In some embodiments, the running of the new version of the BOOT program can also be automatically started by the board application layer.
本实施例新版本的BOOT程序的运行是根据远程客户端发送的试运行指令启动,满足用户的个性化需求;此外,在备用区不处于试运行状态时运行备用区中新版本的BOOT程序,这避免了因重复发送试运行指令而影响新版本的BOOT程序的运行。The operation of the new version of the BOOT program in this embodiment is started according to the trial run command sent by the remote client, and meets the personalized requirement of the user; in addition, the new version of the BOOT program in the spare area is run when the spare area is not in the trial run state. This avoids the operation of the new version of the BOOT program due to repeated transmission of the test run command.
参照图5,图5为本发明单板的BOOT程序远程升级方法第五实施例的流程示意图。Referring to FIG. 5, FIG. 5 is a schematic flowchart diagram of a fifth embodiment of a remote upgrade method for a BOOT program of a board according to the present invention.
本发明单板的BOOT程序远程升级方法第五实施例中,本实施例在第三实施例的基础上,所述步骤S50替换为:In the fifth embodiment of the BOOT program remote upgrade method of the board of the present invention, in the third embodiment, the step S50 is replaced by:
步骤S51,单板侦测到远程客户端经网元主控板发送的激活指令时,识别所述备用区是否处于试运行状态;Step S51, the board detects that the remote client is in the trial running state when the activation command sent by the network element main control board is sent by the remote client.
步骤S52,当所述备用区处于试运行状态时,则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;Step S52, when the spare area is in the trial running state, clearing the trial running timing identifier, using the spare area as a new primary area, and using the primary area as a new spare area;
步骤S53,当所述备用区不处于试运行状态,且存在所述试运行计时标识时,则清除所述试运行计时标识。Step S53: When the spare area is not in the trial running state, and the trial running timing identifier exists, the trial running timing identifier is cleared.
若备用区不处于试运行状态,则可能是备用区的试运行成功并被设置为新的主用区,且其试运行计时标识已被清除;或者,备用区的上一次试运行失败,单板应用层已经控制单板复位并启动主用区运行主用区中的BOOT程序,而由于只有在单板侦测到远程客户端经网元主控板发送的激活指令时, 单板应用层才会清除试运行计时标识,因此,在备用区试运行失败的情况下,试运行计时标识不会被清除。If the spare area is not in the trial running state, it may be that the trial operation of the spare area is successful and is set as the new main area, and the trial operation timing indicator has been cleared; or the previous trial operation of the spare area fails, The board application layer has already controlled the board reset and starts the BOOT program in the active area of the active area. However, only when the board detects the activation command sent by the remote client through the network element main control board, The board application layer will clear the trial run timing indicator. Therefore, if the standby area trial fails, the trial run timing indicator will not be cleared.
参照图6,图6为本发明单板的BOOT程序远程升级方法第六实施例的流程示意图。Referring to FIG. 6, FIG. 6 is a schematic flowchart diagram of a sixth embodiment of a BOOT program remote upgrade method for a board according to the present invention.
本发明单板的BOOT程序远程升级方法第六实施例中,本实施例在第一实施例、第二实施例、第三实施例、第四实施例、第五实施例的基础上,所述步骤S30包括:In the sixth embodiment of the remote upgrade method of the BOOT program of the board of the present invention, the present embodiment is based on the first embodiment, the second embodiment, the third embodiment, the fourth embodiment, and the fifth embodiment. Step S30 includes:
步骤S31,单板在接收到远程客户端经网元主控板发送的远程升级指令时,判断单板是否处于试运行状态;In step S31, the board determines whether the board is in the trial running state when receiving the remote upgrade command sent by the remote client through the network element main control board.
网元主控板发送远程升级指令至单板BOOT层,单板BOOT层在接收响应该远程升级指令,判断单板是否处于试运行状态,该判断方法可以是:判断单板软件、逻辑、EPLD、BOOT是否处于试运行状态,单板软件、逻辑、EPLD、BOOT若处于试运行状态,则会存在标识标记试运行状态。单板软件、逻辑、EPLD、BOOT中只要存在一个或多个处于试运行状态,则判定单板处于试运行状态。The remote control board sends a remote upgrade command to the BOOT layer of the board. The BOOT layer receives the response to the remote upgrade command to determine whether the board is in the trial running state. The judgment method can be: determining the board software, logic, and EPLD. If the BOOT is in the trial running state, if the board software, logic, EPLD, and BOOT are in the trial running state, the identification mark trial running status will exist. As long as one or more of the board software, logic, EPLD, and BOOT are in the trial running state, it is determined that the board is in the trial running state.
步骤S32,单板在判定单板不处于试运行状态时,向网元主控板发送所述远程升级响应;In step S32, the board sends the remote upgrade response to the network element main control board when it is determined that the board is not in the trial running state;
单板BOOT层在判定单板不处于试运行状态时,设置下载标识用以标识存在新版本的BOOT程序,向网元主控板发送远程升级响应。When the board is determined that the board is not in the trial running state, the download identifier is set to identify the new version of the BOOT program, and the remote upgrade response is sent to the NE main control board.
步骤S33,单板接收网元主控板转发的由远程客户端预先发送至网元主控板的所述新版本的BOOT程序。Step S33: The board receives the new version of the BOOT program forwarded by the remote client to the network element main control board forwarded by the network element main control board.
网元主控板发送由远程客户端预先发送至网元主控板的新版本的BOOT程序至单板BOOT层,单板BOOT层依次接收该新版本的BOOT程序的数据包,同时判断接收的数据包是否为最后一包,在判定接收的数据包为最后一包后,对接收的BOOT程序进行校验,例如,CRC校验法。在校验成功之后,反馈网元主控板完成接收新版本的BOOT程序。The NE main control board sends a new version of the BOOT program sent by the remote client to the main control board of the NE to the BOOT layer of the board. The BOOT layer receives the data packet of the new version of the BOOT program in sequence, and simultaneously determines the received packet. Whether the data packet is the last packet, after determining that the received data packet is the last packet, the received BOOT program is verified, for example, the CRC check method. After the verification succeeds, the feedback network element main control board completes receiving the new version of the BOOT program.
在单板BOOT层完成新版本的BOOT程序的接收后,单板BOOT层根据下载标识,根据新版本的BOOT程序,更新BOOT的状态信息。 After the BOOT layer of the board completes the reception of the new version of the BOOT program, the BOOT layer of the board updates the status information of the BOOT according to the new version of the BOOT program according to the download identifier.
本发明还提供一种单板的BOOT程序远程升级装置。The invention also provides a remote upgrade device for a BOOT program of a single board.
参照图7,图7为本发明单板的BOOT程序远程升级装置第一实施例的功能模块示意图。Referring to FIG. 7, FIG. 7 is a schematic diagram of functional modules of a first embodiment of a BOOT program remote upgrade apparatus for a board according to the present invention.
本发明单板的BOOT程序远程升级装置第一实施例中,该装置包括:In the first embodiment of the BOOT program remote upgrading device of the board of the present invention, the device includes:
初始化模块10,设置为:单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;The initialization module 10 is configured to: when the board is started, initialize a storage area in the board to divide the storage area to obtain a primary area and a spare area;
运行模块20,设置为:运行所述主用区中的BOOT程序;The running module 20 is configured to: run the BOOT program in the main area;
下载模块30,设置为:在侦测到远程客户端经网元主控板发送的远程升级指令时,从网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;The downloading module 30 is configured to: when detecting a remote upgrade command sent by the remote client via the network element main control board, obtain a new version of the BOOT program from the network element main control board, and store the new version of the BOOT program. To the spare area;
试运行模块40,设置为:运行所述备用区中新版本的BOOT程序;The trial running module 40 is configured to: run a new version of the BOOT program in the spare area;
激活模块50,设置为:在新版本的BOOT程序运行成功时,将备用区作为新的主用区,且将主用区作为新的备用区。The activation module 50 is configured to: when the new version of the BOOT program runs successfully, use the spare area as a new primary area, and use the primary area as a new spare area.
初始化模块10将存储划分为主用区和备用区的方法可以是:将存储区中的存储地址进行划分,主用区对应一部分存储地址,备用区对应一部分存储地址,存储在存储地址的数据不会因初始化而改变。The method for dividing the storage into the main area and the spare area by the initialization module 10 may be: dividing the storage address in the storage area, the main area corresponding to a part of the storage address, the spare area corresponding to a part of the storage address, and the data stored in the storage address is not Will change due to initialization.
运行模块20启动主用区的方法可以是:单板中的EPLD首先启动,EPLD根据其内部的存储器中预先设置的启动标识识别并启动主用区。其中启动标识是根据BOOT的状态信息预先设置的,启动标识也可存储在其他位置。The method for starting the main area by the running module 20 may be: the EPLD in the board is first started, and the EPLD identifies and activates the main area according to the startup identifier preset in the internal memory. The startup identifier is preset according to the status information of the BOOT, and the startup identifier may also be stored in other locations.
获取远程客户端发送至网元主控板的新版本的BOOT程序的步骤由下载模块30执行,其方法可以是:在用户需要更新单板的BOOT程序时,首先通过远程客户端且利用FTP发送新版本的BOOT程序至网元主控板,然后通过Telnet远程登录至网元主控板,用户利用客户端经网元主控板发送远程升级指令至单板,控制网元主控板直接经S口发送新版本的BOOT程序至下载模块30,或者,网元主控板可在接收到下载模块30发送的获取新版本的BOOT程序的请求时,经S口发送新版本的BOOT程序至单板BOOT层。The step of obtaining the new version of the BOOT program sent by the remote client to the network element main control board is performed by the downloading module 30. The method may be: when the user needs to update the BOOT program of the board, first send the remote client through the FTP client. After the new version of the BOOT program is sent to the main control board of the NE, the Telnet is used to remotely log in to the main control board of the NE. The user sends a remote upgrade command to the board through the main control board of the NE to control the main control board of the NE. The S port sends a new version of the BOOT program to the download module 30, or the network element main control board can send a new version of the BOOT program to the S through the S port upon receiving the request for the new version of the BOOT program sent by the download module 30. Board BOOT layer.
试运行模块40通过挂狗复位,停止在主用区中运行BOOT程序,而在备用区中尝试运行新版本的BOOT程序,并监控试运行的情况。The trial run module 40 stops running the BOOT program in the main area by hanging the dog reset, and tries to run the new version of the BOOT program in the spare area, and monitors the trial operation.
激活模块50在新版本的BOOT程序运行成功时,将备用区作为新的主用区,且将主用区作为新的备用区,激活模块50判断新版本的BOOT程序运行 是否成功的方法可以是:通过新版本的BOOT程序运行成功时设置的相应标识判断,本实施例中激活模块50可以采用与相关技术类似的方法判断BOOT程序是否成功运行,在此不做赘述。The activation module 50, when the new version of the BOOT program runs successfully, uses the spare area as the new primary area, and uses the primary area as the new spare area, and the activation module 50 determines that the new version of the BOOT program is running. The successful method may be: determining, by using the corresponding identifier set when the new version of the BOOT program runs successfully. In this embodiment, the activation module 50 may determine whether the BOOT program runs successfully by using a method similar to the related art, and no further description is provided herein.
激活模块50可在新版本的BOOT程序运行成功时,自动将备用区作为新的主用区,且将主用区作为新的备用区;或者,激活模块50可在新版本的BOOT程序运行成功,且接收到远程客户端经网元主控板发送的激活指令时,再将备用区作为新的主用区,将主用区作为新的备用区。单板再启动时,优先启动该新的主用区以运行该新的主用区中的BOOT程序,即新版本的BOOT程序The activation module 50 can automatically use the spare area as a new primary area and the primary area as a new spare area when the new version of the BOOT program runs successfully; or the activation module 50 can successfully run in the new version of the BOOT program. And receiving the activation command sent by the remote client via the network element main control board, then using the spare area as a new primary area and the primary area as a new spare area. When the board is restarted, the new main area is preferentially started to run the BOOT program in the new main area, that is, the new version of the BOOT program.
激活模块50将备用区作为新的主用区,且将主用区作为新的备用区的方法可以是:通过设置标记分区优先启用的启动标识切换主用区和备用区;或者,通过设置主备状态标识标记主用区和备用区,通过设置主备状态标识切换主用区和备用区。The activation module 50 uses the spare area as a new primary area, and the method of using the primary area as a new spare area may be: switching the primary area and the spare area by setting a boot identifier preferentially enabled by the mark partition; or, by setting the primary The standby status indicator marks the primary area and the standby area. The primary and backup areas are switched by setting the primary and secondary status indicators.
激活模块50在新版本的BOOT程序运行不成功时,返回试运行模块40重新执行运行新版本的BOOT程序的步骤;或者,单板应用层在新版本的BOOT程序运行失败时,复位并启用主用区以运行主用区中的BOOT程序。When the new version of the BOOT program is unsuccessful, the activation module 50 returns to the trial operation module 40 to re-execute the step of running the new version of the BOOT program; or, the board application layer resets and enables the main when the new version of the BOOT program fails to run. Use the zone to run the BOOT program in the main zone.
本实施例通过远程升级单板的BOOT程序,不需技术人员进行现场操作,提高了升级效率,且节省了人力物力,降低了成本;此外,通过将新版本的BOOT程序在备用区中运行,防止因新版本的BOOT程序安装出错而使得单板无法成功运行的问题,因此,保证了升级BOOT程序的可靠性。In this embodiment, by remotely upgrading the BOOT program of the board, the technician does not need to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area, The problem of preventing the board from running successfully due to the installation error of the new version of the BOOT program, thus ensuring the reliability of the upgrade BOOT program.
参照图8,图8为本发明单板的BOOT程序远程升级装置第二实施例的功能模块示意图。Referring to FIG. 8, FIG. 8 is a schematic diagram of functional modules of a second embodiment of a BOOT program remote upgrade apparatus for a board according to the present invention.
本发明单板的BOOT程序远程升级装置第二实施例中,本实施例在第一实施例的基础上,所述单板的BOOT程序远程升级装置包括:In the second embodiment of the apparatus for remotely upgrading the BOOT program of the board of the present invention, the remote upgrade apparatus of the BOOT program of the board includes:
复位模块60,设置为:在所述新版本的BOOT程序运行不成功时,复位单板并启动所述主用区以运行所述主用区中的BOOT程序。The reset module 60 is configured to: when the new version of the BOOT program is unsuccessful, reset the board and start the main area to run the BOOT program in the main area.
本实施例复位模块60在新版本的BOOT程序运行不成功时,复位并启动主用区,运行主用区中的BOOT程序,因此,在新版本的BOOT程序运行失败时,可快速的启动主用区,使单板继续按原有的方式继续运行。 In the embodiment, the reset module 60 resets and starts the main area when the new version of the BOOT program is unsuccessful, and runs the BOOT program in the main area. Therefore, when the new version of the BOOT program fails, the main program can be quickly started. Use the zone to continue the board in the original mode.
参照图9,图9为本发明单板的BOOT程序远程升级装置第三实施例的功能模块示意图。Referring to FIG. 9, FIG. 9 is a schematic diagram of functional modules of a third embodiment of a BOOT program remote upgrade apparatus for a single board according to the present invention.
本发明单板的BOOT程序远程升级装置第三实施例中,本实施例在第一实施例、第二实施例的基础上,所述试运行模块40包括:In the third embodiment of the apparatus for remotely upgrading the BOOT program of the board of the present invention, in the embodiment, based on the first embodiment and the second embodiment, the trial running module 40 includes:
设置单元41,设置为:单板设置试运行标识及试运行计时标识;The setting unit 41 is configured to: the board sets the trial running identifier and the trial running timing identifier;
试运行单元42,设置为:复位单板并运行所述新版本的BOOT程序;The commissioning unit 42 is configured to: reset the board and run the new version of the BOOT program;
清除单元43,设置为:清除所述试运行标识且保留所述试运行计时标识。The clearing unit 43 is configured to: clear the trial run identifier and retain the trial run timing identifier.
试运行标识用于标记备用区需要运行新版本的BOOT程序的情况。The trial run ID is used to mark the situation where the spare area needs to run a new version of the BOOT program.
试运行计时标识用于在新版本的BOOT程序运行成功时进行计时。The test run timing indicator is used to time when the new version of the BOOT program runs successfully.
试运行单元42复位单板并运行新版本的BOOT程序的步骤之前可包括:试运行单元42设置优先启动备用区。Before the step of the trial operation unit 42 resetting the board and running the new version of the BOOT program, the test operation unit 42 may set the priority start backup area.
单板复位后由于预先设置了优先启动备用区,因此,启动备用区运行新版本的BOOT程序。此时,试运行单元42还需设置优先启动主用区,以使在运行新版本的BOOT程序失败时,可以重新启动主用区。After the board is reset, the backup area is activated in advance, so the standby area is started to run the new version of the BOOT program. At this time, the trial operation unit 42 also needs to set the priority to start the main area, so that when the new version of the BOOT program fails, the main area can be restarted.
在备用区运行新版本的BOOT程序时,清除单元43清除试运行标识,且保留试运行计时标识,以用于对新版本的BOOT程序的运行进行计时。When the new version of the BOOT program is run in the spare area, the clearing unit 43 clears the trial run identifier and retains the trial run timing indicator for timing the operation of the new version of the BOOT program.
本发明单板的BOOT程序远程升级装置第四实施例中,本实施例在第一实施例、第二实施例、第三实施例的基础上,所述试运行模块40用于:In the fourth embodiment of the apparatus for remotely upgrading the BOOT program of the board of the present invention, the present embodiment is based on the first embodiment, the second embodiment, and the third embodiment, and the trial running module 40 is configured to:
在接收到远程客户端经网元主控板发送的试运行指令时,判断所述备用区是否处于试运行状态;When receiving the trial run command sent by the remote client via the network element main control board, determining whether the spare area is in a trial running state;
在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。When it is determined that the spare area is not in the trial running state, the new version of the BOOT program in the spare area is run.
其中,试运行状态是指备用区中存在运行的新版本的BOOT程序。Among them, the trial running state refers to a new version of the BOOT program running in the spare area.
本实施例中,新版本的BOOT程序的运行是根据远程客户端发送的试运行指令启动的,在一些实施例中,新版本的BOOT程序的运行也可以由单板应用层自动启动。In this embodiment, the running of the new version of the BOOT program is started according to the trial running command sent by the remote client. In some embodiments, the running of the new version of the BOOT program can also be automatically started by the board application layer.
本实施例新版本的BOOT程序的运行是根据远程客户端发送的试运行指令启动,满足用户的个性化需求;此外,在备用区不处于试运行状态时运行 备用区中新版本的BOOT程序,这避免了因重复发送试运行指令而影响新版本的BOOT程序的运行。The running of the new version of the BOOT program in this embodiment is started according to the trial running instruction sent by the remote client, and meets the personalized requirement of the user; in addition, the standby area is not in the trial running state. A new version of the BOOT program in the spare area, which avoids the operation of the new version of the BOOT program due to repeated transmission of the test run command.
本发明单板的BOOT程序远程升级装置第五实施例中,本实施例在第三实施例的基础上,所述激活模块50设置为:In the fifth embodiment of the apparatus for remotely upgrading the BOOT program of the board of the present invention, in the embodiment, based on the third embodiment, the activation module 50 is configured to:
侦测到远程客户端经网元主控板发送的激活指令时,识别所述备用区是否处于试运行状态;Detecting whether the remote area is in a trial running state when detecting an activation command sent by the remote client through the network element main control board;
当所述备用区处于试运行状态时,则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;When the spare area is in a trial running state, clearing the trial running timing identifier, using the spare area as a new primary area, and using the primary area as a new spare area;
当所述备用区不处于试运行状态,且存在所述试运行计时标识时,则清除所述试运行计时标识。When the spare area is not in the trial running state, and the trial running timing identifier exists, the trial running timing identifier is cleared.
若备用区不处于试运行状态,则可能是备用区的试运行成功并被设置为新的主用区,且其试运行计时标识已被清除;或者,备用区的上一次试运行失败,复位模块60已经控制单板复位并启动主用区运行主用区中的BOOT程序,而由于只有在激活模块50侦测到远程客户端经网元主控板发送的激活指令时,清除单元43才会清除试运行计时标识,因此,在备用区试运行失败的情况下,试运行计时标识不会被清除。If the spare area is not in the trial running state, it may be that the trial operation of the spare area is successful and is set as the new main area, and the test run timing indicator has been cleared; or the previous test run of the spare area fails, reset The module 60 has already controlled the board reset and starts the BOOT program in the main area running main area, and the clearing unit 43 is only used when the activation module 50 detects the activation command sent by the remote client via the network element main control board. The trial run timing indicator is cleared, so the trial run timing indicator will not be cleared if the spare zone trial run fails.
参照图10,图10为本发明单板的BOOT程序远程升级装置第六实施例的功能模块示意图。Referring to FIG. 10, FIG. 10 is a schematic diagram of functional modules of a sixth embodiment of a remote upgrade apparatus for a BOOT of a board according to the present invention.
本发明单板的BOOT程序远程升级装置第六实施例中,本实施例在第一实施例、第二实施例、第三实施例、第四实施例、第五实施例的基础上,所述下载模块30包括:In the sixth embodiment of the apparatus for remotely upgrading the BOOT program of the board of the present invention, the present embodiment is based on the first embodiment, the second embodiment, the third embodiment, the fourth embodiment, and the fifth embodiment. The download module 30 includes:
判断单元31,设置为:在接收到远程客户端经网元主控板发送的远程升级指令时,判断单板是否处于试运行状态;The determining unit 31 is configured to: determine whether the board is in a trial running state when receiving the remote upgrade command sent by the remote client through the network element main control board;
响应单元32,设置为:在判定单板不处于试运行状态时,向网元主控板发送所述远程升级响应;The response unit 32 is configured to: send the remote upgrade response to the network element main control board when determining that the board is not in the trial running state;
接收单元33,设置为:接收网元主控板转发的由远程客户端预先发送至网元主控板的所述新版本的BOOT程序。The receiving unit 33 is configured to: receive the BOOT program that is forwarded by the network element main control board and sent by the remote client to the new version of the network main control board.
网元主控板发送远程升级指令至单板BOOT层,判断单元31在接收响应 该远程升级指令,判断单板是否处于试运行状态,该判断方法可以是:判断单板软件、逻辑、EPLD、BOOT是否处于试运行状态,单板软件、逻辑、EPLD、BOOT若处于试运行状态,则会存在标识标记试运行状态。单板软件、逻辑、EPLD、BOOT中只要存在一个或多个处于试运行状态,则判定单板处于试运行状态。The NE main control board sends a remote upgrade command to the BOOT layer of the board, and the determining unit 31 receives the response. The remote upgrade command determines whether the board is in a trial running state. The determining method may be: determining whether the software, logic, EPLD, and BOOT of the board are in a trial running state, and the software, logic, EPLD, and BOOT of the board are in a trial running state. , there will be a logo test run status. As long as one or more of the board software, logic, EPLD, and BOOT are in the trial running state, it is determined that the board is in the trial running state.
响应单元32在判定单板不处于试运行状态时,设置下载标识用以标识存在新版本的BOOT程序,向网元主控板发送远程升级响应。When the determining unit 32 determines that the board is not in the trial running state, the downloading identifier is set to identify that the new version of the BOOT program exists, and the remote upgrade response is sent to the network element main control board.
网元主控板发送由远程客户端预先发送至网元主控板的新版本的BOOT程序至接收单元33,接收单元33依次接收该新版本的BOOT程序的数据包,同时判断接收的数据包是否为最后一包,在判定接收的数据包为最后一包后,对接收的BOOT程序进行校验,例如,CRC校验法。在校验成功之后,反馈网元主控板完成接收新版本的BOOT程序。The NE main control board sends a new version of the BOOT program sent by the remote client to the network element main control board to the receiving unit 33. The receiving unit 33 sequentially receives the data packet of the new version of the BOOT program, and simultaneously determines the received data packet. Whether it is the last packet, after determining that the received packet is the last packet, the received BOOT program is verified, for example, the CRC check method. After the verification succeeds, the feedback network element main control board completes receiving the new version of the BOOT program.
在接收单元33完成新版本的BOOT程序的接收后,接收单元33根据下载标识,根据新版本的BOOT程序,更新BOOT的状态信息。After the receiving unit 33 completes the reception of the new version of the BOOT program, the receiving unit 33 updates the status information of the BOOT according to the new version of the BOOT program according to the download identifier.
本发明进一步提供一种单板的BOOT程序远程升级系统。The present invention further provides a remote upgrade system for a BOOT program of a single board.
参照图11,图11为本发明单板的BOOT程序远程升级系统第一实施例的功能模块示意图。Referring to FIG. 11, FIG. 11 is a schematic diagram of functional modules of a first embodiment of a remote upgrade system for a BOOT program of a board according to the present invention.
本发明单板的BOOT程序远程升级系统第一实施例中,所述单板的BOOT程序远程升级系统包括单板01、网元主控板02及远程客户端03;The remote upgrade system of the BOOT program of the board of the present invention includes the board 01, the network element main control board 02 and the remote client 03;
所述远程客户端03,设置为:发送新版本的BOOT程序至所述网元主控板02;在单板01启动后,发送远程升级指令至所述网元主控板02,供所述网元主控板02转发所述远程升级指令至所述单板01;The remote client 03 is configured to: send a new version of the BOOT program to the network element main control board 02; after the board 01 is started, send a remote upgrade command to the network element main control board 02 for the The NE main control board 02 forwards the remote upgrade command to the board 01;
所述网元主控板02,设置为:接收所述远程客户端03发送的所述新版本的BOOT程序;转发所述远程客户端03发送的所述远程升级指令至所述单板01;The network main control board 02 is configured to: receive the new version of the BOOT program sent by the remote client 03; and forward the remote upgrade command sent by the remote client 03 to the board 01;
所述单板01,设置为:单板01启动时,初始化单板01中的存储区,以将存储区进行划分,获得主用区和备用区;运行所述主用区中的BOOT程序;在侦测到远程客户端03经网元主控板02发送的远程升级指令时,从网元主控板02中获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至 所述备用区;运行所述备用区中新版本的BOOT程序;在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。The board 01 is configured to: when the board 01 is started, initialize the storage area in the board 01 to divide the storage area to obtain the main area and the spare area; and run the BOOT program in the main area; When detecting the remote upgrade command sent by the remote client 03 via the network element control board 02, the new version of the BOOT program is obtained from the network element main control board 02, and the new version of the BOOT program is stored to The spare area; running a new version of the BOOT program in the spare area; when the new version of the BOOT program runs successfully, the spare area is used as a new main area, and the main area is used as a new Spare area.
参照图12,图12为单板的BOOT程序远程升级系统的交互示意图。Referring to FIG. 12, FIG. 12 is a schematic diagram of interaction of a remote upgrade system of a BOOT program of a single board.
单板01获取远程客户端03发送至网元主控板02的新版本的BOOT程序的步骤的方法可以是:在用户需要更新单板01的BOOT程序时,首先通过远程客户端03且利用FTP发送新版本的BOOT程序至网元主控板02,然后通过Telnet远程登录至网元主控板02,用户利用客户端经网元主控板02发送远程升级指令至单板01,控制网元主控板02直接经S口发送新版本的BOOT程序至单板01,或者,网元主控板02可在接收到单板01发送的获取新版本的BOOT程序的请求时,经S口发送新版本的BOOT程序至单板01。The method of the step of obtaining the new version of the BOOT program sent by the remote client 03 to the network element control board 02 may be: when the user needs to update the BOOT program of the board 01, first through the remote client 03 and using FTP. Send a new version of the BOOT program to the NE main control board 02, and then log in to the NE main control board 02 through Telnet. The user sends a remote upgrade command to the board 01 through the NE main control board 02 to control the network element. The main control board 02 directly sends a new version of the BOOT program to the board 01 through the S port, or the network element main control board 02 can send the S-port by receiving the request of the new version of the BOOT program sent by the board 01. The new version of the BOOT program goes to the board 01.
单板01通过挂狗复位,停止在主用区中运行BOOT程序,而在备用区中尝试运行新版本的BOOT程序,并监控试运行的情况。The board 01 stops the dog running in the main area by running the dog reset, and tries to run the new version of the BOOT program in the spare area and monitors the trial operation.
单板01在新版本的BOOT程序运行成功时,将备用区作为新的主用区,且将主用区作为新的备用区,单板01判断新版本的BOOT程序运行是否成功的方法可以是:通过新版本的BOOT程序运行成功时设置的相应标识判断,本实施例中单板01可以采用与相关技术类似的方法判断新版本的BOOT程序运行是否成功,在此不做赘述。When the new version of the BOOT program runs successfully, the board uses the spare area as the new primary area and uses the active area as the new spare area. The method for the board 01 to determine whether the new version of the BOOT program is successful may be The board can be judged by the method similar to the related art to determine whether the running of the new version of the BOOT program is successful, and the details are not described herein.
单板01可在新版本的BOOT程序运行成功时,自动将备用区作为新的主用区,且将主用区作为新的备用区;或者,单板01可在新版本的BOOT程序运行成功,且接收到远程客户端03经网元主控板02发送的激活指令时,再将备用区作为新的主用区,将主用区作为新的备用区。单板01再启动时,优先启动该新的主用区以运行该新的主用区中的BOOT程序,即新版本的BOOT程序The board 01 can automatically use the spare area as the new main area and the main area as the new spare area when the new version of the BOOT program runs successfully. Alternatively, the board 01 can run successfully in the new version of the BOOT program. And receiving the activation command sent by the remote client 03 via the network element control board 02, then using the spare area as a new primary area and the primary area as a new spare area. When the board 01 is restarted, the new main area is preferentially started to run the BOOT program in the new main area, that is, the new version of the BOOT program.
单板01将备用区作为新的主用区,且将主用区作为新的备用区的方法可以是:通过设置标记分区优先启用的启动标识切换主用区和备用区;或者,通过设置主备状态标识标记主用区和备用区,通过设置主备状态标识切换主用区和备用区。The board 01 uses the spare area as the new primary area, and the method of using the primary area as the new spare area may be: switching the primary area and the spare area by setting the boot identifier preferentially enabled by the mark partition; or, by setting the primary The standby status indicator marks the primary area and the standby area. The primary and backup areas are switched by setting the primary and secondary status indicators.
单板01在新版本的BOOT程序运行不成功时,返回重新执行运行新版本的BOOT程序的步骤;或者,单板01在新版本的BOOT程序运行失败时, 复位并启用主用区以运行主用区中的BOOT程序。When the new version of the BOOT program fails to run, the board returns to the step of re-executing the running of the new version of the BOOT program; or, when the new version of the BOOT program fails to run, Reset and enable the main area to run the BOOT program in the main area.
本实施例通过远程升级单板01的BOOT程序,不需技术人员进行现场操作,提高了升级效率,且节省了人力物力,降低了成本;此外,通过将新版本的BOOT程序在备用区中运行,防止因新版本的BOOT程序安装出错而使得单板01无法成功运行的问题,因此,保证了升级BOOT程序的可靠性。In this embodiment, by remotely upgrading the BOOT program of the board 01, the technician does not need to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area. To prevent the problem that the board 01 cannot run successfully due to the installation error of the new version of the BOOT program, therefore, the reliability of the upgrade BOOT program is guaranteed.
本发明单板01的BOOT程序远程升级系统第二实施例中,本实施例在第一实施例的基础上,所述单板01设置为:In the second embodiment of the BOOT program remote upgrade system of the board 01 of the present invention, in the embodiment, the board 01 is set as follows:
设置试运行标识及试运行计时标识;Set the trial run ID and test run timing indicator;
复位并运行所述新版本的BOOT程序;Reset and run the new version of the BOOT program;
清除所述试运行标识且保留所述试运行计时标识。The trial run identifier is cleared and the trial run timing indicator is retained.
本发明单板01的BOOT程序远程升级系统第三实施例中,本实施例在第一实施例、第二实施例的基础上,In the third embodiment of the remote upgrade system of the BOOT program of the board 01 of the present invention, the present embodiment is based on the first embodiment and the second embodiment.
所述远程客户端03还设置为:发送试运行指令至所述网元主控板02,供所述网元主控板02转发所述试运行指令至所述单板01;The remote client 03 is further configured to: send a trial run command to the network element control board 02, and the network element main control board 02 forwards the test run command to the board 01;
所述网元主控板02还设置为:接收所述远程客户端03发送的所述试运行指令,转发所述试运行指令至所述单板01;The network element control board 02 is further configured to: receive the test run command sent by the remote client 03, and forward the test run command to the board 01;
所述单板01还设置为:在接收到所述远程客户端03经所述网元主控板02发送的所述试运行指令时,判断所述备用区是否处于试运行状态;在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。The board 01 is further configured to: determine, when the remote client 03 receives the trial operation command sent by the network element main control board 02, whether the spare area is in a trial running state; When the spare area is not in the trial running state, the new version of the BOOT program in the spare area is run.
本发明单板01的BOOT程序远程升级系统第四实施例中,本实施例在第三实施例的基础上,In the fourth embodiment of the BOOT program remote upgrade system of the board 01 of the present invention, the embodiment is based on the third embodiment.
所述远程客户端03还设置为:发送激活指令至所述网元主控板02,供所述网元主控板02转发所述激活指令至所述单板01;The remote client 03 is further configured to: send an activation command to the network element control board 02, and the network element main control board 02 forwards the activation instruction to the board 01;
所述网元主控板02还设置为:接收所述远程客户端03发送的所述激活指令,转发所述试激活指令至所述单板01;The network element control board 02 is further configured to: receive the activation command sent by the remote client 03, and forward the test activation command to the board 01;
所述单板01还设置为:在侦测到远程客户端03经网元主控板02发送的激活指令时,识别所述备用区是否处于试运行状态;当所述备用区处于试运 行状态时,单板01则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;当所述备用区不处于试运行状态,且存在所述试运行计时标识时,单板01则清除所述试运行计时标识。The board 01 is further configured to: when detecting the activation command sent by the remote client 03 via the network element control board 02, identify whether the spare area is in a trial running state; when the spare area is in trial operation In the row state, the board 01 clears the trial operation timing identifier, uses the spare area as a new primary area, and uses the primary area as a new spare area; when the spare area is not in trial operation When the test run timing indicator exists, the board 01 clears the test run timing indicator.
本发明单板01的BOOT程序远程升级系统第五实施例中,本实施例在第一实施例、第二实施例、第三实施例、第四实施例的基础上,In the fifth embodiment of the remote upgrade system of the BOOT program of the board 01 of the present invention, the present embodiment is based on the first embodiment, the second embodiment, the third embodiment, and the fourth embodiment.
所述单板01还设置为:在接收到远程客户端03经网元主控板02发送的远程升级指令时,判断单板01是否处于试运行状态;在判定单板01不处于试运行状态时,向网元主控板02发送所述远程升级响应;接收网元主控板02转发的由远程客户端03预先发送至网元主控板02的所述新版本的BOOT程序;The board 01 is further configured to: determine that the board 01 is in a trial running state when receiving the remote upgrade command sent by the remote client 03 via the network element control board 02; and determine that the board 01 is not in the trial running state. Sending the remote upgrade response to the network element control board 02; receiving the new version of the BOOT program forwarded by the remote source terminal 03 to the network element main control board 02 forwarded by the network element control board 02;
所述网元主控板02还设置为:在接收到所述单板01发送的所述远程升级响应时,转发的由远程客户端03预先发送至网元主控板02的所述新版本的BOOT程序。The network element control board 02 is further configured to: before receiving the remote upgrade response sent by the board 01, the forwarded version is sent by the remote client 03 to the new version of the network element control board 02. BOOT program.
本领域普通技术人员可以理解上述实施例的全部或部分步骤可以使用计算机程序流程来实现,所述计算机程序可以存储于一计算机可读存储介质中,所述计算机程序在相应的硬件平台上(如系统、设备、装置、器件等)执行,在执行时,包括方法实施例的步骤之一或其组合。One of ordinary skill in the art will appreciate that all or a portion of the steps of the above-described embodiments can be implemented using a computer program flow, which can be stored in a computer readable storage medium, such as on a corresponding hardware platform (eg, The system, device, device, device, etc. are executed, and when executed, include one or a combination of the steps of the method embodiments.
可选地,上述实施例的全部或部分步骤也可以使用集成电路来实现,这些步骤可以被分别制作成一个个集成电路模块,或者将它们中的多个模块或步骤制作成单个集成电路模块来实现。这样,本发明不限制于任何特定的硬件和软件结合。Alternatively, all or part of the steps of the above embodiments may also be implemented by using an integrated circuit. These steps may be separately fabricated into individual integrated circuit modules, or multiple modules or steps may be fabricated into a single integrated circuit module. achieve. Thus, the invention is not limited to any specific combination of hardware and software.
上述实施例中的各装置/功能模块/功能单元可以采用通用的计算装置来实现,它们可以集中在单个的计算装置上,也可以分布在多个计算装置所组成的网络上。The devices/function modules/functional units in the above embodiments may be implemented by a general-purpose computing device, which may be centralized on a single computing device or distributed over a network of multiple computing devices.
上述实施例中的各装置/功能模块/功能单元以软件功能模块的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。上述提到的计算机可读取存储介质可以是只读存储器,磁盘或光盘等。 When each device/function module/functional unit in the above embodiment is implemented in the form of a software function module and sold or used as a stand-alone product, it can be stored in a computer readable storage medium. The above mentioned computer readable storage medium may be a read only memory, a magnetic disk or an optical disk or the like.
工业实用性Industrial applicability
本发明实施例通过远程升级单板的BOOT程序,不需技术人员进行现场操作,提高了升级效率,且节省了人力物力,降低了成本;此外,通过将新版本的BOOT程序在备用区中运行,防止因新版本的BOOT程序安装出错而使得单板无法成功运行的问题,因此,保证了升级BOOT程序的可靠性。 In the embodiment of the present invention, the BOOT program of the board is remotely upgraded, and the technician is not required to perform on-site operations, thereby improving the upgrade efficiency, saving manpower and material resources, and reducing the cost; in addition, by running the new version of the BOOT program in the spare area. The problem of preventing the board from running successfully due to the installation error of the new version of the BOOT program, thus ensuring the reliability of the upgrade BOOT program.

Claims (14)

  1. 一种单板的BOOT程序远程升级方法,包括以下步骤:A remote upgrade method for a BOOT program of a single board includes the following steps:
    单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;When the board is started, the storage area in the board is initialized to divide the storage area to obtain the primary area and the spare area.
    所述单板运行所述主用区中的BOOT程序;The board runs a BOOT program in the main area;
    所述单板在侦测到远程客户端经网元主控板发送的远程升级指令时,从所述网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;The board obtains a new version of the BOOT program from the network element main control board when detecting the remote upgrade command sent by the remote client via the network element main control board, and stores the new version of the BOOT program to The spare area;
    所述单板运行所述备用区中新版本的BOOT程序;The board runs a new version of the BOOT program in the spare area;
    所述单板在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。When the new version of the BOOT program runs successfully, the board uses the spare area as a new primary area and uses the primary area as a new spare area.
  2. 如权利要求1所述的方法,其中,所述单板运行所述备用区中新版本的BOOT程序的步骤之后,该方法还包括:The method of claim 1, wherein after the step of running the new version of the BOOT program in the spare area, the method further comprises:
    所述单板在所述新版本的BOOT程序运行不成功时,复位并运行所述主用区中的BOOT程序。The board resets and runs the BOOT program in the active area when the new version of the BOOT program is unsuccessful.
  3. 如权利要求1所述的方法,其中,所述单板运行所述备用区中新版本的BOOT程序的步骤包括:The method of claim 1, wherein the step of the board running a new version of the BOOT program in the spare area comprises:
    所述单板设置试运行标识及试运行计时标识;The board sets a trial running identifier and a trial running timing identifier;
    所述单板复位并运行所述新版本的BOOT程序;The board resets and runs the new version of the BOOT program;
    所述单板清除所述试运行标识且保留所述试运行计时标识。The board clears the trial run identifier and retains the trial run timing identifier.
  4. 如权利要求1至3中任一项所述方法,其中,所述单板运行所述备用区中新版本的BOOT程序的步骤替换为:The method according to any one of claims 1 to 3, wherein the step of the board running a new version of the BOOT program in the spare area is replaced by:
    所述单板在接收到远程客户端经所述网元主控板发送的试运行指令时,判断所述备用区是否处于试运行状态;When receiving the trial operation command sent by the remote client via the network element main control board, the board determines whether the standby area is in a trial running state;
    所述单板在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。 When the board determines that the spare area is not in the trial running state, the board runs a new version of the BOOT program in the spare area.
  5. 如权利要求3所述的方法,其中,所述单板在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区的步骤替换为:The method of claim 3, wherein the board uses the spare area as a new primary area when the new version of the BOOT program runs successfully, and uses the primary area as a new backup. Replace the steps of the zone with:
    所述单板侦测到远程客户端经所述网元主控板发送的激活指令时,识别所述备用区是否处于试运行状态;When the board detects that the remote client sends an activation command sent by the network element main control board, the board identifies whether the standby area is in a trial running state;
    当所述备用区处于试运行状态时,所述单板则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;When the spare area is in a trial running state, the board clears the trial running timing identifier, uses the spare area as a new primary area, and uses the primary area as a new spare area;
    当所述备用区不处于试运行状态,且存在所述试运行计时标识时,所述单板则清除所述试运行计时标识。When the spare area is not in the trial running state, and the trial running timing identifier exists, the board clears the trial running timing identifier.
  6. 如权利要求1、2、3或5中任一项所述的方法,其中,所述从所述网元主控板获取新版本的BOOT程序的步骤包括:The method of any of claims 1, 2, 3 or 5, wherein the step of obtaining a new version of the BOOT program from the network element master control board comprises:
    所述单板在接收到所述远程客户端经网元主控板发送的远程升级指令时,判断单板是否处于试运行状态;The board determines whether the board is in a trial running state when receiving the remote upgrade command sent by the remote client via the network element main control board;
    所述单板在判定单板不处于试运行状态时,向网元主控板发送远程升级响应;The board sends a remote upgrade response to the network element main control board when it is determined that the board is not in the trial running state;
    所述单板接收网元主控板转发的由所述远程客户端预先发送至网元主控板的所述新版本的BOOT程序。The board receives the new version of the BOOT program forwarded by the remote client to the network element main control board forwarded by the network element main control board.
  7. 一种单板的BOOT程序远程升级装置,包括:A remote upgrade device for a BOOT program of a single board, comprising:
    初始化模块,设置为:单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;The initialization module is configured to: when the board is started, initialize the storage area in the board to divide the storage area to obtain the primary area and the spare area;
    运行模块,设置为:运行所述主用区中的BOOT程序;Running the module, set to: run the BOOT program in the main area;
    下载模块,设置为:在侦测到远程客户端经网元主控板发送的远程升级指令时,从所述网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;The download module is configured to: when detecting a remote upgrade command sent by the remote client via the network element main control board, obtain a new version of the BOOT program from the network element main control board, and execute the new version of the BOOT program. Stored to the spare area;
    试运行模块,设置为:运行所述备用区中新版本的BOOT程序;以及a trial run module, set to: run a new version of the BOOT program in the spare area;
    激活模块,设置为:在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。 The activation module is configured to: when the new version of the BOOT program runs successfully, use the spare area as a new primary area, and use the primary area as a new spare area.
  8. 如权利要求7所述的装置,其中,所述单板的BOOT远程升级装置包括:The device of claim 7, wherein the BOOT remote upgrade device of the single board comprises:
    复位模块,设置为:在所述新版本的BOOT程序运行不成功时,复位单板并运行所述主用区中的BOOT程序。The reset module is configured to: when the new version of the BOOT program is unsuccessful, reset the board and run the BOOT program in the main area.
  9. 如权利要求7所述的装置,其中,所述试运行模块包括:The apparatus of claim 7 wherein said commissioning module comprises:
    设置单元,设置为:设置试运行标识及试运行计时标识;Set the unit, set to: set the trial run ID and test run timing indicator;
    试运行单元,设置为:复位单板并运行所述新版本的BOOT程序;The commissioning unit is configured to: reset the board and run the new version of the BOOT program;
    清除单元,设置为:清除所述试运行标识且保留所述试运行计时标识。And a clearing unit, configured to: clear the trial run identifier and retain the trial run timing identifier.
  10. 如权利要求7至9中任一项所述的装置,其中,所述试运行模块设置为:The apparatus of any of claims 7 to 9, wherein the commissioning module is configured to:
    在接收到远程客户端经网元主控板发送的试运行指令时,判断所述备用区是否处于试运行状态;When receiving the trial run command sent by the remote client via the network element main control board, determining whether the spare area is in a trial running state;
    在判定所述备用区不处于试运行状态时,运行所述备用区中新版本的BOOT程序。When it is determined that the spare area is not in the trial running state, the new version of the BOOT program in the spare area is run.
  11. 如权利要求9所述的装置,其中,所述激活模块设置为:The apparatus of claim 9 wherein said activation module is configured to:
    侦测到远程客户端经网元主控板发送的激活指令时,识别所述备用区是否处于试运行状态;Detecting whether the remote area is in a trial running state when detecting an activation command sent by the remote client through the network element main control board;
    当所述备用区处于试运行状态时,则清除所述试运行计时标识,将所述备用区作为新的主用区,且将所述主用区作为新的备用区;When the spare area is in a trial running state, clearing the trial running timing identifier, using the spare area as a new primary area, and using the primary area as a new spare area;
    当所述备用区不处于试运行状态,且存在所述试运行计时标识时,则清除所述试运行计时标识。When the spare area is not in the trial running state, and the trial running timing identifier exists, the trial running timing identifier is cleared.
  12. 如权利要求7、8、9或11中任一项所述的装置,其中,所述下载模块包括:The apparatus of any of claims 7, 8, 9, or 11, wherein the downloading module comprises:
    判断单元,设置为:在接收到远程客户端经网元主控板发送的远程升级指令时,判断单板是否处于试运行状态; The determining unit is configured to: determine whether the board is in a trial running state when receiving the remote upgrade command sent by the remote client through the network element main control board;
    响应单元,设置为:在判定单板不处于试运行状态时,向网元主控板发送远程升级响应;The response unit is configured to: send a remote upgrade response to the network element main control board when it is determined that the board is not in the trial running state;
    接收单元,设置为:接收网元主控板转发的由远程客户端预先发送至网元主控板的所述新版本的BOOT程序。The receiving unit is configured to: receive the new version of the BOOT program forwarded by the remote client to the network element main control board and forwarded by the remote control board.
  13. 一种单板的BOOT程序远程升级系统,包括单板、网元主控板及远程客户端;A remote upgrade system for a BOOT program of a board, including a board, a network element main control board, and a remote client;
    所述远程客户端,设置为:发送新版本的BOOT程序至所述网元主控板;在单板启动后,发送远程升级指令至所述网元主控板,供所述网元主控板转发所述远程升级指令至所述单板;The remote client is configured to: send a new version of the BOOT program to the network element main control board; after the board is started, send a remote upgrade command to the network element main control board, where the network element is controlled. The board forwards the remote upgrade command to the board;
    所述网元主控板,设置为:接收所述远程客户端发送的所述新版本的BOOT程序;转发所述远程客户端发送的所述远程升级指令至所述单板;The network element control board is configured to: receive the new version of the BOOT program sent by the remote client, and forward the remote upgrade command sent by the remote client to the board;
    所述单板,设置为:单板启动时,初始化单板中的存储区,以将存储区进行划分,获得主用区和备用区;运行所述主用区中的BOOT程序;在侦测到远程客户端经所述网元主控板发送的远程升级指令时,从所述网元主控板获取新版本的BOOT程序,且将所述新版本的BOOT程序存储至所述备用区;运行所述备用区中新版本的BOOT程序;在所述新版本的BOOT程序运行成功时,将所述备用区作为新的主用区,且将所述主用区作为新的备用区。The board is configured to: when the board is started, initialize a storage area in the board to divide the storage area to obtain a main area and a spare area; and run the BOOT program in the main area; When the remote client sends the remote upgrade command sent by the network element main control board, the new version of the BOOT program is obtained from the network element main control board, and the new version of the BOOT program is stored in the spare area; Running a new version of the BOOT program in the spare area; when the new version of the BOOT program runs successfully, the spare area is used as a new primary area, and the primary area is used as a new spare area.
  14. 一种计算机可读存储介质,存储有程序指令,当该程序指令被执行时可实现1-6任一项所述的方法。 A computer readable storage medium storing program instructions that, when executed, can implement the method of any of 1-6.
PCT/CN2015/071819 2014-08-01 2015-01-29 Remote upgrade method, device and system of boot program of single board WO2015154578A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410378411.4A CN105320534B (en) 2014-08-01 2014-08-01 BOOT remote upgrading method, device and system for single board
CN201410378411.4 2014-08-01

Publications (1)

Publication Number Publication Date
WO2015154578A1 true WO2015154578A1 (en) 2015-10-15

Family

ID=54287289

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/071819 WO2015154578A1 (en) 2014-08-01 2015-01-29 Remote upgrade method, device and system of boot program of single board

Country Status (2)

Country Link
CN (1) CN105320534B (en)
WO (1) WO2015154578A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110471674A (en) * 2019-08-21 2019-11-19 上海无线电设备研究所 The remote upgrade method of DSP embedded program based on C6455 chip
CN114322244A (en) * 2021-09-09 2022-04-12 青岛海尔空调电子有限公司 Program upgrading method and device and multi-split air conditioning system

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109144532B (en) * 2017-06-13 2023-04-11 中兴通讯股份有限公司 Upgrading method and device
CN111683022B (en) * 2020-08-12 2020-11-27 广东省新一代通信与网络创新研究院 White box switch, method for upgrading forwarding function of white box switch and readable storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101464804A (en) * 2008-12-29 2009-06-24 杭州迪普科技有限公司 Double-boot backup method and security equipment
CN102053842A (en) * 2009-11-09 2011-05-11 中兴通讯股份有限公司 Method and device for improving BOOT compatibility
CN103823664A (en) * 2012-11-19 2014-05-28 中兴通讯股份有限公司 Design method for binary system unified Boot programs and kernel programs

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100354825C (en) * 2006-08-02 2007-12-12 华为技术有限公司 Software staging and back spacing method
CN101329632B (en) * 2008-04-30 2014-02-19 中兴通讯股份有限公司 Method and apparatus for starting CPU by BOOT
WO2009156615A1 (en) * 2008-06-02 2009-12-30 Awox Method and device for updating a computer application
CN101908008B (en) * 2009-06-03 2012-09-26 大唐移动通信设备有限公司 Device and method for switching BIOS (Basic Input/Output System)
CN101848108A (en) * 2010-05-25 2010-09-29 中兴通讯股份有限公司 Method and system for downloading software

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101464804A (en) * 2008-12-29 2009-06-24 杭州迪普科技有限公司 Double-boot backup method and security equipment
CN102053842A (en) * 2009-11-09 2011-05-11 中兴通讯股份有限公司 Method and device for improving BOOT compatibility
CN103823664A (en) * 2012-11-19 2014-05-28 中兴通讯股份有限公司 Design method for binary system unified Boot programs and kernel programs

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110471674A (en) * 2019-08-21 2019-11-19 上海无线电设备研究所 The remote upgrade method of DSP embedded program based on C6455 chip
CN114322244A (en) * 2021-09-09 2022-04-12 青岛海尔空调电子有限公司 Program upgrading method and device and multi-split air conditioning system
CN114322244B (en) * 2021-09-09 2023-02-28 青岛海尔空调电子有限公司 Program upgrading method and device and multi-split air conditioning system

Also Published As

Publication number Publication date
CN105320534B (en) 2020-06-09
CN105320534A (en) 2016-02-10

Similar Documents

Publication Publication Date Title
TWI602124B (en) Baseboard Management Controller Firmware Updating Method For Fan Speed Control
US10268471B2 (en) Method for upgrading terminal system, terminal, and system
US20120117557A1 (en) Method and system for upgrading wireless data card
US8862865B2 (en) Rebooting infiniband clusters
US20140123121A1 (en) Rack and method thereof for simultaneously updating basic input output systems
US10635428B2 (en) System and method for in-service update of software
CN106020875B (en) Firmware update management method and device of embedded terminal
WO2015154578A1 (en) Remote upgrade method, device and system of boot program of single board
US9904561B2 (en) Computer system and method for setting BIOS
JP2010541105A (en) Firmware image update and management
CN106549789B (en) Method and system for realizing server installation
US20080127166A1 (en) Synchronizing controller firmware download
CN102238093A (en) Service interruption prevention method and device
US9792106B1 (en) Technique for fast network device configuration upgrade and reload
JP7345921B2 (en) OTA differential update method and system for master-slave architecture
JP2009020886A (en) System and method for ota programming
US20180046448A1 (en) Collaborative maintenance of software programs
WO2016033941A1 (en) Boot on-line upgrading apparatus and method
CN108874410B (en) Patch management method and device
CN110688136B (en) Application program updating method and device
WO2014187401A1 (en) Method and device for remote base station version installation
CN103442041A (en) Method, device and system for upgrading firmware of embedded device
TWI668635B (en) Mainboard and setting updating method thereof
TWI663509B (en) System information managing method
JP2006113754A (en) Software update device and method

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 15776184

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15776184

Country of ref document: EP

Kind code of ref document: A1