Via its Twitter account, the general prosecutor said a preliminary report indicates four women and two men died from gunshots on the road that connects the towns of La Venta and Union Hidalgo.
The prosecutor's office said the shooting occurred Monday morning around 8 a.m. local time (1300 GMT) and an investigation into the shooting was immediately opened.
According to local media reports, the armed gunmen shot at several people who had gathered on the road in the municipality of Juchitan de Zaragoza of the Istmo de Tehuantepec region, outside a small wind farm.
Police were immediately deployed to the area in search for the attackers, who had fled in a van.
Oaxaca, one of the poorest regions in Mexico, has seen several cases related to multiple murders in the past, which local authorities link to disputes over land.
More about: #Mexico