integration: attempt more times to listen on specified port

Travis is rather slow, and it may fail to listen on that port sometimes.
Merge pull request #1799 from yichengq/237

integration: attempt more times to listen on specified port