Solve equation using Little Fermat's theorem

I'm trying to solve $8^x \equiv 2 \mod 23$ using Fermat's little theorem.

We have $2^{3x} \equiv 2 \mod 23$, then $3x=23$, but this doesn't work.

As $(2,11)=1$, we have $2^{3x-1}\equiv1\pmod{23}$
Now, $2^2=4\not\equiv1,2^5=32\equiv9,2^{10}\equiv9^2\equiv12,2^{11}\equiv24\equiv1$
So, $3x-1\equiv0\pmod{11}\iff3x\equiv1\pmod{11}\equiv1+11$
$\implies x\equiv4\pmod{11}$ as $(3,11)=1$
You have $2^{22}\equiv 1$ so you should be able to see that there are alternatives to $3x=23$.