Jim Mcisaac, Getty Images
Yankees' closer Mariano Rivera delivers a pitch in the ninth inning of Saturday's game against Boston.

NEW YORK — Mariano Rivera was on the ropes, and the Boston Red Sox were poised to earn a memorable comeback victory.

That's when the New York Yankees closer found his classic form again.

Rivera pitched himself in and out of trouble Saturday, escaping a bases-loaded, no-out jam in the ninth inning and preserving a 2-1 victory.

"You can't have doubts," Rivera said. "You have to make pitches. If you have doubts, a lot of things can happen."

After Mike Mussina pitched six shutout innings, Rivera took over in the ninth with a 2-0 lead. Boston scored a run and was poised for more, but Rivera struck out Coco Crisp, got Jason Varitek on a popup and fanned Julio Lugo for his 23rd save.

"We gave ourselves a great chance with really good at-bats in the ninth and then Mariano went to work and really carved us up for three batters," Boston manager Terry Francona said. "He gave himself no wiggle room and he didn't need it."

The Red Sox were on the brink of capturing the first three of the four-game series and fourth in a row in the season series when Rivera escaped.

"It was a big game for us," Yankees manager Joe Girardi said.

Melky Cabrera and Brett Gardner, two of New York's three healthy outfielders, each drove in a run and made a nice play in the field. Cabrera had an RBI single in the second and Gardner's sacrifice fly made it 2-0 in the sixth.

Justin Masterson (4-3) hit three batters, threw a wild pitch and walked two, but managed to hold the Yankees in check in his six innings. The rookie right-hander allowed six hits in his first appearance against New York.

Dustin Pedroia went 2-for-4 to extend his hitting streak to 13 games for Boston, which almost dealt the Yankees a heartbreaking loss.

"When you get bases loaded and nobody out, most of the time we're still playing," Francona said.

Mussina (11-6) allowed four hits and walked one in his first win over the Red Sox since June 5, 2006. He was 0-3 with a 7.71 ERA in his previous six games against Boston.

RAYS 3, ROYALS 0: At St. Petersburg, Fla., Andy Sonnanstine (10-3) pitched seven strong innings, Ben Zobrist homered again and Tampa Bay won its sixth straight. Zobrist homered for the third game in a row and the Rays increased their AL East lead to a season-high four games over second-place Boston. Tampa Bay has won 10 of 11. Sonnanstine (10-3) won his fourth consecutive decision. He allowed five hits, walked one and struck out two.

J.P Howell pitched the eighth inning and Grant Balfour worked the ninth for his third save.

Akinori Iwamura put the Rays ahead 2-0 with a two-out, two-run double in the second off Zack Greinke (7-5). Royals center fielder Joey Gathright made a dive and just missed catching the ball.

WHITE SOX 6, ATHLETICS 1: At Chicago, Gavin Floyd pitched 7 1/3 scoreless innings to get his 10th victory and Nick Swisher, Brian Anderson and Alexei Ramirez homered in Chicago's win over Oakland. Oakland had captured the first two games of the four-game series to cool off the White Sox, who'd won seven straight before the A's came to town. Floyd (10-4), who was 8-10 in his career entering this season, allowed only three singles.

Greg Smith (5-7), who pitched a complete game four-hitter in his previous start against the Angels, went five-plus innings, allowing five hits and four runs while tying a career high with six walks.

TWINS 9, INDIANS 6: At Minneapolis, Joe Mauer homered, walked three times and scored three runs to help Kevin Slowey and streaking Minnesota rally past Cleveland. Craig Monroe and Alexi Casilla hit two-run doubles for the Twins rebounded from the Indians' five-run second inning by scoring five times in the sixth. Slowey (6-6) settled down, striking out six and allowing five hits in six innings.Grady Sizemore's three-run homer, his league-leading 22nd, was the lone highlight for last-place Cleveland, which lost its seventh straight amid speculation that ace C.C. Sabathia will be dealt before the trade deadline on July 31. Tom Mastny (0-2) relieved starter Aaron Laffey in the sixth and gave up four runs while retiring just one batter.

RANGERS 5, ORIOLES 3: At Baltimore, Ian Kinsler homered, German Duran and Michael Young had three hits apiece, and Texas used a sharp pitching performance by substitute starter Scott Feldman to beat Baltimore. Moved up in the rotation after Eric Hurley was scratched with a hamstring injury, Feldman (3-3) gave up three runs and five hits in six innings. The right-hander allowed three runs and three hits in the first, then blanked the Orioles on two hits until his departure. Kinsler, who came into the game with an AL-leading .325 batting average, went 2-for-4 to extend his hitting streak to 17 games. His two-run homer off Lance Cormier (1-3) in the sixth put the Rangers ahead 4-3.

Nick Markakis had two hits and two RBIs for the Orioles, who fell to 5-28 when scoring three runs or fewer.

BLUE JAYS 7, ANGELS 5: At Anaheim, Calif., Vernon Wells hit a two-run homer, Alex Rios went 3-for-5 with two RBIs and three stolen bases, and Toronto beat error-plagued Los Angeles. Roy Halladay (10-6) gave up two runs and six hits in seven innings, struck out seven and recorded only three of his outs on flyballs to the outfield. The 2003 AL Cy Young Award winner allowed only one runner past first base after giving up a two-run homer to Vladimir Guerrero in the fourth.

