The explosion killed and wounded police officers in the compound and local residents in homes nearby, officials said.
At least nine children were said to be among the wounded, Svetlana Gorbakova, of the regional branch of the Russian prosecutor general's office, said.
Dmitry Medvedev, Russia's president, said on Monday that he had sacked Ingushetia's interior minister following the attack.
"Today I've made the decision to relieve Ingushetia's interior minister of his duties," Medvedev said at a meeting in the city of Astrakhan on Russia's Caspian Sea coast.
"This terrorist act could have been avoided," he said in comments shown on state television.
Medvedev also said that Rashid Nurgaliyev, Russia's interior minister, should submit to the Kremlin "concrete proposals on how to bring about order and strengthen cadres within Ingushetia's interior ministry".
'Out of control'
Kremlin authorities have largely blamed Islamist fighters for recent violence in the region, which lies in Russia's volatile North Caucasus.
Shaun Walker, the Moscow correspondent for the UK's Independent
newspaper, told Al Jazeera that attacks in the region appeared to becoming "nastier and more frequent".
"Although there is a lot of violence in this region on a regular basis, it's still relatively unusual to have suicide bombings and a bombing of this scale," he said, adding Monday's attack appeared to be the work of the "local Islamic insurgency".
"These attacks have been happening with alarming regularity. What we've seen in the last week or so is a series of slightly larger scale attacks.
"Taken overall it is a really quite a scary picture for Russia and the leaders of these republics.
"In a sense it does seem a little bit like the Caucasus is spiralling out of control."
Last week, Ruslan Amerkhanov, the region's construction minister, was shot dead inside his own office.
Yunus-Bek Yevkurov, Ingushetia's president, was badly injured in June after a suicide bomber attacked his car.
Yevkurov, who is due to return to work in the next several days, said Monday's attack was an attempt to destabilise the region, and blamed the West for fomenting unrest in the North Caucasus.
"I am miles from believing that Arabs are behind this. There are other, more serious forces there... We understand whose interests these are: the United States, Britain, and Israel too," he told the Russian News Service (RSN) radio.
"The West will keep seeking to prevent Russia from reviving the former Soviet might," he added.
Moscow has long struggled to impose the Kremlin's authority in the North Caucasus region, which has been the site of two wars in Chechnya and hundreds of violent attacks since the 1991 collapse of the Soviet Union.
While large-scale fighting in Chechnya, Ingushetia's neighbour, has ended, rebels continue to mount hit-and-run attacks and skirmishes.
Bloodshed has surged in recent months and increasingly spilled into the republic's neighbours.