Magilton felt the wrath of unhappy fans during Saturday's lacklustre home draw with Crystal Palace, but his side bounced back against a Barnsley side who did far better than the scoreline suggests.
Town's ex-England goalkeeper Richard Wright made a string of fine saves to deny the visitors, while his opposite number Heinz Muller gifted Ipswich two goals.
The German sent a clearance straight to Jon Stead for the first and he allowed a speculative Ivan Campo shot through his hands for the third either side of an Owen Garvan strike.
Barnsley had begun well, with Wright making a good diving save to deny the lively Diego Leon before blocking Dennis Souza's header from the ensuing corner at point blank range.
Wright also beat away a fierce Iain Hume shot before Muller's howler handed Stead his third goal of the season on 20 minutes.
In an end-to-end half, Muller made good saves to deny Alan Quinn and Campo, but Wright made the half's best save, superbly palming away a Souza downward header destined for the corner.
Barnsley tried to hit back in the second half with ex-Town loanee Jon Macken twice being narrowly off target.
Town doubled their lead on 66 minutes with a quick break which ended with Pablo Counago's pass to Garvan which the Irish midfielder stroked home.
Muller's second clanger provided Campo with his first Town goal to seal the points three minutes later as he allowed his 30-yard shot to bobble into the net.
A bit of history was made on 84 minutes when Barnsley sent on substitute Reuben Noble-Lazarus, believed to be the youngest ever Football League player aged just 15 years and 45 days.