Server reuse method, device, computer equipment and storage medium
By matching and grouping the shelf position identification and target position identification of the multiplexed server, and determining the target server set in combination with priority, the problem of low server reuse efficiency in the prior art is solved, and more efficient server acquisition and Listing process.
Patent Information
- Application Number
- CN202210193046.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-02-28
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2042-02-28
AI Technical Summary
The existing server multiplexing method has the potential to be scattered in various parks and warehouses, and technicians have added a large number of invalid distances in the process of obtaining servers to be multiplexed and putting them on, which consumes time and reduces the server multiplexing efficiency.
By obtaining the shelf position identification of the server to be multiplexed and matching it with the target position identification of the server's expected shelf position, grouping the multiplexed server according to the matching result to obtain the server set. Then, based on the priority of the server set, a target server set that meets the preset requirements is determined, and a target multiplexing server is determined in the target server set for multiplexing.
By optimizing the server acquisition and shelf path, invalid distances are reduced, time is saved, and server reuse efficiency is improved.
Smart Images

Figure CN114791858B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of server management technology, and in particular to a server multiplexing method, apparatus, computer equipment, storage medium and computer program product. Background Art
[0002] As server usage increases, server deployment becomes more frequent, and server reuse is also increasing.
[0003] During the server reuse and deployment process, the reuse of the decommissioned server requires the technician to search for the reusable target server in the warehouse resources and obtain the target server at the actual location of the warehouse, and then put the target server back on the shelf at the specified location for reuse and deployment of the target server.
[0004] However, based on the current server reuse method, since the reused servers may be scattered in various parks and warehouses, technicians do not have an accurate server reuse plan. Therefore, in the process of obtaining the servers to be reused and putting the servers on the shelves, a lot of invalid steps are added, which is time-consuming and reduces the efficiency of server reuse. Therefore, a server reuse method is urgently needed. Summary of the invention
[0005] Based on this, it is necessary to provide a server multiplexing method, apparatus, computer device, computer readable storage medium and computer program product to address the above technical issues.
[0006] In a first aspect, the present application provides a server multiplexing method. The method comprises:
[0007] Obtain the on-rack location identifier of the server to be reused;
[0008] Matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set;
[0009] Determine a target server set that meets preset requirements according to the priorities corresponding to the server sets;
[0010] A target multiplexing server is determined in the target server set to perform multiplexing processing on the target multiplexing server.
[0011] In one of the embodiments, obtaining the on-rack location identifier of the server to be reused includes:
[0012] According to the preset multi-level regional division rules, determine the regional location identifiers corresponding to the servers to be reused in the regions at each level;
[0013] According to the arrangement order of the regions at each level, the regional location identifiers corresponding to the servers to be reused in the regions at each level are combined to obtain the on-shelf location identifiers of the servers to be reused.
[0014] In one embodiment, the target location identifier includes regional location identifiers corresponding to regions at all levels; the on-shelf location identifier is matched with the target location identifier of the expected shelf location of the server, and the servers to be reused are grouped according to the obtained matching results to obtain a server set, including:
[0015] Determine the matching relationship between the target location identifier and the regions of the rack location identifier of the server to be reused in descending order of the regions of the respective levels;
[0016] The servers to be reused with the same minimum matching area are determined as a server set.
[0017] In one embodiment, determining the target server set that meets the preset requirements according to the priorities of the server sets includes:
[0018] Using the priority of the minimum matching area corresponding to the server set as the priority of the server set;
[0019] The server sets are sorted from high to low according to their corresponding priorities, and the server set with the highest priority is used as the target server set.
[0020] In one of the embodiments, determining the target multiplexing server in the target server set includes:
[0021] Determine the priority corresponding to the target server set;
[0022] If the priority reaches a preset priority level, determining any server in the target server set as a target reuse server;
[0023] If the priority does not reach the preset priority level, a path planning rule is obtained, and the path value of each server in the target server set is determined based on the path planning rule, and the server with the minimum path value is determined as the target multiplexing server.
[0024] In one embodiment, the obtaining of the path planning rule includes:
[0025] Based on the minimum matching area corresponding to the target server set, obtaining a path planning rule corresponding to the target server set;
[0026] The determining the path value of each server in the target server set based on the path planning rule includes:
[0027] According to the path planning rule, a path value between the target location identifier and the unmatched area corresponding to the on-rack location identifier of each server in the target server set is calculated.
[0028] In one embodiment, calculating the path value between the target location identifier and the unmatched area corresponding to the rack location identifier of each server in the target server set according to the path planning rule includes:
[0029] If the minimum matching area belongs to the same computer room area, the computer room area is gridded according to the width and length of the server cabinet, and the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server is calculated according to the computer room area path planning rule;
[0030] If the minimum matching area is an area belonging to the same building or the same floor, the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server is calculated according to the preset area path value matrix and the floor area path planning rule;
[0031] If the minimum matching area belongs to the same campus area, the path value of the unmatched area between the target location identifier and the in-place location identifier of each server is calculated according to the regional path value matrix and the campus path planning rule.
[0032] In a second aspect, the present application also provides a server multiplexing device. The device comprises:
[0033] An acquisition module, used to acquire the on-rack location identifier of the server to be reused;
[0034] A matching module, used for matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set;
[0035] A first determination module, used to determine a target server set that meets preset requirements according to the priorities corresponding to the server sets;
[0036] The second determination module is used to determine a target multiplexing server in the target server set to perform multiplexing processing on the target multiplexing server.
[0037] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
[0038] Obtain the on-rack location identifier of the server to be reused;
[0039] Matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set;
[0040] Determine a target server set that meets preset requirements according to the priorities corresponding to the server sets;
[0041] A target multiplexing server is determined in the target server set to perform multiplexing processing on the target multiplexing server.
[0042] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0043] Obtain the on-rack location identifier of the server to be reused;
[0044] Matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set;
[0045] According to the priorities corresponding to the server sets, a target server set that meets preset requirements is determined; and a target multiplexing server is determined in the target server set to perform multiplexing processing on the target multiplexing server.
[0046] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0047] Obtain the on-rack location identifier of the server to be reused;
[0048] Matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set;
[0049] Determine a target server set that meets preset requirements according to the priorities corresponding to the server sets;
[0050] A target multiplexing server is determined in the target server set to perform multiplexing processing on the target multiplexing server.
[0051] The above-mentioned server reuse method, apparatus, computer equipment, storage medium and computer program product obtain the shelf position identifier of the server to be reused; match the shelf position identifier with the target position identifier of the server's expected shelf position, and group the servers to be reused according to the obtained matching results to obtain a server set; determine the target server set that meets the preset requirements according to the priority corresponding to the server set; determine the target reuse server in the target server set to perform reuse processing on the target reuse server. This method is adopted to perform group processing and priority planning between the shelf position identifiers of multiple servers to be reused and the target position identifiers of the server's expected shelf position, realize simulation planning of reuse paths for servers to be reused, determine the optimal choice among the servers to be reused, save server acquisition time, and improve server reuse efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 An application environment diagram of a server reuse method in an embodiment;
[0053] Figure 2 A schematic diagram of a process of constructing an on-shelf identifier in an embodiment;
[0054] Figure 3 A schematic diagram of a flow chart of a step of determining a server set in one embodiment;
[0055] Figure 4 A schematic diagram of a flow chart of a step of determining a target server set in one embodiment;
[0056] Figure 5 A flow chart of the steps of determining a target multiplexing server in a target server set in one embodiment;
[0057] Figure 6 A flowchart of determining unmatched zone path values in a target server set in one embodiment;
[0058] Figure 7 A flowchart of a step of determining path values for different minimum matching areas in one embodiment;
[0059] Figure 8 A schematic diagram of a gridded plane of a computer room area in an embodiment;
[0060] Fig. 9 A schematic diagram of a building plan of a certain floor in an embodiment;
[0061] Fig.10 A grid coordinate system diagram corresponding to a floor building plane in an embodiment;
[0062] Fig.11 is a structural block diagram of a server multiplexing device in one embodiment;
[0063] Fig.12 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0064] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0065] In one embodiment, Figure 1 As shown, a server multiplexing method is provided. This embodiment takes the method applied to a terminal as an example for illustration. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:
[0066] Step 102: Obtain the shelf location identifier of the server to be reused.
[0067] The on-rack position identifier is used to represent the on-rack position information of each server to be reused.
[0068] In implementation, when the technicians are installing the server application, the server will be placed in the server cabinet for power-on deployment, etc. Therefore, the state of the server in the server cabinet is called the server on-rack state. When the server is down or the server is not needed, the server will be taken out of the server cabinet, and this operation is called the server off-rack operation. The server reuse mentioned in this application is to re-power on and deploy the server that has exited the server application process. Since the reuse of servers occurs frequently, when a normal server exits the server application, the server only needs to be powered off, and the server will not be removed from the shelf, that is, the unused server is kept in the on-rack state.
[0069] When server reuse is required, the computer device first obtains multiple servers to be reused that meet the server performance parameter conditions according to the server performance requirements required for reuse (corresponding to the server performance parameter conditions). Each server to be reused carries a shelf position identifier. For example, the shelf position identifier of server 1 to be reused is: A1-B1-C1-D1-E1-F1-G1.
[0070] Step 104 , matching the shelf location identifier with the target location identifier of the expected shelf location of the server, and grouping the servers to be multiplexed according to the obtained matching result to obtain a server set.
[0071] In implementation, since the rack position identifier contains the location information of the multi-level region where the server to be reused is located, and the target position identifier contains the location information of the multi-level region corresponding to the expected rack position of the server. Therefore, the computer device matches the multi-level region location information contained in the rack position identifier and the target position identifier to obtain the matching result between each rack position identifier and the multi-level region position of the target position identifier. Then, the computer device groups the servers to be reused according to the obtained matching results to obtain the server set corresponding to each group.
[0072] Step 106: Determine a target server set that meets preset requirements according to the priorities of the server sets.
[0073] In implementation, since the server set is divided based on the regional location matching results, the server set with a higher matching degree in the matching results should have a higher priority. According to this principle, each server set preset by the computer device has a corresponding priority. Then, based on the preset priority order, the computer device determines the target server set that meets the preset requirements from multiple server sets.
[0074] Step 108, determining a target multiplexing server in the target server set to perform multiplexing processing on the target multiplexing server.
[0075] During implementation, the computer device determines the server filtering rules corresponding to the target server set based on the attribute information of the target server set, and the computer device determines the target reused server in the target server set based on the server filtering rules to perform server reuse processing on the target reused server, that is, to move the target reused server from its shelf position to the expected shelf position, and power on and deploy the target reused server.
[0076] In the above-mentioned server reuse method, the computer device obtains the shelf position identifier of the server to be reused. Then, the shelf position identifier is matched with the target position identifier of the expected shelf position of the server. Then, the computer device groups the servers to be reused according to the obtained matching results to obtain a server set. The computer device determines the target server set that meets the preset requirements according to the priority corresponding to the server set. Finally, the computer device determines the target reuse server in the target server set to perform reuse processing on the target reuse server. According to this method, the shelf position identifiers of multiple servers to be reused are matched with the target position identifier of the expected shelf position of the server to obtain a matching result, and the server set is obtained based on the matching result, and then the target server set that meets the requirements is determined to screen and determine the target reuse server in the target server set. Through this server reuse planning method, the shelf position of the target server obtained is closest to the expected server shelf position, which reduces the travel time of the server during the reuse process and improves the reuse efficiency of the server.
[0077] In one embodiment, Figure 2 As shown, the specific processing process of step 102 includes the following steps:
[0078] Step 202: Determine the regional location identifiers corresponding to the servers to be reused in the regions at each level according to the preset multi-level region division rule.
[0079] In implementation, the computer equipment determines the regional location identifiers corresponding to the servers to be reused in the regions at each level according to the preset multi-level regional division rules. For example, for the on-shelf position of the server, the computer equipment performs multi-level regional division from large to small, and can obtain: park, building, floor, computer room, cabinet row, cabinet column. Among them, the regional location is represented by a unique identifier for each level of area. For example, based on the multi-level areas divided as described above, A represents the park, B represents the building, C represents the floor, D represents the computer room, E represents the cabinet row, and F represents the cabinet column. Therefore, for each server to be reused, its target regional location number in each level of area can be first determined according to the regional identifiers at each level (that is, its corresponding target regional location identifier is determined). For example, the regional location identifiers of a server to be reused are: A1, B2, C2, D1, E3 and F4, which means that the target regional location determined by the regions at each level of the server to be reused is: the 2nd floor (floor) of Building No. 2 in Park No. 1, and the 3rd row and 4th column in Computer Room No. 1.
[0080] Step 204 , combining the regional location identifiers corresponding to the servers to be reused in the regions at each level according to the arrangement order of the regions at each level, to obtain the on-shelf location identifiers of the servers to be reused.
[0081] In implementation, the computer device combines the regional location identifiers corresponding to the regions at each level of each server to be reused according to the arrangement order of the regions at each level, and obtains the on-shelf location identifier of the server to be reused.
[0082] Among them, the sorting order of the regions at all levels can be the order from large to small, or the order from small to large, which is not limited in the embodiments of the present application. The present application takes the order from large to small for example to construct the on-shelf position identification. Then, for the regional position identification corresponding to each level of the server to be reused, the on-shelf position identification reflecting the overall position from large to small is obtained. Specifically, the regional position identifications of each level of a server to be reused are combined to obtain the on-shelf position identification: A1-B2-C2-D1-E3-F4.
[0083] In one embodiment, Figure 3 As shown, the specific processing process of step 104 includes:
[0084] Step 302 , determining the matching relationship between the target location identifier and the regions of the rack location identifier of the server to be reused in descending order of the regions of the regions of the respective levels.
[0085] In implementation, since the corresponding shelf position when the server is reused can be represented by the target position identifier, and the shelf positions of multiple servers to be reused can be represented by the shelf position identifier. Therefore, the computer device uses the target position identifier as a reference to match the shelf position identifier of each server to be reused. Specifically, for each server to be reused, the computer device matches the levels of regions from large to small, until the shelf position identifier corresponding to the server to be reused does not match a certain level of region in the target position identifier. For example, determine whether the "park" represented in the on-rack location identifier of the server M to be reused is the same as the regional location number of the "park" in the target location identifier. If they are the same, it means that the first-level regional location in the on-rack location identifier matches that in the target location identifier, and continue to match the next-level area. If the regional location number of the "building" represented in the on-rack location identifier of the server M to be reused is the same as the regional location number of the "building" represented in the target location identifier, it means that the second-level regional location in the on-rack location identifier matches that in the target location identifier; if the regional location number of the "floor" represented in the home location identifier of the server M to be reused is different from the regional location number of the "floor" represented in the target location identifier, it means that the third-level regional location in the on-rack location identifier does not match that in the target location identifier, and then, stop the matching process of the on-rack location identifier and the target location identifier of the server M to be reused.
[0086] Step 304: determine the servers to be reused with the same minimum matching area as a server set.
[0087] During implementation, in the process of matching the on-rack location identifier and the target location identifier of the server to be reused, the minimum level regional location that can match the on-rack location identifier and the target location identifier of each server to be reused is the matching result corresponding to the server to be reused, and multiple servers to be reused with the same matching results are divided into the same group, and then the multiple servers contained in the same group are regarded as a server set.
[0088] For example, the shelf location identifiers of the servers to be reused Q, W and U are all servers to be reused whose minimum matching area with the target location identifier is the third-level area (characterized by the same regional location identifier), which means that the "park", "building" and "floor" of the expected shelf location of the servers to be reused Q, W and U are the same as those in the target location identifier, and the next level regional location identifier "computer room" is different (that is, the minimum matching area is the third-level regional location). The computer device divides the servers to be reused Q, W and U into a group to form a server set {Q, W, U}.
[0089] In one embodiment, Figure 4 As shown, based on the above embodiment of combining the servers to be reused with the same minimum matching area into one server set, a plurality of server sets corresponding to different minimum matching areas are determined, and the specific processing process of step 106 includes the following steps:
[0090] Step 402: The priority of the minimum matching area corresponding to the server set is used as the priority of the server set.
[0091] In implementation, since the minimum matching area corresponding to each server set is different, the smaller the minimum matching area corresponding to the server, the closer the location of the server to be reused in the server set is to the expected shelf location. Therefore, the computer device uses the size of the minimum matching area corresponding to the server set (that is, the priority of the minimum matching area) as the priority of the server set.
[0092] For example, the priority order of the minimum matching area is: cabinet column > cabinet row > computer room > floor > building > campus. If there are multiple server sets: Q1, Q2, Q3, Q4, Q5, Q6, and their corresponding minimum matching areas are: campus, building, floor, computer room, cabinet row, and cabinet column, then the priority order of the corresponding multiple server sets is Q6>Q5=Q4>Q3>Q2>Q1. Among them, the same cabinet row and different cabinet columns in the same computer room are at the same priority level as the cabinet rows in different rows in the same computer room.
[0093] Step 404: sort the server sets from high to low according to their corresponding priorities, and use the server set with the highest priority as the target server set.
[0094] In implementation, the computer device sorts the server sets from high to low according to their corresponding priorities, and uses the server set with the highest priority as the target server set. Specifically, for multiple server sets Q1, Q2, Q3, Q4, Q5, and Q6, the priority order of the corresponding multiple server sets is Q6>Q5=Q4>Q3>Q2>Q1. In this way, the computer device determines the Q6 server set with the highest priority as the target server set.
[0095] In one embodiment, Figure 5 As shown, based on the priority level of the target server set determined in the above embodiment, the specific processing process of step 108 includes:
[0096] Step 502: Determine the priority corresponding to the target server set.
[0097] In implementation, the computer device determines the priority level corresponding to the target server set. Specifically, the priority level of the target server set is the priority level corresponding to the minimum matching area in the target server set. For example, if the minimum matching area of the target server set is "floor", the priority level of the target server set is the level of "floor". If the minimum matching area of the target server set determined is "row where the cabinet is located", the priority level of the target server set is the level of "row where the cabinet is located".
[0098] Step 504: If the priority reaches a preset priority level, any server in the target server set is determined as a target reuse server.
[0099] In implementation, if the priority reaches a preset priority level, the computer device determines any one server in the target server set as a target reuse server.
[0100] Among them, the judgment condition of the preset priority level in the computer equipment is selected as the highest priority level in the set priority order. For example, in the pre-set priority order, the highest priority level is the priority corresponding to the "column where the cabinet is located". This priority level indicates that the minimum matching area corresponding to the target server set is the "column where the cabinet is located". Since the "column where the cabinet is located" is the minimum level area of all areas in the multi-level area division rule, this means that the position of any server in the server set is matched (the same) with the minimum level area "column where the cabinet is located" of the expected shelf position of the server. Therefore, any server in the target server set that meets this priority level can be used as a target reuse server. The target reuse server can achieve the closest distance transportation to the expected shelf position of the server, reduce the transportation time during the server shelf process, and improve the server reuse efficiency.
[0101] Step 506: If the priority does not reach the preset priority level, a path planning rule is obtained, and a path value of each server in the target server set is determined based on the path planning rule, and a server with a minimum path value is determined as a target multiplexing server.
[0102] In implementation, if the priority does not reach the preset priority level, it means that the minimum matching area corresponding to the determined target server set does not meet the area of the "cabinet column" (preset highest priority). For example, the priority level corresponding to the target server set is the priority level corresponding to the "floor", which means that each server included in the target server set belongs to the same park, the same floor of the same building as the expected shelf position of the server, but does not belong to the same computer room, and thus does not belong to a smaller area. Then there is still a certain distance between the shelf position of the servers included in the target server set and the expected shelf position of the servers. The computer device obtains the corresponding path planning rule, determines the path value between each server in the target server set and the expected shelf position of the server according to the path planning rule, and determines the server with the minimum path value as the target reuse server determined in this reuse process.
[0103] In one embodiment, Figure 6 As shown, the specific processing of the step of obtaining the path planning rule in step 506 includes:
[0104] Step 602: Based on the minimum matching area corresponding to the target server set, obtain the path planning rule corresponding to the target server set.
[0105] In implementation, the computer device obtains the path planning rules corresponding to the target server set based on the minimum matching area corresponding to the target server set. The path planning rules include path planning rules for all lower-level unmatched areas below the current minimum matching area. For example, if the minimum matching area corresponding to the determined target server set is "floor", the corresponding path planning rules are obtained, including path planning rules between multi-level regional locations (computer rooms, rows where cabinets are located, and columns where cabinets are located) that are not matched between the rack location identifier and the target location identifier. If the minimum matching area corresponding to the determined target server set is "campus", the corresponding building path planning rules are obtained, including path planning rules between multi-level regional locations (buildings, floors, computer rooms, rows where cabinets are located, and columns where cabinets are located) that are not matched between the rack location identifier and the target location identifier.
[0106] Step 604: Calculate the path value between the target location identifier and the unmatched area corresponding to the rack location identifier of each server in the target server set according to the path planning rule.
[0107] In implementation, the computer device calculates the path value between the target location identifier and the unmatched area corresponding to the rack location identifier of each server in the target server set according to the path planning rule. For example, the priority corresponding to the target server set is floor (minimum matching area), which means that the rack location of each server in the target server set and the expected target server's rack location belong to the same park, the same building and the same floor, but are not in the same computer room. Therefore, the path planning value calculates the path value between the computer room and the cabinet where each server is located and the expected rack location.
[0108] In one embodiment, Figure 7 As shown, for the target server set that does not meet the preset priority level in the above embodiment, the computer device needs to calculate the path value between the rack position of each server in the target server set and the expected server rack position, so as to screen the target reuse server according to the path value. The specific processing process of step 604 includes:
[0109] Step 702, if the minimum matching area belongs to the same computer room area, the computer room area is gridded according to the width and length of the server cabinet, and the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server is calculated according to the computer room area path planning rules.
[0110] In implementation, if the minimum matching area of the target server set corresponds to the same computer room area, it means that the on-shelf positions of the servers included in the target server set and the expected shelf positions of the servers are distributed in different (different rows and / or different columns) cabinets in the same computer room. The computer equipment grids the computer room area where the target server set and the expected server shelf positions are located according to the width and length of a single server cabinet, and establishes a plane coordinate system for the computer room area with the exit of the computer room as the coordinate origin. Then, each cabinet in the computer room is accurately located, that is, each cabinet corresponds to a position coordinate. Figure 8 As shown, if the width of each cabinet is 1 and the length of the cabinet is 2, the position coordinates of cabinet a are [2,1].
[0111] In this way, the computer device determines the position coordinates of the servers included in the target server set in the computer room where they are located, and then the computer device determines the multiple path values corresponding to the target server set based on the position coordinates of the on-shelf position of each server and the position coordinates of the expected shelf position of the server. Among them, the determination of multiple path values is not obtained by calculating the straight-line distance between the two position coordinates, but is calculated by level based on the unmatched area in the multi-level area division. The computer device first determines whether the row and column of the cabinet corresponding to the on-shelf position of the server and the expected shelf position are the same. If they are not the same, the path value between the on-shelf position of the server and the expected shelf position is determined based on the row coordinates and column coordinates between the two position coordinates. Among them, there are multiple methods for determining path values in the same computer room area, and the embodiments of the present application provide two methods, as shown below:
[0112] Method 1: Treat each cabinet as a position point in the coordinate system (not occupying a position): the on-rack position identifier corresponding to the on-rack position of the target server set (cabinet b) and the target position identifier of the expected rack position of the server (cabinet c) have the same A, B, C, and D area position numbers (where D is the minimum matching area). Since there may be multiple paths between two position coordinates in different rows (rows) and / or columns in the same computer room, there are multiple corresponding path values. In this way, the row coordinates and column coordinates of the two position coordinates are directly subtracted, and then the row coordinate subtraction value and the vertical coordinate subtraction value are summed. In this way, the path values under other paths can be effectively excluded (the path values under other paths are farther away than the path values of the method of subtracting and summing the row coordinates and column coordinates).
[0113] Method 2: Consider the length and width of the cabinet's floor space: The rack position identifier corresponding to the server rack position (cabinet b) in the target server set and the target position identifier of the server's expected rack position (cabinet c) have the same A, B, C, and D area position numbers (where D is the minimum matching area), but the E position is different (that is, the two cabinets are located in different rows in the same computer room). The computer equipment calculates the path values corresponding to the multiple paths that may exist between the two cabinets. Figure 8 As shown, from the multiple paths from cabinet b to cabinet c, two shorter paths are initially screened out (i.e., from cabinet b to the end of the row of cabinets, then to the end on the same side of the row where cabinet c is located, and then to cabinet c), and the shortest path of the two shorter paths is determined as the target path, and the target path value is calculated. The ordinate values (column coordinates) of the fixed ends of each row of cabinets (i.e., the length of the cabinets) are β1 and β2, respectively. The coordinates of cabinets b and c are [αb, βb]) and [αc, βc, respectively. The values of the two shorter paths are L1 = |αb-αc| + |2*β1-βb-βc| and L2 = |αb-αc| + |2*β2-βb-βc|).
[0114] Step 704: If the minimum matching area is an area belonging to the same building or the same floor, the path value of the unmatched area between the target location identifier and the rack location identifier of each server is calculated according to the area path value matrix and the floor area path planning rule.
[0115] In implementation, if the minimum matching area of the target server set corresponds to the same building, this means that the rack locations of the servers included in the target server set and the expected rack locations of the servers belong to the same park and the same building (that is, A and B in the location identifier are the same), but are not in the same floor area or the same computer room. If the minimum matching area of the target server set corresponds to the same floor, this means that the rack locations of the servers included in the target server set and the expected rack locations of the servers belong to the same park and the same building and are in the same floor area (that is, A, B and C in the location identifier are the same), but are not in the same computer room (D is different).
[0116] The computer device obtains the corresponding path value in the regional path value matrix for the minimum matching area corresponding to the target server set, and calculates the obtained path value according to the floor area path planning rules to obtain the path value between the target location identifier and the on-rack location identifier of each server.
[0117] Among them, combined with the coding rules of the target server set on-shelf location identification and the location identification in the target location identification, the doors included in all passages in all areas are coded, A1-0-0-0 represents the door of the A1 park, A1-B2-C1-0 represents the elevator entrance of the B2 floor C1 floor in the A1 park, and A1-B2-C1-D4 represents the D4 computer room of the B2 floor C1 floor in the A1 park. According to this coding rule, n door codes are generated corresponding to the target server set and the expected shelf location of the server. The minimum area of the door code only reaches the door of the computer room. Then, the computer equipment generates an n*n dimensional regional path value matrix based on the n door codes.
[0118] The method of constructing the regional path value matrix is as follows: the architectural plan of the park and the floor is mapped to a grid coordinate system. The grid coordinate system contains coordinate points for marking the starting position or the end position of the accessible passages such as the machine room door, the floor elevator entrance, and the park door. The coordinates of the position points of the accessible passages (including doors, elevators, etc.) in the grid coordinate system are marked as 1, otherwise (that is, the coordinates correspond to the wall, machine room, etc. in the architectural plan) The coordinates are marked as 0, such as Fig. 9 As shown, it corresponds to the building plan of a certain floor. According to the grid coordinate system method provided in this application, the grid coordinate system corresponding to the floor is obtained as follows Fig.10 As shown, the path value between any channels is converted into the shortest path calculation problem from a certain starting point coordinate to the end point coordinate. By solving it using the Dijkstra algorithm, the corresponding shortest path value can be obtained.
[0119] By solving the path value by this method, the regional path value matrix may include but is not limited to the path values between two computer room doors on the same floor, from the computer room door to the floor elevator door, from the first floor computer room door to the building door, between the elevator doors of two floors, from the floor elevator door to the building door, between the doors of two floors, and from the building door to the park door.
[0120] The regional path value matrix contains path values between doorways of various types of areas, and their meanings in the regional path value matrix are: for example, the value corresponding to the a-th row and the b-th column in the regional path value matrix represents the path value from the entrance of Park A to the entrance of Building B in Park A, represented by matrix (a, b). The value corresponding to the c-th row and the d-th column in the regional path value matrix represents the path value from the elevator entrance on the C floor to the door of the D-th machine room on the C floor. The meanings of other path values in the regional path value matrix are the same as the interpretation principles of the path values in the above two examples, and will not be repeated in the embodiments of the present application.
[0121] Step 706: If the minimum matching area belongs to the same campus area, the computer device calculates the path value of the unmatched area between the target location identifier and the in-place location identifier of each server according to the regional path value matrix and the campus path planning rules.
[0122] In implementation, if the minimum matching area corresponding to the target server set is the same campus area, it means that among the rack location identifiers of multiple servers in the target server set, only the regional location identifier A is the same as the target location identifier corresponding to the expected rack location. The computer device obtains multiple preset path values between the rack location and the expected rack location of each server in the pre-constructed regional path value matrix, and then, based on the multiple preset path values and the campus path planning rules, the computer device calculates the final path value between the rack location identifier and the target location identifier of the server.
[0123] Among them, the multiple preset path values include: the preset path value between the building entrance where the server is located and the building entrance where the expected shelf position is located, the preset path value between the elevator entrance on the floor where the server is located and the building entrance where the server is located, the preset path value between the elevator entrance on the floor where the server is located and the door of the computer room where the server is located, the preset path value between the elevator entrance on the floor where the expected shelf position is located and the door of the building where the expected shelf position is located, and the preset path value between the door of the computer room where the expected shelf position is located and the elevator entrance on the floor where the expected shelf position is located. The park path planning rules include a method for calculating the path value from a cabinet (row, column) in the computer room to the door of the computer room based on the gridding of the computer room plane area in the above step 702, so that the computer device can determine the path value from the cabinet where the server is located to the door of the computer room where the server is located, and similarly, the computer device can also determine the path value from the cabinet (row, column) corresponding to the expected shelf position of the server to the door of the computer room where it is located. The computer device sums the above-mentioned multiple preset path values and the calculated path value to determine the path value where the server's rack position and the server's expected rack position are in the same park but not in the same building.
[0124] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0125] Based on the same inventive concept, the embodiment of the present application also provides a server reuse device for implementing the server reuse method involved above. The implementation solution provided by the device to solve the problem is similar to the implementation solution recorded in the above method, so the specific limitations in one or more server reuse device embodiments provided below can refer to the limitations of the server reuse method above, and will not be repeated here.
[0126] In one embodiment, Fig.11 As shown, a server multiplexing device 1100 is provided, comprising: an acquisition module 1110, a matching module 1120, a first determination module 1130 and a second determination module 1140, wherein:
[0127] An acquisition module 1110 is used to acquire a rack location identifier of a server to be reused;
[0128] A matching module 1120 is used to match the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and group the servers to be reused according to the obtained matching results to obtain a server set;
[0129] A first determination module 1130 is used to determine a target server set that meets a preset requirement according to the priority corresponding to the server set;
[0130] The second determination module 1140 is used to determine a target multiplexing server in the target server set to perform multiplexing processing on the target multiplexing server.
[0131] In one embodiment, the acquisition module 1110 is specifically used to determine the regional location identifier corresponding to the server to be reused in each level of the region according to a preset multi-level region division rule;
[0132] According to the arrangement order of the regions at each level, the regional location identifiers corresponding to the servers to be reused in the regions at each level are combined to obtain the on-shelf location identifiers of the servers to be reused.
[0133] In one embodiment, the target location identifier includes regional location identifiers corresponding to regions at all levels; the matching module 1120 is specifically used to determine the matching relationship between the target location identifier and the regions at all levels of the on-rack location identifier of the server to be reused in descending order of the regions at all levels;
[0134] The servers to be reused with the same minimum matching area are determined as a server set.
[0135] In one embodiment, the first determining module 1130 is specifically configured to use the priority of the minimum matching area corresponding to the server set as the priority of the server set;
[0136] The server sets are sorted from high to low according to their corresponding priorities, and the server set with the highest priority is used as the target server set.
[0137] In one embodiment, the second determination module 1140 is specifically configured to determine the priority corresponding to the target server set;
[0138] If the priority reaches a preset priority level, determining any server in the target server set as a target reuse server;
[0139] If the priority does not reach the preset priority level, a path planning rule is obtained, and the path value of each server in the target server set is determined based on the path planning rule, and the server with the minimum path value is determined as the target multiplexing server.
[0140] In one embodiment, the second determination module 1140 is specifically configured to obtain a path planning rule corresponding to the target server set based on a minimum matching area corresponding to the target server set;
[0141] The determining the path value of each server in the target server set based on the path planning rule includes:
[0142] According to the path planning rule, a path value between the target location identifier and the unmatched area corresponding to the on-rack location identifier of each server in the target server set is calculated.
[0143] In one embodiment, the second determination module 1140 is specifically configured to grid the computer room area according to the width and length of the server cabinet if the minimum matching area belongs to the same computer room area, and calculate the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server according to the computer room area path planning rule;
[0144] If the minimum matching area is an area belonging to the same building or the same floor, the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server is calculated according to the preset area path value matrix and the floor area path planning rule;
[0145] If the minimum matching area belongs to the same campus area, the path value of the unmatched area between the target location identifier and the in-place location identifier of each server is calculated according to the regional path value matrix and the campus path planning rule.
[0146] Each module in the server multiplexing device can be implemented in whole or in part by software, hardware, or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute operations corresponding to each module.
[0147] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig.12 As shown. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a server multiplexing method is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covered on the display screen, or a button, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.
[0148] Those skilled in the art will understand that Fig.12The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0149] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.
[0150] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0151] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0152] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0153] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0154] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A server multiplexing method, characterized in that: The method comprises: Obtaining an on-rack position identifier of a server to be reused, wherein the server to be reused refers to a server that has exited the server application process but is still on the rack and waiting to be powered on and deployed again; Matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set; Determine a target server set that meets preset requirements according to the priorities corresponding to the server sets; Determining a target multiplexing server in the target server set to perform multiplexing processing on the target multiplexing server, wherein the multiplexing processing refers to a process of re-powering on and redeploying the target multiplexing server; The target location identifier includes the regional location identifiers corresponding to the regions at all levels; the on-shelf location identifier is matched with the target location identifier of the expected on-shelf location of the server, and the servers to be reused are grouped according to the obtained matching results to obtain a server set, including: determining the matching relationship between the target location identifier and the regions at all levels of the on-shelf location identifier of the servers to be reused in descending order of the regions at all levels; and determining the servers to be reused with the same minimum matching area as a server set; Determining the target server set that meets the preset requirements according to the priorities corresponding to the server sets includes: taking the priority of the minimum matching area corresponding to the server set as the priority of the server set; and sorting the server sets from high to low according to the priorities corresponding to the server sets, and taking the server set with the highest priority as the target server set.
2. The method according to claim 1, characterized in that The step of obtaining the on-rack location identifier of the server to be reused includes: According to the preset multi-level regional division rules, determine the regional location identifiers corresponding to the servers to be reused in the regions at each level; According to the arrangement order of the regions at each level, the regional location identifiers corresponding to the servers to be reused in the regions at each level are combined to obtain the on-shelf location identifiers of the servers to be reused.
3. The method according to claim 1, characterized in that Determining the target multiplexing server in the target server set includes: Determine the priority corresponding to the target server set; If the priority reaches a preset priority level, determining any server in the target server set as a target reuse server; If the priority does not reach the preset priority level, a path planning rule is obtained, and the path value of each server in the target server set is determined based on the path planning rule, and the server with the minimum path value is determined as the target multiplexing server.
4. The method according to claim 3, characterized in that The obtaining of the path planning rule includes: Based on the minimum matching area corresponding to the target server set, obtaining a path planning rule corresponding to the target server set; The determining the path value of each server in the target server set based on the path planning rule includes: According to the path planning rule, a path value between the target location identifier and the unmatched area corresponding to the on-rack location identifier of each server in the target server set is calculated.
5. The method according to claim 4, characterized in that The calculating, according to the path planning rule, a path value between the target location identifier and the unmatched area corresponding to the rack location identifier of each server in the target server set comprises: If the minimum matching area belongs to the same computer room area, the computer room area is gridded according to the width and length of the server cabinet, and the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server is calculated according to the computer room area path planning rule; If the minimum matching area is an area belonging to the same building or the same floor, the path value of the unmatched area between the target location identifier and the on-rack location identifier of each server is calculated according to the preset area path value matrix and the floor area path planning rule; If the minimum matching area belongs to the same campus area, the path value of the unmatched area between the target location identifier and the in-place location identifier of each server is calculated according to the regional path value matrix and the campus path planning rule.
6. A server multiplexing device, characterized in that: The device comprises: An acquisition module, used to acquire an on-rack position identifier of a server to be reused, wherein the server to be reused refers to a server that has exited the server application process but is still on the rack and waiting to be powered on and deployed again; A matching module, used for matching the on-shelf position identifier with the target position identifier of the server's expected on-shelf position, and grouping the servers to be reused according to the obtained matching results to obtain a server set; A first determination module, used to determine a target server set that meets preset requirements according to the priorities corresponding to the server sets; A second determination module is used to determine a target multiplexing server in the target server set to perform multiplexing processing on the target multiplexing server, wherein the multiplexing processing refers to a process of re-powering on and redeploying the target multiplexing server; The target location identifier includes the regional location identifiers corresponding to the regions at all levels; the matching module is specifically used to determine the matching relationship between the target location identifier and the regions at all levels of the on-rack location identifiers of the servers to be reused in descending order of the regions at all levels; and the servers to be reused with the same minimum matching area are determined as a server set; The first determination module is specifically configured to use the priority of the minimum matching area corresponding to the server set as the priority of the server set; sort the server sets from high to low according to their corresponding priorities, and use the server set with the highest priority as the target server set.
7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 5 are implemented.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.
9. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
Mounting position checking method for servers in batches
CN103428034A
Server position distribution method, electronic equipment and computer readable storage medium
CN109587997A