He remains holed up in a hotel room, San Rafael police spokeswoman Margo Rohrbacher said.
A woman is also in the room with him, but Rohrbacher said she did not know if the woman is being held against her will. No injuries have been reported.
In order to ensure public safety, I-580 was shut down between U.S. Highway 101 and Sir Francis Drake Boulevard, according to the California Highway Patrol.
Westbound traffic on the Richmond-San Rafael Bridge, which was initially closed after the shooting, was at a standstill Wednesday evening, CHP Officer Marc Johnston said.
"It's practically a parking lot," Johnston said about the bridge. "Cars are traveling less than 10 mph."
Some motorists even ran out of gas, and crews had to assist them, he said.
The CHP also responded to a road rage incident related to the congestion that was quickly quelled, Johnston said.
Some hotel guests have been told to shelter in place or evacuate, depending on their proximity to the suspect's room, Rohrbacher said. Officers continue to talk to the gunman.
The man is suspected of stabbing a clerk during a shoplifting attempt at United Markets at 515 Third St. around 4 p.m. Sunday, Rohrbacher said.
The suspect took groceries from the supermarket and walked out without paying, according to police. The shoplifter was stopped and brought back inside the store, where he was questioned. During the questioning, he threatened an employee and held a knife to the employee's throat, police said.
Police said he then ran out of the store and several employees chased him. He unsuccessfully attempted to stab an employee from the meat section, but then stabbed a clerk in the chest. The victim's injuries were not serious, police said.