MOGADISHU, Somalia — Gunmen who stormed a hotel in Somalia’s capital have taken an unknown number of hotel guests hostage, police said Saturday, as the attackers set up snipers on the rooftop and were throwing grenades.

Capt. Mohamed Hussein said some attackers had moved to the second floor and were using machine guns to resist security forces.

Police said at least seven people had died and 10 others were wounded, according to Reuters. NBC News could not immediately confirm the reports.

Image: Explosion and gunfire at Mogadishu hotel


Image: Explosion and gunfire at Mogadishu hotel

Police told The Associated Press that the attack on the Nasa-Hablod hotel in Mogadishu began when a suicide bomber detonated an explosives-laden vehicle at its gate. Gunmen fought their way inside, and a witness said they began shooting randomly at hotel guests.

Hussein said security forces have killed two of the attackers.

Related: Al-Shabab Car Bomber Targets Hotel in Somali Capital

He also said he saw four bodies, thought to be civilians, lying outside the hotel.

It was not known how many attackers entered the hotel, nor how many guests were inside.

Image: A vehicle burns at the scene of a suicide bomb attack outside Nasahablood hotel in Somalia's capital Mogadishu


Image: A vehicle burns at the scene of a suicide bomb attack outside Nasahablood hotel in Somalia's capital Mogadishu

The attackers “took positions behind blast walls and sandbags; fighting is still ongoing,” Hussein said, as gunfire could be heard in the background.

A witness, Ali Mohamud, said the attackers randomly shot at guests. “They were shooting at everyone they could see. I escaped through the back door,” he said.

Yusuf Ali, an ambulance driver, told The Associated Press that he evacuated 11 people injured in the attack to hospitals.

“Most of them were wounded in crossfire,” he said.

There was no immediate claim of responsibility for the attack. The Somalia-based, al Qaeda-linked al-Shabab extremist group has been waging a deadly insurgency across large parts of Somalia and often employs suicide car bomb attacks to penetrate heavily fortified targets in Mogadishu and elsewhere.

In early June, an overnight siege by extremist gunmen at another hotel in the capital killed least 15 people, including two members of parliament. Al-Shabab claimed responsibility for that attack.

The latest attack comes during the Muslim holy month of Ramadan, during which extremists often step up attacks in this volatile East African country.

The assaults in the seaside capital have highlighted the challenges facing the Somali government and African Union forces that are struggling to secure the country. An attack on another Mogadishu hotel and public garden in February killed at least nine civilians. A car bomb outside a restaurant in the capital in April killed at least five.

The al-Shabab insurgents have been ousted from most of Somalia’s cities but continue to carry out bombings and suicide attacks.