BESLAN, Russia (Reuters) - A grieving man lies across a grave on the outskirts of this southern Russian town in a cemetery which acts as a silent memorial to one of Vladimir Putin's defining moments as Russian president.
Putin on Wednesday hands over power to his protege Dmitry Medvedev after an eight-year rule that has in part been shaped by his campaign against Islamist insurgents who have fought Moscow along this wild, mountainous border region.
That conflict reached a watershed in September 2004, when heavily-armed Chechen separatist sympathizers seized a school in Beslan. When the siege ended three days later, 334 people -- half of them children -- were dead.
"Beslan was Putin's 9/11," said Oksana Antonenko, at the London-based International Institute for Strategic Studies. "It was a benchmark for Putin's vision of domestic government and a test of him as a leader."
Four years on, Putin -- who will stay on as prime minister -- can claim some real successes in the North Caucasus, a region where Moscow has struggled for centuries to control a volatile mix of Islam, nationalism and clan allegiances.
In Chechnya, centre of insurgency in the 1990s, separatist rebellion has largely been pacified. Moscow has handed responsibility for security to a loyal local warlord.
Since Beslan, the insurgents have carried out no major attacks on civilian targets. In most of the region, people are feeling the benefit of greater stability, and a nationwide economic boom.
Izeta Kuchiyeva, 45, earns her living selling women's clothes imported from Turkey at Beslan's market, tucked away behind a leafy street.
"For years pensions and child benefits were not paid. As soon as Putin arrived they were paid," Kuchiyeva said. "Things have got better under Putin."
But the picture is less tranquil in some parts of the North Caucasus. Chechnya's violence has spilled into the neighboring regions of Dagestan and Ingushetia. Ambushes, shootouts with police and bombings are regular occurrences there.
"He (Putin) is leaving a legacy of stopping terrorist attacks and improving stability but also of growing violence in Dagestan and Ingushetia," said security analyst Antonenko.
Putin forged his reputation for toughness as Prime Minister in 1999 by sending Russian soldiers again into Chechnya where rebels had achieved de facto independence in a 1994-96 war.
His instruction to his soldiers on how to deal with insurgents was: "Smash them in the outhouse." Chechen civilians were routinely caught up in raids to root out rebel sympathizers.
The insurgents hit back, singling out civilian targets in the Russian heartland in bomb attacks and raids that killed hundreds of people.
But on the ground in Chechnya, Moscow's soldiers succeeded in driving the rebel groups into mountain hideouts.
Most of the main rebel leaders have been killed, including Shamil Basayev, once Russia's most wanted man who admitted to organizing the Beslan raid.
Analysts though say the stability is shaky and the loyalty of the former Chechen rebels and their bickering leaders cannot be trusted.
The Beslan school siege -- with its pictures of children running from the building in their underpants and rows of small, bloody bodies that were beamed around the world -- remains a vivid symbol of Putin's war with the insurgents.
Some victims' relatives say some of the blame for the deaths rests with the authorities.
Relatives' groups say officials mounted a botched rescue operation in which heavy arms fire was directed into the school where hostages were sheltering.
An official inquiry into the way the operation was handled has still not filed its final conclusions, and no officials have been convicted.
On the other side of Beslan from the cemetery, three middle-aged women sat on a sofa in a room in a private house.
One of the women saw her two sons and husband die in the siege, another cradled her daughter as she died and the third lost a son.
"Putin is to blame as he is the commander-in--chief," said Emilya Bazarova, 37. "As long as the Putin regime continues there will be no truth, no rights."
Editing by Richard Balmforth