A hard-hitting 69 by veteran wicketkeeper-batsman James Foster put Essex in control of their Specsavers County Championship game against Lancashire and in line for their first win of the season.

Foster hammered 10 boundaries from 125 balls and shared an eight-wicket, final-session partnership of 103 in 25 overs with Simon Harmer (49) to demoralise Lancashire, who had still fancied their chances when the pair came together at 208 for seven just after tea.

Instead, Foster built on the foundations provided principally by Tom Westley’s 49 – as well as valuable contributions by Varun Chopra (32), Ravi Bopara (26) and Ryan ten Doeschate (25) – to extend Essex’s six-run advantage on first innings to set Lancashire 320 to win with two days to go.

Overnight rain is likely to foreshorten play on the third day, but the reigning champions are set to make up ground on the leaders after losing all four days of their opening game at Headingley to an unfit outfield. And all this after Essex were skittled for 150 in the first innings.

Lancashire lasted just nine balls at the start of the day in losing their two remaining wickets. Jamie Porter and Harmer split the 10 wickets equally, Porter removing Graham Onions’s middle-stump with his third ball of the day. Jordan Clark then wafted hazily at Harmer and was bowled for 25.

Porter’s five for 26 was his eighth career five-wicket haul; Harmer’s five for 46 was his fifth since he joined Essex last year. At the lunch interval, the South African’s impact in Essex’s title success last season was rewarded when – along with prodigal son Chopra – he was presented with his county cap.

Second time round, Essex rattled along at a fair lick throughout. The openers Nick Browne and Chopra put on 48 in 10 overs, which compared favourably with the more pedestrian overall three-an-over of the difficult first day. Chopra was particularly savage on anything wayward, thrashing seven fours in his 32 at just under a run a ball.

However, after a particularly pleasing wristy cut to the boundary off Graham Onions, he had his off-stump sent cartwheeling by the former Durham pace bowler.

Browne followed, albeit reluctantly, after scoring 17 from 41 balls. The left-hander stood his ground as the Lancashire fielders rushed to congratulate Dane Vilas for a tumbling, low catch in the gully off Joe Mennie. It was only when umpire Bainton conferred with Rob Bailey at square leg that Browne was sent on his way.

Dan Lawrence was similarly unhappy with his dismissal and hung around as Bainton again sought advice after Liam Livingstone took a catch falling forward at second slip to give Mennie his second wicket.

That brought together Westley and Bopara for the highest partnership thus far in a low-scoring match with a fourth-wicket stand of 57 in 17 overs either side of lunch. Bopara became increasingly fluent after a hesitant start before getting a thick edge to Tom Bailey and giving Liam Livingstone further catching practice at second slip for 26.

Westley batted serenely for 119 balls, caressing half-a-dozen boundaries, in reaching 49. But he was undone by a loopier delivery from spinner Matt Parkinson and spooned to Keaton Jennings at short cover.

Ten Doeschate pulled Parkinson for six during a 40-ball 25, but fell to a delivery from Onions that kept low and trapped him lbw. Paul Walter departed straight after tea for 14 when he became Mennie’s third victim of the innings, pushing forward and edging behind.

Foster went on the rampage after the break as boundary followed boundary, all around the wicket. One beat Parkinson’s dive at cow corner, two in row raced to third man, another was clubbed through the covers and there was even a cheeky reverse sweep off Livingstone.

He was slightly fortunate with the scampered single that took him to 50, just beating home Onions’s direct hit from mid-on. It had taken him 80 balls. Soon after the fifty-run eighth-wicket stand with an equally hard-hitting Harmer was passed.

Harmer was retrieved on 44, with the partnership worth 93, when the usually reliable Livingstone spilled a chance in the slips off Onions. Harmer survived, brought up the 100 partnership and then nicked Onions to wicketkeeper Alex Davies when one short of his fifty. He had batted for 81 balls and hit five fours.

Peter Siddle lasted just two balls, going lbw to Bailey, and the same bowler celebrated his 27th birthday with a third wicket in the innings when Foster fell lbw shortly before the scheduled close.