[Bug 486154] Re: System beep broken in Karmic despite heroic efforts to fix it
Robert Schroll
rschroll at gmail.com
Tue Jun 22 04:14:41 BST 2010
Update for Lucid, for which I'm sure everyone has been waiting with
bated breath.
pcspkr is still blacklisted. See the above comment for details.
Metacity behaves the same way as it did in Karmic, trapping all system
bell events and using it's own playback capabilities. This is despite
the fact that module-x11-bell is loaded by default now. Someone should
write a patch for Metacity that would fix that. Oh, wait.
Compiz still doesn't handle system bell events, but now Pulse Audio is set up to handle them, so we get nice-sounding bells in Compiz. At least we would, if the Pulse Audio setup weren't completely broken. In two separate ways:
1) Pulse Audio's module-x11-bell respects the X bell volume, which Gnome sets to 0 somewhere in its startup sequence. (Metacity, of course, ignores this setting. If it isn't in GConf, it doesn't exist.) This was presumably done to shut off the PC speaker beep, but this isn't needed anymore. The volume must be turned up before you could hear anything (`xset b on` or `xset b <percentage>`).
2) As loaded by default, module-x11-bell points to the sample bell.ogg, which doesn't exist! You must either load the sample (`pactl upload-sample /usr/share/sounds/ubuntu/stereo/bell.ogg bell.ogg`) or reload the module with the sample name correctly set (`pactl unload-module <number of module-x11-bell>; pactl load-module module-x11-bell display=:0.0 sample=bell-window-system`).
Now that it's working, you must realize the Gnome's Sound Preferences dialog, which assumes Metacity is running, no longer adjusts the beep sound. (Curiously, the mute button does work.)
But what we REALLY want isn't this high-falutin' boink sound -- we want
the PC speaker beep back! When I check previously in the VM, Lucid's
Metacity could be patched in the same way Karmic's could. I haven't
tried this on my actual machine, as Metacity keeps crashing on me (!?!).
But under Compiz, all you should have to do is load the pcspkr module,
use `xset b on` to turn up the volume, and unload the module-x11-bell
module from Pulse Audio. This turns out not to work -- you also need to
start a new instance of Compiz, using `compiz --replace` i.e., for
reasons I can't begin to fathom.
This all probably warrants a new bug (or 12). But maybe I'll wait for
Maverick, which promises to bring us two new window managers and a whole
host of ill-considered mis-configurations. I hope you're all as excited
about this as I!
--
System beep broken in Karmic despite heroic efforts to fix it
https://bugs.launchpad.net/bugs/486154
You received this bug notification because you are a member of Ubuntu
Sponsors Team, which is a direct subscriber.
Status in The Metacity Window Manager: New
Status in “libcanberra” package in Ubuntu: New
Status in “metacity” package in Ubuntu: Triaged
Status in “pulseaudio” package in Ubuntu: Invalid
Bug description:
Between Jaunty and Karmic, a number of changes were made to keep the PC speaker from beeping. As part of this, system bell events are now captured by metacity, which uses libcanberra to play a sound. For users without speakers, this fails to be useful. The current setup makes restoring the old behavior extremely difficult.
The absolute show stopper is that metacity traps audible system bell events. This behavior is, as best we can tell, not configurable. The attached patch keeps metacity from capturing system bell events. It also removes the sound playback capability. As Lucid will be using pulse audio's module-x11-bell to play sounds for system bell events, it is not necessary for this capability to be in metacity. Additionally, this removes the discrepancy between metacity's and compiz's handling of system bell events.
There are several other difficulties in enabling the system bell:
1) Even if it is taken out of the blacklist, the pcspkr module may not load properly. Another modprobe may be necessary to get it loaded. See bug #398161.
2) Something in Gnome's startup does the equivalent of `xset b off`, so `xset b on` must be run on every login. (Note that bug #280767 keeps you from setting the bell volume with xset.)
3) A number of settings in gnome-terminal and gconf may keep the shell from sounding system bell events.
Comments #28, #34, and #50 give more detailed summaries of the various problems.
More information about the Ubuntu-sponsors
mailing list