Linux Ubuntu 12.10 and XBMC autostart not working
#16
(2013-04-11, 22:47)Axman Wrote: Hmm ok, thanks.

Thats what I have now, but XBMC is the only desktop-program I use on this machine so I'd like to have lightdm start right into XBMC for me..
If anyone who knows how to make this happen on Ubuntu 12.10, please chime in!

Thanks


Did you get this working?
I like xbmcbuntu but would prefer a full Ubuntu that I can login as when needed.
Reply
#17
You can log in to XBMCbuntu if you need to.
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
#18
(2013-05-02, 23:53)natdeamer Wrote: Did you get this working?
I like xbmcbuntu but would prefer a full Ubuntu that I can login as when needed.

Yes, but I had to borrow some scripts from this thread: http://forum.xbmc.org/showthread.php?tid=141369

I am using the lighdm/xsession approach, but I also added this script, although I'm not sure if its actually needed.
Reply
#19
No, using both is contraproductive. Both try to start xbmc, one as a session via lightdm, one even with own xserver. Remove one of them. Btw. the script you linked could end you up without sound devices, cause there is no waiting for udev trigger / settle.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#20
(2013-05-03, 08:44)fritsch Wrote: No, using both is contraproductive. Both try to start xbmc, one as a session via lightdm, one even with own xserver. Remove one of them. Btw. the script you linked could end you up without sound devices, cause there is no waiting for udev trigger / settle.

Well thanks, I removed the /etc/init.d/xbmc script and now it does NOT boot into XBMC, but Ubuntu desktop. Which makes sense, because I had trouble getting the lightdm/xsession-approach to work properly before, and then I tried the script linked to in my previous post and saved it as /etc/init.d/xbmc - and bam it worked.

Btw, my "lightdm/xsession" approach involves creating a /usr/share/xsessions/XBMC.desktop file as outlined in this thread, and then configuring /etc/lightdm/lightdm.conf to use it at boot. But this has not worked for me.

What I make of this is that the init.d or xinit or whatever you want to call it -approach works, while lightdm session config doesn't. Which I don't really understand, as lightdm should be the "better" approach for Ubuntu 12.10, which I am running.

I'll paste my scripts/configs below, just so it's clear what I'm doing:

Certainly there is the chance that I have configured lightdm.conf and the .desktop file wrongly, but I really did try quite a bit to make it work without success.

/etc/lightdm/lightdm.conf:
PHP Code:
[SeatDefaults]
autologin-guest=false
autologin
-user=my-user
autologin
-user-timeout=0
user
-session=XBMC 

/usr/share/xsessions/XBMC.desktop:
PHP Code:
[
Desktop Entry]
Name=XBMC
Comment
=This session will start XBMC Media Center
Exec
=xbmc-standalone
TryExec
=xbmc-standalone
Type
=Application
greeter
-session=lightdm-gtk-greeter 

/etc/init.d/xbmc:
PHP Code:
#! /bin/sh

### BEGIN INIT INFO
# Provides:          xbmc
# Required-Start:    $all
# Required-Stop:     $all
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: starts instance of XBMC
# Description:       starts instance of XBMC using start-stop-daemon and xinit
### END INIT INFO

############### EDIT ME ##################

# path to xinit exec
DAEMON=/usr/bin/xinit

# startup args
DAEMON_OPTS=" /usr/bin/xbmc-standalone -- :0"

# script name
NAME=xbmc

# app name
DESC=XBMC

# user
RUN_AS=my-user

# Path of the PID file
PID_FILE=/var/run/xbmc.pid

############### END EDIT ME ##################

test -x $DAEMON || exit 0

set 
-e

case "$1" in
  start
)
        echo 
"Starting $DESC"
        
start-stop-daemon --start -c $RUN_AS --background --pidfile $PID_FILE --make-pidfile --exec $DAEMON -- $DAEMON_OPTS
        
;;
  
stop)
        echo 
"Stopping $DESC"
        
start-stop-daemon --stop --pidfile $PID_FILE
        
;;

  
restart|force-reload)
        echo 
"Restarting $DESC"
        
start-stop-daemon --stop --pidfile $PID_FILE
        sleep 5
        start
-stop-daemon --start -c $RUN_AS --background --pidfile $PID_FILE --make-pidfile --exec $DAEMON -- $DAEMON_OPTS
        
;;
  *)
        
N=/etc/init.d/$NAME
        
echo "Usage: $N {start|stop|restart|force-reload}" >&2
        
exit 1
        
;;
esac

exit 
Reply

Logout Mark Read Team Forum Stats Members Help
Ubuntu 12.10 and XBMC autostart not working0