We explore how subjects with heterogeneous beliefs respond to a surprise restart in a linear public goods game played for 20 rounds using either a "partners" or a "strangers" protocol. There are two restarts: one prior to Round 11 and another prior to Round 16. We elicit subject beliefs at the outset and classify subjects into three groups-Top, Middle, and Bottom-depending on their prior beliefs about their peers' contributions to the public good. Then, we look at how these three groups respond, in terms of their beliefs and contributions, before and after the restart. We replicate the restart effect, but find that (i) it is much more pronounced for partner matching than for stranger matching and (ii) it is less pronounced in treatments with belief elicitation compared to control treatments where beliefs are not elicited. We also find that the restart has the effect of regenerating a sense of optimism among the subjects, which is reflected in increased contributions subsequently. This increase in contribution is driven mostly by those subjects who started the game with relatively more optimistic beliefs. Our results have implications for sustaining cooperation in social dilemma games.