2008-04-30, 22:11
Since more than one person has asked about my setup, I'm going to try to write a guide covering what I did to install my system using 7.10 server and no GDM. This guide will assume you at least know basic linux commands and how to install an os to begin with. I also assume that your hardware is supported, as mine is with no special configuration needed.
My hardware consists of an Asus Pundit P1/AH2, 1GB RAM, Sempron 3000+, geForce 6150. Hardly anything spectacular, but works well, is easy to setup and can play up to 720p. I'm confident I could replace the Sempron with a newer dual-core Athlon and play 1080p content just fine.
First, install 7.10 Server and after the core install is done and the software selection box comes up, choose OpenSSH only and then continue with the install. At this point, install should be finished within a couple of minutes.
After the system reboots you will have a command-line install of 7.10 server. Login to a command line and start adding packages.
During install of the above packages, you will be prompted for input for x setup(choose 1024x768 and 800x600 for now), lirc setup(choose your remote and receiver), and localepurge(choose the language you want to keep). After these install are finished, install envy.
The above install will probably fail, so run:
After envy installs, run it to install your nvidia or ati drivers:
Choose the option to install the nvidia or ati driver and follow the default prompts.
Now, either get the deb package for xbmc or add the xbmc repositories and do an apt-get install:
Option 1:
And when it fails:
Option 2:
With your favorite editor, (vi hopefully) edit your /etc/apt/sources.list as sudo and add the following lines:
Then, update your repositories and apt-get install xbmc:
At this point, xbmc and all dependencies should be installed. You should probably test it by opening an x session and trying to run xbmc. I installed the deb package so my binary is at /opt/xbmc/XboxMediaCenter.
An x session should start, and at the command line in your new window type:
If all is well, an x session should have started and after launching the binary, xbmc should have fired up. You can go ahead and fix your xbmc settings for resolution and everything else now, or after you're done.
Now lets make everything automated. With your favorite editor, create a new file called XboxMediaCenter.sh at /usr/local/bin
The above irexec command is for buttons I use on my remote for reboot and shutdown.
Make it executable with:
Now we need a script in /etc/init.d called XboxMediaCenter
Make it executable with:
Now we need to link the script to /etc/rc2.d
Now let's create a reboot and shutdown script. At /usr/local/bin create Reboot.sh and Shutdown.sh
Now, let's create an lircrc file to allow you to shutdown or reboot with your remote. I use a Microsoft MCE remote so the DVD and RecTV buttons are not used at this time by xbmc so I will use them for reboot and shutdown.
We need the file at /root and it needs to be called .lircrc (note the preceding period)
You probably won't need to do the following since xbmc is running as root, but just in case, run visudo and near the bottom of the file, add
Now, to clean everything up, run the following:
If all goes well, you typed everything correctly, and I didn't leave anything out, the system should reboot and come up directly in xbmc. It takes about 20 seconds for xbmc to come up on my hardware.
My hardware consists of an Asus Pundit P1/AH2, 1GB RAM, Sempron 3000+, geForce 6150. Hardly anything spectacular, but works well, is easy to setup and can play up to 720p. I'm confident I could replace the Sempron with a newer dual-core Athlon and play 1080p content just fine.
First, install 7.10 Server and after the core install is done and the software selection box comes up, choose OpenSSH only and then continue with the install. At this point, install should be finished within a couple of minutes.
After the system reboots you will have a command-line install of 7.10 server. Login to a command line and start adding packages.
Code:
sudo apt-get install wget x-window-system lirc lirc-x liblircclient0 localepurge
During install of the above packages, you will be prompted for input for x setup(choose 1024x768 and 800x600 for now), lirc setup(choose your remote and receiver), and localepurge(choose the language you want to keep). After these install are finished, install envy.
Code:
wget http://albertomilone.com/ubuntu/nvidia/scripts/legacy/envy_0.9.10-0ubuntu9_all.deb
sudo dpkg -i envy_0.9.10-0ubuntu9_all.deb
The above install will probably fail, so run:
Code:
sudo apt-get install -f
After envy installs, run it to install your nvidia or ati drivers:
Code:
sudo envy -t
Choose the option to install the nvidia or ati driver and follow the default prompts.
Now, either get the deb package for xbmc or add the xbmc repositories and do an apt-get install:
Option 1:
Code:
wget http://web.ics.purdue.edu/~nelson11/xbmc_2.1a1_svn12195-0ubuntu1_i386.deb
sudo dpkg -i xbmc_2.1a1_svn12195-0ubuntu1_i386.deb
And when it fails:
Code:
sudo apt-get install -f
Option 2:
With your favorite editor, (vi hopefully) edit your /etc/apt/sources.list as sudo and add the following lines:
Code:
deb http://ppa.launchpad.net/team-xbmc/ubuntu gutsy main
deb-src http://ppa.launchpad.net/team-xbmc/ubuntu gutsy main
Then, update your repositories and apt-get install xbmc:
Code:
sudo apt-get update
sudo apt-get install xbmc
At this point, xbmc and all dependencies should be installed. You should probably test it by opening an x session and trying to run xbmc. I installed the deb package so my binary is at /opt/xbmc/XboxMediaCenter.
Code:
xinit
An x session should start, and at the command line in your new window type:
Code:
./opt/xbmc/XboxMediaCenter
If all is well, an x session should have started and after launching the binary, xbmc should have fired up. You can go ahead and fix your xbmc settings for resolution and everything else now, or after you're done.
Now lets make everything automated. With your favorite editor, create a new file called XboxMediaCenter.sh at /usr/local/bin
Code:
#/usr/local/bin/XboxMediaCenter.sh
#Script to start x server and XBMC
#!/bin/bash
/usr/bin/X11/xinit /opt/xbmc/XboxMediaCenter -q &
irexec -d /root/.lircrc &
fi
The above irexec command is for buttons I use on my remote for reboot and shutdown.
Make it executable with:
Code:
sudo chmod 755 XboxMediaCenter.sh
Now we need a script in /etc/init.d called XboxMediaCenter
Code:
#/etc/init.d/XboxMediaCenter
#Start XBMC
#!/bin/sh
export PATH=/usr/bin:/usr/local/bin:/opt/xbmc
export HOME=/root
case "$1" in
start) echo -n "Starting XboxMediaCenter"
setterm -blank 0
/usr/local/bin/XboxMediaCenter.sh
esac
exit 0
Make it executable with:
Code:
sudo chmod 755 XboxMediaCenter
Now we need to link the script to /etc/rc2.d
Code:
ln -s /etc/init.d/XboxMediaCenter /etc/rc2.d/S99XboxMediaCenter
Now let's create a reboot and shutdown script. At /usr/local/bin create Reboot.sh and Shutdown.sh
Code:
#/usr/local/bin/Reboot.sh
#Reboot System
#!/bin/bash
sudo reboot
Code:
#/usr/local/bin/Shutdown.sh
#Shutdown System
#!/bin/bash
sudo shutdown -h now
Now, let's create an lircrc file to allow you to shutdown or reboot with your remote. I use a Microsoft MCE remote so the DVD and RecTV buttons are not used at this time by xbmc so I will use them for reboot and shutdown.
We need the file at /root and it needs to be called .lircrc (note the preceding period)
Code:
# Reboot System
begin
prog = irexec
button = DVD
config = /usr/local/bin/Reboot.sh
end
# Shutdown System
begin
prog = irexec
button = RecTV
config = /usr/local/bin/Shutdown.sh
end
You probably won't need to do the following since xbmc is running as root, but just in case, run visudo and near the bottom of the file, add
Code:
ALL ALL = NOPASSWD:/sbin/reboot, /sbin/shutdown
Now, to clean everything up, run the following:
Code:
sudo apt-get clean
sudo apt-get autoclean
sudo localepurge
sudo reboot
If all goes well, you typed everything correctly, and I didn't leave anything out, the system should reboot and come up directly in xbmc. It takes about 20 seconds for xbmc to come up on my hardware.