Less than two months after arriving in the United States as a refugee from Syria, Rashid Mahmoud rejoiced at the news of American missiles pummeling a Syrian air base Thursday night, and struggled with an unexpected sentiment: praise for President Donald J. Trump, who has more often seemed like an antagonist than an ally.

“It was good to protect people, and I think it’s human — it’s required by humanity,” Mr. Mahmoud, 24, said in an interview on Friday in his new home in Lowell, Mass. As for the president, he said, “I’m just supportive for yesterday, not all the time.”

Syrian refugees mostly welcomed an attack on the violent and oppressive Assad government they fled, even if they thought it was too little or too late. But they are unaccustomed to seeing Mr. Trump as any sort of advocate, and their praise for him seemed tentative.

Mr. Trump had spoken out repeatedly against taking action against the Syrian ruler, Bashar al-Assad, while praising the actions of Russia, Mr. Assad’s biggest backer in Syria’s long-running civil war, and arguing that the United States should make common cause with Russia and Syria in fighting the Islamic State terrorist group. During the campaign, Mr. Trump called for a temporary ban on all Muslim immigration, and as president he has tried to halt entry from Syria and a handful of other Muslim-majority countries, contending that some of the refugees and other migrants could be terrorists trying to slip into the United States under false colors.

Mr. Mahmoud and his family left their hometown, Afrin, northwest of Aleppo, and lived for years in Turkey, before getting permission to go to the United States. Just as they were about to leave, in late January, Mr. Trump’s first pass at an immigration order put their plans on hold; when courts struck down the order, they were finally able to enter the country, on Feb. 9.

He heard about the president’s action on Thursday night, while in the middle of a work sheet on English verb tenses. He described the jubliation he felt as “a new emotion.”

Mohamad Chaghlil, 35, a woodworker from Damascus, said he hoped the missile attack — far too limited in his view to change the course of the war — would be the start of a major course correction by Mr. Trump. But he said he doubted it. And like some other refugees, he questioned why a poison gas attack that was blamed on the government prompted the American strike now, when earlier atrocities did not.

“I don’t have full idea why he did that now,” he said. “We lose hundreds of Syrian people every day, we lost more than half a million people in Syria. So why chemical attack is worse? Dead is dead. I can’t understand, and the Syrians can’t understand.”

Mr. Chaghlil and his parents left Syria for Jordan four years ago, then began the laborious process of gaining refugee status. After his father died last July, his mother had to revise her paperwork, he said, delaying her case, so while Mr. Chaghlil came to the United States in December, she remains in Jordan.

“I talk with her every morning,” he said. “She is old. She needs me, and I need her. I’m alone here and she is alone there.”

He said he worries about where American immigration policy will leave her, and still sees the president as anti-Muslim.

“I think he doesn’t care about who needs the support, and who is the murderer and who is the good person,” said Mr. Chaghlil, who was admitted to the country in December and lives in New Haven. “Maybe he felt he has to do something for politics.”

Ayham al-Asmi , who had been upset by Mr. Trump’s attempts to bar refugees, was so enthusiastic in his support for the airstrikes that he said he would vote for Mr. Trump if he could. He said more than 150 members of his extended family have died in the violence in Syria.

“He’s a national hero now,” he said of the president, adding, “100 percent.”

Mr. Asmi, 34, who arrived in Worcester, Mass., about 18 months ago, said he had stayed up all night after seeing news of the raid on Facebook, contacting elated friends and family around the world.

“The Syrian people just gave up on anyone coming to their rescue,” he said through an interpreter, Amjad Bahnassi, who is a leader in his mosque. The attack, Mr. Asmi said, was “light at the end of the tunnel.”

For Zelekha Mahmoud, 31, news of the American missile attack allowed her to hope that the war could come to an end, and that she, her husband, and their four small children, could return home. They settled in October in Chicago, and are adjusting to their new life. They pray and socialize at an Islamic center, the children go to school, and her husband has found work at a food packaging company. But she longs for Syria.

The Times is withholding her family name — Mahmoud is her middle name — because she fears for the safety of the children and four siblings still in Syria. She says she is grateful that the United States has sheltered her and her family, but she remains wary of the welcome here; Mr. Trump’s travel orders at first made her fear they would be expelled.

When her husband joyfully told her of the strike, “I was so happy,” she said, sitting in their apartment on Chicago’s North Side. “I feel that maybe now they will get rid of Assad so that Syria will be secure again, so we can return.”

Anwar Jebran, 28, who has lived in Chicago since 2013, said he and his family, had mixed feelings about the strike.

“We want peace, we want safety,” said Mr. Jebran, who recently graduated from medical school. “We don’t want more military, more weapons, more rockets.”

Mohamad Haidar, 47, who settled with his family in San Diego a year ago, said he feared that limited American strikes might escalate the war rather than tamp it down.

“If the U.S. wanted to interfere with military action it would be more beneficial to strike the presidential palace in Damascus,” said Mr. Haidar, who, with his wife and three children, fled their town southwest of Aleppo in 2012, moving at first to Indonesia. “The United States is capable of stopping the conflict in one month if they are taking it seriously.”

Unlike some others, he said he was not angered by Mr. Trump’s travel orders.

“I thought as the president, it is up to him to decide to decide what is beneficial to his own country,” he said. “But I wish they took into consideration in the decision how many innocent people are suffering and hurting in Syria.”