The Astros, who have won four in a row and 12 of their past 13, moved to within four games of Milwaukee in the National League Wild Card race.
Since the All-Star break, the Astros are a Major League best 34-16. The Astros are 11 games over .500 for the first time this season.
Berkman went 3-for-4 with his 28th home run. His four RBIs gave him 100 for the season, the sixth time in his career he's reached that benchmark. Only Jeff Bagwell (eight) had more 100-RBI seasons in franchise history.
"You come into every season with goals, but I feel like if I can hit certain goals I'm doing my part to help the team win, and 100 RBIs is one of those, so I'm pleased about that," Berkman said. "The name of the game for a guy like me is scoring runs and driving guys in, so those are two stats that are really important to me personally, because that's really my job and what I'm supposed to do to help this team win."
Berkman, who snapped an 0-for-18 streak on Monday, is 5-for-7 in the series.
"We need Lance to step up," Astros manager Cecil Cooper said. "Tonight he was big and we need him to continue to lead our club, because he is our big horse in the middle. So is Miguel Tejada.
"Those are the guys we count on, those are the guys we rely on. They've swung it well lately, that's what we need them to do and then everybody else just chip in."
Darin Erstad scored twice and drove in another run on a three-hit night, and Tejada also contributed three hits as the Astros scored three times off Pirates starter Ross Ohlendorf (0-1) in the first inning before building an 8-2 lead by the end of the fifth.
Wolf (10-11) gave up a pair of runs during a 35-pitch first inning, but settled in after that. The left-hander allowed only one baserunner over the next five frames -- a single by pinch-hitter Robinzon Diaz -- and needed just 56 pitches to retire the 16 batters he faced during that span. He allowed three runs on four hits in seven innings.
"I just don't think I was very aggressive in the first inning in pounding the strike zone," Wolf said. "As the game went on I was more aggressive. Sometimes you get caught in the trap of trying to throw the ball away from the bat instead of to the bat."
Houston improved to 8-1 in Wolf's nine starts since he was acquired from San Diego in July.
The game also saw the first use of instant replay at Minute Maid Park, as crew chief Tim Welke reviewed video of a ball hit by Houston's Hunter Pence in the sixth inning. Ruled an RBI double initially, that call was upheld upon review of the video.
"Those guys are great at what they do and they got the call right," Pence said. "I was pretty grateful when I was out there that they wanted to make sure they got the call right. I was kind of indifferent on [instant replay] until a situation came up where it could change things, and now I think it's a great thing for baseball and I can't say enough about those guys."
Jim Molony is a reporter for MLB.com. This story was not subject to the approval of Major League Baseball or its clubs.