Chase Headley doubled home San Diego's lone run in the first inning, giving the Padres a start toward what could have been only their second win in 14 games.
San Diego, however, wound up with just five hits against four Giants pitchers.
San Francisco, meanwhile, produced a 17-hit attack and poured it on late in the game to win its second straight.
Posey's sacrifice fly in the third inning tied the game and he contributed a two-run single during a three-run sixth. San Francisco then sent 10 men to the plate while scoring five times in the seventh with Posey contributing a two-run double in the inning.
Marco Scutaro had RBI singles in both the sixth and seventh.
Chad Gaudin (3-1) picked up the easy win by holding the Padres to a run on three hits in five innings.
Sean O'Sullivan (0-1), starting for the first time in what is his fourth major league season, allowed two runs on six hits in five frames to take the loss.
Lytro unveils camera that can focus a photo after shooting it
Turkey considering to use pistachios to heat country’s first eco-city