SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I just compiled a new 2.6.7 kernel for my Slackware 10.0 and got ALSA set up. I ran alsaconf and everything works great but every time I reboot the sound goes back to being muted. How do I fix this?
Yea i already looked at that... I did an "alsactl store" and now i can do an "alsactl restore" and I get my volume back but I want to know how to do this automatically without having to type "alsactl restore" everytime.
#!/bin/sh
# Load the mixer settings and OSS compatibility for ALSA.
# (the Advanced Linux Sound Architecture)
# A function to load the ALSA mixer settings:
load_alsa_mixer() {
if [ -r /etc/asound.state ]; then
echo "Loading ALSA mixer settings: /usr/sbin/alsactl restore"
/usr/sbin/alsactl restore
else
echo "ALSA warning: No mixer settings found in /etc/asound.state."
echo " Sound may be muted. Use 'alsamixer' to unmute your sound card,"
echo " and then 'alsactl store' to save the default ALSA mixer settings"
echo " to be loaded at boot."
fi
}
# A function to load the ALSA OSS compat modules:
load_alsa_oss_modules() {
if ! cat /proc/modules | grep -w snd-pcm-oss 1> /dev/null 2> /dev/null ; then
echo "Loading OSS compatibility modules for ALSA."
modprobe snd-pcm-oss
modprobe snd-mixer-oss
fi
}
# If hotplug or something else has loaded the ALSA modules, then
# simply load the mixer settings and make sure the OSS compat
# modules are loaded:
if [ -d /proc/asound ]; then
load_alsa_mixer
load_alsa_oss_modules
else
# If there are ALSA modules defined in /etc/modules.conf, but
# ALSA is not yet loaded, then load the modules now:
DRIVERS=`modprobe -c | grep -E "^[[:space:]]*alias[[:space:]]+snd-card-[[:digit:]]" | awk '{ print $3 }'`
if [ ! "$DRIVERS" = "" ]; then
echo "Loading ALSA kernel modules."
for module in $DRIVERS; do
modprobe $module
done
fi
# If ALSA is now up, then load the mixer settings and OSS modules:
if [ -d /proc/asound ]; then
load_alsa_mixer
load_alsa_oss_modules
fi
fi
Originally posted by AFI_Flame I don't have that script... I uninstalled the ALSA drivers that came with Slackware and compiled my own when I upgraded my kernel.
Did you compile and install the alsa-utils package, too? That is where the rc.alsa, et al, come from.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.