CN110633179A - Method and device for checking physical lamp of case - Google Patents

Method and device for checking physical lamp of case Download PDF

Info

Publication number
CN110633179A
CN110633179A CN201910838559.4A CN201910838559A CN110633179A CN 110633179 A CN110633179 A CN 110633179A CN 201910838559 A CN201910838559 A CN 201910838559A CN 110633179 A CN110633179 A CN 110633179A
Authority
CN
China
Prior art keywords
state
lamp
physical
chassis
command
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.)
Withdrawn
Application number
CN201910838559.4A
Other languages
Chinese (zh)
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.)
Suzhou Wave Intelligent Technology Co Ltd
Original Assignee
Suzhou Wave Intelligent Technology 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 Suzhou Wave Intelligent Technology Co Ltd filed Critical Suzhou Wave Intelligent Technology Co Ltd
Priority to CN201910838559.4A priority Critical patent/CN110633179A/en
Publication of CN110633179A publication Critical patent/CN110633179A/en
Withdrawn legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2205Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using arrangements specific to the hardware being tested
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2273Test methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/324Display of status information
    • G06F11/325Display of status information by lamps or LED's

Abstract

The embodiment of the application discloses a method and a device for checking a physical lamp of a case, wherein the method comprises the following steps: the storage system issues a command for lighting a physical lamp of the chassis in one state; reading the actual state of the physical lamp of the current chassis by using an independent check thread set by a storage system; comparing the priority of the state of the chassis physical lamp in the command with the priority of the state of the current chassis physical lamp, and triggering a state machine to enter lighting verification when the priority of the state of the chassis physical lamp in the command is not lower than the priority of the state of the current chassis physical lamp; lighting checking: when the state of the physical lamp of the case in the command is inconsistent with the expected state of the physical lamp of the case, starting a timer to time and issuing the command for lightening the physical lamp of the case; and when the timer is overtime, triggering the state machine to enter lighting verification. The technical scheme of the application ensures the reliability of the storage device and reduces the risk of user data loss.

Description

