Archive:HOW-TO:Install XBMC on Ubuntu/HOW-TO 1: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
>D4rk
No edit summary
 
(104 intermediate revisions by 31 users not shown)
Line 1: Line 1:
The purpose of this guide is to give a hand to new XBMC users, who want to build a Linux based, dedicated [http://en.wikipedia.org/wiki/Home_theater_PC HTPC (Home Theater PC)], a true living-room media center computer, but don't have any knowledge and experience in the Linux world.
{{outdated}}
The following is the recommended way of installing XBMC as a standalone app for Ubuntu. This is not the most stripped down approach but it is the safest and most simplistic. Please also consider XBMC Live as an easy way to try XBMC without changing your system. For a more stripped down approach, consider the more advanced guide XBMCbuntu which starts with a minimal server install.


You always have the chance to try [[XBMC Live]] to test/demo XBMC Media Center, but if you want to have more control and more customization possibilities, than a Linux installation like in this guide is more suitable.
This guide assumes that desktop based Ubuntu (Gnome, KDE, XFCE) is installed and working and that your system meets the minimum requirements for XBMC. If you're having trouble getting to this point please visit [http://ubuntuforum.org Ubuntu Forums] for help.


= Introduction =
[http://www.loggn.de/ubuntu-xbmc-repository-10-1-dharma-und-11-0-eden-mit-und-ohne-pvr/ XBMC-Repository-Overview] for 8.04, 9.04, 9.10, 10.04, 10.10, 11.04, 11.10 & 12.04 with PVR (Live-TV) and without PVR-Support
This is a real step-by-step guide, I hope everybody can follow and walk through the whole installation procedure. The guide is based on either Ubuntu 8.04 (Hardy Heron) or 8.10 (Intrepid Ibex) as a platform, start with a minimal install and only install the needed components at the top of that.


On the face of it, maybe seems very lengthy process, but you will feel shorter while you follow it.
== Installing XBMC Ubuntu 9.10 Karmic or higher ==
'''Note:''' You find newer XBMC packages on this [http://www.loggn.de/ubuntu-xbmc-repository-11-eden-airplay-pvr-livetv/ Repository-Overview] for Ubuntu 12.04 and older.


'''Please note:'''
If you are using Ubuntu 9.10 or higher, you have the option of a more streamlined install. Load the terminal window and issue the following:
* The guide is for using XBMC on a dedicated HTPC, so there is no window manager and/ or any additional applications installed.
* You need minimum 4GB size Flash drive or harddisk drive to install on.
* Since you will use this PC only as a [http://en.wikipedia.org/wiki/Media_center media center]. I therefor assume that you use digital audio pass-through (S/PDIF or HDMI) to a receiver/amplifier with built-in Dolby Digital (AC3) decoder, and hence I choose NOT to install the dependency libraries for PulseAudio and compile XBMC later without PulseAudio support.


'''You will get:'''
<source lang="bash">
* A dedicated HTPC which auto-boots directly to XBMC Media Center.
sudo apt-get install python-software-properties pkg-config
* Latest XBMC SVN version.
sudo add-apt-repository ppa:team-xbmc
* Updated ALSA (audio) driver.
sudo apt-get update
* Updated VIDEO (graphics) driver.
sudo apt-get install xbmc xbmc-standalone
* LIRC (Microsoft MCE Remote will work out-of-the-box, however if you have any other remotes and/or LCD displays then you are on your own to solve the individual LIRC and LCDproc issues).
sudo apt-get update
* Suspend/resume (works perfectly on for example ASUS P5N7A-VM motherboard with Intrepid).
</source>


'''Known issues:'''
You do not need to add the XBMC Repo nor the PPA Keys. XBMC is already installed. To have content, go to Adding the XBMC SVN Repo Installer (not to be confused with XBMC Repo below).
* Installations based on Intrepid having some performance issues, due to unidetified reason. You can read more on that [http://forum.xbmc.org/showthread.php?t=43075 here].
* You might have some difficulties with suspend/ resume on Hardy based installation


= Preparation =
If you get an error message like <code>xbmc: Depends: xbmc-data (= 2:10.00~svn35648-lucid1) but it is not going to be installed E: Broken packages</code> while doing this, please enable <code>multiverse</code> and <code>multiverse</code> repositores in <code>/etc/apt/sources.list</code>, or go to the System menu, then Administration, then Software Sources and check the "Community-maintained open Source software (universe)" and "Software restricted by copyright or legal issues (multiverse)" checkboxes and apply the changes.
'''FIRST STEP'''<BR>


Download and burn Ubuntu Hardy or Intrepid mini.iso (according to your platform preference) from here:
For NVidia hardware acceleration (VDPAU) in Ubuntu 10.04 install the following packages:
<BR>https://help.ubuntu.com/community/Installation/MinimalCD
<source lang="bash">
sudo apt-get install libvdpau1 nvidia-185-libvdpau
</source>


<span style="color:red">Please be aware, if you are installing a full Ubuntu system with GDM, then the guide will not fully work!</span>
== Adding the XBMC Repo ==
Adding the XBMC Repo tells your system where to look for xbmc for installation and future updates
* From the Desktop, click System -> Administration -> Software Sources.
* Click the "Third Party Software" tab.
* Click "Add" for each of the following. For the Apt line type the following, substituting "jaunty" for your version:
<pre>deb http://ppa.launchpad.net/team-xbmc/ppa/ubuntu jaunty main
deb-src http://ppa.launchpad.net/team-xbmc/ppa/ubuntu jaunty main</pre>
* Click "Close". If you see a GPG Error upon closing the window, not to worry. That will be handled in the next step.


Now perform a default install.
== Adding PPA Keys ==
These packages are signed with a unique key for added security. Synaptic needs to know this key in order to verify the packages' authenticity.
* Click [http://keyserver.ubuntu.com:11371/pks/lookup?op=get&search=0x6D975C4791E7EE5E here] to view the PGP key
* Select the text from the beginning of the keyblock to the end (including those lines)
* Copy that text to the clipboard (Edit -> Copy)
* Open your text editor from Applications -> Text Editor.
* Paste the key contents (Edit -> Paste)
* Save the document in your home folder as xbmc-ppa.key
* Reopen Software Sources, this time choosing the "Authentication" tab.
* Click "Import Key File" and choose the newly created xbmc-ppa.key and press OK.


* '''When asked during the installation, please set „xbmc” as username and password at the account creation.'''
''You can also combine all these steps into a single command-line command:
<source lang="bash">sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0x6d975c4791e7ee5e</source>


* At the end, when you have to choose from the optional components, check only „OpenSSH” to be able to access your HTPC remotely via SSH.
== Installing XBMC ==
Now that the repo and key have been added, install XBMC like any other program.
* Click System -> Administration -> Synaptic Package Manager
* Click "Reload"
* Search for "xbmc"
* Mark xbmc and xbmc-standalone for installation and mark additional changes when prompted.
* Click "Apply" and agree to the changes after reading them.
XBMC is now installed and ready for use.
== Adding the XBMC SVN Repo Installer ==
In Ubuntu the SVN Repositories are not automatically added. You must add them manually.
* First, download the SVN Repo Installer from:
* http://xbmc-addons.googlecode.com/svn/packages/plugins/programs/SVN_Repo_Installer.zip
* Extract it to the ~/.xbmc/plugins/programs directory. If this directory does not exist, run XBMC one time and then exit back to Ubuntu. The directory should now exist.
* Select XBMC Media Center: Applications -> Sound & Video -> XBMC Media Center
* Scroll down to Programs.
* Select program plugins.
* Select SVN Repo Installer
* Select xbmc-addons
* Select plugins
* Choose the plugins that you want to add (i.e., videos)
== Autostart XBMC (optional) ==
By following these instructions, your system will boot directly into XBMC rather than your desktop from now on. '''It is advised that you delay this step until XBMC is setup as you'd like it.
* From the desktop click System -> Administration -> Login Screen
* From the "Security" tab choose "Enable Automatic Login" and select your username.
* Click "OK" to exit.
* Logout of your system.
* From the Login screen choose "Select Session"
* Choose "XBMC" and click "Change Session"
You're finished. Next time you login you should be greeted with XBMC.


''Apparently there seems to be an issue with '''''Intrepid''''' installer. If you are using flash drive, it's not installing GRUB for some reason.'' '''''<BR>This is only affect Intrepid, and only when you are installing it onto a flash drive.'''''
== Autostart XBMC (optional alternative) ==
* From the desktop click System -> Administration -> Login Screen
* From the "Security" tab choose "Enable Automatic Login" and select your username.
* Click "OK" to exit.
* From the desktop click System -> Preferences -> Startup Applications
* Click "Add"
* Name: XBMC
* Command: xbmc
* Comment: XBMC
* Click "OK"
You're DONE, Ubuntu will now load gnome first then xbmc straight after, slightly slower but it keeps your gnome session available.


''To handle this, you have to options:''
'''NOTE:''' It is important to use all lower case characters when entering the command.
# ''Either install Hardy(Ubuntu 8.04) mini.iso first, which is installing GRUB correctly, then right after that, install Intrepid mini.iso over the same flash drive. It will reformat the drive, but GRUB will stay alive on the drive.''
== Weblinks ==
# ''Second option is that right after Intrepid mini installation, boot up Intrepid mini.iso from the CD again, choose rescue mode, and there you will find an "install GRUB" option.''
* [http://www.loggn.de/ubuntu-xbmc-repository-10-1-dharma-und-11-0-eden-mit-und-ohne-pvr/ HOW-TO: Ubuntu – XBMC-Repository-Overview – 10.1 Dharma und 11.0 Eden – with and without PVR] - XBMC-Repository for 8.04, 9.04, 9.10, 10.04, 10.10, 11.04, 11.10 & 12.04
 
* [http://www.loggn.de/all-in-one-howto-ubuntu-10-04-installation-konfiguration-von-nvidia-vdpau-vdr-mit-vnsi-server-xbmc-pvr-testing2/ HOW-TO: HowTo – Ubuntu 10.04 – Installation & Konfiguration von NVIDIA VDPAU, VDR mit VNSI-Server & XBMC PVR-TESTING2] - Hierbei handelt es sich um ein deutsches All-in-One Tutorial wie man XBMC (pvr-testing2) inkl. VDR mit dem VNSI-SERVER und LIRC zum laufen bringt.
After you’ve done, boot it up, then use an SSH application (e.g. putty) to log in remotely from your desktop, using the above created username and password. This way, you will be able to copy/ paste all the steps below. Alternatively you can use console on the htpc too, but then you will have a hard time type in everything.
 
So once you logged in:
 
 
'''First of all, update the repositories, and install all prerequisites:'''
 
'''NEXT STEP'''
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get update
</div>
 
'''NEXT STEP Hardy''' - <span style="color:red">Skip this and jump to '''''NEXT STEP Intrepid''''', if you are installing Intepid</span> <BR>
<div style="height: auto; width: 1000px; overflow:auto; border: thin inset black; background: #E6E6FA">
# sudo apt-get --purge autoremove -y nvidia-kernel-common linux-restricted-modules-generic linux-restricted-modules-common linux-restricted-modules-2.6.24-23-generic
</div>
 
'''NEXT STEP Hardy''' - <span style="color:red">Skip this and jump to '''''NEXT STEP Intrepid''''', if you are installing Intepid</span> <BR>
<div style="height: auto; width: 1000px; overflow:auto; border: thin inset black; background: #E6E6FA">
# sudo apt-get install -y linux-headers-generic localepurge subversion make g++ gcc gawk pmount libtool nasm automake cmake gperf unzip bison libsdl1.2-dev libsdl-image1.2-dev libsdl-gfx1.2-dev libsdl-mixer1.2-dev libsdl-sound1.2-dev libsdl-stretch-dev libfribidi-dev liblzo-dev libfreetype6-dev libsqlite3-dev libogg-dev libasound-dev python-sqlite libglew-dev libcurl4-gnutls-dev x11proto-xinerama-dev libxinerama-dev libxrandr-dev libxrender-dev libmad0-dev libtre-dev libogg-dev libvorbis-dev libmysqlclient15-dev libpcre3-dev libdbus-1-dev libhal-dev libhal-storage-dev libjasper-dev libfontconfig-dev libbz2-dev libboost-dev libfaac-dev libenca-dev libxt-dev libxmu-dev libpng12-dev libjpeg-dev mesa-utils wget zip curl hal build-essential linux-headers-`uname -r` xorg pm-utils
</div>
 
'''NEXT STEP Intrepid'''<BR>
<div style="height: auto; width: 1000px; overflow:auto; border: thin inset black; background: #E6E6FA">
# sudo apt-get install -y localepurge subversion make g++ gcc gawk pmount libtool nasm automake cmake gperf unzip bison libsdl1.2-dev libsdl-image1.2-dev libsdl-gfx1.2-dev libsdl-mixer1.2-dev libsdl-sound1.2-dev libsdl-stretch-dev libfribidi-dev liblzo-dev libfreetype6-dev libsqlite3-dev libogg-dev libasound-dev python-sqlite libglew-dev libcurl4-gnutls-dev x11proto-xinerama-dev libxinerama-dev libxrandr-dev libxrender-dev libmad0-dev libtre-dev libogg-dev libvorbis-dev libmysqlclient-dev libpcre3-dev libdbus-1-dev libhal-dev libhal-storage-dev libjasper-dev libfontconfig-dev libbz2-dev libboost-dev libfaac-dev libenca-dev libxt-dev libxmu-dev libpng12-dev libjpeg-dev mesa-utils wget zip curl build-essential linux-headers-`uname -r` xorg pm-utils
</div>
 
During the installation of the packages, there will be a popup window to choose your locale languages to let "localepurge" know which locales not to remove in further installations. I would suggest to keep all en_us (3 all together) and your own country locales (again should be 3) as well. Localepurge will save you some space with removing unneccessary languages.<BR>
 
= Upgrading ALSA (sound driver) to the latest version =
 
I have modified the ALSA upgrade script (available at Ubuntuforums), and now it is working with only “-di” option in our case here (Also on ASUS P5N7A-VM).
 
To download and use the script:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# wget http://217.20.138.65/xbmc/AlsaUpgrade-1.0.x-rev-1.16.sh
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# chmod a+x AlsaUpgrade-1.0.x-rev-1.16.sh
</div>
 
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo ./AlsaUpgrade-1.0.x-rev-1.16.sh -di
</div>
 
If you are on Intrepid, you have to add the user created at installation to the „audio” group (you don't need to do that in case of Hardy).
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo usermod -a -G audio xbmc
</div>
('''''Please note:''''' replace „xbmc” with username you installed with)
 
<BR>
You also have to edit the following file to make spdif and/or hdmi work properly:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /etc/modprobe.d/alsa-base
</div>
 
and add this line to the end:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
options snd-hda-intel model=6stack-dig
</div><BR>
 
reboot the computer:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo reboot
</div>
 
For some reason, the driver snapshot for ALSA 1.0.19 is not always downloading properly; in this case you have to run the script again. To check whether the driver upgraded or not:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# more /proc/asound/version
</div>
 
If you see driver version 1.0.19 here, you can continue, but it's shows 1.0.17 as driver version, then you have to repeat the last 3 step (upgrade, reboot, check).
 
If it’s OK, then you can delete the just downloaded ALSA source to free up some disk space:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo rm -r /usr/src/Alsa-1.0.19/
</div>
 
Now run alsamixer:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# alsamixer
</div>
 
Navigate right with cursor keys until IEC958 and unmute all three of them (IEC958) with „M” key. You should see in case of all three IEC958 a „00” in green background. Press „ESC” to quit from alsamixer.
 
= Update Video driver =
 
== Nvidia==
 
''(For Ati owners: jump to [[#Ati]])''
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# wget ftp://download.nvidia.com/XFree86/Linux-x86/180.37/NVIDIA-Linux-x86-180.37-pkg1.run
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo sh NVIDIA-Linux-x86-180.37-pkg1.run
</div>
 
In the nvidia installer: accept the License agreement, choose „YES” for „No precompiled kernel interface...”, choose „OK” for „No matching precompiled kernel interface...”, than choose „YES” to update X configuration file, than finally „OK” again at the end.
 
Now you can delete Nvidia installer:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# rm NVIDIA-Linux-x86-180.37-pkg1.run
</div>
 
=== xorg.conf configuration (Nvidia) ===
 
If you want your Xorg autodetect the native resolutions from EDID and want to use 24p you have to replace your xorg.conf with this (not guaranteed to work, but should with newer Nvidia cards):
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.backup
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/xorg.conf -O /etc/X11/xorg.conf
</div>
 
'''''(To continue click on: [[#Download, compile, and install XBMC from source]] (skip section Ati))'''''
 
<BR>
 
== Ati ==
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get install -y cdbs fakeroot dh-make debhelper debconf libstdc++5 dkms
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# wget http://www2.ati.com/drivers/linux/ati-driver-installer-8-12-x86.x86_64.run
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo sh ati-driver-installer-8-12-x86.x86_64.run --buildpkg Ubuntu/intrepid
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo dpkg -i xorg-driver-fglrx_8.561-0ubuntu1_i386.deb fglrx-kernel-source_8.561-0ubuntu1_i386.deb fglrx-amdcccle_8.561-0ubuntu1_i386.deb
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# rm ati-driver-installer-8-12-x86.x86_64.run  *.deb
</div>
 
=== xorg.conf configuration (Ati) ===
Will be discussed later, stay tuned
 
<BR>
 
= Download, compile, and install XBMC from source =
 
'''NEXT STEP''' - <span style="color:red">This is the main trunk, skip to the following step, if you want to use vdpau<BR>
<div style="height: auto; width: 1000px; overflow:auto; border: thin inset black; background: #E6E6FA">
# svn checkout https://xbmc.svn.sourceforge.net/svnroot/xbmc/branches/linuxport/XBMC
</div>
 
In case of Hardy, you will get a certificate warning, accept it permanetly by pressing „P”.
Wait for downloading XBMC source files, might takes long time, depend on your Internet connection.
 
'''OPTIONAL STEP''' - <span style="color:red">In case you want to use vdpau branch, skip if you choosed the main trunk<BR>
'''''You have to have vdpau compatible VGA vard for this with 512MB video ram at least!'''''
<div style="height: auto; width: 1000px; overflow:auto; border: thin inset black; background: #E6E6FA">
# svn checkout https://xbmc.svn.sourceforge.net/svnroot/xbmc/branches/xbmc-vdpau/XBMC
</div>
 
In case of Hardy, you will get a certificate warning, accept it permanetly by pressing „P”.
Wait for downloading XBMC source files, might takes long time, depend on your Internet connection.
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# cd XBMC
</div>
 
Then configure, compile, and install XBMC:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# ./configure --prefix=/usr --disable-pulse
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# make -j2 ('''''Please note''''': use only „make”, if you don’t have a dualcore CPU)
</div>
 
This is again, can take quite some time, depending on your CPU speed.
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo make install
</div>
 
<BR>
 
= Autoboot to XBMC =
 
'''WARNING!!! Do NOT follow this section unless you understand what EVERY step is actually doing.  The original author hasn't thoroughly explained each step. If something goes wrong you WILL NOT be able to easily get to a normal desktop, so if you aren't 100% comfortable with recovering any and all issues in Linux from the command line, THINK TWICE!!!  You can easily setup gdm to auto login and gnome to autostart XBMC.'''
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/xbmc -O /etc/init.d/xbmc
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo chmod a+x /etc/init.d/xbmc
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo update-rc.d -f xbmc defaults
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/runXBMC.sh -O /usr/bin/runXBMC.sh
</div>
If you not choosed "xbmc" as your user at the installation, you have to modify this file according to your username.
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo chmod a+x /usr/bin/runXBMC.sh
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/setAlsaVolumes.py -O /usr/bin/setAlsaVolumes.py
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo chmod a+x /usr/bin/setAlsaVolumes.py
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo dpkg-reconfigure x11-common
</div>
And choose "anyone" to run X. Leave the other question on default.
 
<BR>
 
= Install Lirc =
 
I've found MS MCE Remotes, listed here: http://www.mythtv.org/wiki/MCE_Remote, are plug & plays, working out of the box. I also found, that there're remotes out there, which instalation are a real pain. The choise is yours. If you have one of the above mentioned MS MCE remotes, the installation is that simple:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get install -y lirc
</div>
 
And follow the wizard.
 
<BR>
= Power Management =
 
To be able to control power management (suspend, shutdown, reboot) from within XBMC, you have to modify PolicyKit.conf to grant privilegies to your user for power management. There is a preprepared PolicyKit.conf for this, you can get it by:
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/PolicyKit.conf -O /etc/PolicyKit/PolicyKit.conf
</div>
Please note: if you installed your system with username other than "xbmc" at the begining, you have to modify that in the file.
 
 
If you wish to enable CPU scaling, install the required packages as the following, but '''don’t forget to enable it in the BIOS as well'''.
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get install powernowd
</div>
 
<BR>
 
= Install Splash =
You may want to have a look at du-duke's fantastique splash screens. You can check these here: http://du-duke.blogspot.com/
You can download your choice below.
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get -y install usplash libusplash-dev
</div>
 
'''NEXT STEP Hardy''' - <span style="color:red">Skip this and jump to '''''NEXT STEP Intrepid''''', if you are installing Intepid</span> <BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get -y install usplash-theme-ubuntu
</div>
 
'''NEXT STEP Hardy''' - <span style="color:red">Skip this and jump to '''''NEXT STEP Intrepid''''', if you are installing Intepid</span> <BR>
'''<span style="color:red">CHOICE 1</span> - Downloading spinner-blue'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/splash/usplash-spinner-hardy.so -O /usr/lib/usplash/usplash-theme-ubuntu.so
</div>
 
'''NEXT STEP Hardy''' - <span style="color:red">Skip this and jump to '''''NEXT STEP Intrepid''''', if you are installing Intepid</span> <BR>
'''<span style="color:red">CHOICE 2</span> - Downloading pulsating-logo'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/splash/usplash-pulsating-hardy.so -O /usr/lib/usplash/usplash-theme-ubuntu.so
</div>
 
'''NEXT STEP Intrepid'''<BR>
'''<span style="color:red">CHOICE 1</span> - Downloading spinner-blue'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/splash/usplash-spinner-intrepid.so -O /usr/lib/usplash/usplash-theme-ubuntu.so
</div>
 
'''NEXT STEP Intrepid'''<BR>
'''<span style="color:red">CHOICE 2</span> - Downloading pulsating-logo'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo wget http://217.20.138.65/xbmc/splash/usplash-pulsating-intrepid.so -O /usr/lib/usplash/usplash-theme-ubuntu.so
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /etc/usplash.conf
</div>
 
and set your desired splash resolution, so inserting the following to here.
('''''Please note:''''' this is a FullHD example):
 
<div style="height: auto; border: thin inset black; background: #E6E6FA">
xres=1920<BR>
yres=1080
</div>
 
'''NEXT STEP'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo update-initramfs -u
</div>
 
<BR>
 
= Enable thermal monitoring =
 
To install the necessary package:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get install -y lm-sensors
</div>
 
Once lm-sensors installed, you have to run sensor detection to identify your sensors:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo sensors-detect
</div>
There will be a lot of questions here, but you can answer by "enter" key to all of them, '''except the last question'''.
So answer "enter" to all questions, until you see the the question "Do you want to add these lines automatically?" At here, you have to type "yes", then enter.
 
Reboot the computer:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo reboot
</div>
 
After rebooted, check if the sensors are working:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sensors -u
</div>
You should see the output of the sensors here.<BR>
 
== XBMC CPU temp detection ==
 
To let XBMC detect your CPU temps provided by lm-sensors, you have to edit your advancedsettings.xml and insert the following:
<div style="height: auto; border: thin inset black; background: #E6E6FA">
<advancedsettings> <BR>
<cputempcommand>echo "$(sensors | grep "Core 0" | sed -e 's/[a-z]*..............\([0-9].\)\..*/\1/') C"</cputempcommand> <BR>
</advancedsettings> <BR>
</div> <BR>
 
== XBMC GPU (nvidia) temp detection ==
To let XBMC detect your GPU temps provided by nvidia-settings, you have to edit your advancedsettings.xml and insert the following:
<div style="height: auto; border: thin inset black; background: #E6E6FA">
<advancedsettings> <BR>
<gputempcommand>echo "$(nvidia-settings -tq gpuCoreTemp) C"</gputempcommand> <BR>
</advancedsettings> <BR>
</div>
 
 
<BR>
 
= Enable eject button of your ODD =
 
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /etc/sysctl.conf
</div>
 
and uncomment (by deleting # from the begining of the line) the last line, so it will look like this:
 
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
dev.cdrom.lock=0
</div>
 
<BR>
= Reduce boot time =
 
'''reduce GRUB waiting (~2 sec)'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /boot/grub/menu.lst
</div>
 
Find the timeout (currently set to 3) and change this to 0
 
 
'''reduce the number of loaded vts (virtual terminal service)'''<BR>
 
By default, there're F1 through F7, we don't need that much for a HTPC, so we can remove most of them.
 
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /etc/event.d/tty3
</div>
 
and comment out all the lines, using #.
Repeat the above command for tty4-tty6, so at the end you've deactivated 3 vts's.
 
 
'''Enable concurrent booting (if you own a dual-core CPU)'''<BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /etc/init.d/rc
</div>
 
Find the line "CONCURRENCY=none" and change it to "CONCURRENCY=shell"
 
 
'''Disable unneccessary services'''<BR>
Install the necessary application
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get -y install sysv-rc-conf
</div><BR>
 
And run it:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo sysv-rc-conf
</div>
Navigate with your cursor keys, you can disable services by clearing X in each runlevel by "space" key.<BR>
You can disable the following services:
<BR>
* apparmor<BR>
* dns-clean<BR>
* fancontrol (unless you're using it)<BR>
* pppd-dns<BR>
* rsync<BR>
 
<BR>
 
= BIOS OEM Splash screen =
Recent motherboards usually featured with the possibility to change to BIOS OEM logo. Below you can find a modified XBMC logo. The format and size of the picture has been modified to fit into the BIOS (ASUS P5N7A-VM), '''''there is no guarantee to work with any other motherboard, but I guess it should work with all boards with newer AMI bioses.'''''
 
'''''BE AWARE! I take no responsibility if you brick your motherboard while playing with BIOS.'''''
 
In case of ASUS, you can do it with MyLogo2, which is a bundled tool for your MB.
 
The aspect ratio of the picture is like this for purpose. When your BIOS displays it, it will stretch to fit to the screen. So this is made for 16:9 (not for 4:3, and nor for 16:10)
 
[[Image:Bios splash pwrd by xbmc.jpg|360px|http://217.20.138.65/xbmc/pwrd_by_xbmc_bios_splash.bmp]] [[Image:Bios splash oldFor16x9.jpg|360px|http://217.20.138.65/xbmc/Splash_oldFor16x9.bmp]]
<BR>[http://217.20.138.65/xbmc/pwrd_by_xbmc_bios_splash.bmp Download1] [http://217.20.138.65/xbmc/Splash_oldFor16x9.bmp Download2]
 
 
<BR>
 
= Wake On Lan =
 
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo apt-get install -y ethtool
</div><BR>
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo nano /etc/init.d/wol.sh
</div>
 
Copy the following text into it, then save the file:
 
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
ethtool -s eth0 wol g
</div><BR>
Make this newly created script executable:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo chmod a+x /etc/init.d/wol.sh
</div><BR>
Make it start during boot:
<div style="height: 32px; border: thin inset black; background: #E6E6FA">
# sudo update-rc.d -f wol.sh defaults
</div>
 
<BR>
= Sound configuration in XBMC =
 
After booted into XBMC switch to „digital” audio output, than '''''choose the AC3 and DTS capabilities''''' according to your receiver.
 
<BR>'''''For SPDIF:'''''                                   
<BR>Leave audio output device: default           
<BR>Leave passthrough to IEC958                   
<BR>[[Image:Audio_iec958_default_1.jpg]]
<BR> 
 
'''''For HDMI:'''''
<BR>Change audio output device to hdmi
<BR>Change passthrough to hdmi
<BR>[[Image:Audio hdmi.jpg|Audio hdmi.jpg]]
<BR>(you will loose analog sound eg. navigation sound in case of hdmi)
<BR>
 
= MythTV =
 
You may want to have a look at here:
 
http://wiki.xbmc.org/?title=MythTV

Latest revision as of 22:11, 17 June 2020

Time.png THIS PAGE IS OUTDATED:

This page or section has not been updated in a long time, no longer applies, refers to features that have been replaced/removed, and/or may not be reliable.

This page is only kept for historical reasons, or in case someone wants to try updating it.

The following is the recommended way of installing XBMC as a standalone app for Ubuntu. This is not the most stripped down approach but it is the safest and most simplistic. Please also consider XBMC Live as an easy way to try XBMC without changing your system. For a more stripped down approach, consider the more advanced guide XBMCbuntu which starts with a minimal server install.

This guide assumes that desktop based Ubuntu (Gnome, KDE, XFCE) is installed and working and that your system meets the minimum requirements for XBMC. If you're having trouble getting to this point please visit Ubuntu Forums for help.

XBMC-Repository-Overview for 8.04, 9.04, 9.10, 10.04, 10.10, 11.04, 11.10 & 12.04 with PVR (Live-TV) and without PVR-Support

Installing XBMC Ubuntu 9.10 Karmic or higher

Note: You find newer XBMC packages on this Repository-Overview for Ubuntu 12.04 and older.

If you are using Ubuntu 9.10 or higher, you have the option of a more streamlined install. Load the terminal window and issue the following:

sudo apt-get install python-software-properties pkg-config
sudo add-apt-repository ppa:team-xbmc
sudo apt-get update
sudo apt-get install xbmc xbmc-standalone
sudo apt-get update

You do not need to add the XBMC Repo nor the PPA Keys. XBMC is already installed. To have content, go to Adding the XBMC SVN Repo Installer (not to be confused with XBMC Repo below).

If you get an error message like xbmc: Depends: xbmc-data (= 2:10.00~svn35648-lucid1) but it is not going to be installed E: Broken packages while doing this, please enable multiverse and multiverse repositores in /etc/apt/sources.list, or go to the System menu, then Administration, then Software Sources and check the "Community-maintained open Source software (universe)" and "Software restricted by copyright or legal issues (multiverse)" checkboxes and apply the changes.

For NVidia hardware acceleration (VDPAU) in Ubuntu 10.04 install the following packages:

sudo apt-get install libvdpau1 nvidia-185-libvdpau

Adding the XBMC Repo

Adding the XBMC Repo tells your system where to look for xbmc for installation and future updates

  • From the Desktop, click System -> Administration -> Software Sources.
  • Click the "Third Party Software" tab.
  • Click "Add" for each of the following. For the Apt line type the following, substituting "jaunty" for your version:
deb http://ppa.launchpad.net/team-xbmc/ppa/ubuntu jaunty main
deb-src http://ppa.launchpad.net/team-xbmc/ppa/ubuntu jaunty main
  • Click "Close". If you see a GPG Error upon closing the window, not to worry. That will be handled in the next step.

Adding PPA Keys

These packages are signed with a unique key for added security. Synaptic needs to know this key in order to verify the packages' authenticity.

  • Click here to view the PGP key
  • Select the text from the beginning of the keyblock to the end (including those lines)
  • Copy that text to the clipboard (Edit -> Copy)
  • Open your text editor from Applications -> Text Editor.
  • Paste the key contents (Edit -> Paste)
  • Save the document in your home folder as xbmc-ppa.key
  • Reopen Software Sources, this time choosing the "Authentication" tab.
  • Click "Import Key File" and choose the newly created xbmc-ppa.key and press OK.

You can also combine all these steps into a single command-line command:

sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0x6d975c4791e7ee5e

Installing XBMC

Now that the repo and key have been added, install XBMC like any other program.

  • Click System -> Administration -> Synaptic Package Manager
  • Click "Reload"
  • Search for "xbmc"
  • Mark xbmc and xbmc-standalone for installation and mark additional changes when prompted.
  • Click "Apply" and agree to the changes after reading them.

XBMC is now installed and ready for use.

Adding the XBMC SVN Repo Installer

In Ubuntu the SVN Repositories are not automatically added. You must add them manually.

  • First, download the SVN Repo Installer from:
  • http://xbmc-addons.googlecode.com/svn/packages/plugins/programs/SVN_Repo_Installer.zip
  • Extract it to the ~/.xbmc/plugins/programs directory. If this directory does not exist, run XBMC one time and then exit back to Ubuntu. The directory should now exist.
  • Select XBMC Media Center: Applications -> Sound & Video -> XBMC Media Center
  • Scroll down to Programs.
  • Select program plugins.
  • Select SVN Repo Installer
  • Select xbmc-addons
  • Select plugins
  • Choose the plugins that you want to add (i.e., videos)

Autostart XBMC (optional)

By following these instructions, your system will boot directly into XBMC rather than your desktop from now on. It is advised that you delay this step until XBMC is setup as you'd like it.

  • From the desktop click System -> Administration -> Login Screen
  • From the "Security" tab choose "Enable Automatic Login" and select your username.
  • Click "OK" to exit.
  • Logout of your system.
  • From the Login screen choose "Select Session"
  • Choose "XBMC" and click "Change Session"

You're finished. Next time you login you should be greeted with XBMC.

Autostart XBMC (optional alternative)

  • From the desktop click System -> Administration -> Login Screen
  • From the "Security" tab choose "Enable Automatic Login" and select your username.
  • Click "OK" to exit.
  • From the desktop click System -> Preferences -> Startup Applications
  • Click "Add"
  • Name: XBMC
  • Command: xbmc
  • Comment: XBMC
  • Click "OK"

You're DONE, Ubuntu will now load gnome first then xbmc straight after, slightly slower but it keeps your gnome session available.

NOTE: It is important to use all lower case characters when entering the command.

Weblinks