It usually means to be competitive, but suggests that whatever you're doing is more hassle than it's worth (eg."the nine to five rat race").
It's a reference to the way that rats are used in labs, desperately doing whatever is needed of them to try to get some cheese, but never actually achieving much in the long term.
The rats never seem to understand that what they're doing is pointless, getting the cheese seems to be the most important thing in the world to them, in the same way as getting through the work day seems to be the most important thing in the world to the tube full of commuters every morning.