Zenit St Petersburg were indebted to goalkeeper Vyacheslav Malafeev for a series of outstanding saves as they earned the 0-0 draw in Porto that took the Russian side through to the Champions League knockout stages for the first time at the expense of the Portuguese team.
Last season's Europa League winners knew only a win would be good enough to progress and dominated proceedings at Estadio do Dragao. However, Malafeev denied Djalma, James Rodriguez, Kleber and Hulk to leave Porto to defend their Europa League crown.
"We missed goals and more goals," said the Porto coach, Vitor Pereira, who replaced the Chelsea-bound Andre Villas-Boas in the summer. "We leave the Champions League with the feeling of deserving to qualify."
Apoel Nicosia suffered their first defeat of the group stages when they went down 2-0 at home to Shakhtar Donetsk but they still ended up celebrating as the result in Porto sent them through as Group G winners.
Barcelona fielded virtually a reserve team, with the outfield players boasting an average age of just 21, but were still far too powerful for Bate Borisov, winning 4-0 at the Nou Camp.
Teenage midfielder Sergi Roberto opened the scoring against the Belarusian champions in the 35th minute. Full-back Martin Montoya got the second in the 60th minute before Pedro scored the third three minutes later with an audacious flick and then converted a penalty two minutes from time.
"Having this generation of players and being able to depend on them is very valuable," coach Pep Guardiola said of "baby Barça". "The difficult thing for them now will be maintaining this level when they go back to playing at second-division stadiums."