The leakage occurred at a recycling center in Lisi Village, Linyi County. The toxic gas had seeped out of an abandoned container, the county government said.
The primary school is just 30 meters away from the recycling center.
The students were admitted to hospital after all complained of breathing difficulties and stomach ache, state-run Xinhua news agency reported.
So far two kids were still in hospital but their condition is stable. The rest have all been discharged.
A suspect, who is linked to the recycling center, is currently in police custody.