Method and device for checking physical lamp of case
Technical Field
The application relates to the field of storage, in particular to a method and a device for checking a physical lamp of a case.
Background
When the storage device is in the cluster state, the operation of lighting the physical lamp of the chassis is performed by a Baseboard Management Controller (BMC). With the development of science and technology, the physical lamp of the case does not only show whether the storage device is normally added to a cluster state through the bright green lamp, but also shows whether the case system has other states such as a fault state through the bright red lamp, and therefore the physical lamp of the case is required to have multiple colors so as to correspondingly show multiple states of the storage system.
For example, when the inside of the storage device is failed, the expected state of the physical light of the chassis should be a warning light showing red color, but if the actual state of the physical light of the chassis shows a state light showing green color (normal state) at this time, once the user uses the storage device for storage, the data cannot be stored, and the data is lost. It is therefore important to ensure that the expected display state of the physical light of the chassis is consistent with the actual state of the storage device.
Disclosure of Invention
Based on the above problems, the present invention provides a method for checking a physical lamp of a chassis, so as to solve the problem that an expected display state of the physical lamp of the chassis is inconsistent with an actual state of a storage device.
In a first aspect of the present application, a method for verifying a physical lamp of a chassis is provided, the method including:
the storage system issues a command for lighting a physical lamp of the chassis in one state;
reading the actual state of the physical lamp of the current chassis by using an independent check thread set by a storage system;
comparing the priority of the state of the chassis physical lamp in the command with the priority of the state of the current chassis physical lamp, and triggering a state machine to enter lighting verification when the priority of the state of the chassis physical lamp in the command is not lower than the priority of the state of the current chassis physical lamp;
lighting checking: when the state of the chassis physical lamp in the command is consistent with the expected state, ending the verification process; when the state of the physical lamp of the case in the command is inconsistent with the expected state of the physical lamp of the case, starting a timer to time and issuing the command for lightening the physical lamp of the case;
and when the timer is overtime, triggering the state machine to enter lighting verification.
Optionally, the physical light of the chassis includes:
a positioning lamp, a warning lamp and a status lamp.
Optionally, the priorities of the three physical lamps include:
the priority of the positioning lamp state is higher than that of the warning lamp state, and the priority of the state lamp state is higher than that of the physical lamp extinguishing state of the chassis.
Optionally, the lighting verification step includes:
and when the state of the physical lamp of the case in the command is not consistent with the expected state after repeating the lighting verification step for multiple times, ending the verification process.
Optionally, the method further includes:
and in the operation process of the case, triggering a verification process of the physical lamp of the case when the physical lamp of the case is turned off after the restart of the hardware fault is judged and the storage equipment is in a cluster state to provide storage service.
Optionally, the step of setting, by the storage system, the individual check thread to read the actual state of the current physical lamp includes:
and the storage system sets an individual checking thread to poll and read the actual state of the current physical lamp at intervals.
In a second aspect of the present application, there is provided a device for checking a physical lamp of a cabinet, the device comprising:
the device comprises a command unit, a state reading unit, a priority comparison unit, a state machine unit, a lighting verification unit and a timer unit;
the command unit is used for sending a command for lightening one state of the physical lamp of the chassis by the storage system;
the state reading unit is used for reading the actual state of the physical lamp of the current chassis by utilizing the single check thread set by the storage system;
the priority comparison unit is used for comparing the priority of the state of the chassis physical lamp in the command with the priority of the state of the current chassis physical lamp;
the state machine unit is used for triggering the state machine to enter lighting verification when the priority of the state of the chassis physical lamp in the command is not lower than the priority of the state of the current chassis physical lamp;
the lighting verification unit is used for ending the verification process when the state of the physical lamp of the case in the command is consistent with the expected state of the physical lamp of the case; when the state of the physical lamp of the case in the command is inconsistent with the expected state of the physical lamp of the case, starting a timer to time and issuing the command for lightening the physical lamp of the case;
and the timer unit is used for triggering the state machine to enter lighting verification after the timer is overtime.
Optionally, the physical light of the chassis includes:
a positioning lamp, a warning lamp and a status lamp;
wherein the positioning lamp is used for positioning a storage device in use in a storage system;
the warning lamp is used for giving an alarm when the main power supply module fails;
the status light is used for displaying that the storage device successfully joins the cluster.
Optionally, the priority in the comparing unit includes:
the priority of the positioning lamp state is higher than that of the warning lamp state, and the priority of the state lamp state is higher than that of the physical lamp extinguishing state of the chassis.
Optionally, the verification lighting unit includes:
and when the state of the physical lamp of the case in the command is not consistent with the state of the physical lamp of the current case after the lighting verification step is repeated for multiple times, ending the verification process.
Compared with the prior art, the technical scheme of the application has the advantages that:
firstly, a storage system sets an independent check thread to read the actual state of the current chassis physical lamp, compares the priority of the state of the chassis physical lamp in a lighting command with the priority of the state of the current chassis physical lamp, if the priority of the state of the chassis physical lamp in the lighting command is not lower than the priority of the state of the current chassis physical lamp, triggers a state machine to carry out lighting check, starts a timer to time and issues the command for lighting the chassis physical lamp again when the check result is that the state of the chassis physical lamp in the command is not consistent with the expected state of the chassis physical lamp, and triggers the state machine to enter lighting check again after the timer is overtime until the lighting is successful. According to the technical scheme, the state of the physical lamp of the storage system cabinet can be checked in real time by combining the state machine and the timer, and consistency of the expected state of the physical lamp of the storage device cabinet and the actual state of the storage device is guaranteed by comparing priorities and issuing lighting commands for multiple times, so that reliability of the storage device is guaranteed, and risk of user data loss is reduced.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments described in the present application, and other drawings can be obtained by those skilled in the art without creative efforts.
Fig. 1 is a flowchart of a method for checking a physical lamp of a chassis provided in the present application;
fig. 2 is a flowchart of a method for checking a physical lamp of a chassis provided in the present application.
Detailed Description
In order to make the technical solutions of the present invention better understood, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Referring to fig. 1, fig. 1 is a flowchart of a method for checking a physical lamp of a chassis provided in the present application. Specifically, the method comprises the following steps:
and S101, the storage system issues a command for lighting one state of the physical lamp of the chassis.
And the storage system sends a command for lightening the state of the physical lamp of the chassis to the BMC firmware. For example, the storage system issues a command to the BMC firmware to turn on a red light in the physical light of the chassis, or the storage system issues a command to the BMC firmware to turn on a green light in the physical light of the chassis.
S102: and reading the actual state of the physical lamp of the current chassis by using a single check thread set by the storage system.
The storage system sets an independent check thread, and then the actual state of the current chassis physical lamp is read through the BMC by using the independent check thread.
S103: comparing the priority of the state of the chassis physical light in the command with the priority of the state of the current chassis physical light.
And S104, when the priority of the state of the physical lamp of the case in the command is not lower than the priority of the state of the physical lamp of the current case, triggering the state machine to enter lighting verification, and otherwise, ending the process.
The priority of each state of the physical lamp in the chassis may be set according to actual needs, and is not specifically limited in the embodiment.
S105: the status of the chassis physical lights in the command is compared to its expected status.
S106, when the state of the physical lamp of the case in the command is consistent with the expected state, ending the verification process; and when the state of the physical lamp of the case in the command is inconsistent with the expected state, starting a timer to time and issuing the command for lightening the physical lamp of the case.
To ensure that the physical light state of the cabinet that the user wants to light is consistent with the physical light state that should light.
S107: and judging whether the timer is overtime, and triggering the state machine to enter lighting verification when the timer is overtime, namely repeating the steps S104-S107 until the lighting is successful.
In order to explain the verification method proposed in the present application more clearly, the verification method proposed in the present application is further explained below with reference to fig. 2.
In one embodiment, the chassis physical lights may include, for example, a position light, a warning light, and a status light. Wherein the positioning lamp is used for positioning a storage device in use in a storage system; the warning lamp is used for giving an alarm when the main power supply module fails; the status light is used for displaying that the storage device successfully joins the cluster.
Referring to fig. 2, fig. 2 is a flowchart of a method for checking a physical lamp of a chassis provided in the present application. Specifically, the method comprises the following steps:
s201, the storage system sends a command of lightening the warning lamp.
S202: and reading the actual state of the physical lamp of the current chassis by using a single check thread set by the storage system.
The actual state of the current physical lamp of the chassis may be, for example, a blue positioning lamp, a red alarm lamp, a green status lamp, or an off status.
S203: and comparing the priority of the state of the warning lamp with the priority of the state of the physical lamp of the current chassis.
The priority of the positioning lamp state is higher than that of the warning lamp state, and the priority of the state lamp state is higher than that of the extinguishing state of the physical lamp of the chassis.
S204, when the priority of the warning lamp is not lower than that of the physical lamp of the current chassis, triggering a state machine to enter lighting verification; otherwise, the checking process is ended.
If the current physical lamp of the case is in an off state or a state lamp or an alarm lamp, triggering the state machine to enter lighting verification; if the physical lamp of the current case is the positioning lamp, the process is ended.
S205: and judging whether the states of the warning lamp and the current chassis physical lamp are consistent or not.
S206: when the states of the warning lamp and the current chassis physical lamp are consistent, ending the verification process; and when the states of the alarm lamp and the current chassis physical lamp are inconsistent, starting a timer to time and issuing a command for lightening the correct chassis physical lamp.
And if the current physical lamp of the case is the warning lamp, ending the verification process.
And if the current physical lamp of the case is in a state lamp or an off state, starting a timer to time and issuing a command of lightening an alarm lamp.
S207: and judging whether the timer is overtime, triggering the state machine to enter lighting verification after the timer is overtime, repeatedly starting the timer and issuing a command for lighting the alarm lamp, namely repeating the steps S204-S108 until the lighting is successful.
Because the lower module informs the upper module that the time is not fixed, the triggering scheme of the timer adopts a short-time checking and multi-time triggering mode, namely, after one-time checking is finished, the timer checking is stopped.
In some embodiments, the timer is still unsuccessful after being restarted for multiple times, and in order to avoid excessive occupation of CPU resources, the timer is not restarted any more, and personnel are directly informed to carry out hardware maintenance; and if the lighting is successful, the timer is stopped. The timer can be set to directly inform personnel of hardware maintenance when the timer is unsuccessfully restarted for 5 times, the restarting times are not limited in the invention, and the technical personnel in the field can set the restarting times according to actual needs.
In some embodiments, in the operating process of the chassis, after the BMC firmware is restarted due to a fault, the physical lamp is turned off, and when the storage device is in the cluster state to provide the storage service, the verification process of the physical lamp of the chassis is triggered.
In some embodiments, the storage system sets a separate check thread to poll the BMC at intervals to read the actual status of the current physical light. The polling may be set every 15 seconds, and the specific time is not limited in the present invention, and those skilled in the art may set the polling according to actual needs.
According to the scheme, whether the states of the physical lamp of the case and the current physical lamp of the case are consistent or not can be checked in real time, the states of the physical lamps of the case are accurately displayed, and a user can correctly know the actual states of the physical lamps of the case and safely use the storage equipment.
Based on the method provided by the above embodiment, the embodiment of the present invention further provides a corresponding apparatus, and the working principle of the apparatus is described in detail below with reference to the accompanying drawings.
Device embodiment
The invention provides a structure diagram of a checking device of a cabinet physical lamp, which comprises the following units:
the device comprises a command unit, a state reading unit, a priority comparison unit, a state machine unit, a lighting verification unit and a timer unit;
the command unit is used for sending a command for lightening one state of the physical lamp of the chassis by the storage system;
the state reading unit is used for reading the actual state of the physical lamp of the current chassis by utilizing the single check thread set by the storage system;
the priority comparison unit is used for comparing the priority of the state of the chassis physical lamp in the command with the priority of the state of the current chassis physical lamp;
the state machine unit is used for triggering the state machine to enter lighting verification when the priority of the state of the chassis physical lamp in the command is not lower than the priority of the state of the current chassis physical lamp;
the lighting verification unit is used for ending the verification process when the state of the physical lamp of the case in the command is consistent with the expected state of the physical lamp of the case; when the state of the physical lamp of the case in the command is inconsistent with the expected state of the physical lamp of the case, starting a timer to time and issuing the command for lightening the physical lamp of the case;
and the timer unit is used for triggering the state machine to enter lighting verification after the timer is overtime.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the apparatus embodiment, since it is substantially similar to the method embodiment, it is relatively simple to describe, and reference may be made to some descriptions of the method embodiment for relevant points. The above-described apparatus embodiments are merely illustrative, and the units and modules described as separate components may or may not be physically separate. In addition, some or all of the units and modules may be selected according to actual needs to achieve the purpose of the solution of the embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
The foregoing is directed to embodiments of the present invention, and it is understood that various modifications and improvements can be made by those skilled in the art without departing from the spirit of the invention.

