Ryen Russillo and Adnan Virk see Dave Doeren's flirtation with the Tennessee job as a bargaining chip to increase his current deal. (1:14)

NC State coach Dave Doeren will remain at the school after discussing the Tennessee job on Wednesday, he told ESPN.

Doeren and NC State have agreed on a new contract the school announced Thursday. It's a five-year contract worth $3 million annually, a source told ESPN's Andrea Adelson.

The NC State Board of Trustees will meet on Friday to formally approve the terms of the deal.

NC State coach Dave Doeren is staying with the Wolfpack. Mark Konezny/USA TODAY Sports

The two sides had been working on a new deal over the past six weeks, but Doeren's interview with Tennessee helped get the final negotiations over the finish line. The new deal is a nearly $1 million raise for Doeren, who was making $2.2 million per year.

He is finishing his best season with the Wolfpack, who went 8-4 (6-2 ACC) and are ranked No. 24 by the College Football Playoff selection committee. NC State will learn its bowl destination Sunday.

Doeren is 33-30 in five seasons with the Wolfpack.

"Dave has made significant strides in developing a complete program at NC State, and this new contract continues our commitment to his leadership," athletic director Debbie Yow said in a statement.

The 45-year-old became the latest candidate not to reach an agreement with Tennessee, which also pursued Oklahoma State's Mike Gundy and Purdue's Jeff Brohm this week. Tennessee and Ohio State defensive coordinator Greg Schiano agreed to a deal Sunday, but the school backed out after public outcry and campus protests, plus government officials protesting on Twitter.

Doeren told Adelson that his family, players and incoming recruits led to his decision to remain at NC State.

"My family loves it here too much. I'm here because I love my players and my recruits," Doeren said.

Doeren is 56-34 in seven seasons as an FBS head coach.

With Doeren staying at NC State, Tennessee plans to talk to former Texas A&M coach Kevin Sumlin, sources told ESPN.

ESPN's Chris Low contributed to this story.