PHOENIX (AP) — The Arizona Diamondbacks hustled for extra bases, made some nifty defensive plays and got a dominating performance from their starting pitcher.

At a time when the team has been "wandering," it was good to get back to what made them so successful early in the season.

Zack Greinke struck out nine in six-plus innings to bounce back from his first home loss of the season and the scrappy-again Diamondbacks beat the Houston Astros 2-0 on Monday night.

"We've had some wandering moments and I think today we captured what we are all about in a nine-inning ballgame," Diamondbacks manager Torey Lovullo said. "It's nice to see these guys locked in their focus. They did what they were supposed to when they were supposed to like they've been doing all year long."

Coming off disappointing back-to-back series against two of the NL's best teams, the Diamondbacks had five doubles, including three set up by aggressive baserunning.

Ketel Marte had one to drive in a run off Collin McHugh (0-2) in the second inning and J.D. Martinez had another off the right-hander in the sixth.

The bullpen did its job, with Jorge De La Rosa and Archie Bradley bridging the game to closer Fernando Rodney, who worked around an infield single in the ninth for his 27th save.

Greinke (14-5) was the catalyst.

The All-Star right-hander took his first home loss last week against the Los Angeles Dodgers and followed with a dominating performance against the majors' top-hitting team.

Greinke struck out AL batting leader Jose Altuve three times and held the Astros to five hits in 6 2/3 innings to help the Diamondbacks win for the third time in nine games.