When the repositories change, the apt cache needs updating to bring
in the new indexes. Recently this has failed quite often. In the
hope that we can get more diagnostic information, and in order to
make the tasks a litte easier to read, we split them into two.
Change-Id: I4b1bb0d3c318a1f07b4a1d055faed65691565320