Canada's front-line fighting role in Afghanistan officially ended Tuesday when soldiers of the Royal 22e Regiment handed battlefield combat responsibilities over to the Americans.

Almost all Canadian troops are out of Kandahar's dangerous combat zones, except for a few soldiers who are attached to American platoons for a few more weeks.

Canada's war in Afghanistan is now effectively over after five years of fighting throughout farmland and dusty villages in one of the country's most dangerous areas. It cost Canada the lives of 157 soldiers, one diplomat and one journalist, not to mention the many soldiers left with life-altering injuries.

Canadians have been working towards completion of the combat mission since Parliament voted in 2008 to end the mission by July 2011.

A low-key ceremony happened at Ma'sum Ghar in Kandahar province, marking the changeover in combat roles.

On Thursday, Canada's Brig.-Gen. Dean Milner will formally hand over his command of NATO troops in Panjwai and Dand districts to an American counterpart.

Canadian troops won their first major victory at Ma'sum Ghar in 2006, taking the area from the Taliban after a vicious and bloody battle.

"Everywhere in battle where Canadian soldiers have sacrificed their lives, we have examples of similar places in a number of our conflicts," Lt.-Col. Michel-Henri St-Louis, the Van Doo battle group commander said.

"Ma'sum Ghar is symbolic and had been at the centre of our deployment and was witness to much of our sacrifices."

Ma'sum Ghar, a petrified volcanic mountain, was first captured by Canadian troops in the summer of 2006 after fighting throughout the districts of Panjwaii and Zhari.

It was then used as a launching point in a 2006 battle known as Operation Medusa. Most Canadian combat operations in the region started in Ma'sum Ghar, which was frequently attacked by insurgents' rockets and mortars.

The attacks were so frequent that soldiers made a mock workplace safety sign counting the days since the last rocket attack.

But on Tuesday, the area was still.

Lt.-Col. Steve Miller, commander of the 3rd Battalion 21st U.S. Infantry Regiment and the new military head of the region, said the area is much quieter than he expected.

"We actually expected this fight to be more kinetic than it had been in the last 30 days," he said. "This area has not seen the spike (in violence) that usually occurs here during the spring following the poppy harvest."

Much of that peace and quiet can be attributed to the Canadian Van Doos, who sought out and seized major caches of insurgent weapons over the past six months.

Military analyst Mercedes Stephenson said Canada's troops made great sacrifices in Panjwai, and also great progress in terms of improving the quality of life for locals.

"It's a place where Canada really built a lot of nationhood both within Afghanistan and for ourselves on the international stage," Stephenson told CTV News Channel.

Virtually all of Canada's troops have already transitioned out of Afghanistan's battle areas and are either awaiting transport home from Kandahar Airfield, or have already been shipped home.

Another 950 Canadian soldiers will remain in Afghanistan in a training role until 2014, and will be based out of Kabul.

The goal of that mission, Stephenson said, is to develop the "long-term exit strategy from Afghanistan, and that means developing indigenous capacity for the Afghan forces...develop them in a way that they can stand on their own two feet."

One of the key tasks, she said, will be to ensure that all members of the Afghan police and military are trained to a professional standard.

Currently, Stephenson said, different regions and branches of the police and military have been trained by NATO members, often with wildly different standards.

She said Canadian trainers will work to develop a "professional ethos" among the police and military.

Canada's Mission Closure Unit is now tasked with the job of tearing down, cleaning, packing and shipping all of Canada's gear. Everything from tanks to desks and computers will be cleaned, sterilized and sent home.

The goal is to have that work completed by the end of the year.

With files from The Canadian Press