Movatterモバイル変換


[0]ホーム

URL:


CN105939228A - Health detection method and device - Google Patents

Health detection method and device
Download PDF

Info

Publication number
CN105939228A
CN105939228ACN201510535755.6ACN201510535755ACN105939228ACN 105939228 ACN105939228 ACN 105939228ACN 201510535755 ACN201510535755 ACN 201510535755ACN 105939228 ACN105939228 ACN 105939228A
Authority
CN
China
Prior art keywords
service node
node
service
health detection
class
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
Application number
CN201510535755.6A
Other languages
Chinese (zh)
Other versions
CN105939228B (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.)
Hangzhou DPTech Technologies Co Ltd
Original Assignee
Hangzhou DPTech 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 DPTech Technologies Co LtdfiledCriticalHangzhou DPTech Technologies Co Ltd
Priority to CN201510535755.6ApriorityCriticalpatent/CN105939228B/en
Publication of CN105939228ApublicationCriticalpatent/CN105939228A/en
Application grantedgrantedCritical
Publication of CN105939228BpublicationCriticalpatent/CN105939228B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Classifications

Landscapes

Abstract

The invention provides a health detection method and device, applied to gateway equipment. The gateway equipment performs health detection of multiple servers; and the servers are configured with multiple same service nodes. The method comprises the following steps of: obtaining node information of each service node; classifying the service nodes according to the node information; selecting one service node from each class of service nodes to perform health detection; and sharing a health detection result to other service nodes in the same class of service nodes. According to the health detection method and device disclosed by the invention, system resource consumption of the gateway equipment and the servers can be reduced.

Description

