Sayyiduna Ibn Abbas (may Allah be pleased with them both) narrates: I do not like to pray inside the Ka'bah; whoever prays in it leaves some part of it (the Ka'bah) behind him. However, my brother (al-Fadl, may Allah be pleased with him) told me that when the Messenger of Allah (peace and blessings be upon him) entered the Ka'bah, he fell into prostration between the two pillars, then he sat down, and he did not pray.
Hadith Referenceالمعجم الكبير للطبراني / باب الفاء / 15770