At least 10 people were killed in overnight violence as Bangladesh went to the polls for local elections, seven of them shot dead by security forces, police said Wednesday.

"A magistrate ordered the shooting and officers fired at thousands of unruly people who attacked us with machetes, rocks and sticks. Three people died on the spot and two on the way to hospital," said Walid Hossain, district police chief in the coastal town of Mathbnaria, where many of the clashes occurred.

Five others were killed in separate clashes across the country, police said.