CANCUN, Mexico (Reuters) - At least four people were killed after gunmen opened fire at government offices in the Mexican beach resort of Cancun on Tuesday, a day after at least five people died in a shooting at a music festival nearby.

Slideshow ( 2 images )

Rodolfo del Angel Campos, chief of police for the state of Quintana Roo, said gunfire broke out at the state attorney general’s office in Cancun, a city that is one of the most popular seaside destinations for foreign tourists in Mexico.

Police intervened, and the alarm was sounded, activating federal police and the armed forces, del Angel said, adding that other installations were also attacked. Television broadcast outbreaks of afternoon gunfire in Cancun.

One policeman and three suspected gunmen were killed, and a further five suspects arrested, state governor Carlos Joaquin told Mexican television on Tuesday evening.

“The state is under control and in order,” Joaquin said, adding that he had arranged with the Interior Ministry to send federal forces to reinforce security. “People from Cancun and our visitors can go about their lives as normal.”

Joaquin, who took office in September, described the attacks as a reaction by gangsters to his crackdown on organized crime, which he said had enjoyed impunity for years.

The ruling Institutional Revolutionary Party (PRI) has been reviewing disciplinary action against Joaquin’s predecessor, former PRI state governor Roberto Borge, whom the opposition has accused of fraud and corruption. He denies any wrongdoing.

Lying on the Caribbean coast of eastern Mexico, Quintana Roo has suffered sporadic violence in the past few years as drug cartels battle for control of the lucrative local market.

Changes in power have been known to inflame turf wars between gangs as they fight for supremacy.

On Monday, at least five people were killed and 15 wounded when a gunman opened fire in a nightclub at the nightclub in the resort of Playa del Carmen. The shooting is not being investigated as a suspected terror attack.