Hansa, who now ply their trade in Germany's third division, were the last winners of the now defunct East German league in the 1990/91 season following the nation's reunification but have since fallen on hard times.
When Hansa kick off against the Bavarian superstars it will be a clash of two teams at the opposite ends of German football's financial spectrum. Having narrowly avoided bankruptcy last season, Rostock badly need the predicted €1m of gate revenue for the visit of Guardiola's Bayern.
Hansa's meager resources are dwarfed by the big-spending Bavarians. Bayern, having already spent €37m for Germany star Mario Gotze, are on the verge of blowing another €18m for Barcelona's Spain Under-21 captain Thiago Alacantara.
Apart from a few other friendlies, the match at Hansa's Ostsee Stadium will be ex-Barcelona coach Guardiola's first real test since taking charge of Bayern who won the treble of European, league and cup titles last season.
"It is long time since a team of this caliber was last here," said Rostock captain Sebastian Pelzer after Hansa were last relegated from the Bundesliga in 2008.
All 28,000 tickets for Sunday's match quickly sold-out when Bayern announced in April, after Guardiola was appointed in January, that they would play a benefit match at Rostock, with all proceeds going to the hosts.
"We are very proud that they are playing virtually their first big game under Guardiola with us," said Hansa's chief executive Michael Dahlmann, with Bayern to open the new Bundesliga season on August 9 against Borussia Moenchengladbach.
"It's also a great thing that our coffers will be filled for us, it means the survival of the club. The proceeds of this game are an important part of our restructuring plan. I am incredibly grateful that such a big club, with such a big heart for small clubs, is coming to us."
The match will be broadcast live in 40 countries and Hansa have been flooded with accreditation requests from media around the globe.
"Such a great stage is a superb chance for the team, we will try to sell ourselves as well as possible," added Dahlmann, after Rostock finished 12th in the third division last season.
While Guardiola brings his European champions fresh from their pre-season training camp on Lake Garda in north Italy, Hansa can expect a much smaller gate for their opening league game at home to Kiel the week after.
"My ambition is to keep them at zero, I hope Pep tired Bayern out," said Hansa goalkeeper Joerg Hahnel with a grin.