Pupils stranded as unknown persons lock out classrooms