What is the definition of $\nabla g$ in Riemannian geometry Sorry for this dump question. But I don't know the rigorous definition of $\nabla g$ in Riemannian geometry. It seems to be a tensor(?). Here, $g$ is a Riemannian metric on a manifold and $\nabla$ is a linear connection(?).
I saw from somewhere that $\nabla g \equiv 0$ means the linear connection is compatible with $g$.  
 A: If $T$ is a $(m,n)$-tensor field then $\nabla T$ is a $(m,n+1)$-tensor field which defined as follow
$$(\nabla T)(X,X_1,\cdots,X_{m},\eta_1,\cdots,\eta_n)=(\nabla_X T)(X_1,\cdots,X_{m},\eta_1,\cdots,\eta_n),$$
if $T=g$ then $\nabla g$ is a $(0,3 )$-tensor field which vanish by compatibility condition. for more details see here
A: As pointed out in C. F. G.'s answer, $\nabla g$ is a $(0, 3)$-tensor field given by $$(\nabla g)(X, Y, Z) = (\nabla_Xg)(Y, Z)$$ where $X, Y, Z$ are vector fields. In order for this to make sense, you need to know what $\nabla_Xg$ means. I attempt to address this point below.

Let $M$ be a smooth manifold.

Let $E_1$ and $E_2$ be smooth vector bundles on $M$, and let $\nabla^{E_1}$ and $\nabla^{E_2}$ be connections on $E_1$ and $E_2$ respectively. Then there is an induced connection $\nabla^{E_1\otimes E_2}$ on $E_1\otimes E_2$ which satisfies $$\nabla^{E_1\otimes E_2}_X(s_1\otimes s_2) = (\nabla^{E_1}_Xs_1)\otimes s_2 + s_1\otimes (\nabla^{E_2}_Xs_2)$$ where $X \in \Gamma(M, TM)$, $s_1 \in \Gamma(M, E_1)$, and $s_2 \in \Gamma(M, E_2)$.

In particular, when $E_1 = E_2 = TM$, we obtain a connection $\nabla^{TM\otimes TM}$ on $TM\otimes TM$.

Let $F$ be a smooth vector bundle on $M$, and let $\nabla^F$ be a connection on $F$. There is an induced connection $\nabla^{F^*}$ on $E^*$ which satisfies $$X(\sigma(s)) = (\nabla^{F^*}_X\sigma)(s) + \sigma(\nabla_X^F s)$$ where $X \in \Gamma(M, TM)$, $s \in \Gamma(M, F)$, and $\sigma \in \Gamma(M, F^*)$.

Setting $F = TM\otimes TM$, we obtain a connection $\nabla^{(TM\otimes TM)^*}$ on $(TM\otimes TM)^*$.
There is an identification between $(V\otimes W)^*$ and the collection of bilinear maps $V\times W \to \mathbb{R}$. Under this identification, we can view $g$ as a section of $(TM\otimes TM)^*$ so the expression $\nabla^{(TM\otimes TM)^*}g$ makes sense. More precisely, for $X, Y, Z \in \Gamma(M, TM)$ we have
\begin{align*}
X(g(Y\otimes Z)) &= (\nabla^{(TM\otimes TM)^*}_Xg)(Y\otimes Z) + g(\nabla^{TM\otimes TM}_X(Y\otimes Z))\\
&= (\nabla^{(TM\otimes TM)^*}g)(Y\otimes Z) + g((\nabla^{TM}_XY)\otimes Z + Y\otimes(\nabla_X^{TM}Z))\\
&= (\nabla^{(TM\otimes TM)^*}g)(Y\otimes Z) + g((\nabla^{TM}_XY)\otimes Z) + g(Y\otimes(\nabla_X^{TM}Z)).\\
\end{align*}
Viewing $g$ as a bilinear pairing, the equation becomes
$$X(g(Y, Z)) = (\nabla^{(TM\otimes TM)^*}_Xg)(Y, Z) + g(\nabla^{TM}_XY, Z) + g(Y, \nabla_X^{TM}Z).$$
Often authors use $\nabla$ to denote a connection on the tangent bundle and use the same notation for the connections it induces on other bundles. With this convention, the equation becomes
$$X(g(Y, Z)) = (\nabla_Xg)(Y, Z) + g(\nabla_X Y, Z) + g(Y, \nabla_X Z).$$
This equation implicitly defines $\nabla g$. More explicitly,
$$(\nabla g)(X, Y, Z) = (\nabla_Xg)(Y, Z) = X(g(Y, Z)) - g(\nabla_X Y, Z) - g(Y, \nabla_X Z).$$
