Kagamiyama Tenmangu is hidden away on a large hillside right next to Route 9 as it passes through central Hamada. It is reached through a narrow alleyway and then a long flight of stairs. As is often the case, the shrine is located right next to a small temple, and in all probability they were one and the same place until the government executed shinbutsubunri, the seperation of buddhas and kami, in the mid 19th Century.
The main kami of the shrine is Tenjin, the kami of scholarship and poetry. There are 2 secondary shrines, one an Akiba shrine, a very popular kami spread throughout Japan by yamabushi, and an Ebisu shrine. The shrine does not appear to be used much, probably owing to the fact that 100 metres away is a branch shrine of Izumo taisha, which is very popular.
Route 9, the main road through Hamada starts in Kyoto and runs all the way to Yamaguchi. It follows the ancient Sanindo, one of 7 roads that radiated out from the fledgling capital in Asuka, near Nara, in the 6th Century when the Yamato were beginning to consolidate their control over Japan.