Note to self:
If the sound stops working in Ubuntu, try running alsamixer. If it gets a permission denied error, run
sudo chmod a+rw /dev/snd/*
The ESD/ALSA chooser is in Preferences/Multimedia Systems Selector.
Update: found a better solution - adding my user to the 'audio' group, where it should have been in the first place.