The first shot in the Cafeteria Wars was fired in January 2011. That was when, under the terms of the new law, a team of dietitians, economists and nutritionists at the Department of Agriculture released the revised meal pattern for school breakfasts and lunches. The rules outlined just what schools — and, by extension, their suppliers — would have to do to continue receiving government subsidies. Both groups were struck by just how aggressive the new rules were. Within a few years, schools would need to switch all of their breads and pastas to whole-grain varieties. Within a decade, the average salt content of a high-school lunch would have to be cut by roughly half. When the school year began in fall 2012, lunches would have to offer twice as many fruits and vegetables, and students would be required to take at least half of them. At the same time, plates had to have fewer “starchy vegetables,” obvious code words for French fries.

The starchy-vegetable lobby was quick to take offense. “We didn’t find favor with efforts to paint certain vegetables as, for unspecified reasons, less healthy than other vegetables,” was how Kraig R. Naasz, the head of the American Frozen Food Institute, which represents about 500 makers of frozen foods and vegetables, explained it. The potato and frozen-food lobbies mobilized, orchestrating waves of letters from lawmakers to Tom Vilsack, the agriculture secretary, that extolled the potato’s low cost and high potassium content. When Vilsack went before the Senate to discuss his budget request for the year, Senator Susan Collins of Maine, a state that is one of the country’s largest producers of spuds, marched into the hearing holding a potato in one hand and a head of iceberg lettuce — no one’s idea of a nutrient-dense vegetable — in the other. “My question, Mr. Secretary,” Collins asked, “is: What does the department have against potatoes?”

This, meanwhile, was a minor skirmish compared with the battle over pizza sauce. Pizza is one of the school-food companies’ most popular products; schools purchase more than $450 million worth every year. Under the old rules, companies could market pizza slices as a product combining grains, protein and a full serving of vegetables. This was possible thanks to a longstanding loophole: Rather than count the two tablespoons of tomato paste on a serving of pizza as two tablespoons of tomato paste, they could count it as eight tablespoons of tomatoes, the theory being that at some point before being processed, the two tablespoons had existed in the form of several whole tomatoes.

The new rule counted two tablespoons of tomato paste as two tablespoons of tomato paste, no more — a change that got the full attention of the Schwan Food Company, a privately held frozen-food behemoth based in Minnesota, with 14,000 employees and roughly $3 billion in annual sales. Schwan manufactures a reported 70 percent of all pizza sold in American schools. Publicly, Schwan emphasized its ahead-of-the-curve efforts to create more healthful slices meeting the new requirements, with whole-grain crusts and low-fat cheese. Less publicly, in comments to the U.S.D.A., the company laid out a series of objections, ranging from the sentimental to the scientific. “Many of the products made with tomato paste appeal to children and help sustain participation in the school-meal program,” the company warned, while also maintaining that the final sodium reductions would be “impossible to achieve without significant technological advances.” (The Academy of Nutrition and Dietetics, among others, agreed with the salt assessment.) Moreover, if sodium were aggressively reduced in school lunches without corresponding changes in home and restaurant meals, Schwan suggested, students would find their school lunches bland and tasteless.

The White House wanted Vilsack to hold firm. They viewed objections to the tomato rule as classic special-interest pleading. The lunch ladies, meanwhile, had filed 11 pages of comments asking for a delay or reconsideration of many of the new rules, and officially they agreed with Schwan about the tomato paste. Marshall Matz found himself, not for the last time, in the middle. The administration, particularly the agriculture secretary, was annoyed by the comments — hadn’t the lunch ladies endorsed the bill? — and Matz counseled caution. But when the lunch ladies’ president sent a letter to the White House pledging to work closely with Vilsack, many in the industry were furious. They viewed it as an apology, perhaps engineered by Matz in an effort to soothe the administration’s ruffled feathers. Some felt that Matz was letting his personal beliefs, and desire to stay close to the White House, override the proper interests of the association. Gary Vonck, a senior executive at one of the country’s largest brokerages for school-lunch products and longtime industry adviser to the School Nutrition Association, told me that “there were a lot of times when people disagreed with him.”

In food circles, OFW Law, the boutique law and lobbying firm where Matz is a partner, is known for its bipartisan roster of lobbyists and its long list of food-industry clients, some with competing interests on legislative or regulatory matters. Matz was not only lobbying for the lunch ladies, who wanted to abolish the mandatory fruit-and-vegetable requirement, but he also was general counsel to the fresh-produce trade association, which loved the requirement. Even allies told me Matz could be vague about which client he was representing in any given meeting. Vonck said, “I think Marshall maybe misunderstood what his role was as it relates to S.N.A.”

That summer, more than a dozen food companies, including Schwan and one of its bigger rivals, ConAgra, recruited their own lunch ladies. They enlisted dozens of school-nutrition directors to join a new group, which they called the Coalition for Sustainable School Meals Programs. To run the new group, they hired a former S.N.A. official named Barry Sackin.