President Donald Trump has signed an executive order allowing the Air Force to bring up to 1,000 pilots back to active duty as it grapples with an aviator shortage, the Pentagon said Friday.

The Air Force has complained for years that it is struggling to retain pilots, who are often lured away by better-paying commercial airlines.

Additionally, pilots often choose to leave the military due to the strains of extended deployments overseas.

The US Air Force is trying to tackle a shortage of more than 1,000 pilots, many of whom are lured away by commertical airlines

'We anticipate that the secretary of defense will delegate the authority to the secretary of the Air Force to recall up to 1,000 retired pilots for up to three years,' Commander Gary Ross, a Pentagon spokesman, said in a statement.

Previously, the Air Force had been limited to recalling 25 pilots.

'The pilot supply shortage is a national-level challenge that could have adverse effects on all aspects of both the government and commercial aviation sectors for years to come,' Ross said.

President Trump with UN Secretary General Antonio Guterres on Friday; The Air Force has complained for years that it is struggling to retain pilots, who are often lured away by better-paying commercial airlines

The Air Force welcomed the new rule, but said it could not provide details until it received guidance.

'As the Air Force pursues a variety of initiatives to counter the shortage, it will take care to balance new accessions with voluntary programs for retired and senior pilots to ensure the service maintains a balance of experienced aviators throughout the coming years,' Air Force spokeswoman Erika Yepsen said.

General Stephen Wilson, vice chief of staff of the Air Force, told lawmakers this year that the service is short of 1,555 pilots and 3,400 aircraft maintainers.

The Air Force has already boosted pay and incentives to its fliers and reached out to airlines to come up with solutions to the pilot shortage.