Solve $\frac{dy}{dx}=\frac{y^2-1}{x^2-1}$ with initial condition $y(2)=2$ 
Solve the following differential equation: $\dfrac{dy}{dx}=\dfrac{y^2-1}{x^2-1}$, with the initial condition $y(2)=2$.

My attempt:
I notice that this is a separable differential equation, so I try to get it into the form $p(y) dy=f(x) dx$.
$\dfrac{dy}{dx}=\dfrac{y^2-1}{x^2-1}\\\implies \dfrac{1}{y^2-1} dy=\dfrac{1}{1-x^2}dx\\\implies\displaystyle\int\dfrac{1}{y^2-1} dy=\displaystyle\int\dfrac{1}{1-x^2}dx\\\implies \ln(y^2-1)=\ln(x^2-1)$
Now I tried to apply the initial condition of $y(2)=2$:
$\ln(2^2-1)=\ln(2^2-1)\implies\ln3=\ln3$
I'm fairly new to solving differential equations, so I don't know if I'm doing a step incorrectly or what the problem is. If anyone could shed any light on this, it would be appreciated. Thanks in advance.

Since you are considering the boundary condition $y(2)=2,$ it is only fair to restrict the domain of the function to $x\gt1.$ Therefore, we have that $$\frac{y'(x)}{y(x)^2-1}=\frac1{1-x^2}\implies\frac{2y'(x)}{y(x)^2-1}=\frac2{1-x^2}$$ $$\implies\left[\frac1{y(x)-1}-\frac1{y(x)+1}\right]y'(x)=\frac1{1+x}+\frac1{1-x}=\frac1{x+1}-\frac1{x-1}.$$ This of course assumes that $y(x)\neq-1$ and $y(x)\neq1,$ with these corresponding to the trivial solutions. Since $y(2)=2,$ it is the case that $y(x)\gt1,$ so $$\ln\left[\frac{y(x)-1}{y(x)+1}\right]=\ln\left(\frac{x+1}{x-1}\right)+C.$$ Let $x=2,$ hence $$\ln\left(\frac13\right)=\ln(3)+C,$$ implying $$C=\ln\left(\frac19\right).$$ Therefore, $$\ln\left[\frac{y(x)-1}{y(x)+1}\right]=\ln\left(\frac{x+1}{x-1}\right)+\ln\left(\frac19\right).$$ This is equivalent to $$\frac{y(x)-1}{y(x)+1}=\frac{x+1}{9x-9},$$ which is equivalent to $$[y(x)-1](9x-9)=[y(x)+1](x+1)=(9x-9)y(x)-(9x-9)=(x+1)y(x)+(x+1),$$ which is equivalent to $$(8x-10)y(x)=10x-8,$$ which simplifies to $$y(x)=\frac{10x-8}{8x-10}=\frac{5x-4}{4x-5}.$$
