The setting for Chapter 2, as for the rest of the novel, is Maycomb, Alabama during the 1930s.
In terms of the specific timing of chapter two and its impact on the narration, the setting of chapter two is one of a transition, excitement, and disappointment.
There is a transition going on, as summer is over, and school is about to start. For Scout, this means that Dill is gone and she will start school.
Second, this prospects of school is something that Scout is excited about. She has been looking forward to this day for a long time. Scout is a precocious child and wants to learn. Here is what she says in her own words:
"I never looked forward more to anything in my life."
Finally and quickly disappointment settles. When Scout meets Miss Caroline, it seems that all of Scout's attempts at being helpful or good fail. Scout gets in trouble for knowing how to read. When Scout tries to explain that Walter Cunningham is poor and cannot afford to bring lunch, Miss Caroline is annoyed. Finally, Miss Caroline punishes Scout with a few slaps with a ruler.