Well, I don’t like when my PC goes beep-beep at 2 a.m. and everybody is sleeping! So I’ve found a radical way to disable it: simply forbidding Linux to load the PC speaker kernel module.
/etc/rc.local and add:
1 rmmod pcspkr
If you want to disable it right now simply type the same line in a terminal, as root (or use
1 # rmmod pcspkr