BATON ROUGE, La. (CBSNewYork/AP) — A gunman killed three Baton Rouge police officers on his birthday, CBS News reports.

Sources told CBS News the suspect was identified as Gavin Eugene Long, a 29-year-old black man from Kansas City, Missouri. He was born July 17, 1987.

According to CBS News, Long was honorably discharged from the Marines in 2010 after serving since 2005, reaching the rank of sergeant. He served in Iraq from June 2008 to January 2009, and records show he received several medals during his military career, including one for good conduct.

This is the second time in just over a week that a former member of the military killed police officers. Micah Johnson, the gunman who killed five Dallas police officers, was an Army veteran.

CBS News reports Long ranted about protests and oppression on YouTube under the pseudonym Cosmo Setepenra.

“Let’s just go with the numbers, let’s go with the history, 100 percent of revolutions of victims fighting their oppressors, from victims fighting their bullies, 100 percent have been successful through fighting back, through bloodshed,” Long said in one video. “Zero have been successful just over simply protesting. It has never worked and it never will, you gotta fight back. That’s the only way a bully knows to quit, he doesn’t know words.”

Long continued, “If y’all want to keep protesting, do that, but for the serious ones the real ones, the alpha ones, we know what it’s going to take, it’s only fighting back or money that’s all they care about. Revenue and blood … nothing else. You’re in a world that’s run by devils.”

Long made the video in Dallas last week where five police officers were killed by Army veteran Micah Johnson.

On an Amazon profile, Long claims to have written three books.

“After completing an Associate’s degree in General Studies at Central Texas College, Cosmo then attended Clark Atlanta University to further his education. After a year and a half at Clark Atlanta as a dean’s list student, he had a spiritual revelation that resulted in him dropping out of college, selling his two cars, giving away all of his material possessions, packing two suitcases and journeying to Africa—his ancestral homeland,” the profile reads.

WATCH: LIVE COVERAGE OF BATON ROUGE SHOOTINGS | PHOTOS

Missouri court records show that a Gavin Eugene Long filed a petition for divorce from his wife in February 2011. The online court records don’t say why the couple divorced, but the petition indicates they had no children and that Long had represented himself. Three months after the divorce petition was filed, his ex-wife was granted restoration of her maiden name. Last month, on June 7, a case against Long by the city of Kansas City over unpaid city earnings taxes was dismissed.

Police said the suspect was shot and killed at the scene. Authorities initially believed that two other assailants might be at large, but hours later said the dead gunman was the only person who fired at the officers.

However, a state police spokesman said investigators were unsure whether he had some kind of help from others.

“We are not ready to say he acted alone,” Major Doug Cain said.

Two people were detained in the nearby town of Addis, but they were questioned and released. No charges were filed against them.

The shooting — which took place just before 9 a.m., less than a mile from police headquarters — came amid escalating tensions across the country between the black community and police. The races of the suspect and the officers were not immediately known.

It was the fourth high-profile deadly encounter in the United States involving police over the past two weeks. The violence has left 12 people dead, including eight police officers, and sparked a national conversation over race and policing.

President Barack Obama said the slayings were attacks “on the rule of law and on civilized society, and they have to stop.” He said there was no justification for violence against law enforcement and that the attacks are the work of cowards who speak for no one.

Sen. Bill Cassidy told CNN “there’s a war right now on police.”

The attack began at a gas station on Airline Highway. The slain shooter’s body was next door, outside a fitness center. Police said they were using a specialized robot to check for explosives near the body.

Gov. John Bel Edwards rushed to the hospital where the shot officers were taken.

“There simply is no place for more violence,” Edwards said. “That doesn’t help anyone. It doesn’t further the conversation. It doesn’t address any injustice perceived or real. It is just an injustice in and of itself.”

A witness told television station WAFB that he saw a masked man in black shorts and shirt running from the scene where the three officers were killed.

On Sunday afternoon, more than a dozen police cars with lights flashing were massed near a commercial area of car dealerships and chain restaurants on the highway. Police armed with long guns stopped at least two vehicles driving away from the scene and checked their trunks.

That area was about a quarter of a mile from a gas station, where almost nightly protests had been taking place.

Five officers were rushed to Our Lady of the Lake Regional Medical Center, hospital spokeswoman Ashley Mendoza said.

Of the two who survived the shooting, one was in critical condition and the other was in fair condition. Multiple police vehicles were stationed at the hospital, and a police officer with a long gun was blocking the parking lot at the emergency room.

One officer was sent to Baton Rouge General Medical Center and was being treated for non-life-threatening injuries, spokeswoman Meghan Parrish said.

Officers and deputies from the Baton Rouge Police Department and East Baton Rouge Sheriff’s Office were involved, Hicks said.

Each of the officers was married and had a family, East Baton Rouge Parish Sheriff Sid Gautreaux said.

Police-community relations in Baton Rouge have been especially tense since the death of 37-year-old Alton Sterling, a black man killed by white officers July 5 after a scuffle at a convenience store. The killing was captured on widely circulated cellphone video.

It was followed a day later by the shooting death of another black man in Minnesota, whose girlfriend livestreamed the aftermath of his death on Facebook. The next day, a black gunman in Dallas opened fire on police at a protest about the police shootings, killing five officers and heightening tensions even further.

Thousands of people have protested Sterling’s death, and Baton Rouge police arrested more than 200 demonstrators.

Sterling’s nephew condemned the killing of the three officers.

Terrance Carter spoke Sunday to The Associated Press by telephone, saying the family just wants peace.

“My uncle wouldn’t want this,” Carter said. “He wasn’t this type of man.

Michelle Rogers said Sunday the pastor at her church had led prayers Sunday for Sterling’s family and police officers, asking members of the congregation to stand up if they knew an officer.

Rogers said an officer in the congregation hastily left the church near the end of the service, and a pastor announced that “something had happened.”

“But he didn’t say what. Then we started getting texts about officers down,” she said.

Rogers and her husband drove near the scene, but were blocked at an intersection closed down by police.

“I can’t explain what brought us here,” she said. “We just said a prayer in the car for the families.”

(TM and © Copyright 2016 CBS Radio Inc. and its relevant subsidiaries. CBS RADIO and EYE Logo TM and Copyright 2016 CBS Broadcasting Inc. Used under license. All Rights Reserved. This material may not be published, broadcast, rewritten, or redistributed. The Associated Press contributed to this report.)