5. Let $F_{1}$ and $F_{2}$ be

the left and right foci of the hyperbola $C: \frac{x^{2}}{a^{2}}-\frac{y^{2}}{b^{2}}=1(a>0, b>0)$,
and let the line $l$ passing through $F_{2}$ intersect the right branch of the hyperbola $C$ at points $A$ and $B$, and
$$
\overrightarrow{A F_{1}} \cdot \overrightarrow{A F_{2}}=0, \overrightarrow{F_{2} B}+2 \overrightarrow{F_{2} A}=\mathbf{0} \text {. }
$$

Then the eccentricity of the hyperbola $C$ is
5. $\frac{\sqrt{17}}{3}$.

As shown in Figure 4, let $\left|A F_{2}\right|=t$.
According to the problem, we have
$$
\left.\begin{array}{l}
\left|B F_{2}\right|=2 t, \\
|A B|=3 t, \\
\left|A F_{1}\right|=2 a+t, \\
\left|B F_{1}\right|=2 a+2 t . \\
\text { By } \overrightarrow{A F_{1}} \cdot \overrightarrow{A F_{2}}=0 \\
\Rightarrow A F_{1} \perp A F_{2} . \\
\text { Then }\left\{\begin{array}{l}
\left|A F_{1}\right|^{2}+\left|A F_{2}\right|^{2}=\left|F_{1} F_{2}\right|^{2}, \\
\left|A F_{1}\right|^{2}+|A B|^{2}=\left|F_{1} B\right|^{2}
\end{array}\right. \\
\Rightarrow\left\{\begin{array}{l}
(2 a+t)^{2}+t^{2}=(2 c)^{2}, \\
(2 a+t)^{2}+(3 t)^{2}=(2 a+2 t)^{2}
\end{array}\right. \\
\Rightarrow t=\frac{2}{3} a, c=\frac{\sqrt{17}}{3} a
\end{array}\right]
$$