1. A virtual-machine managing apparatus comprising: a delay storage unit that stores delay times between a plurality of managers managing a virtual machine; a route extractor that extracts a migration route from a source manager to a target manager based on the delay times between the managers stored in the delay storage unit such that the delay times between the managers are equal to or shorter than a threshold; and a migration controller that migrates the virtual machine from the source manager to the target manager through the migration route while maintaining the operation of the virtual machine.