Well the 9 tailspower is from the sealed Kinkaku / Ginkaku combo, who obtained some of his power after beeing for about 2 weeks inside him. And the 8 tails i guess came from the tentacle of the 8 tails
And didn´t Madara / Obito have to get Jinchuriki of the Juubi first to get the power to perform infinite tsukuyomi ??