SAN CLEMENTE (AP) — It literally was a whale of a job.

Crews on Friday finished removing the 60,000-ton carcass of a rotting whale from a Southern California beach.

READ MORE: Orange County Qualifies To Move Into Least-Restrictive Yellow Tier

A contractor working for the state parks department spent two days using an excavator to cut up the 40-foot whale, which was hauled off to a San Diego County landfill.

The end of the two-day, $30,000 project included skimming the top layer of sand off the Lower Trestles, a surfing beach near San Clemente where the whale washed ashore on Sunday.

That was to eliminate any sand contaminated by the whale’s body fluids.

“As they started to dismember the carcass, they said it was messy but it wasn’t as messy as it could have been,” Rich Haydon, area state parks superintendent, told the Orange County Register.

“It’s to be expected there will be a little bit of a smell down there for a while,” he said, “but I think we dodged a bullet.”

READ MORE: Police Identify Homeless Man Arrested In Palisades Fire

The whale was a tourist attraction for a few days. Despite an overpowering stench, some people skipped work or school to snap photos with the towering carcass.

However, few people were on hand Friday for the finish.

Nick Lind of Newport Beach and Matthew Howell of San Clemente were surfing as the last remnants of the whale were being removed.

“It did have an interesting stench to it, sort of like a rotten baked potato,” Lind said. “It was overpowering when we were near shore.”

Lind said he wasn’t worried about sharks that might have been attracted by the whale’s remains.

MORE NEWS: 'Midnight Run,' 'Beethoven' Star Charles Grodin Dies At 86

(Copyright 2016 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.)