The exodus of foreigners from Libya gathered pace Sunday as the government said at least 22 people were killed in clashes in Tripoli and warned of a "worsening humanitarian situation".
Thousands of Egyptians seeking to flee the strife-torn North African country were being airlifted home after being allowed into neighbouring Tunisia, many after a wait of several days at a border crossing.
And a British navy ship was evacuating Britons from Tripoli, the defence ministry in London said.
On the political front, a formal opening session of Libya's elected parliament scheduled for Monday hung in the balance, with Islamists insisting on a Tripoli venue and nationalists calling for it to be held in the eastern city of Tobruk.
The parliament, elected on June 25, is to take over from the interim General National Congress (GNC) chosen in the wake of the 2011 revolt which toppled longtime dictator Moamer Kadhafi.
"We're in a situation where we have two different authorities: a legislature in Tobruk and another on the ground which dominates the three big cities," Tripoli, Benghazi and Misrata, all Islamist strongholds, said political activist Salah al-Bakush.
The latest flare-up of violence, which erupted on Saturday, takes the death toll in Tripoli to 124 since July 13, with more than 500 wounded.
A medical source said the weekend casualty figures of 22 dead and 72 wounded did not cover hospitals outside Tripoli, in particular in the town of Misrata which has sent fighters to the capital.
The transitional government said "several hundred" families had been displaced and there was a "worsening humanitarian situation" in Tripoli, where petrol, bottled gas and food supplies are scarce.
On Sunday, most shops and banks were shut and the sky was filled with black smoke from a fuel depot ravaged by a fire resulting from clashes over the past two weeks.
Tripoli airport has been closed and several aircraft destroyed or damaged in the clashes between rival militias.
The unrest is seen as a struggle for influence, both between regions and political factions, as Libya plunges into chaos, with authorities failing to control the dozens of militias in the absence of a structured regular army and police force.
Signup to our newsletter and follow us on Facebook and Twitter!
- Egypt airlift, British warship -
In Tunisia, buses started on Saturday to pick up Egyptian evacuees at the Ras Jedir border crossing to take them to Jerba airport, 100 kilometres (60 miles) north, for flights back to Egypt, AFP journalists said.
Egypt's civil aviation minister, Hossam Kamal, said 1,796 people had been taken to Jerba and another 1,355 were to be transferred there on Sunday, with five flights home planned.
Tunisia had refused to admit people who were neither Libyan nor Tunisian unless they could prove they would be immediately repatriated and were only in transit.
The government said it could not cope with a large number of Arab or Asian workers fleeing Libya as it did in 2011.
The Ras Jedir crossing was shut on Friday and part of Saturday after violent clashes between Libyan border guards and hundreds of Egyptians who had tried to storm the border post.
On Sunday, the crossing was operating normally.
Ahmed Ali, a 42-year-old labourer, told AFP that he and 6,000 other Egyptians had spent since Wednesday out in the open, under the blazing desert sun, and had survived thanks to daily food handouts by the Libyan Red Crescent and at times by locals.
"Our situation was desperate, that's why we exploded on Friday and tried to force our way across the border. We want to go home," he said.
Since mid-July, Libya has seen deadly clashes been rival militias in both Tripoli and the eastern city of Benghazi.
Tripoli airport has been closed since gunmen, mostly Islamists, attacked it in a bid to wrest control from the Zintan brigade of former rebels who have held it for the past three years.
Britain's defence ministry, meanwhile, said HMS Enterprise, which had been on a Mediterranean deployment, arrived off Tripoli on Sunday.
"A number of passengers were transferred to Enterprise by boat and given supplies for the journey," it added.
A foreign ministry spokesman said that most of those being evacuated from Tripoli, believed to number around 100, were British.