‘Abdullāh ibn ‘Umar (may Allah be pleased with him) reported that whenever the Messenger of Allah (may Allah's peace and blessings be upon him) set out on a journey, he would say by nightfall: "O earth, my Lord and your Lord is Allah, I seek refuge in Allah from your evil, the evil of what you contain, the evil of what has been created in you, and the evil of what walks upon you. I seek refuge in You from lions, black serpents, snakes, scorpions, the inhabitants of the place, and from the parent (Satan) and his offspring (the devils)."
عن عبدالله بن عمر -رضي الله عنهما- كان رسول الله - صلى الله عليه وسلم - إذا سافر فأقبل الليلُ، قال: «يا أرضُ، ربي وربُّك الله، أعوذ بالله مِن شَرِّكِ وشر ما فيك، وشر ما خُلق فيك، وشر ما يَدُبُّ عليك، وأعوذ بِك من شر أسد وأسود، ومن الحية والعقرب، ومن ساكِن البلد، ومن والد وما ولد».
شرح الحديث :
The Prophet's statement "O earth, my Lord and your Lord is Allah" means if my Creator and your Creator is Allah, then He is the One whom I should turn to in all affairs, and seek refuge in from your evil. The Prophet (may Allah's peace and blessings be upon him) sought refuge in Allah from the earth's evil, which is the evil caused in it by the decree of Allah, such as sinking of earth, earthquakes, straying into the lands, and being lost in the desert. The evil contained in the earth implies the harm that results from it and may kill people, like water or plants. The evil of what has been created in earth, however, refers to the vermin and like. This Hadīth is weak and thus does not need much explanation. It is mentioned just to draw the intention to its weakness. Allah knows best!