Recent network research has focused on the cascading failures in a system of interdependent networks and the necessary preconditions for system collapse. An important question that has not been addressed is how to repair a failing system before it suffers total breakdown. Here we introduce a recovery strategy of nodes and develop an analytic and numerical framework for studying the concurrent failure and recovery of a system of interdependent networks based on an efficient and practically reasonable strategy. Our strategy consists of repairing a fraction of failed nodes, with probability of recovery $gamma$, that are neighbors of the largest connected component of each constituent network. We find that, for a given initial failure of a fraction $1-p$ of nodes, there is a critical probability of recovery above which the cascade is halted and the system fully restores to its initial state and below which the system abruptly collapses. As a consequence we find in the plane $gamma-p$ of the phase diagram three distinct phases. A phase in which the system never collapses without being restored, another phase in which the recovery strategy avoids the breakdown, and a phase in which even the repairing process cannot avoid the system collapse.