1. A virtual-machine managing apparatus comprising: a memory that stores delay times between a plurality of managers managing a virtual machine; and a processor that: extracts a migration route from a source manager to a target manager based on the delay times between the managers stored in the memory such that the delay times between the managers are equal to or shorter than a threshold; and migrates the virtual machine from the source manager to the target manager through the migration route while maintaining the operation of the virtual machine, wherein, when the delay time of the virtual machine between the source manager and the target manager exceeds the threshold, the processor extracts the migration route through at least one route manager by carrying out: a first process of selecting, among managers being disposed on the migration route between the source manager and the target manager and being included in the plurality of managers, a first route manager that has the delay time from a first manager being equal to or less than the threshold and that has the delay time from the second manager being lowest, and a second route manager that has the delay time from the second manager being equal to or less than the threshold and that has the delay time from the first manager being lowest, the first process being started, regarding the source manager and the target manager as the first manager and the second manager, respectively; and a second process of replacing the first manager with the first route manager selected in the first process and replacing the second manager with the second route manager selected in the first process, the first process and the second process being alternately carried out until the first route manager coincides with the second route manager.