WASHINGTON — Recent gains against the Islamic State in eastern Syria have helped sever critical supply lines to Iraq and set the stage for what will be the biggest fight yet against the Sunni militancy, the battle to retake Mosul, Pentagon officials said on Monday.

Gen. Joseph F. Dunford Jr., the chairman of the Joint Chiefs of Staff, said at a Pentagon news conference that American-backed forces had begun laying the groundwork for the fight by moving to isolate Mosul from the Islamic State’s de facto headquarters in Raqqa, Syria. Kurdish and Arab forces retook the town of Shaddadi in eastern Syria last week, cutting off what Defense Secretary Ashton B. Carter called the last major artery between Raqqa and Mosul.

But military officials cautioned that the fight for Mosul could last many months, requiring Iraqi forces unproven in urban warfare to advance street by street through the explosives-laden terrain of Iraq’s second-largest city, with more than one million people.

In addition to the advances in eastern Syria, the Pentagon has begun using cyberattacks on Islamic State communications between Raqqa and Mosul, as well as attacks meant to disrupt the militant group’s ability to use social media to recruit fighters, officials said.