Homeland Security Secretary John Kelly, President Trump’s choice to replace Reince Priebus as chief of staff, is a retired Marine general and combat leader who will now face the challenge of bringing order to a White House staff mired in chaos.

Kelly has the skills to impose needed discipline in the White House, say those who know him.

“Whether or not he will be successful depends on his relationship with the president and it seems like that relationship is okay,” said Carl Fulford, a retired Marine Corps four-star general.

“I don’t think he is going to put up with expletives coming from people who want to see their name in the paper,” Fulford said.

Kelly, 67, will need to straighten out a White House riven by public feuds and confused messaging, culminating with an expletive-laden rant against Priebus by Anthony Scaramucci, the new White House communications director, that was posted online Thursday by the The New Yorker magazine.

Kelly retired from the Marine Corps after more than 40 years of service when Trump offered him the Homeland Security position.

Raised in a working class family in Boston, Kelly first enlisted in the Marine Corps and later attended Officer Candidates School.

He served in a wide range of positions in the Marine Corps, including a stint in the service’s liaison office to the House of Representatives, where he spent time with lawmakers and was exposed to politics and the legislative process. “He knows how Congress works,” Fulford said.

Read more:

President Trump replaces White House chief of staff Reince Priebus with Homeland Security Secretary John Kelly

5 things to know about new White House chief of staff John Kelly

New White House chief of staff John Kelly recently broke with Trump on Russia election hacking

As a four-star general, Kelly served as commander of Southern Command, traveling widely throughout South and Central America and making contacts among military leaders in the region.

Kelly is part of a cadre of military leaders that Trump has appointed to key positions in his administration.

Jim Mattis, a retired Marine four star general, serves as Defense secretary and Army Lt. Gen. H. R. McMaster, is the White House national security adviser.

Kelly is particularly close to Mattis and Marine Gen. Joe Dunford, the chairman of the Joint Chiefs of Staff. The three served in the 1st Marine Division in 2003, when the Marines launched a grueling and fast-paced ground attack into Iraq.

Kelly’s family has deep roots in the Marine Corps. His father served as a Marine fighting in the Pacific during World War II.

In 2010, Kelly’s son, 1st Lt. Robert Kelly, 29, was killed in action while leading a platoon of Marines in Afghanistan's Helmand province.

“John Kelly is not looking to feather his nest,” Fulford said. “He is looking to serve the country.”