Implement clustering, loop over machines until one works