Similar connections are round with Latin 're-' and English 'with'. 'Re-' means (1) again and (2) back. 'With' originally meant 'against', as in 'withstand', and then replaced 'mid' (German 'mit'), which didn't survive Middle English.

Perhaps the original idea was 'in the opposite direction', and this gave the 'opposed to' sense of words like 'against', and the 'back' sense, and then from changing direction and going back to something you get the 'once more' idea. The later meaning of 'with' would come from things like ladders being with walls, extended to general location.

A look at a Greek dictionary shows their prefixes 'palin-' and 'ana-' seem to have a similar variety of uses.