Bordeaux qualify by beating Bayern
Yoann Gourcuff opened the scoring after 37 minutes and Marouane Chamakh added a late second to guarantee Bordeaux, with 10 points, a top two finish in Group A.
Juventus are second on eight points after a 1-0 win at Maccabi Haifa, leaving Bayern in third spot on four points and facing an uphill battle to qualify.
"We were solid tonight," Gourcuff told reporters. "We controlled the match after the first goal, though we scored that goal with our first chance of the match."
Gourcuff added that last year's early exit at the group stage had taught the team a lesson. "We learned from that experience. We matured," he said.
Bayern, with Luca Toni partnering Miroslav Klose up front instead of Mario Gomez, missed several good chances and hit the woodwork after just three minutes when Edson Braafheid's cross was palmed on to the bar by Bordeaux keeper Cedric Carrasso.
The Dutch defender then tried his luck from the other wing, curling a 20-metre left-footed free-kick just over.
Bayern, now with only one win in their four group matches, were spectacularly denied again by Carrasso in the 32nd when he punched away Bastian Schweinsteiger's free-kick.
In a subsequent goalmouth scramble, Michael Ciani cleared a Klose shot off the line, although television replays showed the Bordeaux player had touched the ball with his hand. GOURCUFF GOAL
But it was the visitors who broke the deadlock against the run of play when Brazilian Wendel sailed a free-kick high into the box and Gourcuff slipped past Mark van Bommel to head in.
Bayern coach Louis van Gaal brought on winger Arjen Robben in the second half and the Dutchman immediately added some pace to their game.
Toni squandered their best chance seconds after the restart when he shook off Ciani but fired over from 12 metres before Robben's left-footed drive flew just wide on the hour.
The hosts grew impatient, worn down by a double defensive line, and began giving away possession in midfield. Chamakh took full advantage of weak defending by Holger Badstuber to sprint clear and fire in Bordeaux's second goal in the final minute.
"In a top game you have to score and we did not have any luck tonight," van Gaal told reporters.
"We were not lucky but also not good enough but we are still not eliminated. We still have a small chance," he said.