This looks strange to me.  It runs the `yum` command and stores the return value in `cmd` and then passes that back as a new command to run?