Libya is struggling to keep its electricity and gas on amid clashes and fighting with rebels that have driven out foreign providers from the north African country, Reuters reported.

Blackouts lasting at least 10 hours have been reported in the major cities of Tripoli and Benghazi. The electricity was so weak in areas to the east that cellphone coverage was nonexistent this week.

"The network has been broken up in separate regions which has a negative impact, is leading to instability and cases of total blackouts," the country's state electric company said, according to Reuters.

Officials can't even get access to some power plants, including one in Hun, due to rebels fighting for power in the area ever since the ousting of former dictator Muammar Gaddafi in 2011. The electric company tried repairing the entire system but has been unable to because Libya's foreign partners have fled, according to Reuters.  

The conflict has now broken down between an internationally recognized prime minister and parliament and a rival group that established its own government after occupying Tripoli in August, forcing the prime minister to flee to the east.

Attacks on oil bases- like one last week where 10 people were killed after gunmen stormed the al-Mabrouk oilfield- have slowed production. Libya now produces about 350,000 oil barrels a day, about one-fifth of what it was in 2013, Reuters reported. An attempted seize on Libya's biggest gas port, Es Sider, carried out by militants allied with Tripoli rebels resulted in the port being shut down since December. 

Meanwhile, the United Nations is expected on Wednesday to resume attempts to broker an agreement on a single government between the opposing parties.