About 19m Kenyans will decide to vote for president Uhuru Kenyatta or the veteran opposition leader Raila Odlinga to run East Africa’s largest economy.

Odinga, who served as the country’s prime minister between 2008 and 2013, is running for president for the fourth time.

At 55-years-old, Kenyatta is Kenya’s youngest leader in history. He is seeking a second five-year term.

People queued overnight to cast their votes, with long lines outside polling stations by 9am on Tuesday morning.

Basic voting equipment has reportedly already created problems, with claims of malfunctioning voting machines circulating online.

If the country’s computerised voting system fails, as it did in 2013 — the votes will be counted manually, and the loser will be likely to challenge the outcome.

However, Independent Electoral and Boundaries Commission (IEBC) spokesman Andrew Limo said that there have only been “three or four cases of malfunction where the system needed restarting” so far.

“Little glitches here and there will be fixed as they occur,” he added.

In the last days of the campaign, a top election official in charge of the electronic voting system was murdered as violence spiralled out of control amid opposition claims of a plot to rig the vote.

Odinga said on the eve of the elections that 11,000 polling stations located beyond cellular telephone networks were vulnerable to manipulation.

“We see it as a deliberate attempt to do some monkey business,” Odinga said.

As part of a massive security roll-out, troops were outside almost every polling station on Tuesday.

3 Things That Will Change the World Today

However, in some parts of Nairobi there were protests because polling stations failed to open on time, resulting in people blocking roads with tyres, The Times reported.

The IEBC wrote in a tweet:

Former US president Barack Obama, whose father was born in Kenya, called for calm in the lead up to the vote.

“The choices you make in the coming days can either set Kenya back or bring it together,” he said in a statement.

“As a friend of the Kenyan people, I urge you to work for a future defined not by fear and division, but by unity and hope,” he added.

In 2007 more than 1,100 Kenyans died and 600,000 were displaced after a disputed election.