The Bodhisatta was once a bird. He led a flock living in a giant tree that stretched out over a lake. A naga living in the lake grew tired of their excrement fouling his home, so one night he decided to burn them out. He made the water boil, then smoke and flames shot up. The Bodhisatta told his flock to flee as quickly as they could. Many birds followed his advice, but some stayed behind and died.
In the Lifetime of the Buddha
The Buddha had sent one of his disciples out to the forest to do meditation during the rains retreat. Soon after he began, his hut burned down and he was forced to sleep outdoors in great discomfort. He told nearby villagers about the problem and they promised to build him a new hut, but when the three months were over, nobody had built him one and he failed to progress in his meditation because of it.
Upon returning to the monastery, he told the Buddha he had failed and explained why. The Buddha told him this story so he understood that he was a fool for not relocating to an appropriate place to do his meditation as he himself had once done, even though he was just an animal at the time.
The birds who fled the tree with the Bodhisatta were earlier births of the Buddha’s disciples.