Lancashire 268 and 132 for 3 (Livingstone 51*) need a further 44 to beat Surrey 201 for 8 dec and 242 (Stoneman 98, Livingstone 6-52, Parry 4-59)
Liam Livingstone took six wickets and notched a half-century as Lancashire closed in on victory in their Specsavers County Championship clash with Surrey at Old Trafford.
Lancashire took Surrey's ten wickets for just 88 runs to set up a victory target of 176 after Mark Stoneman had given the visitors an excellent start to the day. It looked as though victory would be completed on day three as Livingstone's fifty took Lancashire to within 44 runs of the win, but bad light intervened to force the game into the final day.
The morning session mirrored day two in as much as a strong start by the batting side was undone by a flurry of wickets before lunch.
Surrey resumed on 79 for 0, with a lead of 12, and Stoneman and Rory Burns went on to share a 150-stand for the opening wicket. Stoneman celebrated his call-up to England's Ashes squad by racing to 98 from 113 balls before his wicket, taken by Livingstone, triggered a collapse by the visitors.
Stephen Parry dismissed the other set batsman Rory Burns for 45 before Livingstone went on to claim career-best bowling figures. He removed Scott Borthwick for 4 and Ben Foakes, another Ashes squad member, for a golden duck with successive deliveries to mean that Surrey had lost four wickets in 12 balls for just six runs.
The flow of wickets just continued before lunch with Olly Pope and Rikki Clarke both joining the list of victims claimed by Livingstone and Sam Curran departing first ball to Parry.
At lunch Surrey were 197 for 7, leading by 130 with Kumar Sangakkara, playing in his last first-class game, still at the crease. He received a guard of honour from Lancashire's players on his arrival and he went on to add 44 for the eighth wicket with Gareth Batty as Surrey attempted to respond to that flurry of wickets.
But the last three then fell in the space of six balls. Livingstone claimed his sixth as Batty chipped one high back to the bowler and Parry proceeded to remove Stuart Meaker and Jade Dernbach - both without scoring.
Surrey had slipped from 154 for 0 to 242 all out, leaving Lancashire that chase of 176. Sangakkara, in his last first-class game, was unbeaten on 35.
Lancashire started their chase well, progressing to 40 without loss when Alex Davies fell for a classy 30. It was Livingstone, though, who continued to dominate the day. He guided Lancashire to tea at 73 for 1 and it looked likely that they could complete the chase with a day to spare.
Rob Jones was dismissed by Batty for 35 with Lancashire exactly halfway to their target and Steven Croft became Clarke's second victim as the hosts threatened a wobble. But Livingstone powered his way to his third half-century of the season to take Lancashire to within sight of their target when bad light stopped play at 16.49pm.
They will return in the morning to attempt to complete the victory that would secure second place in Division One.