Let $\pi:X\rightarrow S$ be a smooth scheme over $S$ and let's assume for simplicity that $S=\mathrm{Spec} R$ is affine, Noetherian and regular. Let $\mathcal F$ be a coherent sheaf on $X$ and let's assume as well that $\mathcal F$ is torsion-free. Then I can take the derived global sections $R^\bullet\pi\_\* \mathcal F$, taking further its cohomology I get some $R$-modules $R^i\pi\_\*\mathcal F$. 


Now the question is:


Given $R^i\pi\_\* \mathcal F$ can I say anything about torsion in it (as in an $R$-module)? In particular is there an open dense $U\subset S$ such that $R^i\pi\_\*\mathcal F$ is torsion-free restricted to $U$?


If $\pi$ is proper this is automatic since then $R^i\pi\_\* \mathcal F$ is finitely generated over $R$. If $\pi$ is affine then $R^\bullet\pi\_\* \mathcal F=\pi\_\*\mathcal F$ and we just consider some torsion-free module $M$ over $R'$ as a module over $R$ under an injection $R\subset R'$, so the statement holds as well. For the general case I tried to use a Cech cover of $X$ by affine $S$-schemes, but what you get is a complex whose terms are infinitely generated $R$-modules (though torsion-free) and I'm not sure what I could use to bound the torsion in the cohomology there.


Also, not sure if this makes life any simplier, but under the assumptions above $\mathcal F$ is a perfect complex on $X$ and it would be enough to take $\mathcal F=\mathcal O\_X$.



Boundness of torsion in $R^i\pi_*\mathcal F$ for a smooth $\pi:X\rightarrow S$
No, this isn't true even when $S = \text{Spec}(\mathbf{Z})$ because of an example of [Anurag Singh](https://arxiv.org/abs/math/0406354). Set
$$
R = \mathbf{Z}[X, Y, Z, U, V, W]/(XU + YV + ZW)
$$
and let $\mathfrak a \subset R$ be the ideal generated by $X, Y, Z$ in $R$. Set
$$
X = \text{Spec}(R) \setminus V(\mathfrak a)
$$
Then $H^2(X, \mathcal{O}\_X) = H^3\_\mathfrak a(R)$ has a $p$-torsion element for infinitely many primes $p$ (see link given above).


