This paper proposes a distributed conjugate gradient tracking algorithm (DCGT) to solve resource allocation problems in a possibly unbalanced network, where each node of the network computes its optimal resource via interacting only with its neighboring nodes. Our key idea is the novel use of the celebrated AB algorithm to the dual of the resource allocation problem. To study the convergence of DCGT, we first establish the sublinear convergence of AB for non-convex objective functions, which advances the existing results on AB as they require the strong-convexity of objective functions. Then we show that DCGT converges linearly for strongly convex and Lipschitz smooth objective functions, and sublinearly without the Lipschitz smoothness. Finally, simulation results validate that DCGT outperforms state-of-the-art algorithms in distributed resource allocation problems.