CN106506693B - The method and apparatus of server are deleted from the server cluster that cloud service is provided - Google Patents
The method and apparatus of server are deleted from the server cluster that cloud service is provided Download PDFInfo
- Publication number
- CN106506693B CN106506693B CN201611132398.XA CN201611132398A CN106506693B CN 106506693 B CN106506693 B CN 106506693B CN 201611132398 A CN201611132398 A CN 201611132398A CN 106506693 B CN106506693 B CN 106506693B
- Authority
- CN
- China
- Prior art keywords
- server
- service
- identification information
- information
- 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.)
- Active
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
Abstract
The invention discloses a kind of method and apparatus that server is deleted from the server cluster for providing cloud service.This method comprises: one information list of creation;The identification information correspondence of service associated by each server identification information and each server in server cluster is saved in information list;When needing to delete in server cluster server, the identification information of service associated by the server is inquired from information list, determines the associated each service of the server;Each service associated for the server finds the information associated with the server of the service according to the identification information of the service inquired, is carried out deleting preparation processing according to associated information;It completes after deleting preparation processing, the server is deleted from server cluster.The present invention does not need all services in traversal server cluster, it is small, high-efficient that whole process is simple, operational process occupies resource when server is deleted.
Description
Technical field
The present invention relates to field of computer technology, and in particular to a kind of that clothes are deleted from the server cluster for providing cloud service
The method and apparatus of business device.
Background technique
In the environment of privately owned cloud service, every server in server cluster may all provide multiple business or more
The service of a user.When the virtual machine in a server or server is deleted, in order to prevent to entire clothes
The service business of business device cluster has an impact, and needs the phase in service associated with the server to be deleted or virtual machine
Information is closed to be deleted.In the prior art, when carrying out server or virtual machine is deleted, all services are often traversed,
Service associated with server or virtual machine to be deleted is searched, corresponding delete operation is carried out in the service found,
Then server or virtual machine are deleted again.As it can be seen that whole process is cumbersome, time-consuming, operational process occupancy resource is big, low efficiency.
Summary of the invention
In view of the above problems, it proposes on the present invention overcomes the above problem or at least be partially solved in order to provide one kind
State the method for deletion server and the corresponding device from the server cluster that cloud service is provided of problem.
According to one aspect of the present invention, it provides and a kind of to delete server from the server cluster that cloud service is provided
Method, wherein this method comprises:
Create an information list;
The identification information of service associated by each server identification information and each server in server cluster is corresponding
It is saved in the information list;
When needing to delete in the server cluster server, the service is inquired from the information list
The identification information of service associated by device determines the associated each service of the server;
Each service associated for the server, finds the service according to the identification information of the service inquired
Information associated with the server carries out deleting preparation processing according to the associated information;
After all services associated for the server are all completed to delete preparation processing, deleted from the server cluster
Except the server.
Optionally, the mark of service associated by each server identification information and each server by server cluster
Knowing corresponding be saved in the information list of information includes:
The associated all services of each server in server cluster are ranked up in a certain order and are serviced
Sequencing table;
For a server in server cluster, according to the service ranking table, successively with a binary numeral
It marks whether the server is associated with a service, until the last one service of the associated all services of each server, obtains
One binary digit string;Wherein, 1 association is indicated, 0 indicates not to be associated with;
Using the binary digit string as the mark of the identification information of service associated by the server and the server
Correspondence is saved in the information list.
Optionally, for a server in server cluster, this method further comprises:
The whole of a multi-system in addition to binary system is converted to after the binary digit string is reset in reverse order
Number;
The integer is corresponding with the mark of the server as the final identification information of service associated by the server
It is saved in the information list.
Optionally, the identification information that service associated by the server is inquired from the information list determines the clothes
Business the associated each service of device include:
The identification information that service associated by the server is inquired from the information list, is converted to binary digit
String;
After the binary digit string being converted to is reset in reverse order, compares the service ranking table and determine the service
The associated each service of device.
Optionally, one information list of the creation includes:
Increase by a column in the relationship server table of the server cluster, for saving 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
In the column of server identification information.
Optionally, the server is virtual machine of the creation in physical machine;
It includes: to destroy corresponding virtual machine that the server is deleted from the server cluster.
According to another aspect of the present invention, it provides and a kind of to delete server from the server cluster that cloud service is provided
Device, wherein the device includes:
Table creating unit is suitable for one information list of creation;And it will be by each server identification information in server cluster
It is corresponding with the identification information of service associated by each server to be saved in the information list;
It deletes and prepares processing unit, suitable for when needing to delete in the server cluster server, from described
The identification information that service associated by the server is inquired in information list determines the associated each service of the server;For
The associated each service of the server, which is found according to the identification information of the service inquired with the server phase
Associated information carries out deleting preparation processing according to the associated information;
Unit is deleted, is suitable for after all services associated for the server are all completed to delete preparation and be handled, from described
The server is deleted in server cluster.
Optionally, the table creating unit, suitable for by each server in server cluster it is associated it is all service according to
Certain sequence is ranked up to obtain service ranking table;For a server in server cluster, arranged according to the service
Sequence table successively marks whether the server is associated with a service with a binary numeral, until the associated institute of each server
There is the last one service of service, obtains a binary digit string;Wherein, 1 association is indicated, 0 indicates not to be associated with;And it is suitable for
Using the binary digit string as the preservation corresponding with the mark of the server of the identification information of service associated by the server
Into the information list.
Optionally, the table creating unit is further adapted for for a server in server cluster, by described two
System number word string is converted to the integer of a multi-system in addition to binary system after being reset in reverse order;
The integer is corresponding with the mark of the server as the final identification information of service associated by the server
It is saved in the information list.
Optionally, the deletion prepares processing unit, suitable for inquiring associated by the server from the information list
Service identification information, be converted to binary digit string;After the binary digit string being converted to is reset in reverse order,
It compares the service ranking table and determines the associated each service of the server.
Optionally, the table creating unit is used suitable for increasing by a column in the relationship server table of the server cluster
In the identification information for saving service associated by each server;Wherein, the corresponding clothes of every a line of the relationship server table
Be engaged in device, and in the relationship server table existing server identification information column.
Optionally, the server is virtual machine of the creation in physical machine;
It is specially to destroy corresponding virtual machine that the deletion unit deletes the server from the server cluster.
According to the technique and scheme of the present invention, an information list is created first, by each server identification in server cluster
The identification information correspondence of service associated by information and each server is saved in information list;When needing to delete server cluster
In a server when, it is no longer necessary to take and traverse all service, but directly inquire the server from information list
The identification information of associated service determines the associated each service of the server;Each service associated for the server, root
The information associated with the server that the service is found according to the identification information of the service inquired, according to associated information
It carries out deleting preparation processing, prevents the deletion of the server from having an impact to the service business of entire server cluster;When for
The associated all services of the server are all completed after deleting preparation processing, and the server is deleted from server cluster.As it can be seen that this
Invention does not need all services in traversal server cluster when carrying out server deletion, can by information list
To find out service associated with server to be deleted, whole process is easy to use, time-consuming is short, operational process occupies resource
It is small, high-efficient.
The above description is only an overview of the technical scheme of the present invention, in order to better understand the technical means of the present invention,
And it can be implemented in accordance with the contents of the specification, and in order to allow above and other objects of the present invention, feature and advantage can
It is clearer and more comprehensible, the followings are specific embodiments of the present invention.
Detailed description of the invention
By reading the following detailed description of the preferred embodiment, various other advantages and benefits are common for this field
Technical staff will become clear.The drawings are only for the purpose of illustrating a preferred embodiment, and is not considered as to the present invention
Limitation.And throughout the drawings, the same reference numbers will be used to refer to the same parts.In the accompanying drawings:
Fig. 1 shows the deletion server according to an embodiment of the invention from the server cluster for providing cloud service
The flow diagram of method;
Server is deleted from the server cluster that cloud service is provided Fig. 2 shows according to an embodiment of the invention
The structural schematic diagram of device.
Specific embodiment
Exemplary embodiments of the present disclosure are described in more detail below with reference to accompanying drawings.Although showing the disclosure in attached drawing
Exemplary embodiment, it being understood, however, that may be realized in various forms the disclosure without should be by embodiments set forth here
It is limited.On the contrary, these embodiments are provided to facilitate a more thoroughly understanding of the present invention, and can be by the scope of the present disclosure
It is fully disclosed to those skilled in the art.
Fig. 1 shows the deletion server according to an embodiment of the invention from the server cluster for providing cloud service
The flow diagram of method.As shown in Figure 1, this method comprises:
Step S110 creates an information list.
Step S120, by the mark of service associated by each server identification information and each server in server cluster
Information correspondence is saved in information list.
Each server in server cluster has all services in unique identification information and server cluster
There is unique identification information, is stored in letter for the identification information of each server is corresponding with the identification information for the service that it is provided
It ceases in list, then when being inquired, it is only necessary to corresponding server identification information is searched in information list, it is right
The identification information for the service answered can also be found in information list.Here the associated clothes provided comprising server
The service that business and server are authorized to.For example, have server A 1, A2, A3 in server cluster, the clothes that entire cluster provides
Business has B1, B2, B3, B4, and associated with A1 is B1 and B3 service, and associated with A2 is B1 and B2 service, related to A3
Connection is B3 and B4 service, is saved then just corresponding to A1 and B1, B3, and A2 and B1, B2 are corresponded to and saved, A3 and the corresponding guarantor of B3, B4
It deposits, in information list, every a line can represent a server, and each column save the mark letter of an associated service
Breath.
Step S130 inquires the clothes when needing to delete in server cluster server from information list
The identification information of service associated by business device, determines the associated each service of the server.
When carrying out server deletion, in order to search service associated with server to be deleted, need to be traversed for
All services of entire server cluster, search in the relevant information table of service the service whether the server phase to be deleted with this
Association, if it is, determining associated;If it is not, then continuing to search next service.
In this step, when needing to delete a server, all services are not being needed to be traversed for, as long as preserving
Service to be deleted is searched in the information list of the identification information of service associated by each server identification information and each server
Device, the identification information of associated service also just obtain, and improve search efficiency.
Step S140, each service associated for the server are searched according to the identification information of the service inquired
To the information associated with the server of the service, carried out deleting preparation processing according to associated information.
Server to be deleted influences the service business of entire server cluster in order to prevent after deleting, and is deleting the service
Before device, need to delete information corresponding in service associated there.So related to the server finding
After the identification information of each service of connection, which is found according to the identification information of the service inquired with the server
Associated information, according to associated information carry out delete preparation processing, for example, institute relevant service information in delete this
The attribute information etc. of server.
Step S150, after all services associated for the server are all completed to delete preparation processing, from server set
The server is deleted in group.
After completing all service deletion preparation processing associated for the server, then carry out the deletion behaviour of the server
Make, the service business bring of entire server cluster can thus be influenced to avoid the deletion of the server.
As it can be seen that the present invention does not need all services in traversal server cluster when carrying out server deletion, lead to
Service associated with server to be deleted can be found out by crossing information list, and whole process is easy to use, time-consuming is short, fortune
It is small, high-efficient that row process occupies resource.
If by the mark of service associated by each server identification information and each server in server cluster
Know information correspondence to be saved in information list, then being continuously increased with the associated service number of server, entire information
Information content in list is constantly increasing.For example, every a line represents a server, each column representative server associated one
A service may finally will lead to its occupancy then the columns of information list is also constantly increasing with the increase of service
Memory space is larger and the reduction of inquiry velocity.In order to solve this problem, in one embodiment of the invention, step
The identification information by service associated by each server identification information and each server in server cluster in S120 is corresponding
It is saved in information list and includes:
Firstly, the associated all services of each server in server cluster are ranked up to obtain in a certain order
Service ranking table.For example, the number of the associated all services of each server in server cluster is 5, then in sequence
Arrangement, can be B1, B2, B3, B4, B5.
Secondly, for a server in server cluster, according to service ranking table, successively with a binary numeral
Mark whether the server is associated with a service, until the associated all services of each server the last one service, i.e., according to
It is secondary to judge whether all services are associated with the server, it will eventually get a binary digit string;Wherein, 1 association is indicated,
0 indicates not to be associated with.For example, service associated with server A 1 is B1, B3, then storing for B1, B2, B3, B4, B5
When, successively judge whether B1, B2, B3, B4, B5 associated with server, be associated just be labeled as " 1 ", it is unrelated just
Labeled as " 0 ", in this example, for A1, obtained binary digit string is exactly 10100.
Finally, using binary digit string as the mark of the identification information of service associated by the server and the server
Correspondence is saved in information list.In this way, finally there was only two column datas in information list, a column are the mark letters of server
Breath, a column are the identification informations (string of binary characters) of service mutually associated with server.
When being searched, it is only necessary to the string of binary characters for reading 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 it is corresponding service whether with the server phase
Association.
When being further added by or changing service in a server, according to the service for increasing or changing in service ranking table
Sorting position, increase or change corresponding label in string of binary characters.In the above example, for server A 1, increase
Add the service of B5, then the 5th in the identification information " 10100 " for the associated service for just saving it in information list
" 0 " becomes " 1 ", eventually becomes " 10101 ";Or service B6 is increased for server A 1, then just by the guarantor in information list
The identification information for the associated service deposited is changed to " 101001 ".
But if mark in the huge situation of quantity of service, using string of binary characters as associated service
To know information to be saved, the information content of corresponding cell is also very huge in information list, so, at of the invention one
In embodiment, for a server in server cluster, the above method further comprises: in reverse order by binary digit string
The integer of a multi-system in addition to binary system is converted to after being reset;Using integer as service associated by 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
It can be the decimal system either hexadecimal.
By taking the decimal system as an example, for the identification information " 10100 " of the associated service of server A 1, weight is carried out in reverse order
Become " 00101 " after row, after binary system turns metric transformation, " 00101 " becomes " 5 ", and " 5 " are then used as the service
The final identification information of service associated by device A1 is corresponding with the mark of the server to be saved in information list.
Here it is being converted after first being reset the identification information of associated service in reverse order, is being to reduce
The size of integer after conversion, and in order to increase or change associated service after, obtained integer 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 carrying out inverted order weight
Row, the integer that the integer obtained after the decimal system is converted exactly " 20 " still carries out obtaining after inverted order rearrangement is " 5 ";Or
After if the entire server cluster of person increases service, for the identification information of the associated service of server A 1
" 10100100 ", if not carrying out inverted order rearrangement, the integer obtained after the decimal system is converted be exactly " 164 " but into
It is " 37 " that row inverted order, which becomes the integer that " 00100101 " obtains after resetting, it is seen then that the integer that inverted order obtains after retaking is less than not
Integer after inverted order rearrangement, especially when the quantity of service is very big, this effect can be more obvious.
Because when being stored in the final identification information of the associated service of server, be reset by inverted order, and mostly into
System conversion, so needing when determining the server associated each service according to information list by reverse conversion.?
In one embodiment of the present of invention, the mark of service associated by the server is inquired in the slave information list in step S130
Information determines that the associated each service of the server includes: the mark that service associated by the server is inquired from information list
Know information, is converted to binary digit string;After the binary digit string being converted to is reset in reverse order, control service row
Sequence table determines the associated each service of the server.
An information list is created in step S110, be can be and is re-created a new list, alternatively, utilizing server set
Existing relationship server table itself is created in group.So in one embodiment of the invention, the wound in step S110
Building an information list includes: to increase by a column in the relationship server table of server cluster, for saving 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
In the column of server identification information.
In the field of computer technology of reality, in order to obtain the space for the memory actual size for being greater than physical machine, lead to
The method that can often creation virtual machine be used, it is suitable for the delete operation of virtual machine, so, in a reality of the invention
It applies in example, server is virtual machine of the creation in physical machine;It includes: to destroy accordingly that the server is deleted from server cluster
Virtual machine.
Server is deleted from the server cluster that cloud service is provided Fig. 2 shows according to an embodiment of the invention
The structural schematic diagram of device.As shown in Fig. 2, the device 200 that should delete server from the server cluster for providing cloud service wraps
It includes:
Table creating unit 210 is suitable for one information list of creation;And each server identification in server cluster will be believed
Cease be saved in information list corresponding with the identification information of service associated by each server.
Each server in server cluster has all services in unique identification information and server cluster
There is unique identification information, is stored in letter for the identification information of each server is corresponding with the identification information for the service that it is provided
It ceases in list, then when being inquired, it is only necessary to corresponding server identification information is searched in information list, it is right
The identification information for the service answered can also be found in information list.Here the associated clothes provided comprising server
The service that business and server are authorized to.For example, have server A 1, A2, A3 in server cluster, the clothes that entire cluster provides
Business has B1, B2, B3, B4, and associated with A1 is B1 and B3 service, and associated with A2 is B1 and B2 service, related to A3
Connection is B3 and B4 service, is saved then just corresponding to A1 and B1, B3, and A2 and B1, B2 are corresponded to and saved, A3 and the corresponding guarantor of B3, B4
It deposits, in information list, every a line can represent a server, and each column save the mark letter of an associated service
Breath.
It deletes and prepares processing unit 220, suitable for being arranged from information when needing to delete in server cluster server
The identification information that service associated by the server is inquired in table determines the associated each service of the server;For the service
The associated each service of device finds the associated with the server of the service according to the identification information of the service inquired
Information carries out deleting preparation processing according to associated information.
When carrying out server deletion, in order to search service associated with server to be deleted, need to be traversed for
All services of entire server cluster, search in the relevant information table of service the service whether the server phase to be deleted with this
Association, if it is, determining associated;If it is not, then continuing to search next service.
In this unit, when needing to delete a server, all services are not being needed to be traversed for, as long as preserving
Service to be deleted is searched in the information list of the identification information of service associated by each server identification information and each server
Device, the identification information of associated service also just obtain, and improve search efficiency.
Server to be deleted influences the service business of entire server cluster in order to prevent after deleting, and is deleting the service
Before device, need to delete information corresponding in service associated there.So related to the server finding
After the identification information of each service of connection, which is found according to the identification information of the service inquired with the server
Associated information, according to associated information carry out delete preparation processing, for example, institute relevant service information in delete this
The attribute information etc. of server.
Unit 230 is deleted, is suitable for after all services associated for the server are all completed to delete preparation processing, from clothes
The server is deleted in business device cluster.
After completing all service deletion preparation processing associated for the server, then carry out the deletion behaviour of the server
Make, the service business bring of entire server cluster can thus be influenced to avoid the deletion of the server.
As it can be seen that the present invention does not need all services in traversal server cluster when carrying out server deletion, lead to
Service associated with server to be deleted can be found out by crossing information list, and whole process is easy to use, time-consuming is short, fortune
It is small, high-efficient that row process occupies resource.
If by the mark of service associated by each server identification information and each server in server cluster
Know information correspondence to be saved in information list, then being continuously increased with the associated service number of server, entire information
Information content in list is constantly increasing.For example, every a line represents a server, each column representative server associated one
A service may finally will lead to its occupancy then the columns of information list is also constantly increasing with the increase of service
Memory space is larger and the reduction of inquiry velocity.In order to solve this problem, in one embodiment of the invention, table is created
Unit 210 is built, is suitable for:
Firstly, the associated all services of each server in server cluster are ranked up to obtain in a certain order
Service ranking table.For example, the number of the associated all services of each server in server cluster is 5, then in sequence
Arrangement, can be B1, B2, B3, B4, B5.
Secondly, for a server in server cluster, according to service ranking table, successively with a binary numeral
It marks whether the server is associated with a service, until the last one service of the associated all services of each server, obtains
One binary digit string;Wherein, 1 association is indicated, 0 indicates not to be associated with;For example, for B1, B2, B3, B4, B5, with server
The associated service of A1 is B1, B3, then successively judging whether B1, B2, B3, B4, B5 are related to server when storage
Connection is associated and is just labeled as " 1 ", unrelated to be just labeled as " 0 ", in this example, for A1, obtained binary digit string
It is exactly 10100.
Finally, using binary digit string as the mark of the identification information of service associated by the server and the server
Correspondence is saved in information list.In this way, finally there was only two column datas in information list, a column are the mark letters of server
Breath, a column are the identification informations (string of binary characters) of service mutually associated with server.
When being searched, it is only necessary to the string of binary characters for reading 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 it is corresponding service whether with the server phase
Association.
When being further added by or changing service in a server, according to the service for increasing or changing in service ranking table
Sorting position, increase or change corresponding label in string of binary characters.In the above example, for server A 1, increase
Add the service of B5, then the 5th in the identification information " 10100 " for the associated service for just saving it in information list
" 0 " becomes " 1 ", eventually becomes " 10101 ";Or service B6 is increased for server A 1, then just by the guarantor in information list
The identification information for the associated service deposited is changed to " 101001 ".
But if mark in the huge situation of quantity of service, using string of binary characters as associated service
To know information to be saved, the information content of corresponding cell is also very huge in information list, so, at of the invention one
In embodiment, table creating unit 210 is further adapted for for a server in server cluster, by binary digit string
The integer of a multi-system in addition to binary system is converted to after being reset in reverse order;Using integer as associated by 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 the decimal system either hexadecimal.
By taking the decimal system as an example, for the identification information " 10100 " of the associated service of server A 1, weight is carried out in reverse order
Become " 00101 " after row, after binary system turns metric transformation, " 00101 " becomes " 5 ", and " 5 " are then used as the service
The final identification information of service associated by device A1 is corresponding with the mark of the server to be saved in information list.
Here it is being converted after first being reset the identification information of associated service in reverse order, is being to reduce
The size of integer after conversion, and in order to increase or change associated service after, obtained integer 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 carrying out inverted order weight
Row, the integer that the integer obtained after the decimal system is converted exactly " 20 " still carries out obtaining after inverted order rearrangement is " 5 ";Or
After if the entire server cluster of person increases service, for the identification information of the associated service of server A 1
" 10100100 ", if not carrying out inverted order rearrangement, the integer obtained after the decimal system is converted be exactly " 164 " but into
It is " 37 " that row inverted order, which becomes the integer that " 00100101 " obtains after resetting, it is seen then that the integer that inverted order obtains after retaking is less than not
Integer after inverted order rearrangement, especially when the quantity of service is very big, this effect can be more obvious.
Because when being stored in the final identification information of the associated service of server, be reset by inverted order, and mostly into
System conversion, so needing when determining the server associated each service according to information list by reverse conversion.?
In one embodiment of the present of invention, deletes and prepare processing unit 220, suitable for being inquired from information list associated by the server
Service identification information, be converted to binary digit string;After the binary digit string being converted to is reset in reverse order,
Control service ranking table determines the associated each service of the server.
When creating an information list, can be and re-create a new list, alternatively, using in server cluster itself
Existing relationship server table is created.So in one embodiment of the invention, table creating unit 210, suitable for taking
It is engaged in increasing by a column in the relationship server table of device cluster, for saving the identification information of 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 column.
In the field of computer technology of reality, in order to obtain the space for the memory actual size for being greater than physical machine, lead to
The method that can often creation virtual machine be used, it is suitable for the delete operation of virtual machine, so, in a reality of the invention
It applies in example, server is virtual machine of the creation in physical machine;It then deletes unit 230 and deletes the server from server cluster
Specially destroy corresponding virtual machine.
In conclusion according to the technique and scheme of the present invention, an information list is created first, by each clothes in server cluster
The identification information correspondence of service associated by business device identification information and each server is saved in information list;It is taken when needing to delete
Be engaged in a server in device cluster when, it is no longer necessary to take and traverse all service, but directly inquired from information list
The identification information of service associated by the server determines the associated each service of the server;It is associated for the server every
A service finds the information associated with the server of the service according to the identification information of the service inquired, according to
Associated information carries out deleting preparation processing, prevents the deletion of the server from generating shadow to the service business of entire server cluster
It rings;After all services associated for the server are all completed to delete preparation processing, the service is deleted from server cluster
Device.As it can be seen that the present invention does not need all services in traversal server cluster, passes through letter when carrying out server deletion
Breath list can find out service associated with server to be deleted, and whole process is easy to use, time-consuming is short, ran
Cheng Zhanyong resource is small, high-efficient.
It should be understood that
Algorithm and display be not inherently related to any certain computer, virtual bench or other equipment provided herein.
Various fexible units can also be used together with teachings based herein.As described above, it constructs required by this kind of device
Structure be obvious.In addition, the present invention is also not directed to any particular programming language.It should be understood that can use various
Programming language realizes summary of the invention described herein, and the description done above to language-specific is to disclose this hair
Bright preferred forms.
In the instructions provided here, numerous specific details are set forth.It is to be appreciated, however, that implementation of the invention
Example can be practiced without these specific details.In some instances, well known method, structure is not been shown in detail
And technology, so as not to obscure the understanding of this specification.
Similarly, it should be understood that in order to simplify the disclosure and help to understand one or more of the various inventive aspects,
Above in the description of exemplary embodiment of the present invention, each feature of the invention is grouped together into single implementation sometimes
In example, figure or descriptions thereof.However, the disclosed method should not be interpreted as reflecting the following intention: i.e. required to protect
Shield the present invention claims features more more than feature expressly recited in each claim.More precisely, as following
Claims reflect 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 a separate embodiment of the present invention.
Those skilled in the art will understand that can be carried out adaptively to the module in the equipment in embodiment
Change and they are arranged in one or more devices different from this embodiment.It can be the module or list in embodiment
Member or component are combined into a module or unit or component, and furthermore they can be divided into multiple submodule or subelement or
Sub-component.Other than such feature and/or at least some of process or unit exclude each other, it can use any
Combination is to all features disclosed in this specification (including adjoint claim, abstract and attached drawing) and so disclosed
All process or units of what method or apparatus are combined.Unless expressly stated otherwise, this specification is (including adjoint power
Benefit require, abstract and attached drawing) disclosed in each feature can carry out generation with an alternative feature that provides the same, equivalent, or similar purpose
It replaces.
In addition, it will be appreciated by those of skill in the art that although some embodiments described herein include other embodiments
In included certain features rather than other feature, but the combination of the feature of different embodiments mean it is of the invention
Within the scope of and form different embodiments.For example, in the following claims, embodiment claimed is appointed
Meaning one of can in any combination mode come using.
Various component embodiments of the invention can be implemented in hardware, or to run on one or more processors
Software module realize, or be implemented in a combination thereof.It will be understood by those of skill in the art that can be used in practice
Microprocessor or digital signal processor (DSP) are according to an embodiment of the present invention from providing the server set of cloud service to realize
The some or all functions of some or all components 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 device or device program (for example, computer program and
Computer program product).It is such to realize that program of the invention can store on a computer-readable medium, or can have
The form of one or more signal.Such signal can be downloaded from an internet website to obtain, or on the carrier signal
It provides, or is provided in any other form.
It should be noted that the above-mentioned embodiments illustrate rather than limit the invention, and ability
Field technique personnel can be designed alternative embodiment without departing from the scope of the appended claims.In the claims,
Any reference symbol between parentheses should not be configured to limitations on claims.Word "comprising" does not exclude the presence of not
Element or step listed in the claims.Word "a" or "an" located in front of the element does not exclude the presence of multiple such
Element.The present invention can be by means of including the hardware of several different elements and being come by means of properly programmed computer real
It is existing.In the unit claims listing several devices, several in these devices can be through the same hardware branch
To embody.The use of word first, second, and third does not indicate any sequence.These words can be explained and be run after fame
Claim.
Claims (12)
1. a kind of method for deleting server from the server cluster for providing cloud service, wherein this method comprises:
Create an information list;
By the corresponding preservation of the identification information of service associated by each server identification information and each server in server cluster
Into the information list;
When needing to delete in the server cluster server, the server institute is inquired from the information list
The identification information of associated service determines the associated each service of the server;
Each service associated for the server, according to the identification information of the service inquired find the service with this
The associated information of server carries out deleting preparation processing according to the associated information;
After all services associated for the server are all completed to delete preparation processing, deleting from the server cluster should
Server.
2. the method for claim 1, wherein each server identification information by server cluster and each service
The identification information of service associated by device corresponds to be saved in the information list
The associated all services of each server in server cluster are ranked up to obtain service ranking in a certain order
Table;
For a server in server cluster, according to the service ranking table, successively marked with a binary numeral
Whether the server is associated with a service, until the last one service of the associated all services of each server, obtains one
Binary digit string;Wherein, 1 association is indicated, 0 indicates not to be associated with;
It is corresponding with the mark of the server using the binary digit string as the identification information of service associated by the server
It is saved in the information list.
3. method according to claim 2, wherein for a server in server cluster, this method is further wrapped
It includes:
The integer of a multi-system in addition to binary system is converted to after the binary digit string is reset in reverse order;
Using the integer as the preservation corresponding with the mark of the server of the final identification information of service associated by the server
Into the information list.
4. method as claimed in claim 3, wherein inquire service associated by the server from the information list
Identification information determines that the associated each service of the server includes:
The identification information that service associated by the server is inquired from the information list, is converted to binary digit string;
After the binary digit string being converted to is reset in reverse order, compares the service ranking table and determine that the server closes
Each service of connection.
5. such as method of any of claims 1-4, wherein one information list of the creation includes:
Increase by a column in the relationship server table of the server cluster, for saving the mark of service associated by each server
Know information;
Wherein, the corresponding server of every a line of the relationship server table, and existing clothes in the relationship server table
The column of business device identification information.
6. such as method of any of claims 1-4, wherein
The server is virtual machine of the creation in physical machine;
It includes: to destroy corresponding virtual machine that the server is deleted from the server cluster.
7. a kind of device for deleting server from the server cluster for providing cloud service, wherein the device includes:
Table creating unit is suitable for one information list of creation;And it will be by each server identification information in server cluster and respectively
The identification information correspondence of service associated by server is saved in the information list;
It deletes and prepares processing unit, suitable for when needing to delete in the server cluster server, from the information
The identification information that service associated by the server is inquired in list determines the associated each service of the server;For the clothes
The business associated each service of device, finds the associated with the server of the service according to the identification information of the service inquired
Information, according to the associated information carry out delete preparation processing;
Unit is deleted, is suitable for after all services associated for the server are all completed to delete preparation processing, from the service
The server is deleted in device cluster.
8. device as claimed in claim 7, wherein
The table creating unit, suitable for by each server in server cluster it is associated it is all service in a certain order into
Row sequence obtains service ranking table;For a server in server cluster, according to the service ranking table, successively with one
A binary numeral marks whether the server is associated with a service, until last of the associated all services of each server
A service obtains a binary digit string;Wherein, 1 association is indicated, 0 indicates not to be associated with;And it is suitable for the binary number
Word string is saved in the information list as the identification information of service associated by the server and the mark of the server are corresponding
In.
9. device as claimed in claim 8, wherein
The table creating unit is further adapted for for a server in server cluster, by the binary digit string
The integer of a multi-system in addition to binary system is converted to after being reset in reverse order;Using the integer as the server institute
The final identification information of associated service is corresponding with the mark of the server to be saved in the information list.
10. device as claimed in claim 9, wherein
The deletion prepares processing unit, suitable for inquiring the mark of service associated by the server from the information list
Information is converted to binary digit string;After the binary digit string being converted to is reset in reverse order, the service is compareed
Sequencing table determines the associated each service of the server.
11. the device as described in any one of claim 7-10, wherein
The table creating unit, suitable for increasing by a column in the relationship server table of the server cluster, for saving each clothes
The identification information of service associated by business device;Wherein, the corresponding server of every a line of the relationship server table, and it is described
The column of existing server identification information in relationship server table.
12. the device as described in any one of claim 7-10, wherein
The server is virtual machine of the creation in physical machine;
It is specially to destroy corresponding virtual machine that the deletion unit deletes the server from the server cluster.
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 CN106506693A (en) | 2017-03-15 |
CN106506693B true 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 (5)
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 |
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 |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP5644472B2 (en) * | 2010-12-21 | 2014-12-24 | ソニー株式会社 | Transfer device, client device, server device, playback device, and transfer method |
-
2016
- 2016-12-09 CN CN201611132398.XA patent/CN106506693B/en active Active
Patent Citations (5)
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 |
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 |
---|---|
CN106506693A (en) | 2017-03-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10067954B2 (en) | Use of dynamic dictionary encoding with an associated hash table to support many-to-many joins and aggregations | |
CN103902702B (en) | A kind of data-storage system and storage method | |
US10838963B2 (en) | Optimized access for hierarchical low cardinality value synopsis in analytical databases | |
CN107862026B (en) | Data storage method and device, data query method and device, and electronic equipment | |
CN107783980A (en) | Index data generates and data query method and device, storage and inquiry system | |
CN105677683A (en) | Batch data query method and device | |
CN105677904B (en) | Small documents storage method and device based on distributed file system | |
CN107330119B (en) | Caching data processing method, electronic equipment, computer storage media | |
US11853279B2 (en) | Data storage using vectors of vectors | |
CN108228657B (en) | Method and device for realizing keyword retrieval | |
CN106227769B (en) | Date storage method and device | |
CN110427364A (en) | A kind of data processing method, device, electronic equipment and storage medium | |
CN108563697A (en) | A kind of data processing method, device and storage medium | |
CN106547916A (en) | A kind of user's portrait tag queries method and device | |
CN106506693B (en) | The method and apparatus of server are deleted from the server cluster that cloud service is provided | |
CN106445953A (en) | Advertisement creative information retrieval method and system | |
CN106569734B (en) | The restorative procedure and device that memory overflows when data are shuffled | |
CN104268244A (en) | Method and device for processing form | |
CN107085603A (en) | A kind of data processing method and device | |
CN107239568A (en) | Distributed index implementation method and device | |
CN108092670B (en) | Coding method and device | |
CN104750743A (en) | System and method for ticking and rechecking transaction files | |
CN106375490A (en) | IP information matching and extension method | |
CN109857740A (en) | Storage method, matching process, electronic equipment and the readable storage medium storing program for executing of character string | |
CN104951550B (en) | Date storage method and device |
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 |