Chickens will peck holes in their eggs if they're trying to eat them which could be a sign of hunger, a calcium deficiency, boredom or frustration due to a lack of space. It could also happen just because the chicken has got a taste for eggs or has seen another chicken do it.