NEW YORK -- Andy Pettitte was a rock on the mound in his latest gritty performance. Mariano Rivera jogged in from the bullpen to nail down a ninth-inning lead.
After two straight duds to start the season, the banged-up New York Yankees finally looked like themselves Thursday night.
Pettitte pitched the Yankees to their first win of the year and Rivera made a successful return to the mound in New York's 4-2 victory over the Boston Red Sox.
"I was waiting for 11 months," said Rivera, who acknowledged feeling a little anxious before his first regular-season pitch since knee surgery. "There were a lot of emotions tonight, but you have to control that. You have to finish the game."
Brett Gardner and Francisco Cervelli homered for the Yankees, providing some unexpected power to a depleted lineup missing the "sore four" -- Derek Jeter, Alex Rodriguez, Mark Teixeira and Curtis Granderson.
All those All-Stars are on the disabled list, plus pitcher Phil Hughes, and without them New York dropped its first two games to the rival Red Sox.
"You don't want to leave your home park going 0-3; that's for sure," manager Joe Girardi said. "So I thought it was pretty important."
Lyle Overbay had a two-run single off Ryan Dempster (0-1), who struck out eight in his Boston debut but needed 101 pitches to get through five innings. The two-time All-Star signed a $26.5 million, two-year contract in December after spending last season with the Cubs and Rangers.
"Just got outpitched by the guy on the other side of the field," Dempster said. "I made a lot of good pitches and a couple balls fell in. That was enough to win the game."
Looking for their first season-opening sweep at Yankee Stadium, the Red Sox were handcuffed by a pair of New York greats.
The 40-year-old Pettitte (1-0) tossed eight sharp innings on a 43-degree night and Rivera entered to a standing ovation from those left in the bundled-up crowd of 40,611 as the familiar chords of Metallica's "Enter Sandman" blared over the Yankee Stadium speakers.
Baseball's career saves leader, set to retire after this season, missed most of last year after tearing a knee ligament May 3 while shagging flies during batting practice in Kansas City.
Rivera issued a leadoff walk to Dustin Pedroia and gave up a one-out double to Jonny Gomes before Will Middlebrooks drove in a run with a groundout. But the right-hander threw a called third strike past rookie Jackie Bradley Jr. for his 609th save and first since April 30 last year at Baltimore.
"Obviously, I feel real secure and good about things whenever you see that guy come running in from the bullpen in the ninth inning," Pettitte said. "It's special, and it will be special for me watching him this year and knowing this is it. After this, he won't be closing games for us anymore, so I'll savor it as much as I can."
By appearing in his 19th Yankees season, Rivera broke a tie with Yogi Berra, Mickey Mantle and Jeter to set the franchise mark. Jeter will match Rivera again when the captain makes his season debut.
It was the 69th time Rivera has saved a regular-season win by Pettitte, a major league record. The two hadn't teamed up since the 2010 playoffs against Minnesota.
"These two have been doing it a long time together," Girardi said. "I've caught both of them and I've managed both of them, but as a fan it's really kind of neat to see."
With fans chanting his name, Pettitte got through the eighth inning and pumped his fist before heading into the dugout for good.
Backed by three double plays -- one that he started himself -- Pettitte allowed one run and eight hits. He threw an efficient 94 pitches and gave New York's staff a huge boost after Hiroki Kuroda was pulled in the second inning Wednesday night with a bruised middle finger.
Pettitte, beginning his 15th season with the Yankees, earned his 246th career win and improved to 19-10 in 38 starts against Boston. He missed almost three months last season with a broken left ankle and finished 5-4 with a 2.87 ERA.
Pettitte has practically made a career of righting the ship for the Yankees. The team said he is 18-3 with an ERA below 3.00 in 27 starts with New York trying to avoid a regular-season sweep, according to research by the Elias Sports Bureau.
He was working on a five-hit shutout when Middlebrooks smacked a two-out single in the seventh and scored on a double by Bradley. David Ross made a bid for a tying homer with a long drive to left-center that was caught just in front of the fence, near the 399-foot sign.
"He gave it a ride and Gardner makes a heck of a catch against the wall," Boston manager John Farrell said.
Cervelli greeted Clayton Mortensen with a leadoff homer in the seventh that made it 4-1.
Gardner and Cervelli hit their first homers since going back-to-back off Baltimore's Tommy Hunter on Sept. 6, 2011. Neither player spent much time on the active big league roster last season.
Eduardo Nunez, often a defensive liability, turned three double plays at shortstop and made a leaping grab to rob Shane Victorino of a leadoff hit in the fourth. Nunez also had two hits, including a key double.
Victorino tried to score from second base on a wild pitch in the first inning when Pettitte didn't cover the plate. Cervelli was slow and a little nonchalant in retrieving the ball, then scrambled back in time to tag Victorino as both players dove headfirst and banged into each other.
Victorino jammed two fingers on his throwing hand but remained in the game. He said he was fine, and Cervelli apologized to him the next time up.
Copyright 2015 Associated Press. All rights reserved. This material may not be published, broadcast, rewritten, or redistributed.