Needing 180 to avoid an innings defeat after following on the previous evening, Somerset quickly lost night-watchman Tim Groenewald.
Tom Abell then gave a return catch to Simon Kerrigan to leave the hosts 61-2.
But Trescothick made 129 in an unbroken stand of 168 with skipper Chris Rogers (75 no) before declaring on 229-2.
The two veteran left-handers have a combined age of 78, but they also have a colossal 133 centuries and over 48,000 first class runs between them.
And they defied everything Lancashire - including 15 overs from England paceman Jimmy Anderson - could throw at them.
Twice in one Anderson over early in the afternoon session, Trescothick enjoyed good fortune when, with no second slip, he edged boundaries between first and third slip.
But, in the end, Lancashire, one of only two teams to win a game in Division One of the County Championship this season, took 11 points from the draw, to climb within three points of leaders Warwickshire.
Somerset, who have drawn all three of their Championship matches, took nine points, while the only winner was the typically flat, dry Taunton track, which did offer turn on the final day, but never gave much assistance to the seamers.
Somerset director of cricket Matthew Maynard:
"We saw some real old-fashioned attritional county cricket, with two very experienced batsman battling against a turning ball.
"Marcus and Chris played so well, but we mustn't forget James Hildreth's century in the first innings. He batted superbly.
"It wasn't an ideal pitch and we hope there will be more pace in the next one we prepare here, but it did make for some fascinating cricket.
"Again we have shown character as a team to pick up our third draw against a very good Lancashire side. Now we have to try and get ahead in a game so we can exert pressure."
Lancashire head coach Ashley Giles told BBC Radio Manchester:
"If we continue to play the way we have in the opening two matches we'll be all right. I have to be happy with the way we have performed.
"We knew First Division cricket would be tough and that has certainly been the case for all four days here.
"The surfaces of the wickets at Taunton don't tend to break up. When we arrived I was expecting us to field first, but it was a used pitch.
"We thought it might spin as the game progressed and there was some turn, but it was always going to be difficult to bowl Somerset out twice."
Marcus Trescothick made his 60th first class century - his second in a week - to steer Somerset to a draw against Lancashire in the County Championship.