Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[PARTLY SOLVED] udev strange behavior
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
Perfect Gentleman
l33t
l33t


Joined: 18 May 2014
Posts: 799

PostPosted: Sun Nov 08, 2015 7:35 pm    Post subject: [PARTLY SOLVED] udev strange behavior Reply with quote

rule
Code:
KERNELS=="1-5", SUBSYSTEM=="usb", ATTRS{idVendor}=="041e", ATTRS{idProduct}=="3f04", RUN+="/usr/bin/sudo -u my_user /usr/bin/xfce4-volumed-pulse"
doesn't work, but
rule
Code:
KERNELS=="1-5", SUBSYSTEM=="usb", ATTRS{idVendor}=="041e", ATTRS{idProduct}=="3f04", RUN+="/usr/bin/sudo -u my_user /usr/bin/touch /tmp/log"
works
WTF?

Working rule:
Code:
SUBSYSTEM=="usb", ATTRS{idVendor}=="041e", ATTRS{idProduct}=="3f04", RUN+="/usr/bin/sudo -u my_user DISPLAY=:0.0 /usr/bin/xfce4-volumed-pulse &2"


Partly solved: xfce4-volumed-pulse and pulseaudio start, but no sound


Last edited by Perfect Gentleman on Mon Nov 09, 2015 9:24 am; edited 2 times in total
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Sun Nov 08, 2015 11:53 pm    Post subject: Reply with quote

PG ... I imagine because the latter is cli while the former is X11 ... and so requires knowledge of what DISPLAY its to use:

Code:
% echo $DISPLAY
:0

HTH & best ... khay
Back to top
View user's profile Send private message
Perfect Gentleman
l33t
l33t


Joined: 18 May 2014
Posts: 799

PostPosted: Mon Nov 09, 2015 3:34 am    Post subject: Reply with quote

i corrected it to
Code:
KERNELS=="1-5", SUBSYSTEM=="usb", ATTRS{idVendor}=="041e", ATTRS{idProduct}=="3f04", RUN+="/usr/bin/sudo -u my_user /usr/bin/xfce4-volumed-pulse --display=:0 &>/dev/null"
, it didn't help.
Code:
KERNELS=="1-5", SUBSYSTEM=="usb", ATTRS{idVendor}=="041e", ATTRS{idProduct}=="3f04", RUN+="DISPLAY=:0 /usr/bin/sudo -u my_user /usr/bin/xfce4-volumed-pulse &>/dev/null"
didn't work too.

Last edited by Perfect Gentleman on Mon Nov 09, 2015 7:02 am; edited 1 time in total
Back to top
View user's profile Send private message
khayyam
Watchman
Watchman


Joined: 07 Jun 2012
Posts: 6228
Location: Room 101

PostPosted: Mon Nov 09, 2015 4:28 am    Post subject: Reply with quote

PG ... honestly I don't know why you'd need to run this on connecting a device, surely a volume mixer is started as a component of the XFCE DE? Anyhow, you say it doesn't help ... what is suposed to happen?

best ... khay
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum