[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Sound only as root



On Wed, Oct 18, 2023 at 11:25:51AM +0200, Hans wrote:
> I am in the group "audio".

> correct:
> 
> /dev/snd = root:root , drwxr-xr-x
> 
> All others below /dev/snd are set 
> 
> crw-rw--- = root:audio

It would help if you pasted the actual "ls -l" output.  Here's mine
for comparison:

unicorn:~$ ls -l /dev/snd
total 0
drwxr-xr-x  2 root root       60 Oct  7 08:49 by-id/
drwxr-xr-x  2 root root       80 Oct  7 08:49 by-path/
crw-rw----+ 1 root audio 116, 10 Oct  7 08:49 controlC0
crw-rw----+ 1 root audio 116, 12 Oct  7 08:49 controlC1
crw-rw----+ 1 root audio 116,  8 Oct  7 08:49 hwC0D0
crw-rw----+ 1 root audio 116,  9 Oct  7 08:49 hwC0D2
crw-rw----+ 1 root audio 116,  3 Oct  7 08:50 pcmC0D0c
crw-rw----+ 1 root audio 116,  2 Oct  7 08:57 pcmC0D0p
crw-rw----+ 1 root audio 116,  4 Oct  7 08:49 pcmC0D2c
crw-rw----+ 1 root audio 116,  5 Oct  7 08:50 pcmC0D3p
crw-rw----+ 1 root audio 116,  6 Oct  7 08:50 pcmC0D7p
crw-rw----+ 1 root audio 116,  7 Oct  7 08:50 pcmC0D8p
crw-rw----+ 1 root audio 116, 11 Oct  7 08:50 pcmC1D0c
crw-rw----+ 1 root audio 116,  1 Oct  7 08:49 seq
crw-rw----+ 1 root audio 116, 33 Oct  7 08:49 timer

You see those "+" signs at the ends of the permission strings?  Those
are super important here.  When you login to Debian, there's various
black magic that happens with "session" and "seats" and so on.  One
of the things involved in that magic is adding your account to the
ACL on the audio devices.  For instance,

unicorn:~$ getfacl /dev/snd/hwC0D0
getfacl: Removing leading '/' from absolute path names
# file: dev/snd/hwC0D0
# owner: root
# group: audio
user::rw-
user:greg:rw-
group::rw-
mask::rw-
other::---


If yours isn't doing that, then we have a problem.  In fact, the very
first thing I wondered when I read your post was "Is this actually a
Debian system, or is it something like Devuan?"  If you've altered the
login stuff, for example by trying to remove systemd, then you might
have broken the session/seat magic that sets up the ACLs.


Reply to: