One minute Eric Foster was touting cheese-making as a way to put the endangered family dairy farm on easy street. The next, his wife, Holly, was elbow deep in a vat of curds and whey, struggling to keep their morning's work from literally going down the drain.

As the Fosters made Maryland's first legal batch of raw milk cheese on their Easton dairy farm this week, cheese-making didn't look particularly easy - except when compared to all the work the couple had to do to get to this point.

For years, Maryland has banned the sale of raw milk because of health concerns. The ban also applied to products made with raw milk, even though such products made outside Maryland could be sold here.

Now, Maryland has started a test project allowing several dairy farms to produce raw milk cheese that is aged at least 60 days, a process that mimics pasteurization. And the Fosters' Chapel's Country Creamery is the first to start production.

"Don't expect too much," Eric Foster said with a laugh as he used a tool the size of an oar to stir the curds and whey.

But expectations are high. That three months from now - good Lord and good bacteria willing - the curds and whey will become fine blue cheese. That the blue cheese will command at least $22 a pound at farmers' markets and retailers such as Whole Foods. That this family farm can survive.

The last is perhaps the greatest challenge at a time when small dairy farms around the country are failing because of competition from mega milk producers, declining export markets and plummeting wholesale prices. The number of dairy farmers in Maryland has dwindled to 547 from about 800 just 10 years ago, according to state records.

To break even milking 85 grass-fed Jersey cows on their 114-acre farm, Eric and Holly Foster - both 39, with four children - need to make about $1.75 a gallon.

"You don't get rich, but you could pay your bills" at that price, Eric Foster said. "You could fix a flat tire."

Within the past two years, the Fosters got as much as $2.40 a gallon. Now the price is down to about $1.17 a gallon.

"This is the worst dairy crisis that's occurred in the last 100 years," he said. "It's just a bad spiral."

Cheese-making could help farms like theirs survive, even thrive, because the farmer reaps the return on a "value-added" product instead of a rock-bottom commodity.

"Cheese is the equivalent of $20 a gallon - $250 worth of milk, hopefully, becomes $3,000 worth of product," Eric Foster said.

But they can't make that churning out ordinary supermarket cheese. They need to tap into a high-end, niche market. Using raw milk helps them do that because the so-called "good bacteria," which would be killed in pasteurization, enhances the flavor.

"The way we're trying to market this cheese, it has to be a good cheese. It has to be the best of the best," said Eric Foster. "We can't compete with Kraft, which can just mass produce [pasteurized cheese] by the tractor-trailer load. It's artisanal, small-scale cheese-making."

The Fosters have been making upscale raw milk cheese for four years by carting their milk to Pennsylvania, which has looser milk laws. There, an Amish cheesemaker has helped them turn it into several varieties of cheddar, including a $20-a-pound, cave-aged "reserve" cheddar.

The oddest aspect of this arrangement: The Fosters turned around and sold the cheese in Maryland - legally. State law banned production of raw milk cheese, based on concerns that it could harbor dangerous bacteria, but did not prohibit its sale.

A chance encounter with a cheese-loving state senator helped change that little-known legal quirk. A few years ago, the Fosters were asked to provide a cheese table at a fundraiser for then-Gov. Robert L. Ehrlich Jr.

State Sen. Richard F. Colburn "kept coming back for cheese and he said, 'This is great. And to think it's all made right here in Talbot County,' " Holly Foster recalled.