On Monday 28 January 2008 17:40, Jordan Erickson wrote:
> I've had this issue with lts.conf RCFILE_* entries - see this:
>
> https://bugs.launchpad.net/ubuntu/+source/ltsp/+bug/163000
>
> Most likely, the RCFILE_* scripts are running before your sound hardware
> is fully initialized (that was the case with me setting
> headphone-jack-sense on so it would recognize headphones being plugged
> in and stop playing sound over the internal sound speaker of my clients).

Spot on, my mistake - the script was running, but was unable to do anything 
because the soundcard hadn't been loaded at that point.

I got around the issue by creating a second script "run_unmute" which did 
nothing except fork the original script "unmute". I changed lts.conf to have 
RCFILE_01 = run_unmute. Then at the top of the "unmute" script I added the 
following lines:

amixer
while [ $? != 0 ]; do
  amixer
  sleep 1
done

I.e. it keeps checking amixer and sleeps for a second until such time as 
amixer runs without an error.

Why not just "sleep 10" (or long enough for the soundcard to load)? Because 
for some unknown reason it just terminated the script.

This isn't very elegant and I'm sure someone out there has a better idea - but 
for now it works!

Thanks,
Chris Roberts

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_____________________________________________________________________
Ltsp-discuss mailing list.   To un-subscribe, or change prefs, goto:
      https://lists.sourceforge.net/lists/listinfo/ltsp-discuss
For additional LTSP help,   try #ltsp channel on irc.freenode.net

Reply via email to