Protesters march during a demonstration calling on militiamen to leave, in Tripoli
Protesters march during a demonstration calling on militiamen to leave (Reuters)

A gunman killed at least seven people and wounded 50 in Tripoli in Libya during a peaceful anti-militia protest.

Thousands of people had marched from a mosque to the headquarters of Misrata militia demanding that it be disbanded and its troops leave Tripoli.

The demonstration followed calls by imams for an end to the armed groups who have rejected demands to disarm two years after the fall of Muammar Gaddafi.

The interim government, which has been struggling to control several militias that still control much of the country, has put a deadline at the end of 2013 for armed groups to disband.

Hundreds of people wielding white flags and national flags and singing the national anthem were confronted by a militiaman who fired as soon as they arrived at the headquarters of Misrata in the Gharghour district.

Saddat al-Badri, leader of Tripoli's local council, told the BBC: "[The gunman] fired their weapons as soon as we arrived. There was a 106mm used and even an RPG [rocket-propelled grenade launcher]."

The attacked came two weeks after Libyan PM Ali Zeidan was seized from a hotel in Tripoli by gunmen. He was later released.

French foreign minister Laurent Fabius said that Paris was considering giving Libya more aid in counter-terrorism operations, including more police training.

"Unfortunately, terrorism is increasing in the Maghreb and Sahel regions. Obviously, those countries are the first to be concerned, but we are too," Fabius said.

"Our action in Mali was spectacular but we need to continue to be there for the Malians, the Libyans and the whole region. It is too important for us."

Nato was expected to strengthen its security forces to counter the militia presence.