Each year, members of the Oakland Fire Department’s fire prevention team ascend the meandering roads of exclusive bungalows and estates perched on the city’s woodland hills. They’re looking for fuel — toppled trees, broken branches and thick underbrush that could power catastrophic wildfires.

Kevin Moore was on inspection duty last month when 911 operators received a call about a suspicious man in the backyard of a home he had checked. That same day, a resident sent an Oakland police officer footage from a home security camera that showed Mr. Moore ringing a doorbell. And when Mr. Moore returned to the area last week for more inspections, a resident confronted him with a cellphone camera and demanded to see his identification.

In each of the cases, Mr. Moore, who is black, was reported to the authorities or viewed suspiciously for simply doing his job, the latest high-profile example in recent months of the treatment faced by many people of color in the United States.

“People need to know that minorities are treated differently in this country,” Megan Bryan, an Oakland firefighter who works with Mr. Moore at Fire Station 24, said Tuesday.