Libya faced the challenge of two prime ministers Thursday after parliament named a rival to the existing unity government's chief Abdulhamid Dbeibah, hours after his convoy was targeted in a drive-by shooting.
The appointment of a second prime minister threatens to spark a new power struggle in the war-torn nation.
The House of Representatives, based in Libya's east, "unanimously approved" former interior minister Fathi Bashagha "to head the government," the parliament's spokesman Abdullah Bliheg said.
On Thursday evening Bashagha flew to Tripoli from the eastern city of Tobruk, promising "to open a new chapter" and "reach out to everyone."
Thanking Dbeibah for his work, the former fighter pilot said on his arrival at Mitiga airport that he was "confident" that the government would "respect democratic principles" and hand over power.
The move is expected to deepen rivalries between the eastern assembly and Dbeibah's western-based administration in the capital Tripoli, where experts warned of potential violence.
Dbeibah, a construction tycoon appointed a year ago as part of United Nations-led peace efforts, has vowed he would "accept no new transitional phase or parallel authority" and would only hand over power to an elected government.
The UN will continue to recognise his administration, UN spokesman Stephane Dujarric said Thursday.
The vote came hours after Dbeibah's convoy was targeted in a drive-by shooting in Tripoli, but which caused no casualties.
"Dbeibah is refusing to step down, so there is potential for some kind of conflict in Tripoli and beyond," Amanda Kadlec, a former member of the UN Panel of Experts on Libya, told AFP. "It could get ugly really fast".
Dbeibah's administration had a mandate to lead the country to elections last December 24, but the polls were cancelled amid bitter divisions over their legal basis and the candidacies of several controversial figures.
Parliament speaker Aguila Saleh, who like Dbeibah and Bashagha had been a presidential candidate, has since spearheaded efforts to replace the unity government.
The assembly in the eastern port of Tobruk had considered seven candidates to lead the administration.
But shortly before Thursday's confirmation vote, Saleh announced that Bashagha's only remaining challenger, former interior ministry official Khaled al-Bibass, had withdrawn from the race.
The live television feed cut just before the vote took place.
Libya has seen a decade of conflict since the 2011 revolt that toppled dictator Moamer Kadhafi, leaving a patchwork of militias vying for control over an oil-rich country riven by regional divisions.
Experts warned that Thursday's vote threatens a repeat of a 2014 schism that saw two parallel governments emerge.
"Libya has two prime ministers. Again. Groundhog Day," Anas El Gomati of Libyan think tank the Sadeq Institute wrote in a tweet.