Indonesian workers frustrated by long waits to get exit visas from Saudi Arabia protested outside their consulate on Sunday, setting fire to the building's outer wall and briefly clashing with security forces, witnesses said.
Hundreds of thousands of foreign workers in the world's top oil exporter are trying to rectify their immigration status or leave the country before July 3, when the government will resume a crackdown on illegal labor.
Workers have queued outside government offices and some consulates for days on end over recent weeks in daytime temperatures topping 40 degrees centigrade, often sleeping outside the offices to keep their place in line.
Local media have reported people attempting to resolve their status have hit a string of bureaucratic obstacles as government offices and expatriates consulates are overwhelmed.
Films posted online and verified by witnesses showed a fire against the wall of the consulate. Other pictures showed men with scarves over their faces setting alight plastic barriers next to the wall.
Saudi Arabia is cracking down on expatriates working illegally as part of wide ranging labor reforms aimed at pushing more local people into private sector jobs.
The latest central bank figures, from 2011, showed that around nine tenths of all jobs for private companies were held by some of the roughly nine million foreigners living in the country. Saudis enjoy greater job protection than foreigners and often expect more pay.
The labor reforms have imposed a series of localization quotas backed up with fines and hiring bans, and have levied an annual 2,400 riyals ($640) fee that firms must pay for every foreigner they employ above the number of their Saudi staff.
Under Saudi law, foreigners must be "sponsored" by their employer and can only work in the profession listed on their residency papers. In practice, many foreigners find other jobs without changing their residency status.