The United States and four European countries have called for an end to violence in Libya.

The governments of France, Italy, Germany, Britain and the US said in a statement that they "agree that there is no military solution to the Libyan crisis" and expressed dismay that calls for a ceasefire had not been respected.

Libya has two competing governments vying for control after armed groups from the western city of Misrata seized the capital of Tripoli in August, forcing the government of Prime Minister Abdullah al-Thinni to withdraw to the east.

Dozens of people have been killed in Benghazi in days of violence between the Dawn of Libya, an alliance of militias fighting for an Islamist group that has declared a rival government in Tripoli, and pro-government forces led by former General Khalifa Haftar.

The joint statement voiced concern over Haftar's offensive and said Libya's "fight against terrorist organisations can only be sustainably addressed by regular armed forces under the control of a central authority".

Libya has failed to build up state security forces and disarm former rebels who helped remove Muammar Gaddafi, who ruled the country for 42 years until his downfall in 2011.

Haftar has called on civilians to join his forces, that have attacked militias in western town of Kikla in addition to Benghazi in the east.

Civilians have been caught up in the fighting and supplies are running low in areas hit by violence. The UN has proposed a four-day ceasefire in Kikla to allow for the delivery of humanitarian assistance

The US and its four European allies also condemned Ansar al-Sharia, a member of Dawn of Libya, and said "Libya's hard-fought freedom is at risk if Libyan and international terrorist groups are allowed to use Libya as a safe haven".

The statement threatened sanctions against individuals who "threaten the peace, stability or security of Libya or obstruct or undermine the political process".