Strikes from Robert Lewandowski and Joshua Kimmich helped Bayern Munich to a hard-fought 2-0 Bundesliga win over Schalke at the Veltins Arena on Friday.
The reigning champions were high on confidence heading into the encounter following their 6-0 thumping of Werder Bremen on matchday one, whereas the Gelsenkirchen side lost their opener versus Eintracht Frankfurt 1-0.
Bayern were initially unable to build on that strong display, though, as they were second-best for large parts of the game and Lewandowski missed two big chances to open the scoring when they did prise apart the Schalke defence.
The Poland international made amends for his earlier misses with 10 minutes left on the clock, though, coolly slotting home after a fine throughball from Javi Martinez to break the deadlock, before setting up Kimmich for Bayern's second late on.
Schalke had looked strong until Lewandowski's goal and came close to opening the scoring themselves when Klaas-Jan Huntelaar hit the crossbar with a powerful long-range strike in the second half, but it was all for nothing in the end as Bayern struck late to take home the three points.
Carlo Ancelotti opted to hand new signing Renato Sanches his debut, with the Portugal international taking Arturo Vidal's place in midfield alongside Xabi Alonso, before eventually making way for Kimmich after the interval.
Schalke got the first major chance of the match when Eric Maxim Choupo-Moting reached Leon Goretzka with a fine cross from the left, but the midfielder was unfortunate to see his header hit Bayern defender David Alaba and the opportunity went begging.
Lewandowski should perhaps have opened the scoring for Bayern midway through the first half after some good work from Thomas Muller down the right, only to aim wide from just inside the area.
The home side were the more dangerous in the opening 45 minutes, though, and Huntelaar got another chance to break the deadlock after goalkeeper Manuel Neuer failed to hold on to Yevhen Konoplyanka's cross shortly before the break, with Alaba denying the Dutchman with a last-ditch tackle to block his attempt from the rebound.
Schalke continued to impress after the interval and Huntelaar was once more unfortunate not to score when he hit the crossbar in the 56th minute. The Dutchman took a touch before trying his luck from 25 yards out and Neuer did just enough to push the striker's powerful shot against the woodwork.
Ancelotti opted to bring on Douglas Costa for Franck Ribery at the hour mark and the Brazilian almost made an immediate impact, aiming just too high after being set up by Lewandowski.
The former Borussia Dortmund striker was then guilty of wasting a huge chance to break the deadlock with 15 minutes left on the clock, diverting his shot over the crossbar in front of an open goal after Alaba's sublime cross from the left.
Lewandowski was not to be denied, however, and got his goal in the 81st minute. The striker beat the offside trap after a fine ball from Martinez and beat Ralf Fahrmann from close range to make it 1-0.
The 28-year-old then missed another chance to double Bayern's lead, before he set up Kimmich for the clincher deep into stoppage time, the Germany international finding the net after a quick break to put the match to bed.