I have also encountered situations where data recovery is slow or stuck. I was restoring data in a replica set environment. After checking the log, I found that: if the secondary node is disconnected, when executing the above recovery command on the primary node, due to the Arbiter The heartbeat mechanism will cause the following error:
2016-03-28T16:56:52.304+0800 I REPL [ReplicationExecutor] Error in heartbeat request to 192.168.8.37:27017; Location18915 Failed attempt to connect to 192.168.8.37:27017; couldn't connect to server 192.168.8.37:27017 (192.168.8.37), connection attempt failed
I migrated and imported more than 300 GB of data. It took two days to import only a few hundred MB
I have also encountered situations where data recovery is slow or stuck. I was restoring data in a replica set environment. After checking the log, I found that: if the secondary node is disconnected, when executing the above recovery command on the primary node, due to the Arbiter The heartbeat mechanism will cause the following error:
Then the entire progress bar got stuck.
A situation is provided for reference only.