Find the invertibles modulo 8, then their inverses. Do the same modulo 9.
Modulo 8, the invertibles are $1,3,5$ and 7, and they are their own inverses.

Modulo 9, the invertibles are $1,2,4,5,7$ and 8, 1 and 8 are their own inverses, $2^{-1}=5$, and $4^{-1}=7$.