You are not logged in.

#1 2019-08-10 13:51:27

abspython
Member
Registered: 2019-08-09
Posts: 5

[Solved] ALSA does not restore the sound level

The issue is that every boot, the sound level is resettled to 69% every time.

I have installed alsa-utils package and found that

pacman -Ql alsa-utils|grep "alsa-\(re\|\)store.service"

returns only the following services,

alsa-utils /usr/lib/systemd/system/alsa-restore.service
alsa-utils /usr/lib/systemd/system/sound.target.wants/alsa-restore.service

So, I don't have

alsa-store.service

hmm

When I do

1.

sudo alsactl store

I get

alsactl: state_lock:125: file /var/lib/alsa/asound.state lock error: No such file or directory

2.

sudo alsactl init
alsactl: sysfs_init:48: sysfs path '/sys' is invalid

Found hardware: "HDA-Intel" "Realtek ALC269VB" "HDA:10ec0269,144dc606,00100100 HDA:80862805,80860101,00100000" "0x144d" "0xc606"
Hardware is initialized using a generic method

and after this when I do echo $?, I get 99

3.By default the services are inactive. After I start the services (alsa-restore and alsa-state), I get the following,

 alsa-state.service - Manage Sound Card State (restore and store)
   Loaded: loaded (/usr/lib/systemd/system/alsa-state.service; static; vendor preset: disabled)
   Active: inactive (dead)
Condition: start condition failed at Sat 2019-08-10 19:15:19 IST; 16s ago
            ConditionPathExists=/etc/alsa/state-daemon.conf was not met
 alsa-restore.service - Save/Restore Sound Card State
   Loaded: loaded (/usr/lib/systemd/system/alsa-restore.service; static; vendor preset: disabled)
   Active: inactive (dead)
Condition: start condition failed at Sat 2019-08-10 19:15:31 IST; 10s ago
            ConditionPathExists=/var/lib/alsa/asound.state was not met

4.Also  I have no asound.state in /var/lib/alsa/ directory.

Thanks in advance. smile

Last edited by abspython (2019-08-14 11:19:15)

Offline

#2 2019-08-10 15:00:42

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,423

Re: [Solved] ALSA does not restore the sound level

The main question is why your alsactl store command fails, as that would fix everything else.

Is /var a separate partition/mount point or a symlink of some sort?
What file system is this? Maybe you've just chosen a filesystem that doesn't support enabling file locking

sudo alsactl -L store #Should disable file locking, you might have to adjust the service file so that it also doesn't use locking
stat /var/lib/alsa/ 
mount

Last edited by V1del (2019-08-10 15:08:34)

Offline

#3 2019-08-10 16:42:59

abspython
Member
Registered: 2019-08-09
Posts: 5

Re: [Solved] ALSA does not restore the sound level

Thanks for the fast reply.

V1del wrote:

The main question is why your alsactl store command fails, as that would fix everything else.

Even I  don't know why it fails sad. Also can you explain more about file locking? I'm pretty new to Arch Linux and I never had issue with Debian 10.

Also the output of the code is,
Ouput-After-stat
Ouput-After-mount

Even after that, and a quick rebooting, I still can't do alsactl store

Also, I checked in my Debian setup, I saw a directory named conf.d  with in /etc/alsa/, which is not in Arch Linux. So am I supposed to similarly?(Also ALSA was preconfigured in Debian)

Links I read regarding this issue : Link1,  Link2

Offline

#4 2019-08-10 17:46:23

loqs
Member
Registered: 2014-03-06
Posts: 19,101

Re: [Solved] ALSA does not restore the sound level

What is the output of the following

# touch /var/lib/alsa/asound.state.check && stat /var/lib/alsa/asound.state.check

Offline

#5 2019-08-11 02:22:45

abspython
Member
Registered: 2019-08-09
Posts: 5

Re: [Solved] ALSA does not restore the sound level

Ouput

I find that I can do alsactl store and alsactl restore with the parameter -L (With no locking).But even after reboot it goes back to a default value.

Last edited by abspython (2019-08-11 09:44:57)

Offline

#6 2019-08-11 09:53:59

abspython
Member
Registered: 2019-08-09
Posts: 5

Re: [Solved] ALSA does not restore the sound level

I stopping using alsactl and started to use pulseaudio. I'm having no trouble with sound resetting issue. I have installed

 pulseaudio pulseaudio-alsa pulsemixer

Also I use pavucontrol to change the volume level as GUI.
Also please close this thread.

Last edited by abspython (2019-08-11 09:56:36)

Offline

#7 2019-08-11 11:43:50

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 25,423

Re: [Solved] ALSA does not restore the sound level

If you feel that this is solved like that, please mark your thread as such by editing the title in your first post and prepending [SOLVED] or similar.

I still find it weird that alsactl store didn't work and the stat output looks fine to me...

Offline

Board footer

Powered by FluxBB