Families have been forced to avoid visiting inmates in a Nottinghamshire prison after cells became infested by bed bugs.