Defending champions Spain were knocked out of the Davis Cup finals as the Russian Tennis Federation made the quarter-finals, along with Serbia.
The final tie of the round-robin stage went down to the doubles with Marcel Granollers and Feliciano Lopez needing to win to send Spain through at Serbia's expense.
However, Aslan Karatsev and Andrey Rublev battled back to secure a 4-6 6-2 6-4 victory and ensure Russia finished top of Group A.
Australian Open order of play: Day 6 - Evans looks to keep GB flag flying, Medvedev v crowd?
Novak Djokovic’s Serbia take one of the two best runners-ups spots along with Sweden.
The draw for the quarter-finals is: Russian Tennis Federation vs Sweden, Great Britain vs Germany, Italy vs Croatia, Kazakhstan vs Serbia.
The first tie between Italy and Croatia takes place on November 29, with Great Britain playing Germany on November 30. The final is on December 5.
Spain sent their tie against the Russian Tennis Federation to the deciding doubles after 40-year-old Feliciano Lopez pulled off a memorable 2-6 6-3 6-4 win over world No 5 Rublev.
US Open champion Daniil Medvedev beat Pablo Carreno Busta in straight sets in the second singles match, before watching on as Karatsev and Rublev completed a tense victory.
“We were very close but it was not enough," said Lopez.
It is what it is and I don't want to give excuses. We showed everyone that we are ready to compete in any conditions, even with so many issues that we went through. It's so disappointing.
Colombia's 2-1 victory over the United States in Turin was not enough to see them through as they finished second behind Italy in Group E.
Stream the 2021 Davis Cup finals and the 2022 Australian Open live and on demand on discovery+
'This will hit him hard, he worked so hard to be loved' - McEnroe on Djokovic saga
'Will hurt him for a long time' – Djokovic's coach fumes at 'unjust' deportation