1 |
Hi, |
2 |
|
3 |
For a long time now I experience strange behaviour of sound player configured |
4 |
in Psi (jabber communicator). |
5 |
|
6 |
Psi for every sound starts /usr/bin/aplay. Sometimes that program blocks sound |
7 |
device so that nothing else can play, and every other program started just |
8 |
locks up. So that number of 'aplay' grows with every event from psi. After I |
9 |
kill them all everything works fine until another lockup. Sometimes I need to |
10 |
kill flash, mplayer and other programs playing to "fix" this. |
11 |
|
12 |
I thought that the problem is related to access to soundcard - "there can be |
13 |
only one" program playing, and I have made ~/.asoundrc : |
14 |
------------------------------------------------ |
15 |
pcm.!default { |
16 |
type plug |
17 |
slave.pcm "mixall" |
18 |
} |
19 |
|
20 |
ctl.!default { |
21 |
type hw |
22 |
card 0 |
23 |
} |
24 |
|
25 |
pcm.dsp0 { |
26 |
type plug |
27 |
slave.pcm "mixall" |
28 |
} |
29 |
|
30 |
pcm.dsp1 { |
31 |
type plug |
32 |
slave.pcm "mixall" |
33 |
} |
34 |
|
35 |
pcm.mixall { |
36 |
type asym |
37 |
playback { |
38 |
pcm "mixout" |
39 |
} |
40 |
capture { |
41 |
pcm "mixin" |
42 |
} |
43 |
} |
44 |
|
45 |
pcm.mixin { |
46 |
type dsnoop |
47 |
ipc_key 678929 |
48 |
ipc_key_add_uid true |
49 |
slave { |
50 |
pcm "hw:0,0" |
51 |
channels 2 |
52 |
periods 0 |
53 |
period_time 0 |
54 |
period_size 1024 |
55 |
buffer_size 16384 |
56 |
rate 44100 |
57 |
} |
58 |
#bindings { |
59 |
#0 0 |
60 |
#0 1 |
61 |
#} |
62 |
} |
63 |
|
64 |
ctl.mixin { |
65 |
type hw |
66 |
card 0 |
67 |
} |
68 |
|
69 |
pcm.mixout { |
70 |
type dmix |
71 |
ipc_key 882921 |
72 |
ipc_key_add_uid true |
73 |
slave { |
74 |
pcm "hw:0,0" |
75 |
period_time 0 |
76 |
period_size 1024 |
77 |
buffer_size 16384 |
78 |
rate 44100 |
79 |
} |
80 |
#bindings { |
81 |
#0 0 |
82 |
#1 1 |
83 |
#} |
84 |
} |
85 |
|
86 |
ctl.mixout { |
87 |
type hw |
88 |
card 0 |
89 |
} |
90 |
|
91 |
------------------------------ |
92 |
|
93 |
but it did not solve my problem. Another idea was to recompile my system with |
94 |
support for pulseaudio and ~/.asoundrc is: |
95 |
------------------------------ |
96 |
pcm.pulse { |
97 |
type pulse |
98 |
} |
99 |
|
100 |
ctl.pulse { |
101 |
type pulse |
102 |
} |
103 |
|
104 |
pcm.!default { |
105 |
type pulse |
106 |
} |
107 |
|
108 |
ctl.!default { |
109 |
type hw |
110 |
} |
111 |
--------------------------- |
112 |
(I am in groups pulse and pulse-access groups) |
113 |
With same results. (ctl.!default with type hw instead of pulse because mixer |
114 |
under xfce was "jumping" with sound level for every sound played) |
115 |
|
116 |
My next idea was to change aplay to paplay... then to change paplay with |
117 |
aplay -Dpulse -N (non blocking mode...), and nothing... |
118 |
|
119 |
I haven't found anything on google... or I don't know what to look for :) |
120 |
|
121 |
My temporary solution is to pkill -9 aplay from cron every minute. |
122 |
|
123 |
I have tried to recreate this situation on my own in terminal with: |
124 |
|
125 |
for i in `seq 10`; do (aplay /usr/share/psi/sound/ft_complete.wav &); done |
126 |
|
127 |
but with no luck. |
128 |
|
129 |
lsmod: |
130 |
---------------------------------------------------- |
131 |
Module Size Used by |
132 |
michael_mic 1484 8 |
133 |
hidp 9100 2 |
134 |
hid 34494 1 hidp |
135 |
rfcomm 24833 0 |
136 |
l2cap 26115 8 hidp,rfcomm |
137 |
bluetooth 41286 3 hidp,rfcomm,l2cap |
138 |
ipv6 207660 24 |
139 |
nf_conntrack_ipv4 8696 1 |
140 |
nf_defrag_ipv4 965 1 nf_conntrack_ipv4 |
141 |
iptable_filter 1154 1 |
142 |
ipt_addrtype 1398 0 |
143 |
xt_DSCP 1441 0 |
144 |
xt_dscp 1097 0 |
145 |
xt_string 890 0 |
146 |
xt_owner 782 0 |
147 |
xt_NFQUEUE 1523 0 |
148 |
xt_multiport 1217 0 |
149 |
xt_mark 795 0 |
150 |
xt_iprange 1062 0 |
151 |
xt_hashlimit 5147 0 |
152 |
xt_conntrack 1966 1 |
153 |
xt_connmark 1291 0 |
154 |
ip_tables 7935 1 iptable_filter |
155 |
snd_seq_dummy 1138 0 |
156 |
snd_seq_oss 20110 0 |
157 |
snd_seq_midi_event 5046 1 snd_seq_oss |
158 |
snd_seq 37161 5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event |
159 |
snd_seq_device 4872 3 snd_seq_dummy,snd_seq_oss,snd_seq |
160 |
snd_pcm_oss 26034 0 |
161 |
snd_mixer_oss 10104 1 snd_pcm_oss |
162 |
snd_hda_codec_realtek 196127 1 |
163 |
usb_storage 28352 0 |
164 |
usb_libusual 9069 1 usb_storage |
165 |
snd_hda_intel 18465 3 |
166 |
snd_hda_codec 65149 2 snd_hda_codec_realtek,snd_hda_intel |
167 |
snd_hwdep 4232 1 snd_hda_codec |
168 |
snd_pcm 52948 3 snd_pcm_oss,snd_hda_intel,snd_hda_codec |
169 |
ehci_hcd 27353 0 |
170 |
uhci_hcd 16412 0 |
171 |
r8187se 115923 0 |
172 |
snd_timer 14696 2 snd_seq,snd_pcm |
173 |
r8169 30385 0 |
174 |
snd_page_alloc 6110 2 snd_hda_intel,snd_pcm |
175 |
usbcore 115692 4 usb_storage,usb_libusual,ehci_hcd,uhci_hcd |
176 |
i2c_i801 6522 0 |
177 |
sg 18051 0 |
178 |
eeprom_93cx6 1272 1 r8187se |
179 |
mii 3765 1 r8169 |
180 |
joydev 7009 0 |
181 |
rtc_cmos 7151 0 |
182 |
rtc_core 11303 1 rtc_cmos |
183 |
rtc_lib 1962 1 rtc_core |
184 |
---------------------------------------------- |
185 |
|
186 |
and USE flags for alsa: |
187 |
|
188 |
capsel@ai ~ $ emerge alsa-utils psi alsa-lib -pv |
189 |
|
190 |
These are the packages that would be merged, in order: |
191 |
|
192 |
Calculating dependencies... done! |
193 |
[ebuild R ] media-libs/alsa-lib-1.0.21a USE="python -alisp -debug -doc" |
194 |
ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug |
195 |
file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null |
196 |
plug rate route share shm softvol" 790 kB |
197 |
[ebuild R ] net-im/psi-0.14-r1 USE="crypt dbus extras jingle spell ssl |
198 |
webkit xscreensaver -debug -doc" LINGUAS="pl -be -cs -de -fr -it -ja -pt_BR - |
199 |
ru -sl -sv -ur_PK -zh_TW" 7,880 kB |
200 |
[ebuild R ] media-sound/alsa-utils-1.0.21-r1 USE="nls -doc -minimal" |
201 |
1,050 kB |
202 |
|
203 |
I've runned out of ideas, please help me :) |
204 |
-- |
205 |
Kacper Kopczyński |