Alviro Petersen has retired from international cricket following the Test series against West Indies and will take up a Kolpak deal in English county cricket. The strong suggestion is that Lancashire are the favourites to sign the opener, whose last county stint was with Somerset in 2014.

Petersen played 36 Tests, scored 2093 runs at 34.88 with five hundreds, including one on debut against India in Kolkata. He informed the South Africa management of his decision on the second day of the New Year's Test but revealed that he had considered calling it a day months before.

"It's something I started thinking about over the last six or eight months. I felt I need to move on with my career," he said. "There are some good young players coming through and I think it's about time."

After Graeme Smith stepped down in March, Petersen was the senior opening partner and absorbed a significant portion of the responsibility that came with Smith's departure. He stood at slip next to Hashim Amla, the man who took over the leadership from Smith, and played an active role in mentoring the younger batsmen who came into the squad.

It was only five years ago that Petersen was one himself, but he stepped up to the big stage immediately with an impressive showing in tough conditions at an intimidating venue. Petersen's hundred against India at Eden Gardens was one of the few highlights in a match South Africa lost comprehensively and he listed it as one of his happiest moments in the game. "Just when I walked onto the field at Eden Gardens making my debut, that was one of my best moments," he said.

Petersen went on to play eight more matches before he was dropped in favour of Jacques Rudolph, who returned from England in a streak of good form. Petersen's response was a century for South Africa A on a green pitch in Potchefstroom against the touring Australians and when Rudolph underwhelmed, Petersen was recalled. He scored a century in his comeback match against Sri Lanka in Cape Town and earned a reputation for silencing the critics when it mattered most.

He formed a solid opening stand with Smith which totaled 52 innings, amounted to 2113 runs at an average of 42.36 and made his most significant contribution in South Africa's successful mission for the Test mace. Petersen's 182 at Headingley was instrumental in securing a draw for South Africa, which allowed them to maintain a series lead over England. "It was one of the more satisfying hundreds I have scored. I knew I had to pull through," Petersen said.

South Africa won the next game at Lord's and claimed the top Test ranking, which barring a few weeks in 2014, they have held on to since. But Petersen himself has struggled to maintain those standards. He was overshadowed by his new partner Dean Elgar, who has already scored three centuries from 15 Tests and faced pressure from Stiaan van Zyl, who, like Petersen, scored a hundred on debut. Petersen admitted that took a toll on him.

"It was frustrating in the last couple of months and I would have liked to have scored more," he said. "I was a little bit disappointed because I prided myself on getting in and getting big hundreds."

In his last 27 innings, Petersen did not manage a single century although he got 14 scores over 20, including three half-centuries, and retained the support of both the coach, Russell Domingo, and Amla. Until the end, both said they expected a big score was "around the corner for Petersen", but it never came.

Petersen's final innings lasted only ten minutes and ended with an inside-edge onto his stumps. Only then, did he realise it was over. "I can't even remember the last couple of overs last night but when I walked off the field and I realised I was out, that was the first time I started thinking about it all," he said. "If I could play that innings again, I'd do it differently."

What Petersen does not regret is the timing of his decision. Even though he leaves South Africa as a team in transition, he is confident the calibre of the players coming through will ensure the process continues smoothly. "South Africa has got a great leadership group. Players move on but the game will always remain," he said. "South Africa is in good hands."

According to Domingo, Petersen is to thank for some of that because of what he gave to a team culture that the batsman said he will most. "It's a big loss for our team. He has been a stalwart. There has been a lot of criticism about him, and unfairly so, because he is a standout player for us," Domingo said. Amla also paid tribute: "He has been wonderful for us and handles himself exceptionally well both on and off the field."

South Africa's next Test assignment is six months away, in Bangladesh, which gives them enough time to consider a replacement. In that time, there are six rounds of the first-class competition to be played and a series between South Africa A and the England Lions, in which van Zyl is expected to open. "We've got a good nucleus of players so even though Alviro is not easy to replace, hopefully we will find the right guy," Domingo said.

Firdose Moonda is ESPNcricinfo's South Africa correspondent