copying index to root