MOGADISHU (Reuters) - A Somali general and at least seven of his bodyguards were killed on Sunday when their vehicle was rammed by a car bomb driven by an al Shabaab suicide attacker in the capital, police and the Islamist group said.

Al Shabaab, which frequently launches attacks on officials in Mogadishu, staged this attack in the build-up to a vote for a new parliament and president, part of efforts to rebuild a nation that has been shattered by two decades of war and chaos.

“Military General Mohamed Roble Jimale and at least seven of his bodyguards died,” police colonel Abdikadir Farah told Reuters. “The suicide car bomb hit the car they were in. May God rest their souls.”

The general was known by the name Goobaanle. Somalis often have a nickname that is as commonly used as their proper name.

Somalia’s Andalus radio, which is linked to al Shabaab, said “a mujahid (fighter) was martyred as his suicide car bomb killed General Goobaanle.” It said further details would follow later.

Al Shabaab, which once ruled much of Somalia, wants to topple the Western-backed government of President Hassan Sheikh Mohamud, who is seeking re-election in the upcoming vote.

Voting for the 275-seat parliament is scheduled to start on Sept. 25 and end on Oct. 10, with new lawmakers sworn in on Oct. 30. Those lawmakers will, in turn, pick a president on Oct. 30.

Due to security concerns, including the continuing al Shabaab insurgency, voting will not be based on one-person-one-vote but instead about 14,000 people representing federal states across the nation will choose members of the legislative assembly.

That is a fraction of Somalia’s 11 million people, but is more than the 135 elders who picked the outgoing parliament in 2012.