So you want to compare them.
Sharingan is a good doujutsu if the user knows how to use it (Itachi).
Rinnegan if there strong shinobi they'll be able to brake the genjutsu but that isn't 100 % sure
It depends,
if the Rinnegan user is really skilled and has a variety of Jutsu, they should be able to break it.
However, if not then Tsukuyomi is very powerful if used by a skilled Genjutsu user.
It all depends.