The invention relates to the technical field of physical machine power control and cloud computing virtual machine migration, in particular to an Openstack based physical machine remote maintenance method. The method comprises: firstly, establishing an Openstack cloud platform and setting an IPMI address, an IPMI login user name and a password of a physical machine; secondly, searching for an available physical node in a normal state according to a greedy algorithm at a control node of the Openstack cloud platform, sending an instruction of migrating a virtual machine to the available physical node to a target physical machine through a component, and after all virtual machines are migrated, sending a shutdown command to a baseboard management controller (BMC) of the target physical machine; and finally, executing a request by the BMC of the target physical machine, and returning an executive result. According to the method, the problems that the virtual machines need to be migrated before physical machine maintenance, a Juno version of the Openstack open source cloud platform cannot perform remote physical machine maintenance, an application cannot be ensured to be normally and continuously used, inconvenience is provided for the operation and maintenance personnel to maintain the physical machine, and the like are solved; and the method can be applied to physical machine maintenance and virtual machine migration of the cloud platform.