Enable 5.1 Surround Sound on Linux – Ubuntu 8.04 Hardy

February 14, 2009 | By: UbuntuLinuxHelp | 24 Comments
Posted in How to...

1 Star2 Stars3 Stars4 Stars5 Stars (4 votes, average: 5.00 out of 5)
Loading ... Loading ...

Unfortunately, I recently had to convert my last Windows box to Linux. I used the Windows (WinXP Pro) based box primarily for graphic editing and video creation. However, I got to the stage where I just could not turn it on anymore as it kept displaying the Blue Screen of Death (BSOD) every time I tried to boot. Fortunately I had backups of all my data, so data loss was not an issue. It was interesting to note that the MFT was corrupt and so was its mirror.

Initially, I decided to move up to Ubuntu 8.10 - But, the networking does not work. The network cards were detected and installed, DHCP even leased an IP address to the active card (which I could see in the router status), but alas, networking did not work. So, I simply went back to Hardy 8.04.

Some time ago I wrote a post about the Simple Way to Get 5.1 Surround Sound Audio Working in Ubuntu, and at that time it worked.  However, much to my annoyance, I could not get surround sound to work. I edited the asoundrc file, but that did not work. After much reading (hours of searching), I found an obscure post somewhere (I wish I bookmarked it) that said Ubuntu Linux 8.04 uses PulseAudio for sound mixing (not Alsa and so on). While I did have audio in the front left and right speakers, that indicated 2 channels were operating, so maybe surround sound is not working as there is no configuration for 6 channel enabled?

I noticed that speaker volume icon on my task bar had a red warning on it and checked it out. It said "Surround: muted" - Right clicking and unmuting did not fix the issue. More web searching revealed that I might be able to fix this by editing how PulseAudio is configured. I played with it and the fix worked! Here's what to try if your surround (5.1) does not work in Ubuntu Linux 8.04:

Go to /etc/pulse and make a backup of daemon.conf first, then find this line (as sudo):

; default-sample-channels = 2

And change it to this:

default-sample-channels = 6

Now you'll need to  restart your system (that way the new change you just made will take effect).

After you reboot, test your sound using:

speaker-test -Dplug:surround51 -c6 -l1 -twav

If you don't hear audio properly, some of the channels might be muted. To change that, right click on the speaker volume icon in your task bar and select "Open Volume Control". In the new window that pops up, select Edit" and then "Preferences". Make sure that the following tracks are enabled (visible) - as this is what worked for me:

  • PCM Center
  • PCM Front
  • PCM  LFE
  • PCM Side
  • PCM  Surround

If that does not work, try the same selecting the visible tracks, but without "PCM". Now look at all the selected channel tracks, if any of them have a muted icon underneath, then unmute the icon for each. I should add that again, these changes did not work until I rebooted my system. After the reboot surround sound worked when I inserted and played a video DVD - The movie sounds worked on all surround channels.

Before I forget, this was for an Audigy2 ZS sound card using Creative 5.1 surround speakers. Oh... and one more parting thought (took me a while to realize the problem) - Make sure your media player is configured (usually in the preferences) to use 5.1 surround sound audio (that was the last issue that caught me until I found it).

For the Windows  fans, I still run Windows, but I use VirtualBox, so that it runs in a virtual machine - that way I don't have to worry about a downed system anymore.  ;)

I really hope this post helps some of you and save hours of forum surfing and web searching - Please let me know! :)

If you like this post, why not share it?
  • StumbleUpon
  • del.icio.us
  • Digg
  • Google Bookmarks
  • Reddit
  • Mixx
  • Yahoo! Bookmarks
  • blogmarks
  • Twitter

Related posts:

  1. The Simple Way to Get 5.1 Surround Sound Audio Working in Ubuntu
  2. Build a Web Developer PC and Enable Most Media Playback Using Ubuntu Linux
  3. Installing an Ubuntu Linux Hardy 8.04 LAMP and FFMpeg Server With a GUI – Hardware Installation.
  4. 10 Things to do After Installing Ubuntu Linux
  5. Installing an Ubuntu Linux Hardy 8.04 LAMP and FFMpeg Server With a GUI – Introduction.


