HOUSTON — Dallas Keuchel had a simple answer for what was working for him Tuesday night.

“Everything,” Keuchel said. “I felt good with every pitch.”

Keuchel (4-2) pitched a seven-hitter for his first major league shutout, leading the Astros over the Rangers 8-0.

Keuchel struck out seven without a walk. He gave up just one extra-base hit, a double by Adrian Beltre in the first inning, and threw his second career complete game.

“When you're able to plus and minus your fastball and have the type of command that Dallas has, he's able to ... cut the ball into the righties,” Houston manager Bo Porter said. “He can sink it away from the righties. He runs it in on the lefties. He has confidence to throw his breaking ball, his changeup in any count.”

It was the second straight start where Keuchel hasn't walked anyone, which Porter said shows his confidence in attacking the strike zone. Keuchel didn't think that was a big deal.

“I don't really think about that,” he said. “When I throw strikes I'm good, if I don't I'm not very good.”

The Astros were shut out 4-0 in the series opener but jumped on Matt Harrison (1-1) for three runs in the second before he left with back stiffness. Hoes hit a two-run homer in the frame.

“I felt OK warming up, but looking up (at the radar), I noticed that my velocity just kept going down further and further,” Harrison said. “Then I knew at that point, something wasn't right.”

He said he will go to Dallas on Wednesday to visit a doctor.

The Astros were up by four before a four-run fifth inning powered by an RBI single by Hoes and a three-run shot by Corporan.

The roof at Minute Maid Park was open to start the game, but it was closed during the eighth inning with a storm approaching. It was the first Astros game where the roof was both open and closed since 2006.