Added procedure for resyncing.

Just keep restarting until things start working. :P