Malaysia on Monday rolled out the red carpet for Qatar’s emir, who is on his first trip to Southeast Asia four months after a diplomatic crisis erupted between his nation and four Arab countries.

Emir Sheikh Tamim bin Hamad Al Thani, who arrived in Kuala Lumpur late Sunday, was given a 21-gun salute at a state welcoming ceremony in Parliament attended by Malaysia’s king, Prime Minister Najib Razak and Cabinet ministers.

Sheikh Tamim later held talks with Najib, after which they witnessed the signing of agreements on training for diplomats, higher education, and legal and judicial cooperation.

The emir was to meet Malaysia’s king, followed by a state banquet at the palace before leaving late Monday.

Bahrain, Egypt, Saudi Arabia and the United Arab Emirates cut ties with Qatar on June 5 due to its close ties with Iran and alleged support for extremist groups in the region, charges denied by Doha. They also launched an economic boycott, stopping Qatar Airways flights from using their airspace, closing off the small country’s sole land border with Saudi Arabia and blocking its ships from using their ports.

The emir’s visit to Malaysia comes eight months after Saudi Arabian King Salman visited, the first trip to the Southeast Asian country by a Saudi king in more than a decade.

The Gulf crisis puts predominantly Muslim Malaysia in a tight spot because it is close to both Qatar and Saudi Arabia. Najib in July backed Kuwait’s effort to mediate the crisis and called for a swift solution.

“We pray that all differences among our Arab brothers will be settled amicably and that the unity and harmony of the (Gulf Cooperation Council) countries can be restored,” Najib said in a statement.

The emir, who will also travel to Singapore and Indonesia, is on his second trip abroad since the diplomatic crisis erupted. He traveled to Turkey, Germany, France and the United States in September.

Malaysia’s foreign ministry said it was the first visit by a ruling Qatari emir since Shekih Tamim’s father visited Malaysia in 2009. It said the visit provided an opportunity for the leaders to discuss bilateral issues and exchange views on issues of common interest.

Qatar is Malaysia’s 40th largest trading partner, with total trade of $566 million in 2016.