his running mate and he came in third place with 6.9% of the vote. After the election a conflict broke between front runners Sergei Bagapsh and Raul Khajimba, which was only resolved when the two teams agreed to hold new elections in which they would participate on a joint ticket. During the crisis on 15 October Shamba had founded the Social-Democratic Party of Abkhazia along with other people from his election campaign, chief of staff Gennadi Alamia became its first chairman. The Social-Democratic Party called on voters to boycott the new elections and Shamba did not participate in it. Minister for Foreign Affairs (second time) and Prime Minister On 15 December 2004 Shamba had again been appointed Minister for Foreign affairs by Ardzinba, replacing Igor Akhba. The power-sharing agreement between Bagapsh and Khajimba stipulated that the latter could appoint the new Minister for Foreign Affairs, and Khajimba chose to keep Sergei Shamba, despite the fact that Bagapsh long insisted on appointing Natella Akaba. Even though Shamba had now joined the government, the social-democratic party stayed in opposition. On 20 May 2009 the Social-Democratic Party was one of a number of opposition parties that during a press conference strongly criticised the government's foreign policy. The criticism was rejected by Shamba two days later, dismissing it as "biased". Despite being considered by some to again be a possible candidate, Shamba did not participate in the December 2009 presidential election. The election resulted in a second term for Sergei Bagapsh, and on 13 February 2010, Shamba was appointed prime minister, succeeding Alexander Ankvab, who had become vice president. On 26 February Shamba was succeeded as Foreign Minister by his deputy Maxim Gvinjia. August 2011 presidential election and retirement from active politics The next presidential election was originally scheduled to take place in 2014, however, the Constitution of Abkhazia required an election to be held within three months after the unexpected death of incumbent president Sergei Bagapsh on 29 May 2011. Only three candidates participated: Shamba, outgoing Vice President and Acting President Alexander Ankvab and opposition leader Raul Khajimba. Shamba's vice presidential candidate was deputy chairman of the State Committee for Youth Affairs and Sport Shamil Adzynba. The pair was nominated by an initiative group on 8 July and applied for registration on 16 July. All presidential candidates passed their Abkhaz language test on 20 July 2011, were formally registered by the Central Election