Bayern had to survive a fightback in Rostock on Friday before the German giants came away with a 2-1 win.