Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 406587 - media-libs/alsa-lib-1.0.25-r1 - ALSA lib seq_hw.c:457:(snd_seq_hw_open) open /dev/snd/seq failed: Permission denied Cannot open sequencer - Permission denied
Summary: media-libs/alsa-lib-1.0.25-r1 - ALSA lib seq_hw.c:457:(snd_seq_hw_open) open ...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Gentoo ALSA team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-02 12:28 UTC by yermandu
Modified: 2012-03-06 08:25 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emerge-info.log,6.90 KB, text/plain)
2012-03-02 12:28 UTC, yermandu
Details

Note You need to log in before you can comment on or make changes to this bug.
Description yermandu 2012-03-02 12:28:33 UTC
Created attachment 303971 [details]
emerge --info

The alsa seq midi drivers are not load with correct permissions:

$ aplaymidi -l
ALSA lib seq_hw.c:457:(snd_seq_hw_open) open /dev/snd/seq failed: Permission denied
Cannot open sequencer - Permission denied

To workaround after login, reload snd-seq
# modprobe snd-seq

Then the correct permission are loaded.

$ aplaymidi -l
 Port    Client name                      Port name
 14:0    Midi Through                     Midi Through Port-0


sys-fs/udev-171-r5
Comment 1 Tony Vroon (RETIRED) gentoo-dev 2012-03-04 22:52:46 UTC
modprobe does not reload the module, it just loads it. Have you tried building the ALSA core & MIDI sequencer into the kernel proper? If not, does that resolve your issue?
Comment 2 Alex Barker 2012-03-06 01:51:51 UTC
I am having the exact same issue.  It seems that once something accesses /dev/snd/seq as root the permissions are fixed.

On initial login:  
ls -la /dev/snd/seq 
crw------- 1 root root 116, 1 Mar  5 09:41 /dev/snd/seq

After running /usr/lib64/portmidi/latency as root:

ls -la /dev/snd/seq 
crw-rw---- 1 root audio 116, 1 Mar  5 17:48 /dev/snd/seq


This only occurs with alsa-lib-1.0.25, alsa-lib-1.0.24.1 works fine.  I have not tired to build the modules into the kernel yet.  I will try that next and report back.
Comment 3 Alex Barker 2012-03-06 01:53:06 UTC
I take that back, for some reason I cannot build alsa directly into the kernel.
Comment 4 Tony Vroon (RETIRED) gentoo-dev 2012-03-06 08:25:07 UTC
(In reply to comment #3)
> I take that back, for some reason I cannot build alsa directly into the
> kernel.

I can:

chainsaw@adrastea ~ $ zgrep -i seq /proc/config.gz
CONFIG_SND_SEQUENCER=y

Even on very new kernels:

chainsaw@adrastea ~ $ uname -a
Linux adrastea 3.3.0-rc6-00010-ga5939ee #1 SMP PREEMPT Mon Mar 5 15:21:51 GMT 2012 x86_64 Intel(R) Core(TM) i7-2620M CPU @ 2.70GHz GenuineIntel GNU/Linux

Building your ALSA core & drivers into the kernel is the recommended configuration, and deviating from it is unsupported. Unmaintained module loading infrastructure has been removed, as subtle breakage has been introduced consistently and irrevocably. It was the only action for me to take.

Your "permission issue" is a simple absence of the module. I can't think of a situation where you would *not* want a sequencer loaded. Build it into the kernel, and your problems will disappear.
There is nothing for me to fix here.