Blacklist your PC speaker

I hate the internal beep speaker. I hate it, I hate it, I hate it. :evil: Okay, maybe not that much hate, but I really don’t like having it enabled. It beeps anytime the terminal cursor goes in the wrong direction. Or if the sound isn’t working quite right when I’m setting things up. Or if it’s time to put another quarter in the dryer. It’s just a nuisance.

On some machines I’m fine — Dell’s BIOS, for example, sometimes includes the option to mute the darn thing. But on others I’m not so lucky.

The easiest way I know of — short of popping the case and yanking the cord to the case speaker — is to blacklist the pcspkr module. In Ubuntu, you can do that like this.

sudo nano -w /etc/modprobe.d/blacklist

At the end of the file, add this line.

blacklist pcspkr

Hopefully, that should keep it from ever mouthing off again.

In Arch, the same idea is handled in that lovely rc.conf file, where all the good stuff happens. Open your rc.conf. …

sudo nano -w /etc/rc.conf

(Yes, I use sudo in Arch. I’m a wimp.) Now find this line.

MOD_BLACKLIST=()

And change it to this.

MOD_BLACKLIST=(pcspkr)

Bingo. Silence. Now maybe I can get some work done. :twisted:

10 Responses to “Blacklist your PC speaker”


  1. 1 Dr Small 2007/09/18 at 2:40 AM

    I miss the system beep on this new motherboard :’(
    It doesn’t have an internal speaker, I guess.

    Where would I look to find an internal speaker for my motherboard, to install on it ?

    Dr Small

  2. 2 xanthus 2007/09/18 at 6:40 AM

    It is better to put the blacklisted modules in a custom file (i.e. /etc/modprobe.d/my_custom_blacklist) because if you upgrade the system /etc/modprobe.d/blacklist can be overriden and you lost your blacklisted modules.

    Regards.

  3. 3 K.Mandla 2007/09/18 at 8:01 AM

    I tried that once, about a year ago, and it didn’t work for me. It’s possible I did it wrong; I’ll try that in the next install, and see if it works any better for me. Thanks.

  4. 4 K.Mandla 2007/09/18 at 8:03 AM

    @Dr Small: Usually the speaker itself is part of the case, and there’s a slim wire that leads from a jumper on the motherboard to the speaker. Every motherboard is different, of course. I guess you could check a parts store to see if they have mountable speakers, but I don’t know. You could also tear one out of a used case, and attach it to your present case if it doesn’t have one. :)

  5. 5 Luke 2007/09/18 at 10:16 AM

    This is a tad extreme approach. Have you tried simply adding:

    set bell-style none

    to your .bashrc, .bash_profile or .inputrc?

    Also, xset -b should disable it for the current X session. Or was that not enough for Arch?

  6. 6 K.Mandla 2007/09/18 at 3:35 PM

    I’ll try all three of these. I learned to blacklist the module from the Arch wiki, and just translated it to Ubuntu later. If I’m right, that will only work on a per-user basis, won’t it? I’ll have to try; I don’t want the bell to ring in a root session of nano. :|

  7. 7 GoofY 2007/11/04 at 8:48 PM

    Great artikle, it drove me nuts when I was trying out things. Problem is I couldn’t find out whether it could be a bit more silent, though I don’t think so cause it’s only a beep thingie.

  8. 8 Paul Roach 2008/05/01 at 1:37 AM

    My god…..that’s may my day/week/year and those of my colleagues who share an open-plan office with me…..

    THANKYOUTHANKYOUTHANKYOU :D

  9. 9 RusFuture 2008/06/08 at 1:17 AM

    Hi,

    This was very, very useful information for me. I used your
    note on how to do the “blacklist” to remove the loading of
    my pcspkr speaker driver, on my Fedora 9 DEC-5000 box. This
    has been a *VERY GOOD THING*, as the pcspkr driver apparently
    was conflicting with my “snd-cs4236″ sound card driver, and
    now I have *music*!! (as well as not having the damn
    beeping speaker…) I had put the set no-bell option in
    my runcontrol files, but still got the beep in the vi editor,
    by the way, so this approach is still useful, even if all you
    want to do is whack the annoying beeping.
    Thanx for this.
    - Rus

  10. 10 jan 2009/03/13 at 7:42 AM

    THANKS
    there is always some app i could not control.
    when using headphones the beep really destroyed my ears.

    Never thought to disable in kernel. thanks again for this simple solution.


Leave a Reply




Welcome!

Some recent desktops


July 3, 2009
Openbox 3.4.7.2 on Crux Linux
1Ghz Pentium III 512Mb PC133


June 16, 2009
screen-vs on Crux Linux
700Mhz Celeron 256Mb PC100


June 18, 2009
screen-vs on Crux Linux
550Mhz Celeron 192Mb PC100


Feb. 13, 2009
Awesome 2.3.4 on Crux Linux
100Mhz Pentium 16Mb PC66 120Gb

A recent game


Neverwinter Nights
Gnome 2.26.1 on Ubuntu 9.04
1Ghz Pentium III 512Mb PC133

Be counted!

Recent Comments

CorkyAgain on The cloud is a lie
colonelcrayon on Light and efficient, at under…
tigrmesh on At long last

License

This work is licensed under the GNU Free Documentation License. Please see the About page for details.

Downloads

Blog Stats

  • 1,205,447 hits

Categories

Archives

Calendar

September 2007
S M T W T F S
« Aug   Oct »
 1
2345678
9101112131415
16171819202122
23242526272829
30