In Islamic tradition, Al Rakim was the dog that guarded the legendary Seven Sleepers and that stood by them all through their long sleep.
Etymology
However, Al Rakim has alternately been identified as the name of the location of the cave of the Seven Sleepers, or the name of a "brass plate, or stone table" located at the cave, naming the sleepers.
Story
The Seven Sleepers are seven noble youths of Ephesus who, to escape the persecution of Decius, fled into a cave, where they fell asleep and woke up at the end of two centuries.
Source
The Nuttall Encyclopædia, edited by the Reverend James Wood (1907)