Residents of about four blocks of homes along Seal Beach, south of Los Angeles, swept seawater from ground-floor rooms after flooding overnight, and bulldozers reinforced a 6-foot-tall sand berm hastily built to protect shoreline structures.

The berm — a measure normally not needed until winter storms — and the use of pumps prevented more water intrusion during the morning high tide, and another test was expected close to midnight.

Despite the danger, surfers and body-boarders flocked to favored spots such as the notorious Wedge at Newport Beach and Surfrider in Malibu, where a surfer died Tuesday after being pulled from the water. It was not clear whether the death was related to the surf or a medical condition.

Extra lifeguards were on duty, and there were repeated rescues.

‘‘It’s very hectic, stormy and dangerous, really,’’ said Scott Bosco, 26, who surfed Seal Beach for an hour but only managed to catch two waves because of the roughness. ‘‘You live for days like this. I’m definitely coming back later after school.’’

Two cargo terminals at the Port of Long Beach stopped operations late Tuesday because 10- to 15-foot-high wave surges endangered the longshore workers, a port statement said.

The powerful surge also tossed heavy rocks from a seawall onto a road, causing damage and closing the roadway.

On Santa Catalina Island south of Los Angeles, a heavy surge Tuesday night sent sand, water and even some 3,000-pound rocks into a boatyard, causing substantial damage and tossing some drydocked boats off their stands, Avalon Harbor Master Brian Bray said.

The surge also tore away a floating children’s swim platform and closed several docks to incoming traffic Wednesday, although Bray said most boaters chose to wait in mainland harbors for the surge to subside.

The surge also halted all but a handful of the 18 scheduled Catalina Express ferry trips, and one boat that did arrive at Avalon couldn’t tie up at the lurching dock, company spokeswoman Elaine Vaughan said.

The towering waves and rip currents were being produced by swells generated by Hurricane Marie in the Pacific Ocean about 800 miles west of the southern tip of Mexico’s Baja California peninsula. Although Marie will likely weaken to tropical storm levels, life-threatening water conditions were expected to continue through Thursday.

Along the long arc of Southern California coastline, high surf warnings were posted for Los Angeles County south through Orange County, with lesser beach-hazard advisories down to San Diego and as far northwest as San Luis Obispo County on the state’s central coast. The fiercest surf primarily affected south-facing beaches.

At one point in Seal Beach, a lifeguard climbed from the beach to the deck of the pier, sprinted to the end and dove in to rescue a swimmer. That man was successfully brought ashore well down the beach. Orange County Fire Authority Capt. Steve Concialdi said the man was OK.

Along the shoreline, firefighters went door to door, dropping off more sandbags for residents and surveying damage after the initial surge that arrived late Tuesday and topped a 2 1/2 foot beach wall, causing flooding in or around the first row of homes. About 100 residences were affected, Concialdi said.

‘‘This is our worst summer storm, and I’ve been here 42 years,’’ said resident Jerry Rootlieb, who was sweeping out his home Wednesday.

Jaime and Blanca Brown’s seaside home had a foot of seawater throughout the home, garage and carport. Soaked floor tiles in the hallway were buckled, and a dirty line marked the high point of water in almost every room and the garage. Sodden mattresses and carpets were stacked outside.

‘‘What can you do, man? We are just trying to win the war, and we’re just bringing out water. Water, water, water,’’ said the Browns’ nephew, Hector Brown.

At the Wedge, a famous spot where the interaction of swells and a jetty produce gigantic waves, a huge crowd watched surfers took on ferocious waves for a second day. Lifeguards dove into the surf there as well to save a person with the help of a rescue boat.

Lifeguards sought to keep anyone out of the water who did not have strong experience.

‘‘We are pretty careful about who we let in the water,’’ lifeguard Capt. Boyd Mickley told KCAL-TV. ‘‘We look everyone over, talk to them briefly and find out what their experience level is. And we will suggest strongly that today’s not the day for them to go in.’’

The Malibu Pier was closed after seven pilings were knocked loose. State Parks Department official Craig Sap said rangers noticed three more pilings missing Wednesday. The pier’s structural integrity remained sound because of redundancy but people were asked to stay away, he said.

A previously closed pier at Port Hueneme in Ventura County also lost pilings.