The city of Rockville may soon be rid of its embarrassing and costly failure in the center of town, after a Bethesda developer has agreed to buy and renovate the now-defunct Rockville Mall.

The developer, Eisinger and Kilbane Associates, took control of the building Thursday, after receiving approval from U.S. Bankruptcy Court. The developer will pay $2 million over the next two years to cover back taxes and improvements on the building, officially known as "The Commons."

"This is the end of an error that has caused us a great deal of difficulty and also bad publicity," Rockville Mayor John Freeland said at a press conference called yesterday to announce the plan. "The mall has been the one thorn in our side that we have been trying very hard to rectify. I think we've done that now."

The reorganization plan is the result of two years of negotiations among the city of Rockville, which owns the Town Center Garage beneath the mall; Rockville Redevelopment Associates, the owners of the mall; New York State Teachers Retirement System, the mortgage holder; and developer Eisinger and Kilbane.

Eisinger and Kilbane plan major reconstruction for the face and the interior of the structure, expected to cost between $20 million and $40 million. The developers plan to reopen the mall for office and retail use once the building is complete. No completion date is set, but construction should begin next spring, Roger Eisinger said.

Eisinger and Kilbane will use the city-owned garage, paying $40,000 rent per year on the garage for the first four years while the city continues to operate it. Eisinger presented Freeland with his first $40,000 check Friday, "for carrying the garage for us."

Freeland responded, "It's the first real income we've had in a long time with the mall."

The mall and parking garage were built in 1969, but failed to draw enough customers because of competition from nearby malls like White Flint and Lakeside. In April 1980, the city notified the owners that they were in default. Two years ago, Rockville Redevelopment began bankruptcy proceedings.

Among the terms of the new agreement, the developer is required to lease a minimum of 30,000 square feet of the mall, almost 10 percent, for retail uses, including space for a movie theatre. Eisinger and Kilbane anticipate a "first-class restaurant and additional eating facilities coordinated around a theme," said John Kilbane. Another 100,000 square feet--one-third of the mall--will be devoted to retail space.

The developer also agreed to convert a minimum of 75,000 square feet, or about 25 percent of the floor space, to office use. The developers said the remaining space would be converted later.

Eisinger and Kilbane have already talked to Tribune-United of Montgomery County, which has shown an interest in opening its county cable television headquarters in the building.

The developer must also provide a pedestrian walkway between the Metro pedestrian bridge and courthouse square. The city of Rockville has reserved the right to review the developer's renovation design plans.

Freeland said Rockville has been losing $568,000 per year since 1980 by paying interest on old debts.