In this paper, we study the following Kazdan-Warner equation with sign-changing prescribed function h \begin{align*} -\Delta u=8\pi\left(\frac{he^{u}}{\int_{\Sigma}he^{u}}-1\right) \end{align*} on a closed Riemann surface whose area is equal to one. The solutions are the critical points of the functional J8π which is defined by \begin{align*} J_{8\pi}(u)=\frac{1}{16\pi}\int_{\Sigma}|\nabla u|^2+\int_{\Sigma}u-\ln\left|\int_{\Sigma}he^{u}\right|,\quad u\in H^1\left(\Sigma\right). \end{align*} We prove the existence of minimizer of J8π by assuming \begin{equation*} \Delta \ln h^++8\pi-2K>0 \end{equation*}at each maximum point of 2lnh++A, where K is the Gaussian curvature, h+ is the positive part of h and A is the regular part of the Green function. This generalizes the existence result of Ding, Jost, Li and Wang [Asian J. Math. 1(1997), 230-248] to the sign-changing prescribed function case. We are also interested in the blow-up behavior of a sequence uε of critical points of J8π−ε with ∫Σheuε=1,ε↘0limJ8π−ε(uε)<∞ and obtain the following identity during the blow-up process \begin{equation*} -\varepsilon=\frac{16\pi}{(8\pi-\varepsilon)h(p_\varepsilon)}\left[\Delta \ln h(p_\varepsilon)+8\pi-2K(p_\varepsilon)\right]\lambda_{\varepsilon}e^{-\lambda_{\varepsilon}}+O\left(e^{-\lambda_{\varepsilon}}\right), \end{equation*}where pε and λε are the maximum point and maximum value of uε, respectively. Moreover, pε converges to the blow-up point which is a critical point of the function 2lnh++A.