We study the overdetermined problem
$$
\left\{
\begin{array}{cc}
\Delta u + f(u) = 0 & \mbox{ in $\Omega$,}
\\
u = 0 & \mbox{ on $\partial\Omega$,}
\\
\partial_\nu u = c & \mbox{ on $\Gamma$,}
\end{array}
\right.
$$
where $\Omega$ is a locally Lipschitz epigraph, that is $C^3$ on
$\Gamma\subseteq\partial\Omega$, with $\partial\Omega\setminus\Gamma$
consisting in nonaccumulating, countably many points.
We provide a geometric inequality that allows us to deduce geometric
properties of the sets $\Omega$ for which monotone solutions exist.
In particular, if $\mathcal{C} \in \mathbb{R}^n$ is a cone and either $n=2$
or $n=3$ and $f \ge 0$, then there exists no solution of
$$
\left\{
\begin{array}{cc}
\Delta u + f(u) = 0 & \mbox{ in $\mathcal{C}$,}
\\
u > 0 & \mbox{ in $\mathcal{C}$,}
\\
u = 0 & \mbox{ on $\partial\mathcal{C}$,}
\\
\partial_\nu u = c & \mbox{ on $\partial\mathcal{C} \setminus \{0\}$.}
\end{array}
\right.
$$
This answers a question raised by Juan Luis Vázquez.