It can be complicated. Totem can use various back-ends for dealing with the actual coding/decoding. In Fedora Totem uses the gstreamer backend, as that's part of Gnome, and Totem is a gnome thing. I suspect this is generally how Totem works by default full-stop. So you really need gstreamer codecs for whatever format you're dealing with if you want to use Totem. Mplayer often uses the xine backend, which has many codecs available, so you would want mplayer-xine (that's mplayer built to work with xine as a backend), and then the xine version of the codecs. Something like that anyway.
Other distributions make this much easier and there are many walk-throughs out there, e.g. Fedora and Ubuntu.
Just try googling divx yellowdog and see how other people do it.
You might not need DivX installed at all, xvid might decode divx stuff. I'm not sure.
Best bet is to get onto IRC (irc.freenode.net via xchat), and join #ydl or #yellowdog or something.