Depending on the train you take (and I assume it's stops) it takes anywhere from 3 hrs 40 min to 4 hrs 30 min. It looks like it has to go through Toulouse. [I'm not sure, but it might be faster to drive.]
Take a look at the SNCF website for train schedules:
http://www.sncf.com/en_EN/flash/Rodez is a cool town. I stayed there recently overnight on my way to Villefranche de Rouergue.
We spent some time on another trip in Carcassone and had a wonderful time.