MAIDUGURI, Nigeria (Reuters) - Boko Haram insurgents attacked the outskirts of Maiduguri in northeast Nigeria on Sunday, security sources said, their second assault in a week on a city they hope to make the capital of a breakaway Islamist state.
At least eight people were killed as the militants clashed with soldiers, witnesses and a hospital source said, but the military later said the attack had been repelled.
"There is heavy gunfire going on. Everybody is panicking and trying to flee the area," Idris Abubakar, a resident of Polo suburb on the southwestern outskirts of the city, said.
The insurgents, who arrived in several armed pick-up trucks and on motorbikes, attacked three places in the south of Maiduguri at around the same time, a security source said.
Troops backed by vigilantes had pushed them out of the southeastern outskirts of the city, a spokesman for a local pro-government vigilante group said.
Resident Babagana Lawan said a grenade fell on his house, killing his brother and two factory workers living with him.
In a separate incident in the town of Potiskum, 230 km (140 miles) west of Maiduguri, a suicide bomber blew himself up outside the house of federal legislator Sabo Garbu, killing 10 people, two security sources told Reuters. Garbu was unhurt.
And a suicide bomb attack at a mosque in Gombe town, 300 km (185 miles) southwest of Maiduguri, by a male and a female suicide bomber on a motorbike, killed five people and wounded eight, said a spokesman for National Emergency Management Agency (NEMA) in Gombe.
Growing Boko Haram violence is a big problem for President Goodluck Jonathan, who stands in a presidential election on Feb. 14 that analysts say is too close to call.
The electoral commission is struggling with logistics to enable more than a million internally displaced people to vote.
Capturing Maiduguri, the northeast's main city and the place where the insurgency sprang from five years ago, would be a huge victory for Boko Haram, which controls mostly rural areas along the Cameroon and Chad borders that make up a territory the size of Belgium.
"The terrorists' attack on Maiduguri in the early hours of Sunday was quickly contained," Defense Spokesman Major-General Chris Olukolade said in an emailed statement.
"The terrorists incurred massive casualties. The situation is calm as mopping up operations ... are ongoing."
Last weekend, the military repelled multiple attacks by militants in Maiduguri in which more than 100 people were killed.
Boko Haram has become the main security threat to the stability of Nigeria, Africa's biggest economy and top oil producer, and increasingly threatens its neighbors. The group has killed thousands of people, many of them civilians, and kidnapped hundreds while the government has struggled to forge an effective response.
Last month, its fighters took control of Baga, on the shores of Lake Chad, the headquarters of multinational force comprising troops from Niger, Cameroon and Chad.
Chadian forces killed 120 Boko Haram militants in a battle in the north of Cameroon, the army said in a statement on Saturday. Three of its soldiers were killed.
Gunfire exchanges between the Chadian army and Boko Haram militants resumed again on Sunday afternoon near the Cameroonian locality of Fotokol, a Cameroon army officer told Reuters.
Additional reporting by Chijioke Ohuocha in Lagos, Emma Farge in Dakar, Tansa Musa in Yaounde and Isaac Abrak in Abuja; Writing by Tim Cocks; Editing by Louise Ireland