Claims (10)

1. A method for verifying a physical lamp of a cabinet, the method comprising:
the storage system issues a command for lighting a physical lamp of the chassis in one state;
reading the actual state of the physical lamp of the current chassis by using an independent check thread set by a storage system;
comparing the priority of the state of the chassis physical lamp in the command with the priority of the state of the current chassis physical lamp, and triggering a state machine to enter lighting verification when the priority of the state of the chassis physical lamp in the command is not lower than the priority of the state of the current chassis physical lamp;
lighting checking: when the state of the chassis physical lamp in the command is consistent with the expected state, ending the verification process; when the state of the physical lamp of the case in the command is inconsistent with the expected state of the physical lamp of the case, starting a timer to time and issuing the command for lightening the physical lamp of the case;
and when the timer is overtime, triggering the state machine to enter lighting verification.
2. The verification method of claim 1, wherein the status of the physical lights of the chassis comprises:
a position light state, a warning light state, and a status light state.
3. Verification method according to claim 2, characterized in that said priority is:
the priority of the positioning lamp state is higher than that of the warning lamp state, and the priority of the state lamp state is higher than that of the physical lamp extinguishing state of the chassis.
4. The verification method according to claim 1, wherein the lighting verification step includes:
and when the state of the physical lamp of the case in the command is not consistent with the expected state after repeating the lighting verification step for multiple times, ending the verification process.
5. The verification method of claim 1, further comprising:
and in the operation process of the case, triggering a verification process of the physical lamp of the case when the physical lamp of the case is turned off after the restart of the hardware fault is judged and the storage equipment is in a cluster state to provide storage service.
6. The verification method of claim 1, wherein the storage system setting the individual verification threads to read the actual state of the current physical lamp comprises:
and the storage system sets an individual checking thread to poll and read the actual state of the current physical lamp at intervals.
7. A device for checking a physical lamp of a cabinet, the device comprising:
the device comprises a command unit, a state reading unit, a priority comparison unit, a state machine unit, a lighting verification unit and a timer unit;
the command unit is used for sending a command for lightening one state of the physical lamp of the chassis by the storage system;
the state reading unit is used for reading the actual state of the physical lamp of the current chassis by utilizing the single check thread set by the storage system;
the priority comparison unit is used for comparing the priority of the state of the chassis physical lamp in the command with the priority of the state of the current chassis physical lamp;
the state machine unit is used for triggering the state machine to enter lighting verification when the priority of the state of the chassis physical lamp in the command is not lower than the priority of the state of the current chassis physical lamp;
the lighting verification unit is used for ending the verification process when the state of the physical lamp of the case in the command is consistent with the expected state of the physical lamp of the case; when the state of the physical lamp of the case in the command is inconsistent with the expected state of the physical lamp of the case, starting a timer to time and issuing the command for lightening the physical lamp of the case;
and the timer unit is used for triggering the state machine to enter lighting verification after the timer is overtime.
8. The verification device of claim 7, wherein the chassis physical light comprises:
a positioning lamp, a warning lamp and a status lamp;
wherein the positioning lamp is used for positioning a storage device in use in a storage system;
the warning lamp is used for giving an alarm when the main power supply module fails;
the status light is used for displaying that the storage device successfully joins the cluster.
9. Checking apparatus according to claim 8, characterized in that the priority in the comparing unit comprises:
the priority of the positioning lamp state is higher than that of the warning lamp state, and the priority of the state lamp state is higher than that of the physical lamp extinguishing state of the chassis.
10. The verification device according to claim 7, wherein the verification lighting unit includes:
and when the state of the physical lamp of the case in the command is not consistent with the state of the physical lamp of the current case after the lighting verification step is repeated for multiple times, ending the verification process.
CN201910838559.4A 2019-09-05 2019-09-05 Method and device for checking physical lamp of case Withdrawn CN110633179A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910838559.4A CN110633179A (en) 2019-09-05 2019-09-05 Method and device for checking physical lamp of case

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910838559.4A CN110633179A (en) 2019-09-05 2019-09-05 Method and device for checking physical lamp of case

