Yeah, the "ugly integral" involves something called the digamma function.
The gamma function is given by $$\Gamma(x)=\int_0^{\infty} e^{-t}t^{x-1}dt,$$ and the digamma function is given by $$\Psi(x) = \frac{d}{dx}\ln\bigl(\Gamma(x)\bigr).$$
A closed formula for the sum (for all $n\leq N$) is $$\sum_{n=1}^N \frac{1}{n^2}=\frac{1}{6}\pi^2-\left(\frac{d}{dx}\Psi(x)\right)\bigg|_{x=N+1}.$$
To get your expression for the sum of only even $n$, note that $$\sum_{n=2}^{2N}\frac{1}{n^2}=\sum_{n=1}^{N}\frac{1}{(2n)^2}=\frac{1}{4}\left(\sum_{n=1}^N\frac{1}{n^2}\right),$$ so $$\sum_{\substack{n=2\\ n \text{ even}}}^N \frac{1}{n^2}=\frac{\pi^2}{24}-f(N),$$ where $$f(N)=\frac{1}{4}\left(\frac{d}{dx}\Psi(x)\right)\bigg|_{x=\left\lfloor\frac{N}{2}\right\rfloor+1}$$
For the odds, you can take the difference of these two formulas,
\begin{align} \sum_{\substack{n=1\\ n \text{ odd}}}^N\frac{1}{n^2}&=\left(\sum_{n=1}^N \frac{1}{n^2}\right)-\left(\sum_{\substack{n=2\\ n \text{ even}}}^N \frac{1}{n^2}\right)\\ &=\left(\frac{1}{6}\pi^2-\left(\frac{d}{dx}\Psi(x)\right)\bigg|_{x=N+1}\right)-\left(\frac{\pi^2}{24}-\frac{1}{4}\left(\frac{d}{dx}\Psi(x)\right)\bigg|_{x=\left\lfloor\frac{N}{2}\right\rfloor+1}\right)\\ &=\frac{\pi^2}{8}-g(N), \end{align} where $$g(N)=\left(\frac{d}{dx}\Psi(x)\right)\bigg|_{N+1}-f(N).$$