CHICAGO >> If this was Bobby Miller’s birthday party, he was the piñata.

Miller turned 25 on Friday and celebrated by striking out the side in the first inning. Miller had “tons” (his estimate) of friends and family in attendance for his first career start at Wrigley Field, less than an hour from his hometown.

That’s as long as the celebration lasted. Miller retired just two more batters, didn’t get out of the second inning and gave up the first five runs as the Chicago Cubs beat the Dodgers 9-7 on a cold afternoon with temperatures never leaving the 40s.

“I thought I had a really good gameplan today going into it. First inning, it went very well, but not too worried about that,” Miller said. “The second inning was just pretty unacceptable. Just didn’t feel the best out of the stretch today. But no worries. Next bullpen I’m just going to do a ton of work out of the stretch and just treat it game-like like I always do and move on to the next.”

The Dodgers made a game of it, pulling within a run in the fifth inning, by scoring at least five runs for the 10th consecutive game to start the season, a franchise record. Only seven other teams since 1880 have started a season with a streak of 10 games or more and no team has had a longer streak since the New York Yankees ran off 13 consecutive games of at least five runs to start the 1932 season.

The Dodgers had ample offense against the Cubs. Shohei Ohtani had a double and a two-run home run, his second consecutive game with a homer. Will Smith had four hits. Teoscar Hernandez had three and drove in four runs with them.

But the Dodgers (7-3) kept giving it back every time they gained ground.

“For the most part, it’s hard to point at the offense today,” Dodgers manager Dave Roberts said.

Miller’s second-inning troubles started with a one-out home run by Dansby Swanson. A walk, back-to-back singles and a wild pitch produced two more runs. After a fly out and a walk, Seiya Suzuki doubled in two runs and Miller’s day was done early.

“It was a good first inning from Bobby. Obviously the second one got away from us,” Smith said. “Just constantly behind in counts. They forced him into the zone with some fastballs and they capitalized on it. That was kind of frustrating.

“There were four, five batters where you were a strike away or a ground ball right to an infielder instead of through a hole and you get out of there with two runs, maybe three. That’s baseball. It’s not fun when it’s going on. You’ve just gotta make a little better pitch, do a little more to make better things happen.”

Dinelson Lamet relieved Miller made some better things happen though he did give up a solo home run to former Dodger Michael Busch.

But the costliest damage came in the sixth inning when a poor decision by Hernandez in right field led to two Cubs runs.

Michael Grove put two runners on with a walk and a single before Ian Happ sent a sinking line drive into right center field. Hernandez surrounded it and went to his knees in an attempt to make a catch. He wasn’t very close and the ball skipped under his glove and past him for a two-run triple.

“That’s one of those decisions that he felt that he could make the play,” Roberts said. “I trust his judgment right there. It just kind of sunk at the last minute under his glove for the triple. But I still thought he got a good jump on the ball, and I still think it was the right play. It would have probably hurt to just watch him pull up and (let the ball) land at his feet.”

A sacrifice fly made it a three-run inning for the Cubs. That held up for the difference in the game — with an assist from the wind blowing in off Lake Michigan.

Chris Taylor led off the eighth inning with a walk and moved to second base on a wild pitch. With two outs, Ohtani hit a drive to center field that left the bat at 110 mph and had the potential to tie the score. But it was swallowed up by the Wrigley wind and came down in the glove of center fielder Cody Bellinger.

The Dodgers put the tying runs on with no outs in the ninth and Max Muncy repeated Ohtani’s mistake, hitting a drive 101 mph off the bat but also to straightaway center field. After replay turned an infield single by Hernandez into a ground out, Busch made a diving play on a line drive by James Outman to end the game.

The Dodgers finished the game 3 for 16 with runners in scoring position with Cubs infielders Nico Hoerner and Nick Madrigal making outstanding plays to stifle potential scoring opportunities.

“I thought tonight was really good from the offense,” Roberts said. “They just kept putting up runs and kept fighting and even the last out made, we had a chance to tie the ballgame. Will had a really good day, Sho swung the bat well and even the flyout to center field, it had the trajectory and the exit velocity to be a home run. But with the wind blowing in obviously put that to rest.

“Offensively we were sound and gave ourselves a chance to win.”