CN102141939B - Device capable of recording restart reason of whole machine - Google Patents

Device capable of recording restart reason of whole machine Download PDF

Info

Publication number
CN102141939B
CN102141939B CN 201010104470 CN201010104470A CN102141939B CN 102141939 B CN102141939 B CN 102141939B CN 201010104470 CN201010104470 CN 201010104470 CN 201010104470 A CN201010104470 A CN 201010104470A CN 102141939 B CN102141939 B CN 102141939B
Authority
CN
China
Prior art keywords
complete machine
storage array
cpu
reason
logic chip
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN 201010104470
Other languages
Chinese (zh)
Other versions
CN102141939A (en
Inventor
邓晓勇
王玉田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
New H3C Technologies Co Ltd
Original Assignee
Hangzhou H3C Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hangzhou H3C Technologies Co Ltd filed Critical Hangzhou H3C Technologies Co Ltd
Priority to CN 201010104470 priority Critical patent/CN102141939B/en
Publication of CN102141939A publication Critical patent/CN102141939A/en
Application granted granted Critical
Publication of CN102141939B publication Critical patent/CN102141939B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention discloses a device capable of recording a restart reason of a whole machine. A storage array is cured inside a logic chip of the device capable of recording the restart reason of the whole machine; the logic chip automatically sets the internal storage array into a default value which indicates that the reason of restarting the whole machine is power failure after the whole machine is powered up and started by using the characteristics of the logic chip for resetting the internal storage array during power-up; therefore, the whole machine cannot record any information before power failure, but a central processing unit (CPU) can read the storage array cured in the logic chip after each resetting according to a record of the logic chip after the whole machine is powered on and determines that the reason of restarting the whole machine is power failure; moreover, after reading the storage array, the CPU sets the storage array as an initial value, so that each restart reason can be recorded.

Description

Can record complete machine and restart the device of reason
Technical field
The present invention relates to record and the administrative skill of complete machine event, particularly a kind ofly record the device that complete machine is restarted reason.
Background technology
Existing all kinds of complete machine usually can be owing to restarting appears in certain abnormal conditions in operational process; for example, trigger the CPU abnormal restarting of complete machine Global reset owing to CPU causes house dog unusually, triggered software restarting or because the power-down rebooting that the power down of complete machine hardware causes of Global reset by the software that carries among the CPU.
Yet, existing all kinds of complete machine can't be recorded before restarting restarts reason accurately, especially power-down rebooting can't be preserved any information especially before restarting, because power down causes complete machine all can't work, this information of power down is difficult to obtain record naturally, thereby so that complete machine can't be distinguished the different reasons of restarting after restarting, thereby cause the follow-up machine failure place that is difficult to accurately locate.
Summary of the invention
In view of this, the invention provides a kind of device that complete machine is restarted reason that records, can record the power-down rebooting event of complete machine.
A kind of device that complete machine is restarted reason that records provided by the invention comprises:
Logic chip;
House dog, it triggers the complete machine Global reset after overflowing generation and after the complete machine powering startup;
CPU carries out dog feeding operation by logic chip to house dog after finishing resetting;
The logic chip inside solidification has storage array and possesses the characteristic of the replacement storage array that powers on, and this storage array can be after complete machine powering starts be set to voluntarily represent that by logic chip complete machine restarts former default value because of power-down rebooting;
Aforementioned CPU finish at every turn reset after, reads first the aforementioned storage array in the logic chip and restart reason with the value identification complete machine that reads, and then this storage array is set to initial value.
House dog is after overflowing generation, and further record expression complete machine is restarted former because the numerical value of CPU abnormal restarting in the aforementioned storage array in logic chip.
Further carry the software that can trigger Global reset among the CPU; And CPU is further restarted reason with complete machine and is identified as software restarting only read initial value from aforementioned storage array after.
House dog triggers the complete machine Global reset by producing reset signal to logic chip, and further utilizes in the aforementioned storage array of aforementioned reset signal in logic chip record expression complete machine to restart former because the numerical value of CPU abnormal restarting.
Comprise in the aforementioned storage array that bit wide is the register of at least 2 bits, at least 1 bit wherein is used for CPU and judges complete machine restarts whether reason is the CPU abnormal restarting, at least 1 bit then judges for CPU whether complete machine is restarted reason is the numerical value of power-down rebooting in addition.
Logic chip has and is used for CPU and judges that whether complete machine is restarted reason is that external terminal, this external terminal of the wherein at least 1 bit conducting of CPU abnormal restarting also is connected with the output terminal of house dog generation reset signal.
Further carry the software that can trigger Global reset among the CPU; And CPU is further restarted reason with complete machine and is identified as software restarting only read initial value from aforementioned storage array after.
Described logic chip is CPLD.
As seen from the above technical solution, can record the device that complete machine is restarted reason among the present invention, its logic chip inside solidification has storage array, and utilized the characteristic of the replacement internal memory array that powers on that self possesses by logic chip, after complete machine powering starts, internal memory array is set to voluntarily represent that complete machine restarts former default value because of power-down rebooting, therefore, although complete machine can't record any information before power-down rebooting, but by the record of logic chip behind complete machine powering, CPU can read the storage array that solidifies in the logic chip after resetting finishing at every turn, and identify complete machine with this and restart former because power-down rebooting.And, CPU after reading storage array also this storage array be set to initial value, thereby can guarantee that the reason of at every turn restarting all can be recorded.
Further alternatively, house dog is after overflowing generation, further record expression complete machine is restarted former because the numerical value of CPU abnormal restarting in the aforementioned storage array in logic chip, and/or, CPU is after only reading initial value from aforementioned storage array, can further complete machine be restarted reason and be identified as software restarting, thus, the present invention is except recording and identify the power-down rebooting event, also can further record and identify the CPU abnormal restarting, and/or other of software restarting are restarted reason, restart reason thereby can distinguish exactly all kinds of complete machines, and then can be convenient to the accurate location of follow-up machine failure.
Description of drawings
Fig. 1 can record the preferred illustrative structural representation that complete machine is restarted the device of reason in the embodiment of the invention;
Fig. 2 can record the concrete logical organization schematic diagram that complete machine is restarted the device of reason in the embodiment of the invention;
Fig. 3 can record another concrete logical organization schematic diagram that complete machine is restarted the device of reason in the embodiment of the invention.
Embodiment
For making purpose of the present invention, technical scheme and advantage clearer, referring to the accompanying drawing embodiment that develops simultaneously, the present invention is described in more detail.
Fig. 1 can record the preferred illustrative structural representation that complete machine is restarted the device of reason in the embodiment of the invention.Referring to Fig. 1 and in conjunction with Fig. 2, can record the device that complete machine is restarted reason in the present embodiment, comprise in the existing complete machine usually included CPU10 and the house dog 21 that is used for the complete machine Global reset, wherein:
House dog 21 triggers the complete machine Global reset after overflowing generation and after the complete machine powering startup, namely CPU10's resets by reset trigger module controls among the CPLD11;
CPU10 then reset finish after, by CPLD11 send feeding-dog signal WDI, to realize that house dog 21 is carried out dog feeding operations, that is to say, feed the feeding-dog signal WDI that the dog module sends among the CPLD11 and be controlled by CPU10.
In addition, can record complete machine in the present embodiment restarts the device of reason and also comprises for the logic chip of realizing various additional logic functions (Fig. 1 take logic chip as example as CPLD11), but referring to Fig. 1 and in conjunction with Fig. 2, unlike the prior art be, the CPLD11 inside solidification has the storage array (not shown in figure 1), and, this CPLD11 need to possess the characteristic of the replacement internal memory array that powers on, and after complete machine powering starts, before CPU10 finishes and resets, can utilize the inner replacement module that powers on that internal memory array is set to voluntarily represent that complete machine restarts former because the default value of power-down rebooting;
Need to prove, " storage array of curing " as herein described, refer to the storage array that CPLD11 forms in internal build according to logical program, or be referred to as the logical circuit of tool memory function, it can be any stored logics such as register such as the tool latch function, because the logical program among the CPLD11 can be owing to power down is lost, thereby this storage array just can not be owing to power down is decomposed, and, the characteristic of replacement internal memory array of powering on is that part model CPLD is customarily used in the characteristic that configures self power-up state, and those skilled in the art know and how to utilize logical program to realize this characteristic; In the practical application, for the logic chip of other types, need only the characteristic that inside possesses described " storage array of curing " and possesses the replacement internal memory array that powers on, all replaceable CPLD11 realizes the present invention;
Thus, although complete machine can't record any information before power-down rebooting, but the record of doing based on the storage array that CPLD11 behind the complete machine powering solidifies in it by resetting, CPU10 finish at every turn reset after, can read first the storage array that solidifies in the CPLD11 and go out complete machine with the numerical identification that reads restarts former because power-down rebooting, then, this storage array is set to initial value again, all can be recorded so that guarantee follow-up reason of restarting at every turn.
In addition:
House dog 21 is after overflowing generation, and record expression complete machine is restarted former because the numerical value of CPU abnormal restarting in the storage array that also can further solidify in CPLD11;
And/or, for the situation that further carries the software that can trigger Global reset among the CPU, restart the value that to revise the storage array that solidifies in the CPLD11 by the complete machine that software triggering Global reset causes, therefore, if only read initial value the storage array that CPU solidifies in CPLD11, then can further complete machine be restarted reason and be identified as software restarting;
Like this, except record and identification power-down rebooting event, the present embodiment also can further record and identify CPU abnormal restarting and/or software restarting other restart reason, restart reason thereby can distinguish exactly all kinds of complete machines, and then can be convenient to the accurate location of follow-up machine failure.
Above, be to recording the schematic illustration that complete machine is restarted the device of reason in the present embodiment, when specific implementation, house dog can be realized record by reset signal:
House dog 21 can produce reset signal RST immediately after complete machine powering starts, and triggers the complete machine Global reset by producing reset signal RST to CPLD11; And, referring to Fig. 3, as long as the level value of reset signal RST can make the storage array internal numeric be different from default value and initial value, reset signal RST is exported to the pin of CPLD11 and its inside solidification storage array, also can be by the mode to the storage array assignment, record expression complete machine is restarted former because the numerical value of CPU abnormal restarting in the storage array that solidifies in CPLD11;
Need to prove in addition, low level or high level reset signal that watchdog circuit commonly used produces generally can continue 200ms, this duration is enough to the assign operation of storage array, therefore, house dog 21 is feasible by the scheme that the mode to the storage array assignment records the startup reason.
And then, for the multiple situation of restarting reason of needs record, the storage array bit wide of solidifying in the CPLD11 in the present embodiment can comprise the register that can latch at least 2 Bit datas, CPLD11 can all be set to default value with at least 2 bits of register in the storage array after powering on, and after CPU10 reads register in the storage array that solidifies in the CPLD11, also at least 2 bits of register in this storage array all should be set to initial value, and at least 2 bits of register, at least 1 bit wherein is used for CPU10 and judges whether complete machine is restarted reason is the CPU abnormal restarting, at least 1 bit then judges for CPU10 whether complete machine is restarted reason is the numerical value of power-down rebooting in addition, for example, be used for CPU10 and judge that whether complete machine is restarted reason is that at least 1 bit of CPU abnormal restarting can be the low level of storage array register, judge that for CPU10 whether complete machine is restarted reason is that other at least 1 bit of power-down rebooting then can be the high position of storage array register.
Correspondingly, CPLD11 has the first external terminal, the second external terminal (not shown in figure 1) at least, wherein, register is used for CPU10 and judges whether be at least 1 bit conducting, second external terminal of CPU abnormal restarting to complete machine and be used for reception house dog 21 reset trigger if restarting reason in the first external terminal and the CPLD11 inside solidification storage array.
Adopting mode as above, mainly is to consider three kinds of following problems that reason may exist of record:
House dog 21 produces reset signal RST and comprises two kinds of situations, and a kind of situation is generation reset signal RST when unusually causing overflowing owing to CPU10, and another kind of situation to be house dog 21 namely can produce reset signal RST behind electrifying startup;
For the reset signal RST under the previous case, its must be CPU10 by after reading that the storage array default value is judged the power-down rebooting reason and storage array being set to initial value produce, thereby it can not produce any impact for the judgement of power-down rebooting reason and the judgement of software restarting reason;
And for the reset signal RST under the latter event, because this reset signal RST is used for the complete machine Global reset, thereby CPU10 finish reset and read storage array before, storage array by CPLD11 power on the default value of rear replacement might be before CPU10 reads since the reset signal RST that receives change;
Therefore, reading default value after the change in order to ensure CPU10 still can correctly judge this complete machine of power-down rebooting and restart reason, and take into account simultaneously house dog 21 reset signal can with the reason of storage array conducting for trailer record CPU abnormal restarting, the present embodiment is for the default value situation that meeting changes owing to reset signal RST before being read by CPU10, can arrange reset signal RST only with storage array in the part predetermined bit position conducting of the register that comprises, like this, even if because the level value of reset signal RST is different from the aforementioned part predetermined bit position of default value, and make storage array by CPLD11 power on the default value of rear replacement can be before CPU10 reads since the reset signal RST that receives change, but default value only has the partial bit position and is changed, therefore, after CPU10 reads default value, can be according to can not be owing to the remainder bit that reset signal RST changes judges whether complete machine is restarted reason is power-down rebooting.
So, take the register of bit wide 2 bits, low level 1 bit be used for CPU10 judge complete machine restart reason whether as CPU abnormal restarting, high-order 1 bit for CPU10 judge complete machine restart reason whether as power-down rebooting as example:
The default value of supposing register 2 bits in the storage array is " 11 " for " 00 ", initial value, and reset signal RST is low level 0, then:
When the value of register in the storage array was " 10 ", the expression complete machine was restarted former because the CPU abnormal restarting;
When the value of register in the storage array is default value " 00 ", the expression complete machine is restarted former because power-down rebooting, although the value of register is " 00 " in the storage array at this moment, but the reset signal RST that just produces owing to house dog 21 is low level 0 also, namely reservation low level 1 bit with default value is identical, thereby any bit of default value is changed, at this moment, CPU10 both can be only according to being used for judging that whether complete machine is restarted reason is the bit of power-down rebooting, also can judge according to whole bits;
When the value of storage array was initial value " 11 ", also further the expression machine was restarted former because software restarting.
Still take the register of bit wide 2 bits, low level 1 bit be used for CPU10 judge complete machine restart reason whether as CPU abnormal restarting, high-order 1 bit for CPU10 judge complete machine restart reason whether as power-down rebooting as example:
Suppose, the default value of storage array 2 bits is that " 01 ", initial value are " 11 " again, and reset signal RST is low level 0, then:
When the value of register in the storage array was " 10 ", the expression complete machine was restarted former because the CPU abnormal restarting;
When the value of register in the storage array is " 00 ", although this value is different from default value " 01 ", but it only is low level 1 bit is that the reset signal RST that produces changes owing to house dog 21 powers on, it is high-order to be used for CPU10 and to judge that whether complete machine is restarted reason is that 1 bit of power-down rebooting does not change, therefore, high-order 1 bit " 0 " can be used to still represent that complete machine restarts former because power-down rebooting, this moment, CPU10 only can be according to being used for judging whether complete machine is restarted reason is the bit of power-down rebooting, and can not judge according to whole bits again;
When the value of storage array was initial value " 11 ", also further the expression machine was restarted former because software restarting.
Certainly, default value also can be set to other numerical value (default value that the CPLD of different model supports may be different), correspondingly, the level state of initial value, reset signal RST and with CPLD11 in solidify storage array the conducting relation need to be adjusted accordingly.
Visual in order further to make the complete machine that records in the storage array restart reason, bright by this bit value control or a go out pilot lamp also can be set respectively for each bit of storage array.
The above is preferred embodiment of the present invention only, is not for limiting protection scope of the present invention.Within the spirit and principles in the present invention all, any modification of doing, be equal to and replace and improvement etc., all should be included within protection scope of the present invention.

Claims (8)

1. one kind can be recorded the device that complete machine is restarted reason, comprising:
Logic chip;
House dog, it triggers the complete machine Global reset after overflowing generation and after the complete machine powering startup;
CPU carries out dog feeding operation by logic chip to house dog after finishing resetting;
It is characterized in that, the logic chip inside solidification has storage array and possesses the characteristic of the replacement storage array that powers on, and this storage array can be after complete machine powering starts be set to voluntarily represent that by logic chip complete machine restarts former default value because of power-down rebooting;
Aforementioned CPU finish at every turn reset after, reads first the aforementioned storage array in the logic chip and restart reason with the value identification complete machine that reads, and then this storage array is set to initial value.
2. device as claimed in claim 1 is characterized in that, house dog is after overflowing generation, and further record expression complete machine is restarted former because the numerical value of CPU abnormal restarting in the aforementioned storage array in logic chip.
3. device as claimed in claim 1 or 2 is characterized in that, further carries the software that can trigger Global reset among the CPU; And CPU is further restarted reason with complete machine and is identified as software restarting only read initial value from aforementioned storage array after.
4. device as claimed in claim 1, it is characterized in that, house dog triggers the complete machine Global reset by producing reset signal to logic chip, and further utilizes in the aforementioned storage array of aforementioned reset signal in logic chip record expression complete machine to restart former because the numerical value of CPU abnormal restarting.
5. device as claimed in claim 4, it is characterized in that, comprise in the aforementioned storage array that bit wide is the register of at least 2 bits, at least 1 bit wherein is used for CPU and judges complete machine restarts whether reason is the CPU abnormal restarting, at least 1 bit then judges for CPU whether complete machine is restarted reason is the numerical value of power-down rebooting in addition.
6. device as claimed in claim 5, it is characterized in that, logic chip has and is used for CPU and judges that whether complete machine is restarted reason is that external terminal, this external terminal of the wherein at least 1 bit conducting of CPU abnormal restarting also is connected with the output terminal of house dog generation reset signal.
7. such as each described device in the claim 4 to 6, it is characterized in that, further carry the software that can trigger Global reset among the CPU; And CPU is further restarted reason with complete machine and is identified as software restarting only read initial value from aforementioned storage array after.
8. such as each described device in claim 1 or 2 or 4 to 6, it is characterized in that, described logic chip is CPLD.
CN 201010104470 2010-02-01 2010-02-01 Device capable of recording restart reason of whole machine Active CN102141939B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201010104470 CN102141939B (en) 2010-02-01 2010-02-01 Device capable of recording restart reason of whole machine

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201010104470 CN102141939B (en) 2010-02-01 2010-02-01 Device capable of recording restart reason of whole machine

Publications (2)

Publication Number Publication Date
CN102141939A CN102141939A (en) 2011-08-03
CN102141939B true CN102141939B (en) 2013-03-27

Family

ID=44409477

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201010104470 Active CN102141939B (en) 2010-02-01 2010-02-01 Device capable of recording restart reason of whole machine

Country Status (1)

Country Link
CN (1) CN102141939B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101358776B1 (en) 2010-02-01 2014-02-05 항조우 에이치3씨 테크놀로지스 코., 엘티디. Apparatus and method for recording reboot reason of equipment
CN105279037B (en) * 2014-06-30 2019-01-11 惠州市伟乐科技股份有限公司 Watch dog monitoring method and system
CN106896754B (en) * 2015-12-18 2020-07-03 北京航天测控技术有限公司 Device for generating trigger signal in PXIe bus
CN107590016B (en) * 2017-09-14 2023-08-15 成都西加云杉科技有限公司 Power-down restarting identification method and device
CN108984330B (en) * 2018-05-31 2021-05-11 深圳市江波龙电子股份有限公司 Method and device for controlling storage equipment and electronic equipment
CN108984347B (en) * 2018-08-06 2022-03-01 杭州电子科技大学 Embedded equipment restart state recording method based on Linux system
CN110032465A (en) * 2019-04-12 2019-07-19 苏州浪潮智能科技有限公司 A kind of BMC restarts log recording method and device
CN109960638A (en) * 2019-04-18 2019-07-02 苏州浪潮智能科技有限公司 BMC starts reason recording method, system, device and readable storage medium storing program for executing

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101206599A (en) * 2006-12-19 2008-06-25 深圳市顶星数码网络技术有限公司 Method for diagnosis and insulation of computer mainboard equipment
CN101286130A (en) * 2007-04-11 2008-10-15 中兴通讯股份有限公司 Embedded equipment reset fault positioning accomplishing method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101206599A (en) * 2006-12-19 2008-06-25 深圳市顶星数码网络技术有限公司 Method for diagnosis and insulation of computer mainboard equipment
CN101286130A (en) * 2007-04-11 2008-10-15 中兴通讯股份有限公司 Embedded equipment reset fault positioning accomplishing method

Also Published As

Publication number Publication date
CN102141939A (en) 2011-08-03

Similar Documents

Publication Publication Date Title
CN102141939B (en) Device capable of recording restart reason of whole machine
CN102081573B (en) Device and method for recording equipment restart reason
CN103842968B (en) A kind of moving method of internal storage data, computing machine and device
KR101912023B1 (en) Power fail protection and recovery using low power states in a data storage device/system
US9645546B2 (en) Storage chip, imaging cartridge, method of changing serial number and method of using storage chip
US20080229125A1 (en) Power managing method of a scheduling system and related scheduling system
CN103761122A (en) Chip firmware updating method and system
CN107290650B (en) BIST logic circuit, low-power-consumption chip, memory testing method and electronic equipment
JP6011162B2 (en) Electronic control unit
JP2006338583A (en) Storage medium for computer terminal
CN102915209B (en) Storage control chip, storage equipment and system data writing method
CN112462920A (en) Power supply control method, device, server and storage medium
CN109407807B (en) Chip reset circuit, reset method and MCU chip
EP2585934B1 (en) Pull-up resistor activation in a memory system
JP2016071635A (en) Abnormality monitoring circuit of ECU
CN113960391A (en) Abnormal power failure testing device and method for storage medium
CN102024129B (en) Data writing method of embedded equipment
CN113691722A (en) Control method and device and electronic equipment
CN110442387B (en) Parameter self-adaption method and device of vehicle-mounted system and vehicle
CN1838094A (en) Serial interface circuit
CN108287670B (en) Method for protecting data during system shutdown and BMC
CN110308764B (en) Time acquisition method, processor, processing system and storage device thereof
CN116501156B (en) Power supply time sequence control method, device, equipment and storage medium
CN106468911B (en) A kind of fault message backup method for fault diagnosis
CN217640658U (en) Anti-false erasing protection circuit and vehicle-mounted control system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CP03 Change of name, title or address
CP03 Change of name, title or address

Address after: 310052 Binjiang District Changhe Road, Zhejiang, China, No. 466, No.

Patentee after: Xinhua three Technology Co., Ltd.

Address before: 310053 Hangzhou hi tech Industrial Development Zone, Zhejiang province science and Technology Industrial Park, No. 310 and No. six road, HUAWEI, Hangzhou production base

Patentee before: Huasan Communication Technology Co., Ltd.