According to David Cox’s ‘Galois Theory’ (Proposition 11.1.5.),
If $f \in \mathbb{F}_p[x]$ is nonconstant and $n \geq 1$, then the number of roots of $f$ in $\mathbb{F}_{p^n}$ is the degree of the polynomial $\gcd(f,x^{p^n}-x)$.
(Here the $\gcd$ is computed in $\mathbb{F}_p[x]$).
I was trying to use this to calculate the Galois group of $f=x^5-x-1$. I have first verified that $f$ has no roots mod $2$, but then (here I call $\bar{f}$ the reduction of $f$ mod $2$):
$$ \bar{f} \equiv x^2-x-1 \mod x^4-x $$
…and $x^2-x-1 \equiv x^2+x+1 \mod 2$, which divides $x^4-x$, so the degree of $\gcd(f,x^4-1)$ is at least $2$… but I’m verifying manually and $\bar{f}$ doesn’t seem to have any roots in $\mathbb{F}_4$. Where did I go wrong?
When verifying manually, did you possibly confuse $\mathbb{F}_4$ with $\mathbb{Z}_4$? That would explain why you didn't find the two roots of $x^2 + x +1$, if you tested the elements $0$, $1$, $2$ and $3$.
The four elements of $\mathbb{F}_4$ are found by adjoining a new element $\omega$ to $\mathbb{F}_2$. I tend to think of $\omega$ as a non-trivial cube root of $1$, and the four elements are then $0$, $1$, $\omega$ and $\omega +1$.
We find that $\omega^2$, as the other non-trivial cube root of $1$, has to be the same as $\omega +1$, and after a bit of rearranging that gives us $\omega^2 + \omega +1 = 0$. This gets us the roots you were looking for.
In any case, this construction of $\mathbb{F}_4$ is exactly the same as the quotient ring $\mathbb{F}_2 [X] / (X^2+X+1)$ since that polynomial is irreducible over $\mathbb{F}_2$. Of course, with this construction it clearly has roots to that polynomial.