BOSTON (AP) _ Nearly 400 inmates who filed a class-action suit to protest having to use buckets as toilets in cells at the county jail in Lawrence will split $1.2 million in a settlement.

Inmates sued in 1981, claiming the lack of plumbing violated their rights, and Superior Court Judge Paul G. Garrity two years later gave Essex County six months to provide toilets and sinks.

A financial settlement recently was reached out of court. Essex County Special Sheriff Harry Coppola said Tuesday the money will be divided among 397 inmates forced to use plastic ''night soil pots'' in their cells after the 9 p.m. lockdown.

The state will pay half the settlement this year, and Essex County will pay the rest in three installments over the next three years.