Pages

Monday, 16 July 2012

Restart Linux Mint sound without reboot machine

Sometimes the sound in Linux Mint (I used 11 Katya) seems crashed, especially if you often use hibernate mode, then you can't play sound, music or Youtube video... The simplest solution, of course, is reboot your machine, but it's really annoying, after do some searches, I've found a better way to restart sound system.

Refer to this page http://superuser.com/questions/17312/restart-ubuntu-sound-processes-via-command-line

The solution for Mint is almost the same, first find which process is holding PCM:
 lsof | grep pcm 

The result is something like:
 chrome   3145     admin mem    REG    8,8  22076    5892 /usr/lib/alsa-lib/libasound_module_pcm_pulse.so 
 plugin-co 7171     admin mem    REG    8,8  22076    5892 /usr/lib/alsa-lib/libasound_module_pcm_pulse.so 
 pulseaudi 12954     admin mem    CHR   116,3        2394 /dev/snd/pcmC0D0p 
 pulseaudi 12954     admin  29u   CHR   116,3   0t0    2394 /dev/snd/pcmC0D0p 

Then kill the appropriate process with:
 kill -9 12954 

Restart the sound:
 sudo service alsa-store start