The massive undertaking by Oakland officials and police to prepare for protests would be an exceptional challenge for most Bay Area cities. In Oakland, it's become the new normal.

It involves months of planning, orchestrating hundreds of police and other public workers, and has cost millions of taxpayer dollars.

The Occupy Oakland protesters who took to the streets last week were largely peaceful. But the city had prepared for the worst: They surrounded the protesters with more than a hundred officers on bicycles, motorcycles, all-terrain vehicles, cars,

vans and foot.

Meanwhile, inside a downtown building, dozens of city, county, regional and state workers gathered at the city's Emergency Operations Center to provide support and coordinate the troops on the streets.

Three officers sat at computers monitoring Twitter and other social media for clues on protester plans. Other officers coordinated the taking of internal affairs complaints, and some oversaw the gathering of street intelligence. Five televisions and several other screens showed live streaming video from locations around the city.

"This is a huge task, but it's our job to ensure public safety," said Officer Johnna Watson, a department spokeswoman.

There have been 16 such mobilizations over the past year, according to city spokeswoman Karen Boyd. The cost for Occupy events alone has been $4.8 million from Oct. 10, 2011, through July 3.

The city braces itself because on Oct. 25, Nov. 2 and Jan. 28, Watson said, "we did see disruptions and violence to community members and law enforcement. It's incumbent upon us to ensure that we have all of the logistics and safety precautions in place."

The city has increasingly been the region's base for protest. But a violent clash between Oakland police and Occupy protesters last October intensified that status, making international news. Police command staff say their goal is to allow peaceful expression of First Amendment rights - and they stress they won't tolerate vandalism or other crimes.

Enormous scrutiny

Deputy Police Chief Darren Allison outlined tactics and policies to officers before they hit the streets Thursday. But he also gave them a simpler but more fundamental goal: "Be safe."

The operations place officers under a phenomenal amount of scrutiny. Past police failures to abide by crowd-control policies have helped push the department toward possible federal control. At the same time, a slew of protesters come ready to catch any misstep with a multitude of cameras.

"Assume that you are being filmed," Allison told his men. "There's a lot of video out there."

Although Thursday was relatively incident-free - only two people were arrested - the work was intense.

At one point, at least 150 protesters marched by the Cathedral of Christ the Light, the home of the Catholic Diocese of Oakland, on Harrison Street. Trailing perhaps 50 yards behind protesters were 15 police officers on foot and others in six cars and seven vans.

Bubble around protesters

On parallel streets and in front of the marchers were more officers, in position in case the marchers should turn. Motorcycle cops cleared traffic ahead of protesters, anticipating their movements and keeping potential conflicts with motorists at bay.

This went on for nearly two hours.

"We set a bubble around them," said Lt. Nishant Joshi, who led a platoon of officers for the evening. "As they move, the bubble adjusts."

Part of the police strategy is patience. One protester threw rocks - one of which struck an officer - before hiding in the crowd.

Instead of trying to arrest him immediately and possibly rile up demonstrators, undercover officers tracked him, partly by using some undisclosed technology. They arrested the suspect - identified as Alexander Loutsis, 29, of Stockton, who police say came to the demonstration with a Plexiglas shield - nearly an hour after the first rock was thrown.

"It's tactically smart to have eyes on him and grab him later," said Watson, the police spokeswoman. "The bottom line here is, at the end of the day, is everyone safe?"