New York Islanders center Jean-Gabriel Pageau starts the celebration after the puck got by Boston Bruins goaltender Tuukka Rask and defenseman Jeremy Lauzon for a goal by Islanders center Mathew Barzal (not shown) on Monday in Boston. Elise Amendola/Associated Press

BOSTON — With five minutes left and his New York Islanders bleeding away their three-goal lead, Coach Barry Trotz called a timeout and told his players to breathe.

“He just calmed everyone down,” said forward Josh Bailey, who had a goal and an assist in the 5-4 victory that gave New York a 3-2 lead in the second-round series. “He told us to apply pressure, not sit back. Just getting everyone focused. You need that at certain times, and I thought that was a good time.”

Mathew Barzal scored one power-play goal and assisted on another, and Semyon Varlamov stopped 40 shots Monday night, when the Islanders opened a 5-2 lead and held on to move within one win of the Stanley Cup semifinals.

New York would reach the NHL’s final four for the second straight season with a victory in Game 6 at home on Wednesday.

“We’re excited to go back to the Coliseum,” forward Jordan Eberle said. “You’ve seen how loud it is. It gives us some juice.”

Barzal scored for the third straight game, and Kyle Palmieri, Bailey and Eberle all had goals in the second period, when the Islanders opened a 4-2 lead. Brock Nelson made it 5-2 just two minutes into the third, after Jeremy Swayman replaced Tuukka Rask in Boston’s goal.

But David Pastrnak scored his second of the game two minutes later, and David Krejci brought Boston within one goal with 5:19 left in the third period.

That’s when Trotz used his timeout.

The Bruins pulled Swayman, a rookie from UMaine, in the final two minutes for an extra skater, but didn’t really threaten before the Boston fans pelted the ice with cups and giveaway towels after what could be the final horn of the season.

“We’re going to New York to win a game, and that’s all that’s on our mind,” Boston defenseman Charlie McAvoy said. “We want to put our best foot forward and win a hockey game — that’s it. That’s all we’re thinking about right now. This thing isn’t over.”

The Islanders were successful on 3 of 4 power plays while getting called for just two penalties all game.

Bruins coach Bruce Cassidy didn’t like that.

“I think they sell a narrative over there that it’s more like the New York Saints, not the New York Islanders,” he said. “They play hard and they play the right way, but I feel we’re the same way. The calls, the exact calls that are getting called on us do not get called on them — and I don’t know why.

“Maybe we need to sell them more, flop, but that’s not us. It’s not like I’m sitting there going, ‘Every call against us sucks.’ It’s not true. It’s just the end of the day, the similar plays — they need to be penalized on those plays.

“They play hard, hard brand of hockey. Love the way they play. But they commit as many infractions as we do — trust me. It’s just a matter of calling ’em.”

NOTES: Rask stopped 12 of 16 shots before Swayman made his playoff debut to start the third period. The rookie made two saves on three shots — the first on a short-handed breakaway by Eberle. Cassidy said Rask needed some “maintenance” and could have gone back in. “I’ll just say he wasn’t himself 100%,” Cassidy said. “We made a decision not to put him back in.”

Comments are not available on this story.