Santhava Jātaka (No.162)
The Bodhisatta was once a brahmin, and, when he grew up, he lived in a hermitage in the forest, tending his birth-fire (jātaggi). One day, having received a present of rice and ghee, he took it home, made his fire blaze up, and put the rice into the fire. The flames rose up and burnt his hut. Deciding that the company of the wicked was dangerous, he put out the fire and went up into the mountains. There he saw a deer licking the faces of a lion, a tiger, and a panther. Nothing is better than good friends thought the Bodhisatta.
The story was related to show the uselessness of tending the sacred fire. J.ii.41 f.