BAGHDAD — Thousands of heavily-armed Shiite militiamen paraded through several Iraqi cities on Saturday after Sunni militants seized a town on the Syrian border in what appeared to be the start of a new offensive in the western Anbar province.

The capture on Friday of the town of Qaim and its border crossing dealt another blow to Prime Minister Nouri al-Maliki’s government, which has struggled to push back against Islamic extremists and allied militants who have seized large swaths of the country’s north, including the second largest city Mosul.

But while al-Maliki has come under mounting pressure to reach out to disaffected Kurds and Sunnis, the display of heavy weapons by the Shiite fighters indicated that forces beyond Baghdad’s control may be pushing the conflict toward a sectarian showdown.

In Baghdad, about 20,000 men, many in combat gear, marched through the Sadr City district with assault rifles, machine guns, multiple rocket launchers, field artillery and missiles. Similar parades were held in the southern cities of Amarah and Basra.

The parades were staged by followers of Shiite cleric Muqtada al-Sadr, who once led a powerful militia that battled U.S. troops and was blamed for some of the mass killing of Sunni civilians during the sectarian bloodletting that peaked in 2006 and 2007.

Police and army officials said the al-Qaida breakaway Islamic State of Iraq and the Levant, along with allied militants, seized Qaim and its crossing, about 320 kilometers (200 miles) west of Baghdad, after killing some 30 Iraqi troops in daylong clashes Friday.

The officials, who spoke on condition of anonymity because they were not authorized to talk to media, said people were now crossing back and forth freely.

Chief military spokesman Lt. Gen. Qassim al-Moussawi tacitly acknowledged Qaim’s fall, telling a news conference in Baghdad that troops aided by local tribesmen were seeking to clear the city of “terrorists.”

Sunni militants have carved out a large fiefdom astride the Iraqi-Syrian border and have long traveled back and forth with ease, but the control of crossings allows them to more easily move weapons and heavy equipment to different battlefields.

Al-Moussawi said fighting was continuing for a fifth day over Iraq’s largest refinery in Beiji, north of Baghdad, with the army force there repelling three waves of attacks by the Sunni militants on Friday night.

The fall of Qaim came as al-Maliki faces mounting pressure to form an inclusive government or step aside, with both a top Shiite cleric and the White House strongly hinting he is in part to blame for the worst crisis since U.S. troops withdrew from the country at the end of 2011.

Grand Ayatollah Ali al-Sistani, the most respected voice for Iraq’s Shiite majority, on Friday joined calls for al-Maliki to reach out to the Kurdish and Sunni minorities a day after President Barack Obama challenged him to create a leadership representative of all Iraqis.

Al-Sistani normally stays above the political fray, and his comments, delivered through a representative, could ultimately seal al-Maliki’s fate.

Calling for a dialogue between the political coalitions that won seats in the April 30 parliamentary election, al-Sistani said it was imperative that they form “an effective government that enjoys broad national support” and “avoids past mistakes.”

Al-Sistani is deeply revered by Iraq’s majority Shiites, and his critical words could force al-Maliki, who emerged from relative obscurity in 2006 to lead the country, to step down.

On Thursday, Obama stopped short of calling for al-Maliki to resign, but his carefully worded comments did all but that. “Only leaders that can govern with an inclusive agenda are going to be able to truly bring the Iraqi people together and help them through this crisis,” Obama said.

The Iranian-born al-Sistani, believed to be 86, lives in the Shiite holy city of Najaf, south of Baghdad, where he rarely ventures out of his modest house and does not give media interviews. His call to arms last week prompted thousands of Shiites to volunteer to fight against the Sunni militants.

His call to defend the country, and its Shiite shrines, has given the fight against the Sunni insurgents the feel of a religious war, but his office in Najaf dismissed that charge, saying the top cleric was addressing all Iraqis.

Al-Maliki’s State of Law bloc won the most seats in the April vote, but his hopes to retain his job are in doubt, with rivals challenging him from within the broader Shiite alliance. In order to govern, his bloc must first form a majority coalition in the new 328-seat legislature, which must meet by June 30.

If al-Maliki were to relinquish his post now, according to the constitution the president, Jalal Talabani, a Kurd, would assume the job until a new prime minister is elected. But the ailing Talabani has been in Germany for treatment since 2012, so his deputy, Khudeir al-Khuzaie, a Shiite, would step in for him.

Shiite politicians familiar with the secretive efforts to remove al-Maliki said two names mentioned as replacements are former vice president Adel Abdul-Mahdi, a Shiite and French-educated economist, and Ayad Allawi, a secular Shiite who served as Iraq’s first prime minister after Saddam Hussein’s ouster. Others include Ahmad Chalabi, a one-time Washington favorite to lead Iraq, and Bayan Jabr, another Shiite who served as finance and interior minister under al-Maliki.

Nearly three years after he heralded the end of America’s war in Iraq, Obama announced Thursday he was deploying up to 300 military advisers to help quell the insurgency. They join some 275 troops in and around Iraq to provide security and support for the U.S. Embassy and other American interests.

Obama has been adamant that U.S. troops would not be returning to combat, but has said he could approve “targeted and precise” strikes requested by Baghdad.

Manned and unmanned U.S. aircraft are now flying over Iraq 24 hours a day on intelligence missions, U.S. officials say.