I am certain that I have answered this before. Let $Y$ be $\mathbb{P}^2$. Let $\Omega_{\mathbb{P}^2/k}$ be the sheaf of relative differentials. This is locally free of rank $2$. Via the Euler sequence and the Whitney sum formula, the total Chern class of $\Omega_{\mathbb{P}^2/k}$ equals
$$
c_t(\Omega_{\mathbb{P}^2/k}) = 1 - 3c_1(\mathcal{O}(1))t + 3c_1(\mathcal{O}(1))^2t^2.
$$
If the K-theory class $[\Omega_{\mathbb{P}^2/k}]$ of this rank two sheaf were a sum of the classes of two invertible sheaves, then those invertible sheaves would be $[\mathcal{O}(a)]$ and $[\mathcal{O}(b)]$ for $a,b\in \mathbb{Z}$ (by the classification of invertible sheaves on projective spaces). Again by the Whitney sum formula, this would give an identity in the Chow groups,
$$
1 - 3c_1(\mathcal{O}(1))t + 3c_1(\mathcal{O}(1))^2 t^2 = \left(1+ac_1(\mathcal{O}(1))t\right)\cdot \left(1+bc_1(\mathcal{O}(1))t\right).
$$
Since $1$, $c_1(\mathcal{O}(1))$ and $c_1(\mathcal{O}(1))^2$ are an additive basis for the Chow group of $\mathbb{P}^2$, this gives identities of integers,
$$
a+b = -3, \ \ ab = 3.
$$
This has no solutions. Thus, $\Omega_{\mathbb{P}^2/k}$ fits into no short exact sequence
$$
0 \to \mathcal{O}(a) \to \Omega_{\mathbb{P}^2/k} \to \mathcal{O}(b) \to 0.
$$
Now let $f:X\to Y$ be the $\mathbb{P}^1$-bundle associated to this locally free sheaf,
$$
X = \text{Proj}_Y(\text{Sym}^{\bullet}_{\mathcal{O}_Y}(\Omega_{Y/k})).
$$
If there were a global section $s$ of $f$, then the pullback of the universal quotient invertible sheaf of $f^*\Omega_{Y/k}$ would give a short exact sequence as above. Thus, there is no global section of $f$. However, there are plenty of rational sections.
Edit. I looked through my answers. The construction above is also in my answer to the following: What can we say about this generalization of simply-connectedness?.