HAMPTON — Justin Allgaier snatched the lead after Martin Truex Jr. made a mistake on pit road, and then held off his furious charge at the end to win the NASCAR Xfinity Series race at Atlanta Motor Speedway on Saturday.

Allgaier’s celebration was marred by a scuffle on pit road between Noah Gragson and Daniel Hemric, whose cars had gotten into each other on pit road during the race.

Hemric came over to confront Gragson while he was doing an interview. Gragson took several swings, but appeared to miss before crew members and officials stepped in to separate the drivers. Neither was hurt.

Truex, racing in the second-tier series for the first time since 2010, dominated the first two stages and seemed headed for an easy victory until he got caught speeding on pit road.

The 2017 Cup champion had to drop to the back of the field as a penalty, but he quickly snaked his way through the field. Truex got within a half-second of the lead in the closing laps, but Allgaier pulled away for a 1.449-second victory in his JR Motorsports Chevrolet.

The victory was a big relief for Allgaier, who struggled mightily through the first four races before finishing eighth last week at Phoenix.

He used that momentum to take the checkered flag for the 15th Xfinity victory of his career ahead of Truex. Harrison Burton was third.

“We didn’t start off the day like we wanted to, but the guys persevered,” Allgaier said. “They made some great adjustments on pit road.”

Gragson, who bounced back from an early wreck to take a fourth-place finish, was caught off guard by Hemric’s confrontation.

“I don’t know why he’s mad,” Gragson said. “I was behind him coming into pit road and he’s in our pit box, so I had to come around him. I’m not really sure why he was there.”

Gragson took a verbal shot at Hemric, who has yet to win in any of NASCAR’s top three series.

“I would feel bad if I was in his shoes, too, based on what he’s done in his career,” Gragson said. “I’ll just move on, keep on fighting. Man, what a day.”

Hemric blamed Gragson for the pit-road incident.

“There’s a hole in the nose of my car and he got popped in the eye,” said Hemric, who finished ninth. “From where I stand, we’re in good shape.”

Kyle Busch raced to his 60th NASCAR Trucks Series victory with a dominating performance.

Busch pulled way over the last 30 laps and finished more than 4 seconds ahead of the field.

“It’s always cool to get back to victory lane,” he said.

Busch has been there plenty of times in Atlanta, where he claimed his sixth Trucks victory to go along with four other top-10 finishes. He did a burn-out at the finish line in front of the socially distanced crowd before taking his customary bow.

The Kyle Busch Motorsports team also picked up a third-place finish from series leader John Hunter Nemechek, a fulltime competitor in Trucks.

Austin Hill was second in his best showing of the season.

“That last restart we had, I was trying to save my tires a little bit,” Hill said. “The pit crew did an awesome job today, but I gave that gap up and I could never close it. I needed to be a little quicker.”

Hill, from Winston, Georgia, won’t get another chance to win at Atlanta this season. The track’s second NASCAR weekend in July includes only the Cup and Xfinity series.