MARINERS 3, TIGERS 2: At Seattle, rookie Jeff Clement homered in his final two at-bats, the second a two-run shot off Detroit reliever Fernando Rodney in the eighth inning that lifted the Mariners past Detroit. Clement was all the offense the Mariners got on a night where all five runs came via the long ball. His solo homer in the sixth off Detroit starter Armando Galarraga brought Seattle within 2-1 and snapped an 0-for-11 skid. In the eighth, Richie Sexson walked with one out and pinch-runner Miguel Cairo stole second. On the next pitch, Clement jumped on Rodney (0-2), sending the two-run shot 395-feet into the right field stands.

National League

CARDINALS 5, CUBS 4: At St. Louis, Rick Ankiel slapped a two-run, two-out single to right field in the bottom of the ninth inning to cap the Cardinals' three-run rally off Chicago closer Kerry Wood. The win brought the Cardinals (50-39) to within 2 1/2 games of the first-place Cubs (52-36) in the NL Central.

St. Louis rallied against Chicago closer Kerry Wood (4-2), who blew his fifth save of the season in 27 chances. Ankiel also homered in the sixth, when St. Louis rallied to tie it at 2. St. Louis reliever Kyle McClellan (1-3) picked up his first major league victory in relief.

Chicago infielder Aramis Ramirez broke a 2-2 in the eighth with a two-run homer.

BREWERS 2, PIRATES 1: At Milwaukee, Prince Fielder singled in Rickie Weeks with one out in the bottom of the ninth, leading the Brewers to their second straight win. Pirates reliever Tyler Yates (3-2) was in trouble from the start, walking Weeks to lead off the inning. J.J. Hardy's sacrifice bunt ended his 16-game hitting streak but put the winning run in scoring position and Yates intentionally walked Ryan Braun to bring up Fielder. Brewers reliever Eric Gagne (2-2) got the win by working around a one-out single to Jason Bay in the ninth.

ASTROS 6, BRAVES 1: At Atlanta, Mark Loretta had three doubles and drove in four runs and, with Ty Wigginton batting leadoff for the first time this season, the Astros scored four times in the first two innings. Wigginton walked and scored in a two-run second inning against Braves left-hander Jo-Jo Reyes (3-7), helping Houston snap a four-game losing streak.

Even with Lance Berkman going 0-for-4 with a walk, the Astros had more than enough offense to beat the punchless Braves, who managed only four hits and have lost six of seven.

Chris Sampson (4-3) gave up one run in five innings in his first start since May 25.

REDS 3, NATIONALS 2: At Cincinnati, Brandon Phillips singled in Jerry Hairston Jr. from second base in the ninth inning to lift the Reds. After Jesus Flores' ninth-inning sacrifice fly tied it at 2 and handed Francisco Cordero (4-1) his fourth blown save of the season, Hairston led off the ninth with a single off of Joel Hanrahan (5-3). He stole second, but Jay Bruce struck out and Ken Griffey Jr. was intentionally walked.

Luis Ayala came in to face Phillips, who grounded a single through the hole into left field to score Hairston.

METS 9, PHILLIES 4: At Philadelphia, pinch-hitter Brian Schneider lined a tiebreaking double in the eighth inning and New York rallied against the majors' best bullpen, ending the Phillies' four-game winning streak.

Schneider's two-run double came with two outs. He was the Mets' third pinch-hitter of the inning as they overcame a 4-3 deficit.

The Mets won despite losing starting pitcher John Maine — a right-hander — because of a cramp in his left forearm.

J.C. Romero (4-2) let two runners reach in the eighth. Tom Gordon threw a wild pitch that scored the tying run, then gave up Schneider's hit. Rudy Seanez gave up three more runs in the ninth.

Pedro Feliciano (1-2) earned the win despite giving up a go-ahead hit in the seventh.

PADRES 4, DIAMONDBACKS 2: At Phoenix, Jake Peavy (6-5) threw seven scoreless innings and Scott Hairston homered twice in San Diego's victory over slumping Arizona. Adrian Gonzalez also homered for the Padres who have won two straight after dropping 10 of their previous 11.

Stephen Drew homered for the Diamondbacks, who lost for the fifth time in eight games to fall two games under .500 for the first time this season.

Arizona starter Doug Davis (3-4) was nearly as effective as Peavy, scattering seven hits over a season-high eight innings, but couldn't overcome the two pitches thrown to Hairston.

ROCKIES 12, MARLINS 6: At Denver, Matt Holliday homered and drove in four runs and Joe Koshansky hit his first major league homer as injury-riddled Colorado won its season-best fifth straight.

One night after hitting six homers in an epic 18-17 win over the Marlins, the Rockies went deep four more times. Chris Iannetta and Brad Hawpe also connected for Colorado which has its longest winning streak since last fall's unfathomable 21-1 run-up to the World Series.

Jorge De La Rosa (3-4) scattered six hits and allowed three earned runs over five-plus innings for the Rockies, who placed shortstop Troy Tulowitzki on the DL with a deep cut in his right palm.

Florida right-hander Ryan Tucker (2-3) allowed eight runs, all earned in four innings.

GIANTS 5, DODGERS 2: At San Francisco, Randy Winn and Fred Lewis hit two-out RBI singles during San Francisco's four-run rally in the seventh inning and the Giants kept Los Angeles out of first place in the NL West.

Bengie Molina added a two-run double for the Giants, who tagged the Dodgers' bullpen shortly after starter Chan Ho Park was pulled for a pinch-hitter with a 2-1 lead.

Park and Barry Zito staged an unlikely pitchers' duel over the first six innings. Park threw six innings of three-hit ball while Zito (4-12) struck out 10 in perhaps the best start of his woeful season.

Six straight Giants reached base with two outs in the seventh, starting with Lewis' tying single off Brian Falkenborg (0-1).