If $a, b$ are positive integers such that $a|b^2, b^2|a^3,....$ then $a=b$. The following is a well known problem 

If $a|b^2; b^2|a^3; a^3|b^4; ....$ then $a=b$.

I started with $a$ is a prime $p$ and the conclusion immediately holds. 
So I was comparing powers of primes but can't get anything useful.
 Please help.
Hint $\quad\ \forall n\in\mathbb N: \ \color{#c00}a\:\!\left(\dfrac{a}b\right)^{2n}\!\!\in\mathbb Z\,\Rightarrow \color{#c00}a\,$ is a denominator for unbounded powers of $\,\dfrac{a}b\,$ so $\,\dfrac{a}b\in\Bbb Z$

Likewise $\forall n\in\mathbb N:\ b\:\!\left(\dfrac{b}a\right)^{2n+1}\!\!\in \mathbb Z\ \ \Rightarrow\ \dfrac{b}a\in \Bbb Z.\ $ Thus $\ b\mid a\mid b\ $ so $\,a = b.$

Remark $ $ This generalizes to any Noetherian integrally-closed domain $D,\,$ e.g. any PID, since if unbounded powers of a fraction $f$ over $D$ have a common denominator then $\,f\in D\,$ (Proof)
Hint:  that is a good start.  Now can you prove it for $a=p^k$ with any prime $p$?  $b$ has to again be a power of $p$.  After that, claim that it is multiplicative, so when you factor $a$ you get the two cases you have proved.