If the problem were to find the number of elements conjugate to $\tau$, I had to look for the permutations with the same structure. But, here the question is different. Since $\tau$ and $\pi$ are conjugate to each other, there will be at least one $\sigma$ with the property for sure.
I tried taking an arbitrary $\sigma$ and substituting in the given equation to get some properties of $\sigma$ but didn't get any conclusion from it.
Please guide me to solve similar problems.

Conjugating by $\sigma$ can take $2$ to any of $6$ different permissible locations -- anywhere that's involved in one of the $3$-cycles of $\pi$. That choice determines where $5$ and $8$ have to go. Once those choices have been made, conjugating by $\sigma$ can take $1$ to any of $3$ permissible locations (any point in the unused $3$-cycle of $\pi$), and that choice will determine where $6$ and $7$ have to go. Once those two choices are made, $3$ can go to either of $2$ possible locations (one of the fixed points of $\pi$), and that final choice will determine where $4$ has to go (the unused fixed point of $\pi$).
So there are $6 \cdot 3 \cdot 2=36$ possible permutations $\sigma$ that conjugate $\tau$ to $\pi$.