(Corrects name of assistant to Vietnam's foreign minister in 19th paragraph)
By Ho Binh Minh
HANOI, May 17 (Reuters) - Vietnam vowed on Saturday to thwart any new outbreak of violence after deadly rioting devastated crucial manufacturing centres this week in an outpouring of rage over Chinese oil drilling in a disputed area of the South China Sea.
Vietnam's lead police investigator defended security forces widely blamed for failing to curb the unrest and said "illegal acts" would be not be tolerated, a day ahead of expected anti-China protests in its major cities.
Hoang Kong Tu told reporters the authorities would "strongly deploy measures in line with the law" and there would be no repeat of violence seen on Tuesday and Wednesday, when mobs went on the rampage in three provinces, targeting industrial parks crucial to Vietnam's economy and exports.
The violence was triggered by China's positioning of a $1 billion oil rig in a part of the South China Sea claimed by Hanoi, a move described by the United States as provocative. It is the worst breakdown in ties between the two Communist neighbours since a short border war in 1979.
Crowds of thousands massed as rioters turned against Chinese workers and Chinese-owned businesses, smashing windows, gates and walls and torching vehicles and factories. Taiwanese-owned firms were hit hard after being mistaken for being Chinese.
The trouble broke out on Tuesday in the south after nationalist rage boiled over during protests around the industrial parks near Ho Chi Minh City, formerly Saigon.
Hundreds of Chinese and Taiwanese were forced to flee the country by plane or by bus into neighboring Cambodia.
Tu said two Chinese nationals were killed and 140 people wounded in the unrest.
A doctor at a hospital near one area of clashes said he had seen 21 dead bodies in central Ha Tinh province and an eyewitness to the fighting between Chinese and Vietnamese workers said she had seen at least 13 bodies. There were no reports of violence on Friday or Saturday.
Vietnam and China share close economic ties, worth $50 billion of trade last year, but diplomatic relations are strained, with many Vietnamese harbouring deep resentment for what they see as a history of Chinese aggression.
China's Foreign Ministry on Saturday advised Chinese nationals to hold off from traveling to Vietnam and told its citizens in Vietnam to avoid leaving their premises.
China's public security chief urged Vietnam to take tough measures to stem anti-China violence and punish rioters.
"We are strongly dissatisfied by the Vietnamese side failure to respond effectively to curb an escalation of the situation," state news agency Xinhua quoted Guo Shengkun as telling his Vietnamese counterpart during a phone conversation on Saturday.
Vietnamese authorities have also been criticised by affected businesses and workers for their response to the violence. Witnesses who spoke to Reuters said police arrived too late, or in insufficient numbers to prevent violence.
Tu insisted that was not the case.
"The police force has taken strong measures so that we have minimised the damage from what happened," he said. "We are always proactive, we are not passive, not slow."
Vietnam allowed rallies in its biggest cities a week ago in a rare move by police, which have reputation for thwarting demonstrations and arresting protesters, even though the country's constitution allows freedom of assembly. State media also reported the rallies extensively.
More protests were expected on Sunday and it was unclear whether the authorities would allow them.
Dang Minh Khoi, assistant to Vietnam's Foreign Minister, said both countries had settled disputes diplomatically in the past and would seek to do so again.
However, he said Hanoi would protect its sovereignty and urged China to remove a rig it towed into waters 240 kilometres (150 miles) off Vietnam's coast two weeks ago.
"It has infringed upon Vietnam's sovereignty and jurisdiction. Vietnam strongly protests and many times has demanded China to withdraw the oil rig." (Additional reporting by Chen Aizhu and Niu Shuping in Beijing; Writing by Martin Petty; Editing by Rosalind Russell)