Nine Lebanese Shi'ites flew home to Beirut after their release by Syrian rebels who held them hostage for 17 months.

The nine were freed in exchange for two Turkish Airlines pilots, who were seized in Lebanon on August 9 in retaliation for the abduction of the Lebanese. The pilots returned to Turkey on October 19.

Reports said that under the deal, negotiated in part by Qatari mediators, the Syrian government was supposed to release dozens of prisoners held in Syrian facilities. It was not immediately clear if that part of the deal has been fully carried out.

Lebanese state-run media said the nine Lebanese were traveling through Syria in connection with a religious pilgrimage to Iran when they were kidnapped in May 2012.

Syrian rebels accused them of having links to Shi’ite Hizbollah militia fighters who support Syrian President Bashar al-Assad’s regime. Hizbollah fighters have this year joined regime forces in battles against the rebels.

Shi'ite-led Iran and Hizbollah back the government of Assad, who is from the Alawite sect, an offshoot of Shi’ite Islam, in the war against the rebels, who are supported by mostly Sunni Turkey and Saudi Arabia.

Analysts say the hostage exchange demonstrates how the Syrian conflict, now nearly three years old, has acquired a pronounced sectarian element and has increasingly entangled neighboring countries.

Lebanese government officials, clerics, and hundreds of well-wishers cheered as the nine Lebanese arrived at the Beirut international airport aboard a Qatari jet.

The former hostages appeared in good health.

In Istanbul, Turkish Airlines pilots Murat Akpinar and Murat Agca were met at the airport by Prime Minister Recep Tayyip Erdogan and other officials.

"We were not treated badly, I can say that clearly," Akpinar said. "We were never treated brutally. We were not exposed to verbal or physical violence. If that had been the case you can be sure that we would not have arrived here."