CN106506693A - The method and apparatus for deleting server from the server cluster that cloud service is provided - Google Patents
The method and apparatus for deleting server from the server cluster that cloud service is provided Download PDFInfo
- Publication number
- CN106506693A CN106506693A CN201611132398.XA CN201611132398A CN106506693A CN 106506693 A CN106506693 A CN 106506693A CN 201611132398 A CN201611132398 A CN 201611132398A CN 106506693 A CN106506693 A CN 106506693A
- Authority
- CN
- China
- Prior art keywords
- server
- service
- identification information
- association
- cluster
- 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
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1001—Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/10—Protocols in which an application is distributed across nodes in the network
- H04L67/1001—Protocols in which an application is distributed across nodes in the network for accessing one among a plurality of replicated servers
- H04L67/1031—Controlling of the operation of servers by a load balancer, e.g. adding or removing servers that serve requests
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/14—Session management
- H04L67/146—Markers for unambiguous identification of a particular session, e.g. session cookie or URL-encoding
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Computer And Data Communications (AREA)
Abstract
The invention discloses a kind of method and apparatus for deleting server from the server cluster for providing cloud service.The method includes:Create an information list;It is saved in corresponding with the identification information of the service associated by each server for each server identification information in server cluster in information list;When needing to delete a server in server cluster, the identification information of the service associated by the server is inquired from information list, determine each service of the server association;For each service of the server association, the identification information according to the service for inquiring finds the information being associated with the server of the service, and the information according to association carries out deleting preparation process;After completing to delete preparation process, the server is deleted from server cluster.The present invention is when server is deleted, it is not necessary to all services in traversal server cluster, and whole process is simple, running occupancy resource is little, efficiency high.
Description
Technical field
The present invention relates to field of computer technology, and in particular to a kind of deletion from the server cluster for providing cloud service takes
The method and apparatus of business device.
Background technology
In the environment of privately owned cloud service, every server in server cluster may all provide multiple business or many
The service of individual user.When the virtual machine in a server or server is deleted, in order to prevent to whole clothes
The service business of business device cluster produces impact, needs the phase in the service for being associated the server to be deleted with this or virtual machine
Pass information is deleted.In prior art, when server is carried out or virtual machine is deleted, all services are often traveled through,
The service being associated with server to be deleted or virtual machine is searched, in the service for finding, carries out corresponding deletion action,
Then server or virtual machine are deleted again.It can be seen that, whole process is loaded down with trivial details, time-consuming, running occupancy resource is big, efficiency is low.
Content of the invention
In view of the above problems, it is proposed that the present invention so as to provide one kind overcome the problems referred to above or at least in part solve on
That states problem deletes the method for server and corresponding device from the server cluster for providing cloud service.
According to one aspect of the present invention, there is provided a kind of deletion server from the server cluster for providing cloud service
Method, wherein, the method includes:
Create an information list;
Will be corresponding with the identification information of the service associated by each server for each server identification information in server cluster
It is saved in described information list;
When needing to delete a server in the server cluster, the service is inquired from described information list
The identification information of the service associated by device, determines each service of the server association;
For each service of the server association, the identification information according to the service for inquiring finds the service
The information being associated with the server, the information according to the association carry out deleting preparation process;
After all services for the server association all complete to delete preparation process, delete from the server cluster
Remove the server.
Alternatively, the mark of the service associated by each server identification information and each server by server cluster
Knowledge information is correspondingly saved in described information list to be included:
All services of each server association in server cluster are ranked up in a certain order and are serviced
Sequencing table;
A server in for server cluster, according to the service ranking table, successively with a binary numeral
Whether the labelling server is associated with a service, until last service of all services of each server association, is obtained
One binary digit string;Wherein, 1 represent that association, 0 expression are not associated;
Using the identification information of the service associated by the binary digit string as the server and the mark of the server
Correspondingly it is saved in described information list.
Alternatively, for server cluster in a server, the method further includes:
The binary digit string is entered in reverse order and after rearrangement, is converted to the whole of a multi-system in addition to binary system
Number;
Will be corresponding with the mark of the server for the final identification information of the service associated by the integer as the server
It is saved in described information list.
Alternatively, the identification information of the service associated by the server is inquired from described information list, determines the clothes
Each service of business device association includes:
The identification information of the service associated by the server is inquired from described information list, is converted to binary digit
String;
The binary digit string being converted to is entered after rearrangement in reverse order, the service ranking table is compareed and is determined the service
Each service of device association.
Alternatively, one information list of the establishment includes:
Increase string in the relationship server table of the server cluster, for preserving the service associated by each server
Identification information;
Wherein, the corresponding server of every a line of the relationship server table, and deposited in the relationship server table
Row in server identification information.
Alternatively, the server is the virtual machine created in physical machine;
Deleting the server from the server cluster includes:Destroy corresponding virtual machine.
According to a further aspect in the invention, there is provided a kind of deletion server from the server cluster that cloud service is provided
Device, wherein, the device includes:
Table creating unit, is suitable to create an information list;And each server identification information just in server cluster
Corresponding with the identification information of the service associated by each server it is saved in described information list;
Delete and prepare processing unit, be suitable to when needing to delete a server in the server cluster, from described
The identification information of the service associated by the server is inquired in information list, determines each service of the server association;For
Each service of server association, the identification information according to the service for inquiring find the service with the server phase
The information of association, the information according to the association carry out deleting preparation process;
Unit is deleted, is suitable to after all services for server association all complete to delete preparation process, from described
The server is deleted in server cluster.
Alternatively, the table creating unit, be suitable to by all services of each server association in server cluster according to
Certain order is ranked up and obtains service ranking table;A server in for server cluster, arranges according to the service
Whether sequence table, associated with a service with the binary numeral labelling server successively, until the institute of each server association
There is last service of service, obtain a binary digit string;Wherein, 1 represent that association, 0 expression are not associated;And be suitable to
Preserve corresponding with the mark of the server for the identification information of the service associated by the binary digit string as the server
To in described information list.
Alternatively, the table creating unit, in being further adapted for for server cluster a server, by described two
Binary digits string is converted to the integer of a multi-system in addition to binary system after entering rearrangement in reverse order;
Will be corresponding with the mark of the server for the final identification information of the service associated by the integer as the server
It is saved in described information list.
Alternatively, described deletion prepares processing unit, is suitable to inquire associated by the server from described information list
Service identification information, be converted to binary digit string;The binary digit string being converted to is entered after rearrangement in reverse order,
Compare each service that the service ranking table determines the server association.
Alternatively, the table creating unit, is suitable to increase string in the relationship server table of the server cluster, uses
Identification information in the service preserved associated by each server;Wherein, the corresponding clothes of every a line of the relationship server table
The row of existing server identification information in business device, and the relationship server table.
Alternatively, the server is the virtual machine created in physical machine;
The deletion unit is deleted the server from the server cluster and specially destroys corresponding virtual machine.
Technology according to the present invention scheme, creates an information list first, by each server identification in server cluster
Information is corresponding with the identification information of the service associated by each server to be saved in information list;When need delete server cluster
In a server when, it is no longer necessary to take all of service of traversal, but directly inquire the server from information list
The identification information of associated service, determines each service of the server association;For each service of the server association, root
According to the information being associated with the server that the identification information of the service for inquiring finds the service, according to the information of association
Carry out deleting preparation process, prevent the deletion of the server from impact is produced on the service business of whole server cluster;When for
After all services of the server association all complete to delete preparation process, the server is deleted from server cluster.It can be seen that, this
Invention is when server deletion is carried out, it is not necessary to all services in traversal server cluster, can by information list
To find out the service being associated with server to be deleted, whole process is easy to use, time-consuming short, running takes resource
Little, efficiency high.
Described above is only the general introduction of technical solution of the present invention, in order to better understand the technological means of the present invention,
And can be practiced according to the content of description, and in order to allow the above and other objects of the present invention, feature and advantage can
Become apparent, below especially exemplified by the specific embodiment of the present invention.
Description of the drawings
By reading the detailed description of hereafter preferred implementation, various other advantages and benefit are common for this area
Technical staff will be clear from understanding.Accompanying drawing is only used for the purpose for illustrating preferred implementation, and is not considered as to the present invention
Restriction.And in whole accompanying drawing, it is denoted by the same reference numerals identical part.In the accompanying drawings:
Fig. 1 shows deletion server from the server cluster for providing cloud service according to an embodiment of the invention
The schematic flow sheet of method;
Fig. 2 shows deletion server from the server cluster for providing cloud service according to an embodiment of the invention
The structural representation of device.
Specific embodiment
The exemplary embodiment of the disclosure is more fully described below with reference to accompanying drawings.Although the disclosure is shown in accompanying drawing
Exemplary embodiment, it being understood, however, that may be realized in various forms the disclosure and should not be by embodiments set forth here
Limited.On the contrary, there is provided these embodiments are able to be best understood from the disclosure, and can be by the scope of the present disclosure
Complete conveys to those skilled in the art.
Fig. 1 shows deletion server from the server cluster for providing cloud service according to an embodiment of the invention
The schematic flow sheet of method.As shown in figure 1, the method includes:
Step S110, creates an information list.
Step S120, by the mark of the service associated by each server identification information and each server in server cluster
Information is correspondingly saved in information list.
Each server in server cluster has unique identification information, and all services in server cluster
There is unique identification information, letter is stored in by corresponding with the identification information of the service which provides for the identification information of each server
In breath list, then when being inquired about, it is only necessary to search corresponding server identification information in information list, which is right
The identification information of the service that answers can also be found in information list.Here the associated clothes provided comprising server
Business, and the service that server is authorized to.For example, there are server A 1, A2, A3, the clothes that whole cluster is provided in server cluster
Business has B1, B2, B3, B4, and be associated with A1 is B1 and B3 services, and be associated with A2 is that B1 and B2 is serviced, related to A3
Connection is B3 and B4 services, then just preserve corresponding with B1, B3 for A1, A2 is corresponding with B1, B2 to be preserved, A3 is corresponding with B3, B4 to be protected
Depositing, in information list, a server being represented per a line, the mark letter of an associated service is preserved per string
Breath.
Step S130, when needing to delete a server in server cluster, inquires the clothes from information list
The identification information of the service associated by business device, determines each service of the server association.
When server deletion is carried out, in order to search the service being associated with server to be deleted, need to travel through
Service server phase whether to be deleted with this is searched in all services of whole server cluster, the relevant information the exterior and the interior of service
Association, if it is, determine associated;If it is not, then continuing to search for next service.
In this step, when needing to delete a server, do not needing to travel through all of service, as long as preserving
Service to be deleted is searched in the information list of the identification information of the service associated by each server identification information and each server
Device, the identification information of its associated service are also just obtained, and improve search efficiency.
Step S140, for each service of the server association, searches according to the identification information of the service for inquiring
To the information being associated with the server of the service, carry out deleting preparation process according to the information for associating.
In order to prevent server to be deleted from the service business of whole server cluster is affected after deleting, deleting the service
Before device, need to be deleted corresponding information in service associated there.So, related to the server finding
After the identification information of each service of connection, the identification information according to the service for inquiring find the service with the server
Associated information, the information according to association carry out deleting preparation process, and for example, deleting in the information of related service should
Attribute information of server etc..
Step S150, after all services for the server association all complete to delete preparation process, from server set
The server is deleted in group.
After completing all services of the server association to be deleted to preparation process, then the deletion behaviour for carrying out the server
Make, the impact that can thus avoid the deletion of the server from bringing the service business of whole server cluster.
It can be seen that, the present invention is when server deletion is carried out, it is not necessary to all services in traversal server cluster, leads to
Cross information list and can just find out the service being associated with server to be deleted, whole process is easy to use, time-consuming short, fortune
Row process occupancy resource is little, efficiency high.
If the mark by the service associated by each server identification information and each server in server cluster
Knowledge information is correspondingly saved in information list, then with being continuously increased for the associated service number of server, whole information
Quantity of information in list is constantly increasing.For example, represent a server per a line, each column representative server associated one
Individual service, then as the increase of service, the columns of information list are also constantly increasing, which may finally be caused to take
Memory space is larger, and the reduction of inquiry velocity.In order to solve this problem, in one embodiment of the invention, step
In S120 will be corresponding with the identification information of the service associated by each server for each server identification information in server cluster
Being saved in information list includes:
First, all services of each server association in server cluster are ranked up in a certain order and are obtained
Service ranking table.For example, the number of all services of each server association in server cluster is 5, then in order
Arrangement, can be B1, B2, B3, B4, B5.
Secondly, for server cluster in a server, according to service ranking table, successively with a binary numeral
Whether the labelling server is associated with a service, until last service of all services of each server association, i.e., according to
Secondary judge all of service whether associate with the server, will eventually get a binary digit string;Wherein, 1 association is represented,
0 expression is not associated.For example, for B1, B2, B3, B4, B5, the service being associated with server A 1 is B1, B3, then in storage
When, judge whether B1, B2, B3, B4, B5 are associated with server successively, associated be just labeled as " 1 ", unconnected just
" 0 " is labeled as, in this example, for A1, its binary digit string for obtaining is exactly 10100.
Finally, using the identification information of the service associated by binary digit string as the server and the mark of the server
Correspondingly it is saved in information list.So, in information list, finally there was only two column data, string is the mark letter of server
Breath, string is the identification information (string of binary characters) of the service being mutually associated with server.
When making a look up, it is only necessary to read the string of binary characters of the associated service of the server, by the binary system
Character string is corresponding with service ranking table, according to its association identification " 1 " or " 0 " judge corresponding service whether with the server phase
Association.
When being further added by a server or change service, the service according to increase or change is in service ranking table
Sorting position, increase or change corresponding labelling in string of binary characters.In the above example, for server A 1, increase
Plus the service of B5, then just by the 5th in the identification information " 10100 " of its associated service preserved in information list
" 0 " is changed into " 1 ", eventually becomes " 10101 ";Or B6 is serviced for server A 1 increases, then just by the guarantor in information list
The identification information of the associated service that deposits is changed to " 101001 ".
But, if in the case where quantity of service is huge, using string of binary characters as associated service mark
Knowledge information is preserved, and in its information list, the quantity of information of corresponding cell is also very huge, so, at one of the present invention
In embodiment, for server cluster in a server, said method further includes:By binary digit string in reverse order
The integer of a multi-system in addition to binary system is converted to after entering rearrangement;Using the service associated by integer as the server
Final identification information corresponding with the mark of the server be saved in information list.Here, the multi-system in addition to binary system
Can be decimal scale or hexadecimal.
By taking decimal scale as an example, for the identification information " 10100 " of the associated service of server A 1, weight is carried out in reverse order
It is changed into " 00101 " after row, after binary system turns metric conversion, " 00101 " is changed into " 5 ", then by " 5 " as the service
The final identification information of the service associated by device A1 is corresponding with the mark of the server to be saved in information list.
Here first the identification information of associated service is entered after rearrangement in reverse order being changed, is to reduce
The size of the integer after conversion, and in order to increase or change after associated service, the integer for obtaining is not too large.Example
Such as, in above-mentioned example, for the identification information " 10100 " of the associated service of server A 1, if not done by inverted order weight
Row, its integer for obtaining after decimal scale conversion be exactly " 20 " but. the integer obtained after carrying out inverted order rearrangement is " 5 ";Or
If after the whole server cluster of person increases service, for the identification information of the associated service of server A 1
" 10100100 ", reset if not done by inverted order, its integer for obtaining after decimal scale conversion be exactly " 164 " but. enter
Row inverted order is changed into the integer that " 00100101 " obtain after resetting be " 37 ", it is seen then that the integer that inverted order is obtained after retaking is less than not
Integer after inverted order rearrangement, particularly when the quantity of service is very big, this effect can become apparent from.
Because when being stored in the final identification information of the associated service of server, being to reset through inverted order, and entering more
System conversion, so need through reverse conversion when each service of the server association is determined according to information list.?
The mark for inquiring the service associated by the server from information list in one embodiment of the present of invention, in step S130
Information, determines that each service of the server association includes:The mark of the service associated by the server is inquired from information list
Knowledge information, is converted to binary digit string;The binary digit string being converted to is entered after rearrangement in reverse order, control service row
Sequence table determines each service of the server association.
An information list is created in step S110, can re-create a new list, or, using server set
The relationship server table that itself is present in group is created.So, in one embodiment of the invention, wound in step S110
Building an information list includes:Increase string in the relationship server table of server cluster, for preserving associated by each server
Service identification information;Wherein, the corresponding server of every a line of relationship server table, and deposited in relationship server table
Row in server identification information.
In the field of computer technology of reality, in order to obtain the space of the internal memory actual size more than physical machine, lead to
The method for creating virtual machine can be adopted often, it is suitable for the deletion action of virtual machine, so, in a reality of the present invention
Apply in example, server is the virtual machine created in physical machine;Deleting the server from server cluster includes:Destroy corresponding
Virtual machine.
Fig. 2 shows deletion server from the server cluster for providing cloud service according to an embodiment of the invention
The structural representation of device.As shown in Fig. 2 the device 200 that should delete server from the server cluster for providing cloud service is wrapped
Include:
Table creating unit 210, is suitable to create an information list;And each server identification letter just in server cluster
Breath is corresponding with the identification information of the service associated by each server to be saved in information list.
Each server in server cluster has unique identification information, and all services in server cluster
There is unique identification information, letter is stored in by corresponding with the identification information of the service which provides for the identification information of each server
In breath list, then when being inquired about, it is only necessary to search corresponding server identification information in information list, which is right
The identification information of the service that answers can also be found in information list.Here the associated clothes provided comprising server
Business, and the service that server is authorized to.For example, there are server A 1, A2, A3, the clothes that whole cluster is provided in server cluster
Business has B1, B2, B3, B4, and be associated with A1 is B1 and B3 services, and be associated with A2 is that B1 and B2 is serviced, related to A3
Connection is B3 and B4 services, then just preserve corresponding with B1, B3 for A1, A2 is corresponding with B1, B2 to be preserved, A3 is corresponding with B3, B4 to be protected
Depositing, in information list, a server being represented per a line, the mark letter of an associated service is preserved per string
Breath.
Delete and prepare processing unit 220, be suitable to, when needing to delete a server in server cluster, arrange from information
The identification information of the service associated by the server is inquired in table, determines each service of the server association;For the service
Each service of device association, the identification information according to the service for inquiring find being associated with the server for the service
Information, the information according to association carry out deleting preparation process.
When server deletion is carried out, in order to search the service being associated with server to be deleted, need to travel through
Service server phase whether to be deleted with this is searched in all services of whole server cluster, the relevant information the exterior and the interior of service
Association, if it is, determine associated;If it is not, then continuing to search for next service.
In this unit, when needing to delete a server, do not needing to travel through all of service, as long as preserving
Service to be deleted is searched in the information list of the identification information of the service associated by each server identification information and each server
Device, the identification information of its associated service are also just obtained, and improve search efficiency.
In order to prevent server to be deleted from the service business of whole server cluster is affected after deleting, deleting the service
Before device, need to be deleted corresponding information in service associated there.So, related to the server finding
After the identification information of each service of connection, the identification information according to the service for inquiring find the service with the server
Associated information, the information according to association carry out deleting preparation process, and for example, deleting in the information of related service should
Attribute information of server etc..
Unit 230 is deleted, is suitable to after all services for the server association all complete to delete preparation process, from clothes
The server is deleted in business device cluster.
After completing all services of the server association to be deleted to preparation process, then the deletion behaviour for carrying out the server
Make, the impact that can thus avoid the deletion of the server from bringing the service business of whole server cluster.
It can be seen that, the present invention is when server deletion is carried out, it is not necessary to all services in traversal server cluster, leads to
Cross information list and can just find out the service being associated with server to be deleted, whole process is easy to use, time-consuming short, fortune
Row process occupancy resource is little, efficiency high.
If the mark by the service associated by each server identification information and each server in server cluster
Knowledge information is correspondingly saved in information list, then with being continuously increased for the associated service number of server, whole information
Quantity of information in list is constantly increasing.For example, represent a server per a line, each column representative server associated one
Individual service, then as the increase of service, the columns of information list are also constantly increasing, which may finally be caused to take
Memory space is larger, and the reduction of inquiry velocity.In order to solve this problem, in one embodiment of the invention, table wound
Unit 210 is built, is suitable to:
First, all services of each server association in server cluster are ranked up in a certain order and are obtained
Service ranking table.For example, the number of all services of each server association in server cluster is 5, then in order
Arrangement, can be B1, B2, B3, B4, B5.
Secondly, for server cluster in a server, according to service ranking table, successively with a binary numeral
Whether the labelling server is associated with a service, until last service of all services of each server association, is obtained
One binary digit string;Wherein, 1 represent that association, 0 expression are not associated;For example, for B1, B2, B3, B4, B5, with server
The associated services of A1 are B1, B3, then when storage, judge whether B1, B2, B3, B4, B5 are related to server successively
Connection, associated be just labeled as " 1 ", unconnected be just labeled as " 0 ", in this example, for A1, its binary digit string for obtaining
It is exactly 10100.
Finally, using the identification information of the service associated by binary digit string as the server and the mark of the server
Correspondingly it is saved in information list.So, in information list, finally there was only two column data, string is the mark letter of server
Breath, string is the identification information (string of binary characters) of the service being mutually associated with server.
When making a look up, it is only necessary to read the string of binary characters of the associated service of the server, by the binary system
Character string is corresponding with service ranking table, according to its association identification " 1 " or " 0 " judge corresponding service whether with the server phase
Association.
When being further added by a server or change service, the service according to increase or change is in service ranking table
Sorting position, increase or change corresponding labelling in string of binary characters.In the above example, for server A 1, increase
Plus the service of B5, then just by the 5th in the identification information " 10100 " of its associated service preserved in information list
" 0 " is changed into " 1 ", eventually becomes " 10101 ";Or B6 is serviced for server A 1 increases, then just by the guarantor in information list
The identification information of the associated service that deposits is changed to " 101001 ".
But, if in the case where quantity of service is huge, using string of binary characters as associated service mark
Knowledge information is preserved, and in its information list, the quantity of information of corresponding cell is also very huge, so, at one of the present invention
In embodiment, table creating unit 210, in being further adapted for for server cluster a server, by binary digit string
The integer of a multi-system in addition to binary system is converted to after entering rearrangement in reverse order;Using associated by integer as the server
The final identification information of service corresponding with the mark of the server be saved in information list.Here, in addition to binary system
Multi-system can be decimal scale or hexadecimal.
By taking decimal scale as an example, for the identification information " 10100 " of the associated service of server A 1, weight is carried out in reverse order
It is changed into " 00101 " after row, after binary system turns metric conversion, " 00101 " is changed into " 5 ", then by " 5 " as the service
The final identification information of the service associated by device A1 is corresponding with the mark of the server to be saved in information list.
Here first the identification information of associated service is entered after rearrangement in reverse order being changed, is to reduce
The size of the integer after conversion, and in order to increase or change after associated service, the integer for obtaining is not too large.Example
Such as, in above-mentioned example, for the identification information " 10100 " of the associated service of server A 1, if not done by inverted order weight
Row, its integer for obtaining after decimal scale conversion be exactly " 20 " but. the integer obtained after carrying out inverted order rearrangement is " 5 ";Or
If after the whole server cluster of person increases service, for the identification information of the associated service of server A 1
" 10100100 ", reset if not done by inverted order, its integer for obtaining after decimal scale conversion be exactly " 164 " but. enter
Row inverted order is changed into the integer that " 00100101 " obtain after resetting be " 37 ", it is seen then that the integer that inverted order is obtained after retaking is less than not
Integer after inverted order rearrangement, particularly when the quantity of service is very big, this effect can become apparent from.
Because when being stored in the final identification information of the associated service of server, being to reset through inverted order, and entering more
System conversion, so need through reverse conversion when each service of the server association is determined according to information list.?
In one embodiment of the present of invention, delete and prepare processing unit 220, be suitable to inquire from information list associated by the server
Service identification information, be converted to binary digit string;The binary digit string being converted to is entered after rearrangement in reverse order,
Control service ranking table determines each service of the server association.
When creating an information list, can re-create a new list, or, using in server cluster itself
The relationship server table of presence is created.So, in one embodiment of the invention, table creating unit 210 is suitable in clothes
Increase string in the relationship server table of business device cluster, for preserving the identification information of the service associated by each server;Wherein,
The corresponding server of every a line of relationship server table, and in relationship server table existing server identification information row.
In the field of computer technology of reality, in order to obtain the space of the internal memory actual size more than physical machine, lead to
The method for creating virtual machine can be adopted often, it is suitable for the deletion action of virtual machine, so, in a reality of the present invention
Apply in example, server is the virtual machine created in physical machine;Then deleting unit 230, the server is deleted from server cluster
Corresponding virtual machine is specially destroyed.
In sum, technology according to the present invention scheme, creates an information list first, by each clothes in server cluster
Being engaged in, device identification information is corresponding with the identification information of the service associated by each server to be saved in information list;Take when needing to delete
During a server in business device cluster, it is no longer necessary to take all of service of traversal, but directly inquire from information list
The identification information of the service associated by the server, determines each service of the server association;Every for server association
Individual service, the identification information according to the service for inquiring find the information being associated with the server of the service, according to
The information of association carries out deleting preparation process, prevents the deletion of the server from producing shadow to the service business of whole server cluster
Ring;After all services for the server association all complete to delete preparation process, the service is deleted from server cluster
Device.It can be seen that, the present invention is when server deletion is carried out, it is not necessary to all services in traversal server cluster, by letter
Breath list can just find out the service be associated with server to be deleted, and whole process is easy to use, it is short to take, ran
Cheng Zhanyong resources are little, efficiency high.
It should be noted that:
Algorithm and display be not inherently related to any certain computer, virtual bench or miscellaneous equipment provided herein.
Various fexible units can also be used together based on teaching in this.As described above, construct required by this kind of device
Structure be obvious.Additionally, the present invention is also not for any certain programmed language.It is understood that, it is possible to use various
Programming language realizes the content of invention described herein, and the above description done by language-specific is to disclose this
Bright preferred forms.
In description mentioned herein, a large amount of details are illustrated.It is to be appreciated, however, that the enforcement of the present invention
Example can be put into practice in the case where not having these details.In some instances, known method, structure are not been shown in detail
And technology, so as not to obscure the understanding of this description.
Similarly, it will be appreciated that in order to simplify the disclosure helping understand one or more in each inventive aspect,
Above in the description to the exemplary embodiment of the present invention, each feature of the present invention is grouped together into single enforcement sometimes
In example, figure or descriptions thereof.However, should not be construed to reflect following intention by the method for the disclosure:I.e. required guarantor
The more features of feature that the application claims ratio of shield is expressly recited in each claim.More precisely, such as following
Claims reflected as, inventive aspect is all features less than single embodiment disclosed above.Therefore,
Thus the claims for following specific embodiment are expressly incorporated in the specific embodiment, wherein each claim itself
All as the separate embodiments of the present invention.
Those skilled in the art be appreciated that can to embodiment in equipment in module carry out adaptively
Change and they are arranged in one or more equipment different from the embodiment.Can be the module in embodiment or list
Unit or component are combined into a module or unit or component, and can be divided in addition multiple submodule or subelement or
Sub-component.In addition at least some in such feature and/or process or unit is excluded each other, can adopt any
Combination is disclosed to all features disclosed in this specification (including adjoint claim, summary and accompanying drawing) and so to appoint
Where all processes or unit of method or equipment are combined.Unless expressly stated otherwise, this specification (includes adjoint power
Profit is required, summary and accompanying drawing) disclosed in each feature can identical by offers, be equal to or the alternative features of similar purpose carry out generation
Replace.
Although additionally, it will be appreciated by those of skill in the art that some embodiments described herein include other embodiments
In some included features rather than further feature, but the combination of the feature of different embodiments means in of the invention
Within the scope of and form different embodiments.For example, in the following claims, embodiment required for protection appoint
One of meaning can in any combination mode using.
The present invention all parts embodiment can be realized with hardware, or with one or more processor operation
Software module realize, or with combinations thereof realize.It will be understood by those of skill in the art that can use in practice
Microprocessor or digital signal processor (DSP) are according to embodiments of the present invention from the server set for providing cloud service to realize
The some or all functions of some or all parts in the device of server are deleted in group.The present invention is also implemented as
For execute method as described herein some or all equipment or program of device (for example, computer program and
Computer program).Such program for realizing the present invention can be stored on a computer-readable medium, or can have
The form of one or more signal.Such signal can be downloaded from internet website and be obtained, or on carrier signal
There is provided, or provided with any other form.
It should be noted that above-described embodiment the present invention will be described rather than limits the invention, and ability
Field technique personnel can design alternative embodiment without departing from the scope of the appended claims.In the claims,
Any reference markss being located between bracket should not be configured to limitations on claims.Word "comprising" is not excluded the presence of not
Element listed in the claims or step.Word "a" or "an" before being located at element does not exclude the presence of multiple such
Element.The present invention can come real by means of the hardware for including some different elements and by means of properly programmed computer
Existing.If in the unit claim for listing equipment for drying, several in these devices can be by same hardware branch
To embody.The use of word first, second, and third does not indicate that any order.These words can be explained and be run after fame
Claim.
The invention discloses A1, a kind of method for deleting server from the server cluster that cloud service is provided, wherein, should
Method includes:
Create an information list;
Will be corresponding with the identification information of the service associated by each server for each server identification information in server cluster
It is saved in described information list;
When needing to delete a server in the server cluster, the service is inquired from described information list
The identification information of the service associated by device, determines each service of the server association;
For each service of the server association, the identification information according to the service for inquiring finds the service
The information being associated with the server, the information according to the association carry out deleting preparation process;
After all services for the server association all complete to delete preparation process, delete from the server cluster
Remove the server.
A2, the method as described in A1, wherein, each server identification information and each server by server cluster
The identification information of associated service is correspondingly saved in described information list to be included:
All services of each server association in server cluster are ranked up in a certain order and are serviced
Sequencing table;
A server in for server cluster, according to the service ranking table, successively with a binary numeral
Whether the labelling server is associated with a service, until last service of all services of each server association, is obtained
One binary digit string;Wherein, 1 represent that association, 0 expression are not associated;
Using the identification information of the service associated by the binary digit string as the server and the mark of the server
Correspondingly it is saved in described information list.
A3, the method as described in A2, wherein, for server cluster in a server, the method further includes:
The binary digit string is entered in reverse order and after rearrangement, is converted to the whole of a multi-system in addition to binary system
Number;
Will be corresponding with the mark of the server for the final identification information of the service associated by the integer as the server
It is saved in described information list.
A4, the method as described in A3, wherein, inquire the mark of the service associated by the server from described information list
Knowledge information, determines that each service of the server association includes:
The identification information of the service associated by the server is inquired from described information list, is converted to binary digit
String;
The binary digit string being converted to is entered after rearrangement in reverse order, the service ranking table is compareed and is determined the service
Each service of device association.
A5, the method as any one of A1-A4, wherein, one information list of the establishment includes:
Increase string in the relationship server table of the server cluster, for preserving the service associated by each server
Identification information;
Wherein, the corresponding server of every a line of the relationship server table, and deposited in the relationship server table
Row in server identification information.
A6, the method as any one of A1-A4, wherein,
The server is the virtual machine created in physical machine;
Deleting the server from the server cluster includes:Destroy corresponding virtual machine.
The invention also discloses B7, a kind of device for deleting server from the server cluster that cloud service is provided, wherein,
The device includes:
Table creating unit, is suitable to create an information list;And each server identification information just in server cluster
Corresponding with the identification information of the service associated by each server it is saved in described information list;
Delete and prepare processing unit, be suitable to when needing to delete a server in the server cluster, from described
The identification information of the service associated by the server is inquired in information list, determines each service of the server association;For
Each service of server association, the identification information according to the service for inquiring find the service with the server phase
The information of association, the information according to the association carry out deleting preparation process;
Unit is deleted, is suitable to after all services for server association all complete to delete preparation process, from described
The server is deleted in server cluster.
B8, the device as described in B7, wherein,
The table creating unit, is suitable to all services of each server association in server cluster according to certain suitable
Sequence is ranked up and obtains service ranking table;A server in for server cluster, according to the service ranking table, successively
Whether associated with a service with the binary numeral labelling server, until the association of each server all services most
A service, obtains a binary digit string afterwards;Wherein, 1 represent that association, 0 expression are not associated;And be suitable to enter described two
Numeric string processed is as the identification information of the service associated by the server and the mark of the server is corresponding is saved in described information
In list.
B9, the device as described in B8, wherein,
The table creating unit, in being further adapted for for server cluster a server, by the binary number
Word string is converted to the integer of a multi-system in addition to binary system after entering rearrangement in reverse order;
Will be corresponding with the mark of the server for the final identification information of the service associated by the integer as the server
It is saved in described information list.
B10, the device as described in B9, wherein,
The service that deletes preparation processing unit, be suitable to inquire associated by the server from described information list
Identification information, is converted to binary digit string;The binary digit string being converted to is entered after rearrangement in reverse order, control is described
Service ranking table determines each service of the server association.
B11, the device as any one of B7-B10, wherein,
The table creating unit, is suitable to increase string in the relationship server table of the server cluster, for preserving
The identification information of the service associated by each server;Wherein, the corresponding server of every a line of the relationship server table, and
The row of existing server identification information in the relationship server table.
B12, the device as any one of B7-B10, wherein,
The server is the virtual machine created in physical machine;
The deletion unit is deleted the server from the server cluster and specially destroys corresponding virtual machine.
Claims (10)
1. a kind of from provide cloud service server cluster in delete server method, wherein, the method includes:
Create an information list;
Preserve corresponding with the identification information of the service associated by each server for each server identification information in server cluster
To in described information list;
When needing to delete a server in the server cluster, the server institute is inquired from described information list
The identification information of the service of association, determines each service of the server association;
For each service of server association, the identification information according to the service for inquiring find the service with this
The associated information of server, the information according to the association carry out deleting preparation process;
After all services for the server association all complete to delete preparation process, deleting from the server cluster should
Server.
2. the method for claim 1, wherein each server identification information and each service by server cluster
The identification information of the service associated by device is correspondingly saved in described information list to be included:
All services of each server association in server cluster are ranked up in a certain order and obtain service ranking
Table;
A server in for server cluster, according to the service ranking table, successively with a binary numeral labelling
Whether the server is associated with a service, until last service of all services of each server association, obtains one
Binary digit string;Wherein, 1 represent that association, 0 expression are not associated;
The identification information of the service associated by the binary digit string as the server is corresponding with the mark of the server
It is saved in described information list.
3. method as claimed in claim 2, wherein, for server cluster in a server, the method further wraps
Include:
The binary digit string is entered to be converted to after rearrangement the integer of a multi-system in addition to binary system in reverse order;
Preserve corresponding with the mark of the server for the final identification information of the service associated by the integer as the server
To in described information list.
4. method as claimed in claim 3, wherein, inquires service associated by the server from described information list
Identification information, determines that each service of the server association includes:
The identification information of the service associated by the server is inquired from described information list, is converted to binary digit string;
The binary digit string being converted to is entered after rearrangement in reverse order, the service ranking table is compareed and is determined that the server is closed
Each service of connection.
5. the method as any one of claim 1-4, wherein, one information list of the establishment includes:
Increase string in the relationship server table of the server cluster, for preserving the mark of the service associated by each server
Knowledge information;
Wherein, the corresponding server of every a line of the relationship server table, and existing clothes in the relationship server table
The row of business device identification information.
6. a kind of from provide cloud service server cluster in delete server device, wherein, the device includes:
Table creating unit, is suitable to create an information list;And each server identification information just in server cluster and each
The identification information of the service associated by server is correspondingly saved in described information list;
Delete and prepare processing unit, be suitable to when needing to delete a server in the server cluster, from described information
The identification information of the service associated by the server is inquired in list, determines each service of the server association;For the clothes
Each service of business device association, the identification information according to the service for inquiring find being associated with the server for the service
Information, the information according to the association carry out delete preparation process;
Unit is deleted, is suitable to after all services for the server association all complete to delete preparation process, from the service
The server is deleted in device cluster.
7. device as claimed in claim 6, wherein,
The table creating unit, is suitable to enter all services of each server association in server cluster in a certain order
Row sequence obtains service ranking table;A server in for server cluster, according to the service ranking table, successively with one
Whether individual binary numeral labelling server is associated with a service, until each server association all services last
Individual service, obtains a binary digit string;Wherein, 1 represent that association, 0 expression are not associated;And be suitable to the binary number
Word string is saved in described information list as the identification information of the service associated by the server and the mark of the server are corresponding
In.
8. device as claimed in claim 7, wherein,
The table creating unit, in being further adapted for for server cluster a server, by the binary digit string
The integer of a multi-system in addition to binary system is converted to after entering rearrangement in reverse order;Using the integer as the server institute
The final identification information of the service of association is corresponding with the mark of the server to be saved in described information list.
9. device as claimed in claim 8, wherein,
Described deletion prepares processing unit, is suitable to the mark for inquiring the service associated by the server from described information list
Information, is converted to binary digit string;The binary digit string being converted to is entered after rearrangement in reverse order, the service is compareed
Sequencing table determines each service of the server association.
10. the device as any one of claim 6-9, wherein,
The table creating unit, is suitable to increase string in the relationship server table of the server cluster, for preserving each clothes
The identification information of the service associated by business device;Wherein, the corresponding server of every a line of the relationship server table, and described
The row of existing server identification information in relationship server table.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611132398.XA CN106506693B (en) | 2016-12-09 | 2016-12-09 | The method and apparatus of server are deleted from the server cluster that cloud service is provided |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201611132398.XA CN106506693B (en) | 2016-12-09 | 2016-12-09 | The method and apparatus of server are deleted from the server cluster that cloud service is provided |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106506693A true CN106506693A (en) | 2017-03-15 |
CN106506693B CN106506693B (en) | 2019-06-18 |
Family
ID=58329618
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201611132398.XA Active CN106506693B (en) | 2016-12-09 | 2016-12-09 | The method and apparatus of server are deleted from the server cluster that cloud service is provided |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106506693B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101060663A (en) * | 2006-04-21 | 2007-10-24 | 中兴通讯股份有限公司 | A method for realizing the dynamic reconstruction service of cluster system |
CN101753405A (en) * | 2008-12-02 | 2010-06-23 | 北京空中信使信息技术有限公司 | Cluster server memory management method and system |
US20120158913A1 (en) * | 2010-12-21 | 2012-06-21 | Nishizaki Masatoshi | Transfer device, client apparatus, server apparatus, reproduction apparatus and transfer method |
CN103473296A (en) * | 2013-09-04 | 2013-12-25 | 国云科技股份有限公司 | Recycle bin mechanism and recycle bin system applicable to cloud computing |
CN105636241A (en) * | 2014-11-04 | 2016-06-01 | 中兴通讯股份有限公司 | M2M node deletion and registration methods and M2M node |
CN106101175A (en) * | 2016-05-25 | 2016-11-09 | 腾讯科技(深圳)有限公司 | Apparatus management/control methods, devices and systems |
-
2016
- 2016-12-09 CN CN201611132398.XA patent/CN106506693B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101060663A (en) * | 2006-04-21 | 2007-10-24 | 中兴通讯股份有限公司 | A method for realizing the dynamic reconstruction service of cluster system |
CN101753405A (en) * | 2008-12-02 | 2010-06-23 | 北京空中信使信息技术有限公司 | Cluster server memory management method and system |
US20120158913A1 (en) * | 2010-12-21 | 2012-06-21 | Nishizaki Masatoshi | Transfer device, client apparatus, server apparatus, reproduction apparatus and transfer method |
CN103473296A (en) * | 2013-09-04 | 2013-12-25 | 国云科技股份有限公司 | Recycle bin mechanism and recycle bin system applicable to cloud computing |
CN105636241A (en) * | 2014-11-04 | 2016-06-01 | 中兴通讯股份有限公司 | M2M node deletion and registration methods and M2M node |
CN106101175A (en) * | 2016-05-25 | 2016-11-09 | 腾讯科技(深圳)有限公司 | Apparatus management/control methods, devices and systems |
Also Published As
Publication number | Publication date |
---|---|
CN106506693B (en) | 2019-06-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103902698B (en) | A kind of data-storage system and storage method | |
CN103810224B (en) | information persistence and query method and device | |
CN102184205B (en) | Based on the Multi-Pattern Matching method of easily extensible precision chaos Hash | |
JP6362805B1 (en) | Method for enabling access to past transactions in a blockchain network and nodes for configuring the network | |
CN103902702A (en) | Data storage system and data storage method | |
CN108121810A (en) | A kind of data duplicate removal method, system, central server and distributed server | |
CN104021123B (en) | method and system for data migration | |
CN107360224A (en) | Sequence number generation method, system, equipment and storage medium in distributed system | |
CN106294421A (en) | A kind of data write, read method and device | |
CN106557307B (en) | Service data processing method and system | |
CN105550225A (en) | Index construction method and query method and apparatus | |
CN103902701A (en) | Data storage system and data storage method | |
CN110309368A (en) | Determination method, apparatus, storage medium and the electronic device of data address | |
CN108415912A (en) | Data processing method based on MapReduce model and equipment | |
CN103069396A (en) | Object arrangement apparatus, method therefor, and computer program | |
CN110781200B (en) | Processing method, device, equipment and medium for block chain abnormal data | |
CN108628907A (en) | A method of being used for the Trie tree multiple-fault diagnosis based on Aho-Corasick | |
CN106550006A (en) | Cloud Server resource allocation methods and device | |
CN105574151A (en) | Image storage method and equipment | |
CN104217032B (en) | The processing method and processing device of database dimension | |
CN103761298B (en) | Distributed-architecture-based entity matching method | |
CN108874873A (en) | Data query method, apparatus, storage medium and processor | |
CN106569734B (en) | The restorative procedure and device that memory overflows when data are shuffled | |
CN110019593A (en) | Map datum acquisition methods, apparatus and system, server, storage medium | |
CN115130043B (en) | Database-based data processing method, device, equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | 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 |