A disgruntled worker killed by police after he allegedly opened fire on colleagues felt mistreated on the job and angry about a recent suspension, according to friends and acquaintances.

Authorities say Shareef Allman, 47, gunned down his co-workers during a routine safety meeting at Lehigh Southwest Cement's Permanente Plant near Cupertino on Wednesday. Three people died and six were wounded.

Officials believe Allman also shot a woman in an attempted carjacking a couple of hours after fleeing the quarry.

Allman was shot and killed by police Thursday after an intense manhunt in the Silicon Valley suburbs, authorities said.

Sheriff's officials late Thursday said they had obtained a surveillance video of Allman that was taken from a security camera that showed Allman walking with a rifle after the shooting.

Authorities have not released any details about a possible motive, other than to say the suspect was disgruntled.

Allman's friends and colleagues said he had complained about being treated unfairly by his managers, but still were baffled that he apparently resorted to violence.

Allman was recently suspended after he accidentally hit a power line while dumping a truck load at the quarry, according to Bill Hoyt, secretary-treasurer of Teamster's Local 287.

Allman visited his labor union offices less than a week before the quarry shooting, Hoyt said.

"He told me he had gotten a suspension and didn't feel that the punishment fit the crime," Hoyt said. "But he was fine, and didn't seem angry, we talked and joked around. There was nothing weird about him." I was shocked to hear what happened."

Another longtime friend, Walter Wilson, said Allman complained of racism at work, but he didn't think it was a major issue for him.

"As far as I know he was the only African-American truck driver," Wilson said. "He told me the company was racist."

"I tried to tell him to go through the process, and he said he felt like he had it under control," said Wilson, who last saw Allman three weeks ago at a music festival and described him then as happy and jovial.

On Thursday, three deputies on routine patrol encountered the man matching Allman's description around 7:30 a.m. in a residential neighborhood in Sunnyvale, about five miles east of the cement plant, Santa Clara County Sheriff Laurie Smith said. He was crouched behind a vehicle in the driveway of a home.

The deputies opened fire after the man "displayed in a threatening manner his firearm," Smith said. He praised their work, saying they "did a great job at the scene."

"I'm glad that we were able to reach a resolution. It's unfortunate that an additional person died, but it's over, and my concern is the public safety of the county," Smith said.

News that Allman was the suspect in these attacks shocked his friends, who described him as a devoted single father of two and a longtime community volunteer.

In addition to working at the quarry, Allman had run a nonprofit group for youths and produced and hosted a public access television show for CreaTV in San Jose. He also wrote a novel titled "Saving Grace," about the evils of domestic violence.

Close friend Brandon Powell said he was horrified to learn of the shootings because Allman had mentioned taking a gun to work days before the attack, but Powell, 20, believed the man he called "uncle" was joking.

Powell told The Associated Press that Allman visited him in Sacramento on Saturday and showed off a recently-purchased AK-47 assault rifle. Allman was an avid gun collector who was registered with the state, he said.

When Powell asked Allman what the gun was for, Allman said: "'There's some racist people at my job. They're messing with me,'" Powell recalled.

"We started laughing, so I didn't think he was serious," Powell told the AP in a phone interview Thursday. He added, "He wouldn't hurt nobody. He's not that type of person. He must have snapped."

Powell said he had not contacted authorities but would be willing to speak with them.

Sheriff's spokesman Lt. Rick Sung said Thursday that he was not aware of Powell's claims. He added that any information regarding Allman's motive would be part of the ongoing investigation.

According to authorities, Allman became upset around 4 a.m. Wednesday during the meeting at the quarry. He left briefly and returned with a handgun and rifle and started shooting people, Lt. Sung said. About 15 workers were at the meeting.

The dead were identified as Manuel Pinon, 48, of Newman, Calif., and John Vallejos, 51 and Mark Munoz, 59, both of San Jose. Six others at the quarry were wounded and taken to hospitals, where some were in critical condition, Smith said.

Carmen Rodriguez went to the intersection about a mile from the quarry where families were gathered awaiting word of relatives on Wednesday. She said she was looking for her sister, who is married to Munoz. She held a box of tissues as she spoke to reporters about her brother-in-law, Mark Munoz.

"I just got word that he was one of the ones shot," she said. "It's just devastating to me."

Rodriguez said Munoz was a father and grandfather and cared for his elderly mother. In his free time, he liked to restore old Volkswagen Beetles. He worked at the quarry for 20 years and was looking forward to retirement.

"He was very loving, very caring, and he couldn't wait to retire," she said.

The carjacking victim, a Hewlett-Packard contract employee, was in fair condition at Santa Clara Valley Medical Center, hospital spokeswoman Joy Alexiou said.

During the ensuing manhunt for Allman, schools were locked down in Cupertino, home of Apple Inc., and in nearby communities. Authorities went door to door with guns drawn and residents were warned to stay indoors.

"The SWAT stormed in like ninjas, and they took a position in our front bedroom," said Jenny Martin, a resident of the neighborhood searched by authorities Wednesday and where man believed to be Allman was killed.

Authorities said they found Allman's car, and collected a shotgun, a handgun and two rifles believed to belong to the suspect.

___

Associated Press writers Jason Dearen and Sudhin Thanawala in San Francisco contributed to this report.