GLENVILLE, Minn. – For more than three years, the SoyMor biodiesel plant sat idle — victim of a slump that took down more than a quarter of the plants in the industry.

But biodiesel is booming again, and a sign of the revival happened last month in this small southern Minnesota town. Workers started up the plant in August, and soon the fuel was flowing.

“Everybody kept their fingers crossed and hoped it would be a lot shorter,” rehired worker Aaron Kuennen said of the long layoff as he unloaded tanker trucks full of soybean oil.

Across the nation, biodiesel plants have been restarting or ramping up production, spurred on by a revived federal tax credit and renewable energy mandates. The industry’s trade group, the National Biodiesel Board, last month reported that U.S. production is headed toward a record year after three consecutive months of record output.

It comes after biodiesel’s big bust. At least 52 of the nation’s 170 biodiesel plants were idled last year, and others scaled back production, according to the U.S. Environmental Protection Agency. In the two years ending last December, output of U.S. biodiesel for trucks and heavy equipment fell 54 percent.

In Minnesota, the Glenville plant outside of Albert Lea was among the first to shut down. It originally was called SoyMor Biodiesel LLC, but its local owners in July sold the plant to the company that built and formerly managed it, Renewable Energy Group Inc., based in Ames, Iowa.

The plant’s sign now is draped with a temporary one bearing the company’s initials: REG.

Another of Minnesota’s four biodiesel plants, FUMPA Bio-fuels in Redwood Falls, has remained shuttered since December. The plant, the state’s first biodiesel producer in 2004, is for sale, and because it’s small and portable, it likely will be moved after new owners purchase it, said Chuck Neece, who heads the biofuels division of cooperative that owns it.

The U.S. biodiesel industry grew out of a desire by soybean farmers to get better prices early in the last decade.

Minnesota began requiring that biodiesel be blended into diesel fuel sold at pumps in 2005, and now mandates a 5 percent mix. Nineteen other states now offer various incentives in addition to the federal tax credit that has encouraged blenders to use biodiesel in motor fuel.

At first, biodiesel producers relied almost entirely on soybean oil as a feedstock, subjecting it to a chemical reaction with alcohol to produce fuel similar to petroleum diesel. Some plants now have technology to process waste oils from restaurants and unrefined oils and fats from rendering, meatpacking and ethanol industries. About half of U.S. production still is derived from soy oil, industry officials said.

In the industry’s first boom, U.S. output expanded eightfold from 2004 to 2008, peaking at 691 million gallons.

“It was awfully exciting,” said Ed Hegland, a farmer near Appleton, Minn., who served as chairman of the National Biodiesel Board from 2007 to 2010.

Then the troubles hit — the global financial meltdown, trade barriers that hurt sales to Europe and high soybean prices, Hegland and others said. The worst blow came last year when Congress temporarily eliminated a $1 per gallon tax credit to encourage blenders to use biofuel.

“It was extremely difficult to see a renewable energy industry that was just getting legs under it to be so dramatically set back by a number of things out of our control,” Hegland said.

At the Glenville biodiesel plant, one of two large Minnesota plants with capacities of 30 million gallons per year, the end came suddenly in March 2008.

Rachel Asmus, who recently returned to run the plant’s lab, remembered the shock and sadness. “One week I had a job,” she said. “Then they told us we wouldn’t have jobs at the end of the week.”

Biodiesel’s revival began after Congress in December restored the tax credit for another year, and the EPA established higher biodiesel blending mandates under its renewable fuel standards.

At some plants, production ramped up immediately. But the SoyMor plant in Glenville remained idle until it was sold in July in a stock transaction to REG, the nation’s largest biodiesel producer.

In a major industry consolidation, REG has acquired three other plants in the past 18 months. It wants to raise $100 million in an initial stock offering to acquire another plant it now leases. It also wants to complete work on three plants whose construction was halted during the biodiesel bust.

Myron Danzer, who manages the Glenville plant and two others for REG, said the restart went smoothly. Some electrical components had been damaged by a voltage surge. One pipe was damaged by freezing, others needed to be cleaned and everything needed to be tested, he said.

He hired 20 people, including five former workers, and one day last month the first soybean oil was pumped into the system. Six hours later, at 9:14 p.m., Danzer was holding a flashlight and “sitting up on the tank waiting for it to come in.” After the first gallons flowed, everyone gathered in the plant’s control room for a celebration picture.

“It’s been running ever since then,” he said, and over the next 24 hours had processed about 50,000 gallons. Tanker trucks will begin hauling fuel to blenders this week, he said.

After experiencing one bust, many in the industry wonder whether this plant and others will keep running, given the recent resistance in Congress to extending biofuel tax credits. The industry has been lobbying to retain the $1-per-gallon credit, and Rep. Collin Peterson, D-Minn., an industry supporter, is cosponsor of the House bill.

One question is whether the EPA mandate to blend biodiesel into motor fuels — without the tax incentive to blenders — is enough to keep the industry growing. The effect would be to boost the cost of biodiesel to blenders who supply fuel to pumps.

“It will be very, very challenging as we have seen last year with the lapse of the tax credit,” said Hegland, who is on the board of the Minnesota Soybean Growers Association. “I think it would cause a significant downturn in the market.”