A kind of health detecting method and device
Technical field
The application relates to network communication technology field, particularly relates to a kind of health detecting method and device.
Background technology
The management of application delivery gateway device main charge server cluster, is calculated by selected load balancingThe service request of user is balancedly distributed to service server by method.But, selected by load-balancing algorithmThe server selected is likely to be due to various reasons cannot process the service request of user, and the business causing user pleaseTry to achieve less than response, it is impossible to carry out normal Business Processing.
In order to solve the problems referred to above, on application delivery gateway device, generally enable health detection process to clothesService node on business device detects, to guarantee that server is properly functioning.Prior art is for oftenOne service node is set up corresponding Socket (socket) and is connected, and is connected by Socket and initiates to access,And the response of waiting for server, thus obtain the health status of server.But, in actual applications,The multiple identical service node of same server possible configuration, if carried out for each service nodeHealth detection will result in unnecessary system resource waste.
Summary of the invention
In view of this, the application provides a kind of health detecting method and device.
Specifically, the application is achieved by the following technical solution:
The application provides a kind of health detecting method, is applied on gateway device, and described gateway device is to manyStation server carries out health detection, and described server configures multiple identical service node, the method bagInclude:
Obtain the nodal information of each service node;
According to nodal information, service node is classified;
A service node is selected to carry out health detection from each class service node;
By health detection result-sharing to other service node in same class service node.
The application also provides for a kind of health test apparatus, is applied on gateway device, described gateway device pairMultiple servers carries out health detection, and described server configures multiple identical service node, this deviceIncluding:
Acquiring unit, for obtaining the nodal information of each service node;
Taxon, for classifying to service node according to nodal information;
Detector unit, for selecting a service node to carry out health detection from each class service node;
Shared cell, for saving health detection result-sharing to other service in same class service nodePoint.
By above description it can be seen that the application is by classifying to service node, service from each classNode selects a service node carry out health detection, testing result is shared to its in same classificationIts service node, thus reduce the quantity that Socket connects, reduce system consumption, also mitigate meanwhileThe performance pressures of server end.
Accompanying drawing explanation
Fig. 1 is that server cluster manages system schematic;
Fig. 2 is a kind of health detecting method flow chart shown in the application one exemplary embodiment;
Fig. 3 is the basis of a kind of health test apparatus place equipment shown in the application one exemplary embodimentHardware architecture diagram;
Fig. 4 is the structural representation of a kind of health test apparatus shown in the application one exemplary embodiment.
Detailed description of the invention
Here will illustrate exemplary embodiment in detail, its example represents in the accompanying drawings.FollowingWhen description relates to accompanying drawing, unless otherwise indicated, the same numbers in different accompanying drawings represents same or analogousKey element.Embodiment described in following exemplary embodiment does not represent the institute consistent with the applicationThere is embodiment.On the contrary, they only with as appended claims describes in detail, the one of the applicationThe example of the apparatus and method that a little aspects are consistent.
It is only merely for describing the purpose of specific embodiment at term used in this application, and is not intended to be limitingThe application." a kind of " of singulative used in the application and appended claims, " instituteState " and " being somebody's turn to do " be also intended to include most form, unless context clearly shows that other implications.Also shouldWork as understanding, term "and/or" used herein refer to and comprise one or more be associated list itemAny or all possible combination of purpose.
Although should be appreciated that may use term first, second, third, etc. various to describe in the applicationInformation, but these information should not necessarily be limited by these terms.These terms only be used for by same type of information thatThis distinguishes.Such as, in the case of without departing from the application scope, the first information can also be referred to asTwo information, similarly, the second information can also be referred to as the first information.Depend on linguistic context, as in this instituteUse word " if " can be construed to " and ... time " or " when ... time " or " responseIn determining ".
Fig. 1 show server cluster management system schematic.Wherein, PC is subscriber's main station, is used for visitingAsk server;GW is application delivery gateway device (hereinafter referred to as gateway device), is mainly responsible for serviceThe management of device cluster;Server1 and Server 2 is server, and each station server is configured with multiple phaseSame service node.Such as, the service node 1 on Server1 is identical with service node 2, and port numbers is equalBeing 80, subordinate server IP address is 1.1.1.1.In like manner, the service node 3 on Server 2, serviceNode 4 and service node 5 are identical.
In server set cluster management system, gateway device is responsible for using according to selected load-balancing algorithmThe service request at family balancedly distributes to server.In order to ensure that the server of distribution can be properly functioning,Gateway device to carry out health detection to each station server.
Prior art, when carrying out health detection, is set up with each service node by gateway deviceSocket connects, and is connected by each Socket and initiates to access, obtains the health detection result of correspondence.But, under the collocation method shown in Fig. 1, each server has multiple identical service node, asEach service node is set up Socket connection and is carried out health detection by fruit, will consume substantial amounts of system undoubtedlySystem resource.
For the problems referred to above, the embodiment of the present application proposes a kind of health detecting method, and the method is by clothesBusiness node is classified, and selects a service node to carry out health detection from each class service node, willTesting result shares to other service node in same classification, thus reduces the quantity that Socket connects,Reduce system consumption, meanwhile, also mitigate the performance pressures of server end.
Seeing Fig. 2, for an embodiment flow chart of the application health detecting method, this embodiment is to strongHealth detection process is described.
Step 201, obtains the nodal information of each service node.
Gateway device configures corresponding health detection rule for each service node in advance, and such as, this is good forHealth detected rule can be: uses TCP (Transmission Control Protocol, transmission control protocol)Mode detects.The most also other detection mode, such as UDP (User Datagram Protocol,User Datagram Protocol) mode, SLP (Service Location Protocol, Service Location Protocol) sideFormulas etc., can according to the actual requirements, the health detection rule differently configured to different service nodes.
After completing the configuration of the health detection rule to all service nodes, start health detection process, obtainTaking the nodal information of each server node, this nodal information can include health detection rule, serviceThe IP address of node subordinate server and port numbers etc..Nodal information according to the service node obtained entersRow subsequent treatment.
Step 202, classifies to service node according to nodal information.
The service node with same node point information is classified as a class, particularly as follows:
Perform following sort operation: order selects a unlabelled service node, by these unlabelled clothesBusiness vertex ticks is the execution node of current class.
Perform following vertex ticks of sharing to operate: order selects next unlabelled service node, it is judged thatThis next unlabelled service node is the most identical with the nodal information performing node of current class, ifIdentical, then this next unlabelled service node is labeled as the shared node of current class.
Judge whether that vertex ticks operation is shared in all equal executeds of unlabelled service node, if it is not, thenReturn and perform to share vertex ticks operation;The most then complete the classification to a class service node.
Judge whether the most unlabelled service node;If having, then return and perform sort operation;If nothing,Then complete the classification of all service nodes.
Step 203, selects a service node to carry out health detection from each class service node.
The service node with same node point information is classified as a class by step 202, will be configured withThe service node of identical health detection rule, same server IP address and same side slogan is classified as a class,Now, select wherein any one service node to carry out health monitoring, all can get the healthy shape of serverCondition.In a preferred embodiment, holding in each class service node after gateway device selects to sort outRow node carries out health monitoring.
Step 204, by health detection result-sharing to other service node in same class service node.
Got the health detection result of execution node by step 203 after, by each class service nodePerform node health detection result share to other service node in same class service node respectively.In a preferred embodiment, gateway device will perform the health detection result-sharing of node to sameShared node in class service node.
By foregoing description it can be seen that the application does not carry out health detection to each service node,But be first according to nodal information and sort out, then it is subordinated in multiple service nodes of same classification selectOne service node carries out health detection, and other service node in same classification shares detected serviceThe testing result of node.Thus decrease between gateway device and server the Socket for health detectionConnect quantity, reduce the system resources consumption of gateway device and server.
The most still as a example by Fig. 1, health detection process is discussed in detail.
It is assumed that gateway device GW is respectively service node 1~service node 5 configures health detection rule,Wherein, the health detection rule of service node 1 and service node 2 is TCP detection;Service node 3,The health detection rule of service node 4 and service node 5 is SLP detection.
Gateway device GW starts health detection process, obtains the nodal information of each service node, asShown in table 1.
NodenameHealth detection ruleIP addressPort numbers
Service node 1TCP detects1.1.1.180
Service node 2TCP detects1.1.1.180
Service node 3SLP detects2.2.2.28080
Service node 4SLP detects2.2.2.28080
Service node 5SLP detects2.2.2.28080
Table 1
Above-mentioned service node is sorted out by gateway device.First, it is labeled as performing joint by service node 1Point, it is judged that service node 2 whether with the nodal information of service node 1 (health detection rule, IP address,Port numbers) identical, as shown in Table 1, service node 2 is identical with the nodal information of service node 1, because ofThis, be labeled as service node 2 sharing node.
Order judges that service node 3 is the most identical with the nodal information of service node 1, as shown in Table 1,Service node 3 differs with the nodal information of service node 1, and therefore, service node 3 cannot function as clothesThe shared node of business node 1, is not belonging to same class service node.In like manner, service node 4, service jointPoint 5 is not the shared node of service node 1.
After classifying the first time of above-mentioned service node, service node 1 and service node 2 are sameClass service node, and service node 1 is for performing node, service node 2 is for sharing node.
Starting second time classification, from table 1, order selects a unlabelled service node, i.e. services jointPoint 3, is labeled as service node 3 the execution node of current class, selects next unlabelled serviceNode, i.e. service node 4, it is judged that service node 4 is the most identical with the nodal information of service node 3,As shown in Table 1, service node 4 is identical with the nodal information of service node 3, therefore, by service nodeThe 4 shared nodes being labeled as current class.In like manner, service node 5 is labeled as sharing of current classNode.
After completing above-mentioned double classification, all service nodes are the most marked, wherein, and service node 1 HeService node 3 is for performing node, and gateway device is only set up Socket with execution node and is connected, and sends healthProbe messages carries out health detection, if server normal operation, will respond the detection of gateway device, fromAnd make gateway device confirmed service device normal operation.
Health detection result-sharing, after obtaining the health detection result performing node, is given same by gateway deviceShared node in one classification.Such as, by the health detection result-sharing of service node 1 to service node2, by the health detection result-sharing of service node 3 to service node 4 and service node 5.
Corresponding with the embodiment of aforementioned health detecting method, present invention also provides health test apparatusEmbodiment.
The embodiment of the application health test apparatus can be applied on gateway device.Device embodiment is permissibleRealized by software, it is also possible to realize by the way of hardware or software and hardware combining.Implemented in software it isExample, as the device on a logical meaning, is by the processor run memory of its place equipmentCorresponding computer program instructions is formed.For hardware view, as it is shown on figure 3, be good for for the applicationA kind of hardware structure diagram of health detection device place equipment, except the processor shown in Fig. 3, network interface,And outside memorizer, in embodiment, the equipment at device place is generally according to the actual functional capability of this equipment, alsoOther hardware can be included, this is repeated no more.
Refer to Fig. 4, for the structural representation of the health test apparatus in one embodiment of the application.ShouldHealth test apparatus includes acquiring unit 401, taxon 402, detector unit 403 and shared cell404, wherein:
Acquiring unit 401, for obtaining the nodal information of each service node;
Taxon 402, for classifying to service node according to nodal information;
Detector unit 403, for selecting a service node to carry out healthy inspection from each class service nodeSurvey;
Shared cell 404, for taking health detection result-sharing to other in same class service nodeBusiness node.
Further, described taxon 402, including:
Perform vertex ticks module, for sequentially selecting a unlabelled service node;Do not mark describedThe service node of note is labeled as the execution node of current class;
Share vertex ticks module, for sequentially selecting next unlabelled service node;Judge describedNext unlabelled service node is the most identical with the nodal information performing node of described current class;If identical, then unlabelled for described next one service node is labeled as the shared node of described current class;
Service node judge module, is used for judging whether that all equal executeds of unlabelled service node are sharedVertex ticks operates, and shares vertex ticks module if it is not, then return;The most then complete a class serviceThe classification of node;Judge whether the most unlabelled service node;If having, then return and perform vertex ticksModule;If nothing, then complete the classification of all service nodes.
Further,
Described detector unit 403, specifically for selecting the execution node in each class service node to be good forHealth detects.
Described shared cell 404, same specifically for the health detection result-sharing of described execution node is givenShared node in one class service node.
Further,
Described nodal information includes health detection rule, the IP address of service node subordinate server and endSlogan.
In said apparatus, the function of unit and the process that realizes of effect specifically refer in said method correspondingStep realize process, do not repeat them here.
For device embodiment, owing to it corresponds essentially to embodiment of the method, so relevant part ginsengSee that the part of embodiment of the method illustrates.Device embodiment described above is only schematically,The wherein said unit illustrated as separating component can be or may not be physically separate, makeesThe parts shown for unit can be or may not be physical location, i.e. may be located at a place,Or can also be distributed on multiple NE.Can select according to the actual needs part therein orThe whole module of person realizes the purpose of the application scheme.Those of ordinary skill in the art are not paying creativenessIn the case of work, i.e. it is appreciated that and implements.
The foregoing is only the preferred embodiment of the application, not in order to limit the application, all at thisWithin the spirit of application and principle, any modification, equivalent substitution and improvement etc. done, should be included inWithin the scope of the application protection.

