Witnesses said they saw a man armed with a rifle running to the parliament building after the shooting, and some local media cited reports that there may have been a second shooter.
One witness, Marc-Andre Viau, said he saw a man run into a caucus meeting the parliament, chased by police who yelled “take cover.” That was followed by “10, 15, maybe 20 shots,” possibly from an automatic weapon, he said.
“I’m shaken,” said Viau, who works at the parliament.
The soldier appeared seriously wounded. Emergency medics were seen pushing on his chest to revive him.
Heavily-armed police raced to seal off the parliament building and the office of Canadian Prime Minister Stephen Harper.
Harper left the area of the shooting and was “safe,” his spokesman Jason MacDonald said.
The incident came a day after a 25-year-old driver ran over a soldier, killing him before being shot dead by police, in what the government said was a terrorist attack.
Authorities had raised the security threat level from low to medium after that incident.
Outside parliament, police were seen taking cover behind vehicles, as others expanded a cordoned off area to a city block around parliament.