Obama was also briefed by the national security team on the shootout.
"The President spoke with Prime Minister Harper moments ago," White House Press Secretary Josh Earnest told reporters.
Earnest said Obama was briefed earlier today in the Oval Office by his top homeland security adviser Lisa Monaco.
"The details about the nature of this event are still sketchy, which is not unusual in a chaotic situation like this one," Earnest said.
More From This Section
Noting that Canada is one of the closest friends and allies of the US, Earnest said, "From issues ranging from the strength of our NATO alliance to the Ebola response to dealing with ISIL, there's a strong partnership and friendship and alliance between" the two countries.
"The United States strongly values that relationship, and that relationship makes the citizens of this country safer," he said.
"That includes officials here in the White House," Earnest said.
The State Department said the US Embassy in Canada was also locked down.
"We are following the active shooter situation in Ottawa, near the National War Memorial and Parliament. Canadian Parliament Hill and our embassy in Ottawa are on lockdown," State Department Deputy Spokesperson Marie Harf told reporters.
"Our thoughts and prayers are with the victims and their families. We have full confidence in Canadian law enforcement officials. Secretary (John) Kerry, who's on his plane on the way back from Berlin, has been briefed on the situation and is following it closely," she said.
"ISIL has demonstrated a capacity to use social media and other aspects of modern technology to try to radicalise citizens in other countries," Earnest said.
The Canadians were active participants in the United Nations Security Council meeting that the president convened last month in New York that was focused on this specific issue of countering foreign fighters, he said.
"The concern that the United States and other countries around the world harbors is that these individuals could return to their home countries and carry out acts of violence," Earnest said.