Claims (8)

CN201510535755.6A2015-08-272015-08-27A kind of health detecting method and deviceActiveCN105939228B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201510535755.6ACN105939228B (en)2015-08-272015-08-27A kind of health detecting method and device

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201510535755.6ACN105939228B (en)2015-08-272015-08-27A kind of health detecting method and device

Publications (2)

Publication NumberPublication Date
CN105939228Atrue CN105939228A (en)2016-09-14
CN105939228B CN105939228B (en)2019-02-19

Family

ID=57152826

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201510535755.6AActiveCN105939228B (en)2015-08-272015-08-27A kind of health detecting method and device

Country Status (1)

CountryLink
CN (1)CN105939228B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN106254542A (en)*2016-09-272016-12-21杭州迪普科技有限公司The method and device that a kind of flowing of access controls
CN111341445A (en)*2020-02-052020-06-26网宿科技股份有限公司 Health detection method and health detection system of microservice call chain
CN111835576A (en)*2019-04-192020-10-27厦门网宿有限公司DPVS-based back-end server health detection method and server

Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN101340327A (en)*2008-08-212009-01-07腾讯科技(深圳)有限公司Method, system and domain name parsing server implementing load balance of network server
CN102088720A (en)*2009-12-042011-06-08中国移动通信集团公司Method, system and equipment for monitoring network elements in IP multimedia subsystem (IMS) network
US20130179567A1 (en)*2000-07-202013-07-11Akamai Technologies, Inc.Network performance monitoring in a content delivery system

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20130179567A1 (en)*2000-07-202013-07-11Akamai Technologies, Inc.Network performance monitoring in a content delivery system
CN101340327A (en)*2008-08-212009-01-07腾讯科技(深圳)有限公司Method, system and domain name parsing server implementing load balance of network server
CN102088720A (en)*2009-12-042011-06-08中国移动通信集团公司Method, system and equipment for monitoring network elements in IP multimedia subsystem (IMS) network

