Murray, who won just one match on his least favoured surface at Monte Carlo last month, needed two tie-breaks to overcome German Florian Mayer 7-6 (13-11), 7-6 (7-3).
The world No3 also appeared to be in pain, clutching his back on several occasions, but saved five set points in the opener and eventually saw off the unorthodox Mayer, who is ranked just 23 places below him.
Murray, who celebrated his 400th career win, faces Frenchman Gilles Simon next, after he beat compatriot Jeremy Chardy.
Earlier, world No2 Roger Federer marked his comeback from a two-month absence with a straight-sets victory over Radek Stepanek. Top seed Serena Williams progressed to the third round of the women’s draw with a 6-2, 7-5 win over home hope Lourdes Dominguez Lino.