People stand outside Kronan school after  yesterday's attack, in Trollhattan, Sweden, Friday, Oct. 23, 2015. It was a racially motivated, carefully planned rampage, police say. The 21-year-old masked man marched through a Swedish school with a sword and a knife, methodically selecting his victims. Within minutes, two people had been stabbed to death and two others seriously wounded before the attacker was fatally shot by police. (Bjorn Larsson Rosvall/TT News Agency via AP)  SWEDEN OUT

People stand outside Kronan school after yesterday’s attack, in Trollhattan, Sweden, Friday, Oct. 23, 2015. It was a racially motivated, carefully planned rampage, police say. The 21-year-old masked man marched through a Swedish school with a sword and a knife, methodically selecting his victims. Within minutes, two people had been stabbed to death and two others seriously wounded before the attacker was fatally shot by police. (Bjorn Larsson Rosvall/TT News Agency via AP)

TROLLHATTAN, Sweden (AP) — The southern industrial city of Trollhattan has become a focal point for underlying racial tensions in Sweden, a country known for its generous atttudes to migrants.

On Thursday, a 21-year-old local man with racist motives rampaged through a school, stabbing two people to death and seriously wounding two others before being fatally shot by police. Authorities say he methodically selected dark-skinned victims at Trollhattan’s Kronan school, where most students are foreign-born.

The attacker, who killed a teacher and a student, has not been named by police.

Many in this nation of 10 million were horrified by the violence but not surprised at its eruption, as the migrant surge across Europe has increased anti-immigrant attitudes. A teacher at a nearby school, Jo-Anne Frampton, said it was “just a matter of time.”