The muon spectrometer of the CMS (Compact Muon Solenoid) experiment at the Large Hadron Collider (LHC) is equipped with a redundant system made of Resistive Plate Chambers (RPCs) and Drift Tube (DT) chambers in the barrel, RPC and Cathode Strip Chambers (CSCs) in the endcap region. In this paper, the operations and the performance of the RPC system during the first three years of LHC activity are presented. The stability of the RPC performance, in terms of efficiency, cluster size and noise, is also reported. Finally, the radiation background levels on the RPC system have been measured as a function of the LHC luminosity. Extrapolations to the High Luminosity LHC conditions are also discussed.