retry agent command 10 times