24th Sep, 2013, 01:32 AM
Hi,
I'm trying to update/follow this guide:
http://www.raspberrypi.org/phpBB3/viewtopic.php?t=23051
To summarise, what the user does there is adjust Raspbian so that XBMC only starts on runlevel 2. Then he has a script to switch the default runlevel to 5 before rebooting. In runlevel 5, lxfe is supposed to start. This last bit is what doesn't work at the moment.
I can execute the runlevel changing script via SSH, works fine. I reboot and I'm in runlevel 5. But, X never starts. It just stays on the Xbian boot screen.
If I run startx manually after quitting XBMC, that works fine.
So my guess is that there's something wrong in the script I've included below.
Any help would be greatly appreciated
I'm trying to update/follow this guide:
http://www.raspberrypi.org/phpBB3/viewtopic.php?t=23051
To summarise, what the user does there is adjust Raspbian so that XBMC only starts on runlevel 2. Then he has a script to switch the default runlevel to 5 before rebooting. In runlevel 5, lxfe is supposed to start. This last bit is what doesn't work at the moment.
I can execute the runlevel changing script via SSH, works fine. I reboot and I'm in runlevel 5. But, X never starts. It just stays on the Xbian boot screen.
If I run startx manually after quitting XBMC, that works fine.
So my guess is that there's something wrong in the script I've included below.
Any help would be greatly appreciated
Code:
#!/bin/bash
### BEGIN INIT INFO
# Provides: startx
# Required-Start: $all
# Required-Stop:
# Default-Start: 5
# Default-Stop: 0 1 2 3 4 6
# Short-Description: startx through init, on runlevel - changing runlevel back to 2
# Description:
#
### END INIT INFO
case "$1" in
start)
sed -ri 's/'DEFAULT_RUNLEVEL=5'/'DEFAULT_RUNLEVEL=2'/' /etc/init/rc-sysinit.conf
startx
;;
stop)
stopx
;;
status)
esac
exit
#EOF