Several major prisons in New South Wales are in lockdown after 12 inmates became infected at Parklea Correctional Centre.

A Corrective Services NSW spokesperson said 23 prisons across NSW were taking extra precautions after inmates were recently transferred to those prisons from Parklea Correctional Centre.

The union representing prison guards has called for all guards to be vaccinated as a matter of urgency.

The Public Service Association's Stewart Little says many doses originally earmarked for prison officers had been redirected to high school students.