And then substitute Mark Burchill (right) added a late penalty for the home side before Shrimpers skipper Jim Bentley volleyed in a spectacular consolation in injury time.
Rotherham, playing only for pride, had the better of the early opportunities and might have gone ahead as early as the sixth minute when a cross from Dale Tonge aimed for Ryan Taylor was scrambled away.
Taylor's corner produced an opportunity for Danny Harrison, but his low shot was blocked and another effort from Reuben Reid was well saved by keeper Barry Roche.
Roche was in action again to push over a goalbound header from Taylor and Pablo Mills was a fraction away from connecting with a telling corner from Ryan Taylor.
Morecambe had a breakaway that might have earned them a goal when Mark Duffy produced a swift run and Garry Hunter was halted by Marc Joseph.
Seconds before the break ,Rotherham finally produced a goal with a stylish finish. Ian Sharps found Tonge and his cross was headed in superbly by Ryan Taylor.
Nick Fenton hit the Morecambe bar with a header early in the second half but then Morecambe levelled. A great ball from Rene Howe found O'Carroll and he angled a splendid shot past Andy Warrington.
Ten minutes from the end Rotherham's lead was restored when Jamie Green crossed from the left. Ryan Taylor controlled and substitute Jason Taylor rifled in an excellent shot.
Rotherham sub Burchill added the third from the penalty spot when Morecambe skipper Bentley handled in the area.
Bentley made amends when he crashed in an unstoppable volley in injury time, but it proved to be a mere consolation for the visitors.