If I know $AB$, how can I calculate $BA$?

$(AB)^2=9(AB)\Rightarrow(BA)^3=9(BA)^2\Rightarrow \mu_{BA}(X)\mid X^2(X-9)$

$P_{AB}(X)=X(X-9)^2\Rightarrow P_{BA}(X)=(X-9)^2\Rightarrow\mu_{BA}(X)\mid (X-9)^2$

Conclusion: $\mu_{BA}(X)=X-9$, so $BA=9I_2$.

(Here $\mu_X$, respectively $P_X$ stands for the minimal polynomial, respectively the characteristic polynomial of a square matrix $X$.)