Jon Taylor opened the scoring and Kyle Vassell added a brace before half-time, his second a superb 25-yard strike.
Ansumave pulled one back for Freamunde after Gabby Zakuani's mistake before Posh restored their three-goal lead through Britt Assombalonga's penalty.
Freamunde won a spot-kick of their own following Jack Baldwin's foul and Pedrinho converted to make it 4-2.
At the other end, Darren Ferguson had trialist Aiden Grant in goal and he made a couple of comfortable saves early on.
The match ended on a sour note when Joe Newell's challenge brought a reaction from both sets of players. The Portuguese player was carried off on a stretcher and taken to a nearby hospital as the referee blew the final whistle.