BALTIMORE — Ramon Hernandez and Melvin Mora hit three-run homers, and the Baltimore Orioles overcame an early deficit to beat the Boston Red Sox 11-6 Wednesday night and avoid a three-game sweep.

Baltimore trailed 4-0 before scoring 10 straight runs against three Boston pitch-ers. Hernandez put the Orioles up 6-4 with a third-inning drive, and Mora’s 21st home run of the season made it 10-4 in the fourth.

Mora added a fifth-inning sacrifice fly to boost his team-high RBI total to 95. He has 10 homers and 47 RBIs in 31 games since the All-Star break.

Chris Waters (2-0), making his fourth major league start, gave up five runs, four earned, and eight hits in five innings for Baltimore.

Jason Bay homered for the Red Sox, his fourth in 17 games since being traded from Pittsburgh.

Clay Buchholz (2-9) allowed five runs, three hits and three walks in 2¤ innings, the shortest start of his career. The right-hander, who threw a no-hitter against the Orioles last September, is 0-7 in nine starts since May 2.

Buchholz was sent down to the AA Portland Sea Dogs after the game.

The Red Sox got three hits and two walks in the first inning but could muster only two runs. Dustin Pedroia hit a one-out triple and scored on a single by Kevin Youkilis before Jed Lowrie drew a bases-loaded walk. Jeff Bailey then struck out and Coco Crisp hit a grounder in the hole that shortstop Juan Castro turned into a force play at third.

In the second, Boston used a double by Kevin Cash, a throwing error by Waters and a David Ortiz RBI single to make it 4-0.

Baltimore closed to 4-3 in the bottom half when Lou Montanez singled in a run and Brian Roberts hit a two-run single.

A baserunning error cost Boston a scoring chance in the third. After Lowrie hit a leadoff double, he took a few steps toward third as right fielder Nick Markakis caught a fly ball. Before Lowrie could get back to second, Markakis threw him out.

The Orioles went up 7-4 in the bottom half. Buchholz was lifted after hitting a batter and walking another, and Hernan-dez greeted David Aardsma with a drive to center that Crisp failed to grab with a leap over the 7-foot wall. Montanez then drew a walk and Castro completed the uprising with an RBI single.

Mora connected in the fourth off Javier Lopez, and Bay went deep in the fifth to make it 10-5.

In the Baltimore fifth, Jay Payton got a leadoff single off Mike Timlin and scored on Mora’s fly ball. Payton went 2-for-3, scored twice and stole a base.

Orioles reliever Kam Mickolio made his major league debut in the eighth. He started by striking out Lowrie, but gave up three hits, including an RBI double to Jacoby Ellsbury.

Notes: Timlin made his 1,049th career appearance, one short of tying Kent Tekulve’s major league record for right-handed relievers. … The Orioles have been outscored 106-74 in the first inning. … Eight of Pedroia’s last 15 hits have been for extra bases. He has hit safely in 18 of 19 games.