With long lines of motorists and generator owners searching for gasoline in the aftermath of Hurricane Sandy still a fresh memory, Red Bank officials are taking steps to require filling stations in the borough be equipped with a backup energy source for the next big blackout.

At Wednesday’s borough council meeting, Mayor Pat Menna recommended amending  licensing requirements to mandate that stations have a backup power source by January 1, 2016.

With millions of middle Atlantic region residents left with no electricity for days – in some cases, weeks – after the October 29 storm, many had a hard time finding gasoline for their vehicles and home generators because gas stations also lost power to run their pumps.

The result was long lines of cars and people toting gas cans waiting for rationed gasoline at the few area stations that either still had electricity or had backup generators.

The borough is home to only three filling stations, one of them with a spotty record of remaining open in even the best weather. But Menna characterized the proposed licensing amendment as a public safety issue.

“People didn’t think that the maintenance of the traffic flow in and out to control the mass of humanity that came to our gas stations didn’t cost us anything,’’ Menna said. “It cost us a lot. We had to have police overtime to manage the crowds and the flow, we had to have volunteers from fire and first aid squads. And that took a great deal of time.”

The amendment would require that any existing gasoline station planning improvements include a backup energy source when filing for permits. All stations would be required to have backup energy sources by 2016.

Menna said the council will study a draft ordinance similar to measures being passed  “in many urban areas, not only in this state but in other states.’’

“That would eliminate a lot of the problems that we had. [A backup power source] is a cost of doing business. And I think it’s a safety factor that ultimately will help a lot.” The plan, he said “will give the business owners a substantial amount of time to comply.”