Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Gentoo User (http://www.linux-archive.org/gentoo-user/)
-   -   psi+ and aplay/paplay lock up (?) (http://www.linux-archive.org/gentoo-user/424838-psi-aplay-paplay-lock-up.html)

Kacper Kopczyński 09-09-2010 12:09 PM

psi+ and aplay/paplay lock up (?)
 
Hi,

For a long time now I experience strange behaviour of sound player configured
in Psi (jabber communicator).

Psi for every sound starts /usr/bin/aplay. Sometimes that program blocks sound
device so that nothing else can play, and every other program started just
locks up. So that number of 'aplay' grows with every event from psi. After I
kill them all everything works fine until another lockup. Sometimes I need to
kill flash, mplayer and other programs playing to "fix" this.

I thought that the problem is related to access to soundcard - "there can be
only one" program playing, and I have made ~/.asoundrc :
------------------------------------------------
pcm.!default {
type plug
slave.pcm "mixall"
}

ctl.!default {
type hw
card 0
}

pcm.dsp0 {
type plug
slave.pcm "mixall"
}

pcm.dsp1 {
type plug
slave.pcm "mixall"
}

pcm.mixall {
type asym
playback {
pcm "mixout"
}
capture {
pcm "mixin"
}
}

pcm.mixin {
type dsnoop
ipc_key 678929
ipc_key_add_uid true
slave {
pcm "hw:0,0"
channels 2
periods 0
period_time 0
period_size 1024
buffer_size 16384
rate 44100
}
#bindings {
#0 0
#0 1
#}
}

ctl.mixin {
type hw
card 0
}

pcm.mixout {
type dmix
ipc_key 882921
ipc_key_add_uid true
slave {
pcm "hw:0,0"
period_time 0
period_size 1024
buffer_size 16384
rate 44100
}
#bindings {
#0 0
#1 1
#}
}

ctl.mixout {
type hw
card 0
}

------------------------------

but it did not solve my problem. Another idea was to recompile my system with
support for pulseaudio and ~/.asoundrc is:
------------------------------
pcm.pulse {
type pulse
}

ctl.pulse {
type pulse
}

pcm.!default {
type pulse
}

ctl.!default {
type hw
}
---------------------------
(I am in groups pulse and pulse-access groups)
With same results. (ctl.!default with type hw instead of pulse because mixer
under xfce was "jumping" with sound level for every sound played)

My next idea was to change aplay to paplay... then to change paplay with
aplay -Dpulse -N (non blocking mode...), and nothing...

I haven't found anything on google... or I don't know what to look for :)

My temporary solution is to pkill -9 aplay from cron every minute.

I have tried to recreate this situation on my own in terminal with:

for i in `seq 10`; do (aplay /usr/share/psi/sound/ft_complete.wav &); done

but with no luck.

lsmod:
----------------------------------------------------
Module Size Used by
michael_mic 1484 8
hidp 9100 2
hid 34494 1 hidp
rfcomm 24833 0
l2cap 26115 8 hidp,rfcomm
bluetooth 41286 3 hidp,rfcomm,l2cap
ipv6 207660 24
nf_conntrack_ipv4 8696 1
nf_defrag_ipv4 965 1 nf_conntrack_ipv4
iptable_filter 1154 1
ipt_addrtype 1398 0
xt_DSCP 1441 0
xt_dscp 1097 0
xt_string 890 0
xt_owner 782 0
xt_NFQUEUE 1523 0
xt_multiport 1217 0
xt_mark 795 0
xt_iprange 1062 0
xt_hashlimit 5147 0
xt_conntrack 1966 1
xt_connmark 1291 0
ip_tables 7935 1 iptable_filter
snd_seq_dummy 1138 0
snd_seq_oss 20110 0
snd_seq_midi_event 5046 1 snd_seq_oss
snd_seq 37161 5 snd_seq_dummy,snd_seq_oss,snd_seq_midi_event
snd_seq_device 4872 3 snd_seq_dummy,snd_seq_oss,snd_seq
snd_pcm_oss 26034 0
snd_mixer_oss 10104 1 snd_pcm_oss
snd_hda_codec_realtek 196127 1
usb_storage 28352 0
usb_libusual 9069 1 usb_storage
snd_hda_intel 18465 3
snd_hda_codec 65149 2 snd_hda_codec_realtek,snd_hda_intel
snd_hwdep 4232 1 snd_hda_codec
snd_pcm 52948 3 snd_pcm_oss,snd_hda_intel,snd_hda_codec
ehci_hcd 27353 0
uhci_hcd 16412 0
r8187se 115923 0
snd_timer 14696 2 snd_seq,snd_pcm
r8169 30385 0
snd_page_alloc 6110 2 snd_hda_intel,snd_pcm
usbcore 115692 4 usb_storage,usb_libusual,ehci_hcd,uhci_hcd
i2c_i801 6522 0
sg 18051 0
eeprom_93cx6 1272 1 r8187se
mii 3765 1 r8169
joydev 7009 0
rtc_cmos 7151 0
rtc_core 11303 1 rtc_cmos
rtc_lib 1962 1 rtc_core
----------------------------------------------

and USE flags for alsa:

capsel@ai ~ $ emerge alsa-utils psi alsa-lib -pv

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild R ] media-libs/alsa-lib-1.0.21a USE="python -alisp -debug -doc"
ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug
file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null
plug rate route share shm softvol" 790 kB
[ebuild R ] net-im/psi-0.14-r1 USE="crypt dbus extras jingle spell ssl
webkit xscreensaver -debug -doc" LINGUAS="pl -be -cs -de -fr -it -ja -pt_BR -
ru -sl -sv -ur_PK -zh_TW" 7,880 kB
[ebuild R ] media-sound/alsa-utils-1.0.21-r1 USE="nls -doc -minimal"
1,050 kB

I've runned out of ideas, please help me :)
--
Kacper Kopczyński


All times are GMT. The time now is 06:39 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.