A gunman opened fire at a busy hair salon in the Southern California coastal town of Seal Beach on Wednesday in a shooting rampage that left eight people dead and another critically wounded, police said.

The suspect, who was not immediately identified, fled the scene in a vehicle and was arrested moments later about a half mile away, Seal Beach police Sergeant Steve Bowles told reporters nearly two hours after the shooting.

We feel very confident at this point that we do have the single and only suspect in custody, Bowles said. He appeared cooperative and did not resist our officers at all when he was detained.

The daylight shooting marked a rare outbreak of gun violence for Seal Beach, a quiet Orange County town about 30 miles southeast of Los Angeles, which Bowles said has gone years at a stretch with no homicides, period.

It ranks as the worst mass killing in Orange County's history, surpassing the seven killed and two wounded in a shooting by Edward Charles Allaway at Cal State Fullerton in 1976, according to the Orange County Register newspaper.

Circumstances of the shooting remained murky, and Bowles said detectives were trying to establish a motive for the violence and any link between the gunman and the establishment, called the Salon Meritage.

Former salon employee Lidia Sosa, who went to the crime scene when she heard the news, told reporters the gunman shot and killed his ex-wife, with whom he was embroiled in a custody dispute. The owner of the shopping center, Henry Morales, said he was told by salon employees that the gunman was the former husband of a hair stylist there.

A long-time customer who identified herself only as Karen said she heard about the shooting and called her stylist, who answered the phone in a state of panic.

He was screaming, and the phone went dead. He was hysterical, she said.

SOME INSIDE SALON ESCAPED UNHARMED

Of the nine people struck by gunfire, six were declared dead at the scene and three others were taken to Long Beach Memorial Hospital with critical injuries, Bowles said. Two of those hospitalized later died of their wounds, he said.

Bowles said he did not know how many of the victims were employees or how many were patrons, but the Los Angeles Times reported that the owner of the Meritage was among the dead, citing the man's niece.

Most of the victims were believed to have been shot inside the salon. One man initially listed as wounded was found in the parking lot, but it was not clear where he was shot, he said.

There are survivors from inside the salon that escaped without harm, Bowles said.

The salon, which was filled with customers at the time of the shooting, is located in a large open-air shopping center on Pacific Coast Highway in Seal Beach. The area around the salon was cordoned off with yellow crime-scene tape, and several nearby streets were blocked off by police.

Cindy Spinosa, who works at the Seal Beach Chiropractic Center across the street from the salon, said she and others were left shaken by the outburst of violence.

It's such a quiet little community. We don't experience things like this, she said.

A salon customer who identified herself only as Cindy and a resident of Anaheim told the Orange County Register she was getting her hair colored when the gunman walked in, approached a female stylist near her and opened fire.

She said the man then shot a woman who was getting a shampoo before turning the gun on Cindy's stylist and shooting him. I just kept hearing, 'boom, boom, boom, boom,' she said. I ran out out. I didn't see his face. I just saw the gun in his hand and him shoot anybody.

Overhead television footage broadcast on KCAL9-TV showed a white pickup truck left parked by a roadside about a half mile from the shooting scene. The station reported that a number of weapons were recovered from the vehicle by police.

Bowles said the type of weapon or weapons used by the gunman was not immediately known.