Number of things going on here.
First off it could be the dwarves have been drinking too much rum and will now not touch the stuff for a long time.
Second the barrels could be forbidden, meaning the dwarves are unable to drink from it.
The barrels could also be in a location where the dwarves can't path to, check you haven't locked doors or anything.
The problem could be that you have too few barrels, but this seems unlikely. You'd need a very large population and a very small amount of barrels for this to become a problem at all.
Check to see if you're dwarves are set to a burrow, they will only path to water/food if they're about to die. I've had military dwarves die from thirst from long patrols or fighting, that could be the problem.
As far as i know, animals can't die of thirst. Ever. So it's likely they died from a lack of food (if they're grazers, no other animal will starve)
Dwarves will not use mugs, they serve only as a trade good. Dwarves _should_ still drink from contented water if they have to, getting bad thoughts. Might seem like a stupid question, but did you check to see if the water wasn't ice? The water can also dry up to become "a murky pool" in very hot climates, meaning there is no water to collect.
A long shot: I believe there was an animal that could be slain in 40D which meat was "a bit spicy" or the like. It would make dwarves thirsty. I think it was a fireimp or something like that.