In this paper, we consider a risk model with two independent classes of insurance risks and random incomes. We assume that the two independent claim counting processes are, respectively, the Poisson and the Erlang(2) process. When the individual premium sizes are exponentially distributed, the explicit expressions for the Laplace transforms of the expected discounted penalty functions are derived. We prove that the expected discounted penalty functions satisfy some defective renewal equations. By employing an associated compound geometric distribution, the analytic expressions for the solutions of the defective renewal equations are obtained. Assuming that the distributions of premium sizes have rational Laplace transforms, we also give the explicit representations for the Laplace transforms of the expected discounted penalty functions.