Comments

24 Comments so far

  1. Jean Schoeters Jean Schoeters on February 16, 2009 4:03 pm

    You made my day! For the first time I am able to hear my rear speakers.
    I use a SB Live with a 4.1 speaker system. I changed the line to “default-sample-channels = 4″, rebooted, and my rears were working for the first time. I control the rears via the “Surround” slider and I linked it with the main volume slider by going to “System>Preferences>Sound” so my volume buttons on the keyboard control both.
    Thanks for posting this.

  2. UbuntuLinuxHelp UbuntuLinuxHelp on February 16, 2009 4:15 pm

    @Jean Schoeters – Thanks! I’m glad that this helped you. It’s nice when some of my time can also help others. (I just hope this is not changed in the next release).
    Merci et bonne journée!

  3. Matias Sanguinetti Matias Sanguinetti on February 18, 2009 11:32 pm

    Thanks! Excellent guide, made my home theater work in seconds

  4. ranger_cole ranger_cole on March 1, 2009 3:27 pm

    How do you edit the .conf file? It says you need permission.

  5. UbuntuLinuxHelp UbuntuLinuxHelp on March 2, 2009 7:49 am

    @ranger_cole – Try this command in a terminal (but MAKE SURE you backup a copy of your daemon.conf file BEFORE editing it):

    sudo gedit /etc/pulse/daemon.conf

    You were getting that “permissions” issue because you need to edit the file as root. When you issue the above command in a terminal, it will ask you for the password. Use the same password here, that you use to log into your Ubuntu Linux operating system.

  6. ranger_cole ranger_cole on March 4, 2009 6:37 am

    I did the editing but I did not get 5.1 sound. I am using Creative X-Fi soundcard.

  7. UbuntuLinuxHelp UbuntuLinuxHelp on March 4, 2009 8:14 am

    @ranger_cole – It’s hard to get any idea from here, without seeing the system. Maybe your sound mixer is not using PulseAudio? Maybe it’s Alsa or something else? Maybe it’s even a driver issue? I did read somewhere that the card was not supported because Creative didn’t release the new data sheets? (That’s one reason why I avoided that card – No support). It might be that there is a proprietary driver available?

    Taking a quick look now…

    Try here for a driver: http://connect.creativelabs.co.....pport.aspx
    Look here: http://www.phoronix.com/scan.p.....#038;num=1
    More reference here: http://ubuntuforums.org/showth.....p?t=571656

    Please let us know what finally happens! :)
    Thanks!

  8. ajs ajs on April 28, 2009 9:59 pm

    thanks..a clear, concise howto that worked perfectly..wish all ma linux problems where this easy to solve..

  9. Gianfranco Málaga T. Gianfranco Málaga T. on April 30, 2009 1:48 am

    Thank you very much. Muchas gracias, fuciona muy bien. Al fin puedo disfrutar del sound round con Ubuntu.

  10. UbuntuLinuxHelp UbuntuLinuxHelp on April 30, 2009 7:13 am

    @Gianfranco Málaga T. – Gracias. Es agradable de leer, cuando esta ayuda a las personas. Espero que este trabajo aún para el nuevo Ubuntu 9.04 :) – Thanks. It is nice to read when this helps people. I hope this will still work for the new Ubuntu 9.04

    (Lo siento, mi español es malo)

  11. Gianfranco Málaga T. Gianfranco Málaga T. on April 30, 2009 10:14 pm

    Thanks to you. Tu español es mejor que mi inglés. I am working with Ubuntu 9.04 (64 bits) and listening the music from six speakers. Don’t forget, check all the channels for PulseAudio and ALSA mixer. Hay que verificar el control de volumen para PulseAudio y ALSA mixer. Disfruto más las películas con el sonido en los seis parlantes.

    I have a sound card. It’s a Creative Audigy SE (ca0106).

    Ahora estoy peleando con el TVTime. El volumen no sube de 0.

  12. Top 10 Linux Video Applications - NOT! | Ubuntu Linux Help Top 10 Linux Video Applications - NOT! | Ubuntu Linux Help on May 21, 2009 10:17 am

    [...] Enable 5.1 Surround Sound on Linux – Ubuntu 8.04 Hardy (5.00 out of 5) [...]

  13. Big Trev :: Enabling 5.1 sound Big Trev :: Enabling 5.1 sound on June 14, 2009 5:48 am

    [...] I’m struggling to get 5.1 sound in Ubuntu, so I’ve found this site: http://ubuntulinuxhelp.com/ena.....804-hardy/ [...]

  14. vancleef vancleef on July 1, 2009 10:53 pm

    1. not working for me…… and i just hear the people speak Front Left and Front Right Only…..

    2.
    * PCM Center
    * PCM Front
    * PCM LFE
    * PCM Side
    * PCM Surround

    i’m not found it….

  15. UbuntuLinuxHelp UbuntuLinuxHelp on July 2, 2009 6:57 am

    @vancleef

    • Did you try selecting the corresponding tracks without PCM?
    • Are you using PulseAudio?
    • Did you also configure your media player to use 5.1 surround sound?
    • Did you check the hardware itself? (Cards and cable).

    If so, the issue may be how the speakers are plugged in. (I had to change where they were plugged in a couple of times).

  16. Lupu Lupu on August 2, 2009 10:44 am

    same problem like vancleef…. i used sudo gedit /etc/pulse/daemon.conf and ai changed ” ; default-sample-channels = 2″ with “; default-sample-channels = 6″ but still only front chanel…
    * PCM Center
    * PCM Front
    * PCM LFE
    * PCM Side
    * PCM Surround

    not foud it…. any other solution to use all my 5+1 Chanels???

    Read more from Lupu

    Bancul zilei

    Trece Scufita Rosie prin padure si se intalneste cu lupul care-i spune:
    - Scufito, tu ai o broscuta, eu am o cheita. Hai sa-ti deschid broscuta cu cheita mea.
    De acord.
    Mai tarziu Scufita Rosie se duc[...]

  17. Ceolwulf Ceolwulf on August 18, 2009 3:34 pm

    Thanks very much for your advice. Have now got my surround sound working in linux

  18. Heron Anzures Heron Anzures on September 13, 2009 7:57 pm

    Thank you very much, after hours of trying stuff, this did the trick

  19. Otome Otome on September 18, 2009 11:38 pm

    you don’t need to restart the computer. I enable “disable-lfe-remixing = no”

  20. X X on April 20, 2010 10:36 pm

    Amazing! Thanks for the effort man, it worked like a charm!

    Just have to add WAVE Front, Center and LFE on my pc.

  21. Sarim Khan Sarim Khan on May 14, 2010 10:33 am

    I found this way in many site by google. but this is not working in my INTEL DG 31 PR motherboard’s internel REALTEC sound. AND I am using ubuntu lucid 10.04

    I need help . plz.

  22. Risu Risu on July 16, 2010 8:35 pm

    Excellent share!! I was using Hardy for last 2yrs and since last week my surround volume disappeared on acer 5920. After hours of googling i landed here and the catch was with pulseaudio… oh now i can relax for a while ..

  23. brian brian on July 22, 2010 8:55 pm

    This may be a little late but I have also found that I have to either install gnome-alsamixer and make sure that the digital/analogue is ticked because for what ever reason Pulse audio mutes the sound card… I have had to do it on Audigy 4 and the Audigy 2 zs.

  24. UbuntuLinuxHelp UbuntuLinuxHelp on July 24, 2010 10:01 am

    @brian

    Hmmm… That is strange. Pulsaudio using 5.1 surround is working for me on Ubuntu 9.04, 9.10, 10.04 using Audigy 2 ZS. In my case I’ve not had to install extra packages. (Also, this is on a Shuttle box with the Audigy card added into the PCI slot).

    As a side note… 10.04 has had the best hardware support for me so far!

Name (required)

Email (required)

Website

Speak your mind