[mythtv-users] mythwelcome + mythfrontend + fluxbox

Stephen Worthington stephen_agent at jsw.gen.nz
Fri Jul 16 06:09:14 UTC 2021


On Thu, 15 Jul 2021 21:12:27 -0700, you wrote:

>I am setting-up a FE/BE combo system. I am using mythwelcome to start 
>the mythfrontend in case of a crash. I have set-up an ~/.xsesssion file 
>as follows:
>
>#!/bin/sh
>
>startfluxbox &
>xset s off
>mythwelcome
>
>This almost works, except the frontend does not come to the top of the 
>windows (nor does mythwelcome). I always have to connect a keyboard and 
>use alt-tab to get it to raise to the top.
>
>I've done many searches and tried several solutions without luck. Has 
>anyone else solved this?

It looks wrong to run "startfluxbox" in parallel but then run xset and
mythwelcome before you can be sure that fluxbox (your window manager)
is actually running.  The window manager is responsible for handling
which window is on top.  I would try adding a "sleep 1" before the
xset command.  It may need to be a longer delay if the machine is not
booting from an SSD or is an older (slower) CPU.  So try that and see
if it helps.  If it does, then what would be even better would be
waiting until it was known that fluxbox was up and running.  So
something like this might work:

while true
do
	sleep 0.1
	pgrep -x "fluxbox" >/dev/null
	if [ $? -eq 0 ]; then
		break
	fi
done


More information about the mythtv-users mailing list