Two female tourists were slashed during the incident, which occurred in the town of Nabeul near Hammamet.
The victims are a German mother and her daughter, according to a spokesperson for Tunisia’s tourism and interior ministries.
He said the mother was slightly injured and treated at the scene.
They said the daughter suffered more serious injuries but is “in a stable condition”.
Both women were taken to hospital but have been described as being “out of danger”.
They also ruled out terrorism as a motive.
A photo taken at the scene appears to show a man, nursing a head wound, being restrained by police.
The man appears to be handcuffed and in the company of a large group of men, who intially brought the attacker under control.
In 2015, 38 people, including 30 British tourists, were killed during a terrorist massacre at Port El Kantaou resort.
Islamic State claimed responsibility for the attack, which also claimed casualties from Ireland, Germany, Belgium, Russia and Portugal.