Pedro gave Barca the lead in the first half and Messi added his second-half brace to see Barca stay top of the league and ensure a happy ending to what had been a stressful day for the Catalan club.
Under Pep Guardiola Barca travel to away games on the day of the match, but the Catalans saw their plans thrown into disarray by an unexpected air controllers' strike.
Barca claimed in a statement on their website that they were originally given permission to play the match on Sunday evening by the Spanish Football Federation (RFEF).
However, with Osasuna reportedly unwilling to change the fixture, the Catalan club were later told by the RFEF that the game would go ahead as originally scheduled, forcing Barca to make hasty road and rail arrangements for the journey to Pamplona.
The squad left Barcelona at 4pm local time, catching the high-speed AVE train to Zaragoza and completing the rest of the trip by coach.
That saw the Catalan party arrive at the Reyno de Navarra stadium only shortly before the scheduled kick-off time, which was then put back by 45 minutes.