Publications (1)

Publication Number Publication Date
CN110633179A true CN110633179A (en) 2019-12-31

Family

ID=68970883

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910838559.4A Withdrawn CN110633179A (en) 2019-09-05 2019-09-05 Method and device for checking physical lamp of case

Country Status (1)

Country Link
CN (1) CN110633179A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022052407A1 (en) * 2020-09-11 2022-03-17 苏州浪潮智能科技有限公司 Device control method and system, electronic device, and storage medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022052407A1 (en) * 2020-09-11 2022-03-17 苏州浪潮智能科技有限公司 Device control method and system, electronic device, and storage medium

Similar Documents

Publication Publication Date Title
US20160212818A1 (en) Emergency lighting monitoring and reporting system
CN104133709B (en) The upgrade method and device of embedded system
CN101990226A (en) Automatic restart method, system and device for power failure
US11314665B2 (en) Information processing system, information processing device, BIOS updating method for information processing device, and BIOS updating program for information processing device
CN116685029B (en) Spliced lamp, controller thereof, configuration method and device
US8826078B2 (en) Computer system and diagnostic method thereof
US20230083327A1 (en) Systems and methods for system recovery
CN110633179A (en) Method and device for checking physical lamp of case
CN110445932B (en) Abnormal card dropping processing method and device, storage medium and terminal
CN111176897A (en) Closed BIOS self-repairing method, system, terminal and storage medium
CN111352662B (en) Server starting sequence control method, system, terminal and storage medium
CN111124785B (en) Method, device, equipment and storage medium for hard disk fault detection
TW202112577A (en) Charging device for electric vehicles, automatic troubleshooting method and computer program product
CN115102862A (en) Automatic synchronization method and device for SDN equipment
CN106550448B (en) Positioning method and positioning device
CN111010519B (en) Control method of display device, television and storage medium
US20200204403A1 (en) Electrical device that accesses a mobile telephony network in an alternative operating mode
CN113268400A (en) Synchronous flashing method and device for indicator lamp and server
CN107864414B (en) ONU customized version switching method and device, storage medium and computer equipment
CN114443446B (en) Hard disk indicator lamp control method, system, terminal and storage medium
CN117215859B (en) Main and standby BIOS automatic switching method, automatic switching device and computer
TW201617870A (en) Booting method
CN113824787B (en) Method for controlling restarting of terminal
CN112463548B (en) Server shared lamp control method, system, terminal and storage medium
CN116302844B (en) Method and device for acquiring hard disk information, computer equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
WW01 Invention patent application withdrawn after publication
WW01 Invention patent application withdrawn after publication

Application publication date: 20191231