The riot began when a group of young people were turned away from the festival Saturday, ThinkSpain reported.
Rioters knocked down or jumped over fences to get into the festival grounds.
Police dispersed the crowd using tear gas and shooting rubber pellets.
About 20 people officers and more than 40 festival-goers were injured in the incident and 11 people have been arrested for attacks on police.
'How to Train Your Dragon 2' releases 5-minute clip
Yosemite climber falls 30 feet, suffers major injuries