They clearly were in league with MX, as they worked on two parts of one of MX' backup plan, and as these failed, pulled out the second backup with the time travel stuff.
It was confirmed that Xemnas had some of Terra's memories, but going by what DDD revealed about Xemnas I tend to more believe that he was just using his "Terra"-memories for his own goals and/or those of MX.
His obsession with finding Ventus can easily be traced back to the X-blade, as Ventus unwillingly already is one of the twenty pieces and as going by Xemnas' words in the final battle of KH2 ("Can you spare a heart?") we probably can assume Xemnas knew that Sora has Ven's heart.