/etc might be on a read-only partition which is not suitable for dynamic data such as the mixer settings. Hence move the location of asound.state to /var/lib. --- alsaconf/alsaconf.in | 4 ++-- alsactl/alsactl.1 | 4 ++-- alsactl/alsactl.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/alsaconf/alsaconf.in b/alsaconf/alsaconf.in index ccc1b37..b9815d1 100644 --- a/alsaconf/alsaconf.in +++ b/alsaconf/alsaconf.in @@ -956,8 +956,8 @@ If you have a big amplifier, lower your volumes or say no. aplay -N $TESTSOUND fi fi - if [ ! -r /etc/asound.state ]; then - xecho "Saving the mixer setup used for this in /etc/asound.state." + if [ ! -r /var/lib/alsa/asound.state ]; then + xecho "Saving the mixer setup used for this in /var/lib/alsa/asound.state." $sbindir/alsactl store fi clear diff --git a/alsactl/alsactl.1 b/alsactl/alsactl.1 index eb3cbd1..eb5968c 100644 --- a/alsactl/alsactl.1 +++ b/alsactl/alsactl.1 @@ -43,7 +43,7 @@ Print alsactl version number.
.TP \fI-f, --file\fP -Select the configuration file to use. The default is /etc/asound.state. +Select the configuration file to use. The default is /var/lib/alsa/asound.state.
.TP \fI-F, --force\fP @@ -90,7 +90,7 @@ The configuration file for init. By default, PREFIX/share/alsa/init/00main is used.
.SH FILES -\fI/etc/asound.state\fP (or whatever file you specify with the +\fI/var/lib/alsa/asound.state\fP (or whatever file you specify with the \fB-f\fP flag) is used to store current settings for your soundcards. The settings include all the usual soundcard mixer settings. More importantly, alsactl is diff --git a/alsactl/alsactl.c b/alsactl/alsactl.c index 3b5dfda..59f0738 100644 --- a/alsactl/alsactl.c +++ b/alsactl/alsactl.c @@ -30,7 +30,7 @@ #include <alsa/asoundlib.h> #include "alsactl.h"
-#define SYS_ASOUNDRC "/etc/asound.state" +#define SYS_ASOUNDRC "/var/lib/alsa/asound.state"
int debugflag = 0; int force_restore = 1;