A method for adjusting a deployment location of a virtual machine, wherein the method comprises: determining, according to a topology structure of a network in which a virtual machine is located, and a relationship between physical servers to which any two virtual machine nodes i and j in the network belong, a communication cost C ij (i≠j) between the nodes i and j, wherein C ij is a quantity of switches between i and j if i and j do not belong to a same physical server, C ij is a preset value if i and j belong to a same physical server, a value of i comprises all natural numbers that are not greater than N, a value of j comprises all natural numbers that are not greater than N, and N is a quantity of virtual machine nodes in the network; performing a data smoothing algorithm on C ij, to obtain a corrected value C ij ' of the communication cost between the two virtual machine nodes i and j; obtaining a traffic statistical value D ij between the two virtual machine nodes i and j that is in a preset historical period; calculating a corrected adjacency degree A ij ' between the two virtual machine nodes i and j according to C ij ' and D ij; performing a minimum cut algorithm on a corrected adjacency degree graph comprising the virtual machine nodes in the network, to obtain at least two sets, wherein each set comprises at least one virtual machine node, different vertexes in the corrected adjacency degree graph are respectively corresponding to different virtual machine nodes, and an edge with a weight value A ij ' exists between two vertexes corresponding to the two virtual machine nodes i and j; and adjusting a deployment location of a virtual machine node in the network according to the at least two sets, so that for any virtual machine node x, if x and a virtual machine node y belong to a same set, and x and a virtual machine node z belong to different sets, a communication cost between x and y is not greater than a communication cost between x and z. determining, according to a topology structure of a network in which a virtual machine is located, and a relationship between physical servers to which any two virtual machine nodes i and j in the network belong, a communication cost C ij (i≠j) between the nodes i and j, wherein C ij is a quantity of switches between i and j if i and j do not belong to a same physical server, C ij is a preset value if i and j belong to a same physical server, a value of i comprises all natural numbers that are not greater than N, a value of j comprises all natural numbers that are not greater than N, and N is a quantity of virtual machine nodes in the network; performing a data smoothing algorithm on C ij, to obtain a corrected value C ij ' of the communication cost between the two virtual machine nodes i and j; obtaining a traffic statistical value D ij between the two virtual machine nodes i and j that is in a preset historical period; calculating a corrected adjacency degree A ij ' between the two virtual machine nodes i and j according to C ij ' and D ij; performing a minimum cut algorithm on a corrected adjacency degree graph comprising the virtual machine nodes in the network, to obtain at least two sets, wherein each set comprises at least one virtual machine node, different vertexes in the corrected adjacency degree graph are respectively corresponding to different virtual machine nodes, and an edge with a weight value A ij ' exists between two vertexes corresponding to the two virtual machine nodes i and j; and adjusting a deployment location of a virtual machine node in the network according to the at least two sets, so that for any virtual machine node x, if x and a virtual machine node y belong to a same set, and x and a virtual machine node z belong to different sets, a communication cost between x and y is not greater than a communication cost between x and z.