A late equaliser by Barnsley's Iain Hume condemned Peterborough to relegation to League One in boss Jim Gannon's final game in charge.
With Gary Johnson set to take over as manager on Tuesday, Posh went in front early through Ryan Bennett.
Hume quickly levelled and Jon Macken then forced an excellent save from Peterborough keeper James McKeown.
Barnsley continued to press but Tommy Rowe rifled home Peterborough's second, only for Hume to seal their fate.
With a run of five successive defeats behind them, there was little reason for optimism in the visitors' dressing room before the game.
But with Barnsley's top scorer Daniel Bogdanovic again unavailable because of injury, there was a glimmer of hope that they could produce a result which might enable them to extend their relegation battle until after the weekend.
And spirits were further lifted when Bennett, back in the team after nine games on the sidelines because of an ankle problem, turned smartly to fire into the corner after Dominic Green had played a free-kick into the box.
The lead did not last long as Hume was given too much time and space by the Peterborough defence and found the net via the left-hand upright.
Barnsley had the better of things either side of the break but substitute Craig Mackail-Smith brought the best out of home keeper Luke Steele before Rowe restored Peterborough's lead with a low drive.
With time running out, Barnsley boss Mark Robins made three substitutions, bringing on striker Andy Gray, along with midfielders Anderson de Silva and Nathan Doyle.
But it was Hume who saved the mid-table home side from an eighth home defeat of the season as he ran onto a knockdown in the 84th minute, rounded McKeown and slotted into the empty net.
Departing Peterborough boss Jim Gannon told BBC Radio Cambridgeshire: "You have a multitude of emotions in a situation like this and I feel a little bit guilty for not finishing the job.
"I just hope I've added something to the club and got people talking about our football again.
"There's a great squad here, but it's important the club gears itself mentally and physically for next season.
"They have every chance of being at the top of League One with Gary Johnson and the chairman's (Darragh MacAnthony) continued support."
Barnsley manager Mark Robins: "We huffed and puffed, we created one or two chances and it was a great performance from (Luke) Steele at one end, and a good goal scoring performance from Hume at the other.
"We've got balls into the box, we created chances, but still the overriding emotion is one of relief - which isn't a great one - and knowing that we looked leggy."
Live text and stats
Monday, 5 April 2010
(HT 1-1)Peterborough are relegated
19 Butterfield (Doyle 80)
22 Potter yellow card
11 Devaney (De Silva 81)
21 Macken (Gray 81)
15 De Silva,
23 El Haimour,
02 Gilbert (Reid 16)
29 Bennett (Romone McCrae 46)
34 Geohaghan yellow card
26 Mills (Mackail-Smith 61)
27 Romone McCrae,
Ref: BatesAtt: 11,290
Attempts on target
Attempts off target
90:00+4:14 The match has reached full-time.
90:00+2:45 Craig Mackail-Smith takes a shot. Save by Luke Steele. Inswinging corner taken left-footed by Dominic Green from the right
by-line, Shot on goal by Reuben Reid from inside the box goes harmlessly over the target.
90:00+2:02 The official flags Hugo Colace offside. Indirect free kick taken by James McKeown.
90:00+1:33 Shot by Craig Mackail-Smith. Save by Luke Steele.
90:00+1:02 Long range shot from Anderson De Silva misses to the left of the target.
89:54 Nathan Doyle concedes a free kick for a foul on Reuben Reid. James McKeown takes the direct free kick.
89:19 Free kick awarded for a foul by Exodus Geohaghon on Andy Gray. Free kick crossed by Nathan Doyle, Reuben Reid makes a clearance.
88:16 Inswinging corner taken left-footed by Dominic Green, clearance made by Andy Gray. Lee Frecklington has an effort at goal
from just outside the penalty box which goes wide of the left-hand post.
87:28 Shot from deep inside the area by Reuben Reid goes over the bar.
86:07 Dominic Green takes the outswinging corner, save by Luke Steele.
85:41 Free kick awarded for a foul by Hugo Colace on Craig Mackail-Smith. Direct free kick taken by Tommy Rowe.
83:59 Assist on the goal came from Andy Gray.
83:59 GOAL - Iain Hume:Barnsley 2 - 2 Peterborough Goal scored by Iain Hume from close in to the bottom left corner of the goal. Barnsley 2-2 Peterborough.
82:21 Free kick awarded for an unfair challenge on Bobby Hassell by Craig Mackail-Smith. Direct free kick taken by Luke Steele.
81:41 Unfair challenge on Reuben Reid by Anderson De Silva results in a free kick. James McKeown takes the direct free kick.
79:54 Substitution Anderson De Silva comes on in place of Martin Devaney.
79:54 Substitution Jonathan Macken leaves the field to be replaced by Andy Gray.
79:54 Substitution Nathan Doyle is brought on as a substitute for Jacob Butterfield.
79:30 Reuben Reid takes a shot. Save by Luke Steele.
79:13 Jonathan Macken produces a cross, clearance made by Romone McCrae.
78:38 Sergio Torres has an effort at goal. Save by Luke Steele.
76:09 The assist for the goal came from Lee Frecklington.
76:09 GOAL - Tommy Rowe:Barnsley 1 - 2 Peterborough A goal is scored by Tommy Rowe from just outside the area to the bottom left corner of the goal. Barnsley 1-2 Peterborough.
75:46 Craig Mackail-Smith takes a shot. Save by Luke Steele.
73:57 Craig Mackail-Smith takes a shot. Save by Luke Steele. Outswinging corner taken from the left by-line by Dominic Green, Header
from deep inside the area by Gabriel Zakuani goes over the bar.
73:37 Craig Mackail-Smith takes a shot. Save by Luke Steele.
72:54 Adam Hammill has a curled shot. Save by James McKeown.
72:36 A cross is delivered by Adam Hammill, clearance made by Gabriel Zakuani.
71:30 Shot by Hugo Colace from 25 yards. Blocked by Gabriel Zakuani.
70:39 Outswinging corner taken right-footed by Iain Hume, clearance by Sergio Torres. Outswinging corner taken right-footed by Iain
Hume from the right by-line.
68:53 Reuben Reid takes a shot. Save made by Luke Steele.
67:32 Luke Potter concedes a free kick for a foul on Tommy Rowe. Exodus Geohaghon takes the free kick.
66:25 Adam Hammill concedes a free kick for a foul on Lee Frecklington. James McKeown takes the direct free kick.
66:03 The offside flag is raised against Craig Mackail-Smith. Stephen Foster takes the free kick.
64:59 Booking The referee shows Luke Potter a yellow card for unsporting behaviour.
64:36 The ball is swung over by Sergio Torres, Stephen Foster makes a clearance.
61:51 Effort from deep inside the area by Jonathan Macken bounces off the post. Effort from the edge of the penalty area by Adam
Hammill goes wide of the left-hand post.
61:28 The referee gives a free kick against Tommy Rowe for handball. Stephen Foster takes the direct free kick.
60:38 Substitution Danny Mills goes off and Craig Mackail-Smith comes on.
59:03 Reuben Reid challenges Darren Moore unfairly and gives away a free kick. Direct effort from the free kick comes in from Iain
58:00 The ball is delivered by Adam Hammill, clearance by Scott Griffiths. Outswinging corner taken by Iain Hume, Stephen Foster
takes a shot. Save by James McKeown.
57:16 Free kick awarded for a foul by Luke Potter on Danny Mills. Lee Frecklington takes the free kick.
56:30 Effort on goal by Luke Potter from outside the area goes harmlessly over the bar.
55:28 Jacob Butterfield fouled by Reuben Reid, the ref awards a free kick. Free kick crossed by Jacob Butterfield, Tommy Rowe makes
51:44 Lee Frecklington produces a drilled right-footed shot from 35 yards that went over the crossbar.
49:45 Free kick awarded for a foul by Stephen Foster on Dominic Green. Lee Frecklington takes the free kick. Lee Frecklington has
a drilled shot. Save by Luke Steele.
47:30 Iain Hume is ruled offside. Indirect free kick taken by James McKeown.
47:15 The ball is delivered by Luke Potter, Gabriel Zakuani manages to make a clearance.
46:46 A cross is delivered by Scott Griffiths, save by Luke Steele.
45:54 The ball is delivered by Bobby Hassell, clearance made by Romone McCrae.
45:01 The referee gets the second half underway.
45:01 Substitution Romone McCrae on for Ryan Bennett.
45:00+2:03 The ref blows to signal half-time.
44:58 Foul by Reuben Reid on Luke Potter, free kick awarded. Jacob Butterfield restarts play with the free kick.
44:43 Sergio Torres has an effort at goal from 20 yards. Blocked by Stephen Foster.
39:46 Adam Hammill crosses the ball, Jonathan Macken takes a shot. James McKeown makes a save.
39:24 Booking Exodus Geohaghon booked for unsporting behaviour.
38:30 A cross is delivered by Adam Hammill, clearance by Gabriel Zakuani.
37:51 The official flags Iain Hume offside. Exodus Geohaghon restarts play with the free kick.
36:18 The ball is delivered by Martin Devaney, Jonathan Macken produces a volleyed right-footed shot from deep inside the penalty
box which goes wide of the left-hand upright.
35:21 The ball is crossed by Adam Hammill, clearance by Tommy Rowe. Outswinging corner taken right-footed by Iain Hume from the
right by-line, Exodus Geohaghon manages to make a clearance.
33:58 Free kick awarded for an unfair challenge on Jacob Butterfield by Lee Frecklington. Jacob Butterfield takes the free kick.
32:11 The ball is crossed by Martin Devaney, save by James McKeown.
31:08 Reuben Reid fouled by Luke Potter, the ref awards a free kick. Free kick crossed left-footed by Dominic Green from right wing,
Stephen Foster makes a clearance.
30:51 Jacob Butterfield has a drilled shot. James McKeown makes a save.
28:50 Jacob Butterfield gives away a free kick for an unfair challenge on Tommy Rowe. Direct free kick taken by Exodus Geohaghon.
27:40 Inswinging corner taken right-footed by Iain Hume from the left by-line, Effort from inside the area by Luke Potter misses
to the right of the target.
26:49 Foul by Jacob Butterfield on Sergio Torres, free kick awarded. Free kick taken by Sergio Torres.
26:02 The ball is crossed by Martin Devaney, clearance made by Sergio Torres. Adam Hammill takes a shot. Save by James McKeown.
24:59 The ball is delivered by Ryan Bennett.
17:06 Adam Hammill concedes a free kick for a foul on Reuben Reid. Dominic Green crosses the ball in from the free kick, Bobby Hassell
makes a clearance.
16:15 Outswinging corner taken from the right by-line by Lee Frecklington.
15:16 Free kick taken by James McKeown.
15:16 Substitution Reuben Reid is brought on as a substitute for Kerrea Gilbert.
15:16 Stephen Foster concedes a free kick for a foul on Sergio Torres.
14:28 Free kick awarded for a foul by Danny Mills on Stephen Foster. Free kick taken by Jacob Butterfield.
12:25 Sergio Torres gives away a free kick for an unfair challenge on Adam Hammill. Jacob Butterfield delivers the ball from the
free kick left-footed from left channel, clearance made by Gabriel Zakuani.
8:54 Dominic Green produces a cross, save made by Luke Steele.
8:22 Jonathan Macken is flagged offside by the assistant referee. Free kick taken by James McKeown.
6:13 Martin Devaney provided the assist for the goal.
6:13 GOAL - Iain Hume:Barnsley 1 - 1 Peterborough Iain Hume fires in a goal from inside the area to the bottom left corner of the goal. Barnsley 1-1 Peterborough.
4:31 GOAL - Ryan Bennett:Barnsley 0 - 1 Peterborough Ryan Bennett scores a goal from deep inside the penalty area to the bottom right corner of the goal. Barnsley 0-1 Peterborough.
4:03 Free kick awarded for a foul by Bobby Hassell on Scott Griffiths. The ball is crossed by Dominic Green,
3:22 Shot from 25 yards from Jacob Butterfield. Save made by James McKeown.
2:59 Jonathan Macken has an effort at goal. James McKeown makes a comfortable save.
2:26 The ball is crossed by Dominic Green, Header by Tommy Rowe from deep inside the penalty area misses to the left of the goal.
0:00 The game gets underway.
Live text and data provided by The Press Association.
This page is best viewed in an up-to-date web browser with style sheets (CSS) enabled. While you will be able to view the content of this page in your current browser, you will not be able to get the full visual experience. Please consider upgrading your browser software or enabling style sheets (CSS) if you are able to do so.