Cited By (5)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN106254542A (en)*2016-09-272016-12-21杭州迪普科技有限公司The method and device that a kind of flowing of access controls
CN111835576A (en)*2019-04-192020-10-27厦门网宿有限公司DPVS-based back-end server health detection method and server
CN111835576B (en)*2019-04-192022-03-04厦门网宿有限公司DPVS-based back-end server health detection method and server
CN111341445A (en)*2020-02-052020-06-26网宿科技股份有限公司 Health detection method and health detection system of microservice call chain
CN111341445B (en)*2020-02-052024-04-16网宿科技股份有限公司 Health detection method and health detection system of microservice call chain

Also Published As

Publication numberPublication date
CN105939228B (en)2019-02-19

Similar Documents

PublicationPublication DateTitle
CN105279027B (en)A kind of virtual machine deployment method and device
CN103227754B (en)Dynamic load balancing method of high-availability cluster system, and node equipment
EP3596600B1 (en)Systems and methods for compute node management protocols
KR100998307B1 (en) Distributed Rule Processing for Ubiquitous Computing Environments
CN112602304A (en)Identifying device types based on behavioral attributes
CN104579996A (en)Cluster load balancing method and system
US20150106787A1 (en)Elastic application framework for deploying software
WO2015168312A1 (en)Method and system for providing reference architecture pattern-based permissions management
CN108683668A (en)Resource checksum method, apparatus, storage medium and equipment in content distributing network
CN107315756B (en) A log processing method and device
CN105939228A (en)Health detection method and device
CN112953982B (en)Service processing method, service configuration method and related device
CN105939405A (en)DHCP service processing method and device
CN104702439B (en)The method and apparatus for monitoring network node
CN106603330A (en) A method for checking the connection status of a virtual machine on a cloud platform
CN108764374A (en)Image classification method, system, medium and electronic equipment
CN107547643A (en)A kind of load sharing method and device
CN114461401A (en)Resource scheduling method and device, electronic equipment and storage medium
CN106685708B (en) Method, device and system for determining service relationship
US20070118655A1 (en)Network-based autodiscovery system for mac forwarding dispatcher
WO2004049669A3 (en)Method and appliance for distributing data packets sent by a computer to a cluster system
CN110782211A (en)Data processing method and device, electronic equipment and storage medium
CN116743836A (en)Long connection communication link establishment method and device, electronic equipment and storage medium
CN111182474B (en)Method for determining social relationship and related device
CN106230657A (en)A kind of data push method and supplying system thereof

Legal Events

DateCodeTitleDescription
C06Publication
PB01Publication
C10Entry into substantive examination
SE01Entry into force of request for substantive examination
CB02Change of applicant information
CB02Change of applicant information

Address after:Binjiang District and Hangzhou city in Zhejiang Province Road 310051 No. 68 in the 6 storey building

Applicant after:Hangzhou Dipu Polytron Technologies Inc

Address before:Binjiang District and Hangzhou city in Zhejiang Province Road 310051 No. 68 in the 6 storey building

Applicant before:Hangzhou Dipu Technology Co., Ltd.

GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp