Updated

Thousands of Russian troops streamed into a province bordering war-torn Chechnya on Tuesday to search for heavily armed militant separatists who killed at least 57 people in fierce attacks. President Vladimir Putin vowed to stop the spreading insurgency.

The coordinated assaults on police and border guard facilities in the republic of Ingushetia was also a graphic demonstration of Russian forces' vulnerability to Chechen guerrillas. The rebels recently vowed to step up their fight for an independent Muslim state, and their insurgency has already spilled over occasionally into neighboring regions.

Putin ordered authorities "to find and destroy" the attackers, whose raid came amid preparations for an August election to replace the Kremlin-backed Chechen president.

Troops searched for the attackers, who officials said may have come from Chechnya and were believed to have melted into the thick woods along the Chechen border or were trying to flee over the Caucasus Mountains into Georgia.

Visiting Ingushetia after the attacks, Putin said a regiment of Interior Ministry forces would be stationed permanently in the province. The move raises the number of Russian troops in the troubled Caucasus region even as Moscow tries to distance itself from the war in Chechnya, west of Ingushetia.

Meeting with Ingush President Murat Zyazikov, Putin said the search for the attackers must go on "as long as necessary." He thanked those who "did not allow the bandits to achieve their goals."

Maj. Gen. Ilya Shabalkin, spokesman for the Russian forces in Chechnya, blamed Chechen rebels for planning the attacks, but said the raids were carried out by fighters recruited from both Chechnya and Ingushetia, the Interfax-Military News Agency reported.

Chechnya has seen two wars since the early 1990s, and violence has occasionally spilled into Ingushetia, a republic that has remained comparatively stable. A significant recruitment of Ingush fighters could mean a spreading of the war beyond Chechnya.

"The attacks were clearly saber rattling, aimed to demonstrate the rebels' effectiveness to attract funding from foreign terrorist networks," Shabalkin said, according to Interfax.

Earlier, officials said some fighters shouted "Allahu akbar" -- a frequent rallying cry of Chechnya's separatist rebels as their insurgency increasingly comes under the influence of radical Islam.

The brazen assaults also raised new doubts about the Kremlin's strategy in Chechnya. Unable to defeat the rebels and refusing to negotiate with them, the Kremlin has banked on restoring stability through civil measures, including holding elections for a Chechen president and promising the republic a substantial amount of autonomy.

However, Kremlin-backed Chechen president Akhmad Kadyrov was assassinated by a bomb in May. Last week, Aslan Maskhadov, Chechnya's former separatist president, said the rebels were preparing new offensives.

Rebels stage small deadly hit-and-run assaults daily in Chechnya. Despite an arsenal of heavy weapons and warplanes, Russians have been unable to uproot the insurgents. In the past day alone, nine servicemen were killed, an official in the Moscow-backed Chechen administration said Tuesday.

Beslan Khamkoyev, Ingushetia's acting interior minister, said at least 57 people died in the Ingushetia attacks, which broke out after dark Monday; 47 of them were law-enforcement officers or officials, Khamkoyev said, according to the ITAR-Tass news agency.

Russian news media reported only two deaths among militants. An Associated Press reporter also saw the body of one militant near Yandare. At least one group of rebels were caught by police as they retreated through Galashki, near the Chechen border, said Yakhya Khadziyev, spokesman for Ingushetia's Interior Ministry.

The U.N. office of humanitarian aid coordination in Russia said a U.N. worker, Magomed Getagazov, was killed in crossfire while returning home from work in Nazran, the main city in the province.

Russian television broadcast footage of smoke-charred buildings and burned-out vehicles.

Shamil Basayev, one of the most audacious Chechen commanders, was likely behind the highly coordinated attack, Chechnya's Interior Minister Alu Alkhanov said, told ITAR-Tass. Alkhanov is the Kremlin-supported candidate in Chechnya's coming presidential elections.

Russia's NTV television showed footage of its crew encountering some of the presumed attackers, wearing masks and speaking accented Russian, at a border crossing with North Ossetia. One of the attackers, carrying an automatic weapon, identified the group as "the Martyr's Brigade," according to NTV correspondent Maxim Berezin. The man added, "We have shot everyone here. Go and announce that."

Acting Ingush Interior Minister Abukar Kostoyev, the health minister and a deputy interior minister were killed in the fighting, officials said. ITAR-Tass said Nazran city prosecutor Mukharbek Buzurtanov and Nazran district prosecutor Bilan Oziyev also died.

"Wherever we were, there were armed people, some in uniform, some not, and you didn't know whose side they were on," said a firefighter in Nazran who identified himself only as Aslan.

Although Chechnya is a largely Muslim region in overwhelmingly Christian Russia, the first of Chechnya's two wars was an essentially secular conflict. However, after Russian troops pulled out when Chechen rebels fought them to a standstill, the separatists increasingly took on a specifically Islamic mantle.