CN106648014A - Server protection method and device based on Ethernet port sensing - Google Patents
Server protection method and device based on Ethernet port sensing Download PDFInfo
- Publication number
- CN106648014A CN106648014A CN201610813615.5A CN201610813615A CN106648014A CN 106648014 A CN106648014 A CN 106648014A CN 201610813615 A CN201610813615 A CN 201610813615A CN 106648014 A CN106648014 A CN 106648014A
- Authority
- CN
- China
- Prior art keywords
- server
- network interface
- power
- state
- down state
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F1/00—Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
- G06F1/26—Power supply means, e.g. regulation thereof
- G06F1/30—Means for acting in the event of power-supply failure or interruption, e.g. power-supply fluctuations
- G06F1/305—Means for acting in the event of power-supply failure or interruption, e.g. power-supply fluctuations in the event of power-supply fluctuations
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Power Sources (AREA)
Abstract
The invention provides a server protection method and device based on Ethernet port sensing. The method comprises the steps that 1, after a server is powered on, whether an Ethernet port of the server is powered down or not is detected; 2, when it is detected that the Ethernet port of the server is powered down, the state of the server is switched to emergency operation. According to the technical scheme, whether the state of the server is switched to emergency operation or not is judged by detecting the Ethernet port of the server; due to the fact that the device for detecting power-down of the Ethernet port of the server is arranged on the server, the server can directly acquire power-down information, data transmission is omitted, and cost for server power-down protection is saved.
Description
Technical field
The present invention relates to server power failure resist technology field, and in particular to a kind of server protection perceived based on network interface
Method and apparatus.
Background technology
Server is used as the core component processed in data center with data storage, and the reliability of its work is extremely important,
Especially when supply of electric power goes wrong, not losing for user data how is protected to be very crucial problem.At present this is asked
Topic is solved mainly by adding UPS in server front end that is, without power-supply system is interrupted.
In the also electric power system of UPS, civil power accesses first UPS, then by UPS again by power transmission to server,
When mains-supplied occurs abnormal, the electric power system of server is switched to stand-by power supply state by UPS.But UPS batteries
Electricity is limited, and server work a period of time can only be maintained after civil power power down, when the electricity of UPS batteries exhausts,
Server to be also possible that and lose significant data because of power down abnormal shutdown, and to user huge loss is brought.
Publication No. discloses a kind of method of server power failure protection system power down protection for the patent of CN101895414A,
It is that power loss detection means are set on UPS, when civil power power down is detected, UPS sends power down by RS232 interfaces to server
Information, server is received and switch to after power down information standby mode of operation, that is, carry out data and preserve and hot job process
Working condition, so as to realize the power down protection of server.The device of this method detection power down is arranged on UPS, therefore to make
Server learns power down information, needs to arrange communication connection between UPS and server, thus just causes server power failure
The increase of protection system cost.
The content of the invention
The present invention provides a kind of server guard method perceived based on network interface and device, above-mentioned due to UPS for solving
The problem for needing to arrange the cost increase that communication is connected and causes between server.
A kind of server guard method perceived based on network interface, is comprised the steps:
(1) on server after electricity, whether detection service device network interface is continuously in power-down state;
(2) when the state for detecting server network interface is to continue power-down state, server switches to standby mode of operation.
Further, judge that method of the server network interface in power-down state is continued is comprised the following steps:
(1) when the state for detecting server network interface is changed into power-down state, first timer starts timing;
(2) when the timing of first timer reaches very first time threshold value set in advance, judge that server network interface is in
Continue power-down state.
Further, the server guard method perceived based on network interface, is also included unstable when mains-supplied is detected
Regularly, the step of server switches to standby mode of operation.
Further, the method for judging that mains-supplied is unstable is comprised the following steps:
(1) first timer and the second counter are enabled after electricity on server;
(2) when the state for detecting server network interface is power-down state, first timer starts timing;
(3) before the timing of first timer reaches very first time threshold value set in advance, server network interface is by lower electric shape
When state is changed into power-up state, the count value of the second counter adds 1;
(4) when the count value of the second counter reaches the second digital threshold set in advance, it is judged as mains-supplied not
It is stable.
A kind of server protection device perceived based on network interface, including such as lower module:
On server after electricity, whether the physical internet ports of detection service device are continuously in the module of power-down state;
When the state for detecting server network interface is to continue power-down state, server switches to the mould of standby mode of operation
Block.
Further, judging the module of server network interface power-down state is included with lower unit:
When the state for detecting server network interface is changed into power-down state, first timer starts the unit of timing;
When the timing of first timer reaches very first time threshold value set in advance, judge that server network interface is continuously in
The unit of power-down state.
Further, the server protection device perceived based on network interface, is also included unstable when mains-supplied is detected
Regularly, server switches to the module of standby mode of operation.
Further, the module for judging that mains-supplied is unstable is included with lower unit:
On server after electricity, the unit of first timer and the second counter is enabled;
When the state for detecting server network interface is power-down state, first timer starts the unit of timing;
Before the timing of first timer reaches very first time threshold value set in advance, server network interface is become by power-down state
For power-up state when, the unit that the count value of the second counter adds 1;
When the count value of the second counter reaches the second digital threshold set in advance, it is judged as that mains-supplied is unstable
Unit.
The technical scheme that the present invention is provided is the physical internet ports state by detection service device judging whether server is cut
Standby mode of operation is shifted to, because the device of detection service device network interface power down is arranged on the server, server can be obtained directly
Power information is taken down, the link of data transfer is eliminated, therefore cost-effective purpose can be reached.
The effect of first timer there is provided the foundation that a kind of judgement server network interface continues power down, when server network interface
Occur for some reason the short time it is lower electric when, do not interfere with the judgement to server network interface power down, it is ensured that to server
The reliability that power supply judges.
The effect of first timer and the second counter there is provided a kind of basis for estimation for judging whether civil power is stable.Cause
It is that, when civil power is unstable, the power supply of server can be switched to stand-by power supply by UPS, now need the work of switching server
Make state.The use of the purpose of first timer and the second counter is to realize being allowed hand in civil power shakiness timing applications
To standby mode of operation, the further reliability for ensureing to judge server power supply.
Description of the drawings
Fig. 1 is the schematic diagram that server carries out electric power protection by UPS;
Fig. 2 is the flow chart of the server guard method perceived based on network interface;
Fig. 3 is the flow chart for detecting the unstable method of mains-supplied.
Specific embodiment
Server carries out the schematic diagram of electric power protection as shown in figure 1, civil power works as city by UPS connection servers by UPS
During electric power down, UPS can adopt stand-by power supply to power for server.Server is additionally provided with the network interface of the connection network equipment, and network sets
Standby is not obtain electric power by UPS, but directly obtains electric power from civil power.When power down or voltage instability occurs in civil power electric power
When, the supply of electric power of server can be temporarily switched to stand-by power supply by UPS, and the guarantor of UPS is not received in the supply of electric power of the network equipment
Shield, therefore when there is civil power power down, the network equipment can descend electricity, so as to cause server to connect the network interface power down of the network equipment.
Whether power down can be obtained server network interface by following steps:
(1) network interface information inspection order is run on the server, by the result found output to physical file;
(2) physical file to obtaining is analyzed, and extracts the up/down electricity condition information of server network interface;
(3) the current up/down electricity condition information of the server for extracting is entered with the last up/down electricity condition information extracted
Row compares, if information is different, the up/down electricity condition of server network interface changes.
Based on above-mentioned principle, the present invention provides a kind of server guard method perceived based on network interface and device, by inspection
In power-up state or power-down state, whether the power supply for judging server is stand-by power supply to survey grid mouth.When server
When power supply is stand-by power supply, server switches to standby mode of operation, that is, carry out data preservation and the process of emergency data
Working condition, so as to protect server.The present invention is described in detail below in conjunction with the accompanying drawings.
Embodiment of the method:
The present invention provides a kind of server guard method perceived based on network interface, and the basic scheme of the method includes following step
Suddenly:
(1) on server after electricity, whether detection service device network interface is completely in lasting power-down state;
(2) when the state for detecting server network interface is to continue power-down state, server switches to standby mode of operation.
Above-mentioned to compare the prior art that civil power power loss detection means are arranged on UPS for basic scheme, the present invention is by inspection
Survey the power-down state of server network interface to judge whether server switches to standby mode of operation, detection detection service device network interface falls
The device of electricity is arranged on the server, and server can eliminate the link of data transfer with direct access power down information, therefore can
To reach cost-effective purpose.
Whether above-mentioned detection service device network interface is in power-down state, the flow chart of its determination methods as shown in Fig. 2 including with
Lower step:
(1) on server server network interface is detected after electricity;When the network interface for detecting server is completely in lower electricity
During state, first timer starts timing;
(2) before very first time timer reaches very first time threshold value set in advance, in above-mentioned network interface is detected
When the state of any one network interface is changed into power-up state, reset first timer;
(3) judge whether first timer timing reaches very first time threshold value set in advance, when first timer reaches
During very first time threshold value, then judge server network interface in lasting power-down state;
(4) when server network interface is in lasting power-down state, civil power power down is illustrated, the power supply of server is standby
Power supply;Now server switches to standby mode of operation, hot job is processed and data are preserved, while first
Timer resets.
In the present embodiment, the effect of first timer is to provide foundation to judge that server network interface continues power down, it is to avoid
There is false judgment, such as when server network interface is in power-down state for some reason and temporarily, if being not provided with first
Timer, just makes the mistake of server network interface power down, affects the stability of server operation.As other embodiment, such as
When the performance of server network interface is highly stable, first timer can be not provided with, when server network interface is in power-down state, directly
Connect and judge server network interface power down.
Because when mains-supplied is unstable, the power supply of server can also switch to stand-by power supply, in mains-supplied
Unstable timing applications are also required to switch to standby mode of operation.So, present invention also offers a kind of mains-supplied is unstable
Determination methods, its flow chart is as shown in figure 3, comprise the following steps:
(1) counter of first timer second is enabled after electricity on server;
(2) before the timing of first timer reaches very first time threshold value set in advance, server network interface is by lower electric shape
When state is changed into power-up state, the count value of the second counter adds 1;
(3) when the timing in first timer reaches very first time threshold value set in advance, the value of the second counter resets;
(4) when the count value of the second counter reaches the second digital threshold set in advance, it is judged as mains-supplied not
Stable, now server switches to standby mode of operation, hot job is processed and data are preserved, while second
Counter resets.
In the present embodiment, the effect of the counter of first timer second be to provide the unstable judgement of mains-supplied according to
According to.The judgement that hypothesis is not provided with to mains-supplied stability, due to when mains-supplied is unstable, the power supply of server
For stand-by power supply, therefore in the case where mains-supplied long-time is unstable, when the electric energy of stand-by power supply exhausts, server is also
It is to lose data, is that user brings loss.Therefore, the step of arranging to mains-supplied judgement of stability makes the solution of the present invention
It is more perfect.
Device embodiment
A kind of server protection device perceived based on network interface, including such as lower module:
On server after electricity, whether detection service device network interface is in the module of power-down state;
When the state for detecting server network interface is power-down state, server switches to the module of standby mode of operation.
A kind of server protection device perceived based on network interface that the present embodiment is provided, actually realizes said method reality
The software architecture of example is applied, module therein is software module, may be located at RAM memory, flash memory, ROM memory, EPROM and deposits
Reservoir, eeprom memory, register or other can store on the medium of data.
Specific embodiment according to the present invention is presented above, but the present invention is not limited to described embodiment.
Under the thinking that the present invention is given, to the skill in above-described embodiment by the way of being readily apparent that to those skilled in the art
Art means enter line translation, replacement, modification, and play a part of, realization essentially identical with the relevant art means in the present invention
Goal of the invention it is also essentially identical, so formed technical scheme above-described embodiment is finely adjusted to be formed, this technology
Scheme is still fallen within protection scope of the present invention.
Claims (8)
1. a kind of server guard method perceived based on network interface, it is characterised in that comprise the steps:
(1) on server after electricity, whether detection service device network interface is continuously in power-down state;
(2) when the state for detecting server network interface is to continue power-down state, server switches to standby mode of operation.
2. a kind of server guard method perceived based on network interface according to claim 1, it is characterised in that judge service
Method of the device network interface in power-down state is continued is comprised the following steps:
(1) when the state for detecting server network interface is changed into power-down state, first timer starts timing;
(2) when the timing of first timer reaches very first time threshold value set in advance, judge server network interface in lasting
Power-down state.
3. a kind of server guard method perceived based on network interface according to claim 1, it is characterised in that described to be based on
The server guard method that network interface is perceived, also includes that server switches to emergency when detecting mains-supplied and being unstable
The step of state.
4. a kind of server guard method perceived based on network interface according to claim 3, it is characterised in that the judgement
The unstable method of mains-supplied is comprised the following steps:
(1) first timer and the second counter are enabled after electricity on server;
(2) when the state for detecting server network interface is power-down state, first timer starts timing;
(3) before the timing of first timer reaches very first time threshold value set in advance, server network interface is become by power-down state
For power-up state when, the count value of the second counter adds 1;
(4) when the count value of the second counter reaches the second digital threshold set in advance, it is judged as that mains-supplied is unstable.
5. it is a kind of based on network interface perceive server protection device, it is characterised in that include such as lower module:
On server after electricity, whether the physical internet ports of detection service device are continuously in the module of power-down state;
When the state for detecting server network interface is to continue power-down state, server switches to the module of standby mode of operation.
6. it is according to claim 5 it is a kind of based on network interface perceive server protection device, it is characterised in that judge service
The module of device network interface power-down state is included with lower unit:
When the state for detecting server network interface is changed into power-down state, first timer starts the unit of timing;
When the timing of first timer reaches very first time threshold value set in advance, judge that server network interface is continuously in power down
The unit of state.
7. it is according to claim 5 it is a kind of based on network interface perceive server protection device, it is characterised in that it is described to be based on
The server protection device that network interface is perceived, also includes that server switches to emergency when detecting mains-supplied and being unstable
The module of state.
8. it is according to claim 7 it is a kind of based on network interface perceive server protection device, it is characterised in that the judgement
The unstable module of mains-supplied is included with lower unit:
On server after electricity, the unit of first timer and the second counter is enabled;
When the state for detecting server network interface is power-down state, first timer starts the unit of timing;
Before the timing of first timer reaches very first time threshold value set in advance, on server network interface is changed into from power-down state
During electricity condition, the unit that the count value of the second counter adds 1;
When the count value of the second counter reaches the second digital threshold set in advance, it is judged as the unstable list of mains-supplied
Unit.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610813615.5A CN106648014B (en) | 2016-09-09 | 2016-09-09 | Server protection method and device based on internet access perception |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610813615.5A CN106648014B (en) | 2016-09-09 | 2016-09-09 | Server protection method and device based on internet access perception |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106648014A true CN106648014A (en) | 2017-05-10 |
CN106648014B CN106648014B (en) | 2020-01-03 |
Family
ID=58852020
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610813615.5A Active CN106648014B (en) | 2016-09-09 | 2016-09-09 | Server protection method and device based on internet access perception |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106648014B (en) |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101655733A (en) * | 2009-09-08 | 2010-02-24 | 中山冠虹电子有限公司 | Method and device for collocating uninterruptible power supply to enable computer to safely hibernate during power cut |
CN101841232A (en) * | 2010-03-02 | 2010-09-22 | 北京星网锐捷网络技术有限公司 | Redundancy backup processing method and redundancy backup control circuit of capacitor |
CN101895414A (en) * | 2010-06-24 | 2010-11-24 | 苏州飞鱼星电子技术有限公司 | System and method for power off protection of server |
US8018349B1 (en) * | 2009-04-29 | 2011-09-13 | Cisco Technology, Inc. | Detecting an inline power shutoff failure |
CN103780411A (en) * | 2012-10-19 | 2014-05-07 | 任子行网络技术股份有限公司 | Power-down protection system and method for network auditing device |
CN203720832U (en) * | 2013-10-21 | 2014-07-16 | 云海创想信息技术(北京)有限公司 | Server with backup power supply device |
CN204362075U (en) * | 2014-11-25 | 2015-05-27 | 中国移动通信集团海南有限公司 | A kind of power loss detection means |
CN205263744U (en) * | 2015-12-10 | 2016-05-25 | 夏立堃 | Server power down protection system |
-
2016
- 2016-09-09 CN CN201610813615.5A patent/CN106648014B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US8018349B1 (en) * | 2009-04-29 | 2011-09-13 | Cisco Technology, Inc. | Detecting an inline power shutoff failure |
CN101655733A (en) * | 2009-09-08 | 2010-02-24 | 中山冠虹电子有限公司 | Method and device for collocating uninterruptible power supply to enable computer to safely hibernate during power cut |
CN101841232A (en) * | 2010-03-02 | 2010-09-22 | 北京星网锐捷网络技术有限公司 | Redundancy backup processing method and redundancy backup control circuit of capacitor |
CN101895414A (en) * | 2010-06-24 | 2010-11-24 | 苏州飞鱼星电子技术有限公司 | System and method for power off protection of server |
CN103780411A (en) * | 2012-10-19 | 2014-05-07 | 任子行网络技术股份有限公司 | Power-down protection system and method for network auditing device |
CN203720832U (en) * | 2013-10-21 | 2014-07-16 | 云海创想信息技术(北京)有限公司 | Server with backup power supply device |
CN204362075U (en) * | 2014-11-25 | 2015-05-27 | 中国移动通信集团海南有限公司 | A kind of power loss detection means |
CN205263744U (en) * | 2015-12-10 | 2016-05-25 | 夏立堃 | Server power down protection system |
Non-Patent Citations (1)
Title |
---|
张新林等: ""虚拟服务器在断电时的自我保护方法研究"", 《计算机与现代化》 * |
Also Published As
Publication number | Publication date |
---|---|
CN106648014B (en) | 2020-01-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11631981B2 (en) | Power adapter, terminal, and method for processing impedance anomalies in charging loop | |
CN102750248B (en) | A kind of USB device Working mode switching method and USB device | |
US10491033B2 (en) | Method for hot-plugging, control device for hot-plugging, method and device for voltage balance | |
CN205538070U (en) | Electronic equipment and detecting system entries thereof | |
CN106066450A (en) | There is the insulation monitor of voltage monitoring and method based on it | |
CN103135732B (en) | Server cabinet system | |
CN106814324B (en) | Method and device for monitoring the operating state of a battery pack | |
CN101867468A (en) | Hot reboot processing method for power over Ethernet switch and power over Ethernet switch | |
US11011905B2 (en) | Fall-off protection and reverse-connection protection system and method for connecting clamp of automobile starting power supply | |
CN107425986A (en) | A kind of method and device of POE power protection | |
CN105204486B (en) | A kind of control method of water cooling system main circulation pump | |
US10516260B2 (en) | Multi-node system fault management | |
CN109412819A (en) | Method and device for warning device power down | |
CN106648014A (en) | Server protection method and device based on Ethernet port sensing | |
CN110488205B (en) | Fault recognition device | |
CN104467167A (en) | Power source path management circuit | |
CN104680087B (en) | A kind of control circuit and device of blade server hot plug | |
CN102810840B (en) | Voltage protection system | |
CN104486262A (en) | Control method and device for achieving Dying Gasp based on switch chip | |
CN108388332A (en) | A kind of server power-off protection method and system | |
WO2017049897A1 (en) | Battery inspection method and apparatus | |
CN104577945B (en) | A kind of directionality current protection method and device | |
CN206075133U (en) | A kind of stand-by heat controller | |
CN203406889U (en) | Internet access BYPASS system capable of setting equipment fault flexibly when power is down | |
CN203084736U (en) | Computer network safety control system |
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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |