Erasing heads using permanent magnets