A "disgruntled" worker of an Illinois factory opened fire after being called into a meeting to terminate his employment, killing five co-workers and wounding five police officers before he was shot dead in a gunfight, officials said Saturday.

Aurora Police Chief Kristen Ziman said the suspect, Gary Martin, 45, committed Friday's massacre at the sprawling Henry Pratt Company in Aurora with a .40-caliber Smith & Wesson handgun he should have never been able to possess because of 1995 felony conviction.

Ziman said investigators believe Martin brought the gun to work because he apparently suspected he was going to be terminated from his job.

Killed in the rampage were the company's human resource manager, the plant manager, two warehouse workers and a 21-year-old human resource intern and student at Northern Illinois University who was on his first day of work at the plant.

Another worker at the plant was shot and wounded but expected to survive.

Ziman said four officers were shot by the gunman in the upper and lower extremities within minutes of arriving on the scene. A fifth officer suffered shrapnel wounds, she said.

A sixth officer suffered a minor injury unrelated to the gunfire while responding to the scene, Ziman said.

Gary Martin is pictured in this undated photo released by Aurora Illinois Police Department.(Aurora Illinois Police Department) Gary Martin is pictured in this undated photo released by Aurora Illinois Police Department.

The wounded officers ranged in from age 24 to 53 and have been members of the Aurora Police department between four and 30 years. Ziman said all of them suffered non-life-threatening injuries and four remained in hospitals on Saturday.

Ziman said 911 dispatchers began receiving calls about 1:24 p.m. that there was an active shooter inside the 30,000-square-foot warehouse, where water-pump equipment, pipes and valves are manufactured and stored. Dispatchers could hear shots being fired in the 911 calls, officials said.

Police officers armed with rifles stage near a commercial building where an active shooter was reported in Aurora, Ill., Feb. 15, 2019.(Antonio Perez/Chicago Tribune/TNS via Getty Images) Police officers armed with rifles stage near a commercial building where an active shooter was reported in Aurora, Ill., Feb. 15, 2019.

The chief said Martin reported for work Friday morning and was called into a meeting, where he was informed he was being fired.

"My understanding from the witnesses is that he opened fire right after the termination," Ziman said. "We can surmise that he was speculative about what was going to happen as evidenced by him arming himself with a firearm."

She said investigators are still conducting interviews with Henry Pratt employees to determine why Martin was being terminated after 15 years of employment at the company.

Scott Hall, chief executive officer of Henry Pratt's parent company Mueller Water Products, said during a news conference Saturday that Martin was being fired for a culmination of various workplace rules violations. He declined to reveal specifics of the rules violations.

"In the days and weeks ahead, we will be reviewing every aspect of this tragedy and the steps we need to ensure this horrible incident is never repeated," Hall said.

Hall also said Martin's felony conviction did not surface when he underwent a background check before he was hired.

Martin is believed to have killed Clayton Parks, Henry Pratt's human resource manager; Josh Pinkard, the plant manager; and Trevor Wehner, a human resource intern, Ziman said.

Wehner was a student at Northern Illinois University expected to graduate in May; Parks was an alumnus of the school.

The president of the university, Lisa Freeman, said she announced their deaths with "deep sadness." She added that Friday was Wehner's first day as an intern at Henry Pratt.

Parks graduated from the university in 2014, Freeman said.

"Loss like this is devastating and senseless," she said in the statement. "I ask our university community to please keep the Wehner and Parks families, friends and communities in your hearts and offer them caring thoughts."

Police in Illinois respond to calls of an active shooter in Aurora.(Megan Jones/Beacon News/TNS via Newscom) Police in Illinois respond to calls of an active shooter in Aurora.

Also killed in the shooting were Russell Byer, a mold operator at the facility, and Vicente Juarez, a stockroom attendant and forklift operator, Ziman said.

The first police officers who arrived at the warehouse were immediately confronted by Martin, who allegedly opened fire on them near a front entrance, police said.

Four officers were shot in the first seven minutes of the confrontation with Martin, said Deputy Chief Keefe Jackson.

At least eight SWAT teams and up to 300 officers from numerous surrounding law enforcement agencies swarmed the warehouse and began searching for the gunman and removing victims from the facility, Jackson said.

Lt. Rick Robertson of the Aurora Police Department said police used an armored vehicle to breach the building, crashing through a glass door.

"There was the initial contact with the officers, and then after those shots, everything went quiet," Robertson said.

According to a timeline of the incident released by police officials, it took officers until 2:58 p.m. to locate the gunman hiding in the massive facility.

"He was in a machine shop at the very back corner of the building, farthest from the area that we made entry into the building," Robertson said. "He was probably waiting for us to get to him there in the way it appears and there were some shots exchanged when the officers made their way into that area."

Police in Illinois respond to calls of an active shooter in Aurora.(WLS) Police in Illinois respond to calls of an active shooter in Aurora.

Ziman said Martin was shot multiple times by police. She said it remains unclear if police killed him or if he died from a self-inflicted gunshot wound.

She said investigators found a .40-caliber Smith & Wesson handgun equipped with a laser near Martin, and several spent magazines. She said numerous bullet casings were found throughout the warehouse.

Ziman said Martin purchased the handgun in March 2014 from a gun dealer in Aurora after being issued a firearm owners' identification card in January of that year.

She said when Martin applied for a concealed carry permit on March 16, 2014, he submitted his fingerprints for a background check. But by that time he had already taken possession of the gun, she said.

"During the fingerprinting and background process it was discovered that he had a felony conviction for aggravated assault out of Mississippi. The date of that conviction was Aug. 3, 1995," Ziman said.

She said once the conviction was discovered, Illinois State Police issued him a letter ordering him to surrender his gun, but he did not comply.

Ziman said it remains under investigation whether police made contact with Martin in order to get him to relinquish the weapon.

"Absolutely, he was not supposed to be in possession of a firearm," Ziman said.

She noted that the conviction would not have necessarily shown up on the criminal background check he underwent to get his firearms identification card.

Ziman also said records showed that Aurora police had arrested Martin six times in incidents ranging from traffic violations, domestic battery and a 2008 arrest on suspicion of violating an order of protection.

She said he was last arrested in 2017 by Oswego, Illinois, police on suspicion of disorderly conduct and criminal damage to property.