Kodi Community Forum

Full Version: Run XBMC on an UnRAID server, without a GUI?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
I've seen some folks talk about running XBMC in headless mode, most of the time they are interested in still using it to output audio.

I'm wondering if it would be possible to get XBMC up and running on an UnRAID server for a few reasons:
  1. Always on instance of XBMC
  2. Handle Library Updates (invoked by Sickbeard, Couchpotato, etc.)
  3. Serve Media via UPNP (this way files are nicely organized via the library, over UPNP)

Surely I can't be the first person to want to do something like this. The main motivation here is that I'm moving over to Apple TV's as my clients, which don't handle updating the Library well. Currently I'm just leaving an instance of XBMC open on a mac I have running, but I'd like to move it to my Unraid server instead, which is where I think this belongs.

Not sure what dependencies would all be needed, but it would be nice if someone could point me in the right direction to building a .pkg that I could use in my UnRAID go script, to get XBMC running on it.

Thanks! Smile
pulseaudio is network capable, this might be a way to go, but I didnt dig further into it:

https://wiki.archlinux.org/index.php/Pul...er_network
Thanks... I'm not even interested in making audio work over LAN. All i want XBMC to do on the server is be able to update the library (I'm using mysql database) and scrape TV/Movie info for the library updates. It would be a nice to have if it could act as a UPNP server too, but that's not really necessary.

I guess I just need to know the proper way to get XBMC to run without a gui Smile
XBMC will not run headless, xbmc has never or will never be designed to work as a server, it is a frontend.

You can install it most likely and you can run it but it will require opengl and will take up ALOT of resources for just serving media.
I use mediatomb for upnp on my server.
And a nfs share, that contains all files of the xbmc database. My 3 clients mount this share as their own database and update it at every boot. As there are many clients the updating is shared and takes 2 seconds at boot up.

But I am not sure about the mysql database Huh
topfs2 Wrote:XBMC will not run headless, xbmc has never or will never be designed to work as a server, it is a frontend.

You can install it most likely and you can run it but it will require opengl and will take up ALOT of resources for just serving media.

I understand that the GUI isn't really going away. I'm just interested in getting it to run even if technically opengl is still running, although I'm not sure that would be possible without a desktop manager?

The resources aren't a huge deal with a decent server. I guess the question then is can it be installed and run without a desktop manager? I'm thinking no.

derechteversus Wrote:I use mediatomb for upnp on my server.
And a nfs share, that contains all files of the xbmc database. My 3 clients mount this share as their own database and update it at every boot. As there are many clients the updating is shared and takes 2 seconds at boot up.

But I am not sure about the mysql database

Yeah I've checked out mediatomb, it looks great, but I just wish it or another UPNP server would support reading from an XBMC database for the library. That's why I like using XBMC. It has all my media info in its database complete with thumbs, fanart, etc. It really make a perfect UPNP server for me! Having said that, I'm really using XBMC clients in most places I would need upnp these days, so I guess the concept of UPNP is a bit unnecessary for me at this point. Thanks for the suggestion!
The following tut might be a good place to start: http://lime-technology.com/forum/index.php?topic=11473.0

This post might also be of interest to you, http://forum.xbmc.org/showpost.php?p=668...tcount=104
Redth Wrote:I understand that the GUI isn't really going away. I'm just interested in getting it to run even if technically opengl is still running, although I'm not sure that would be possible without a desktop manager?

The resources aren't a huge deal with a decent server. I guess the question then is can it be installed and run without a desktop manager? I'm thinking no.

As long as you have X on the server and start XBMC within that it will work, you probably should have some GPU in the system though. Be sure to minimize XBMC as then we skip rendering which will take down useage quite a bit, its still going to use ALOT compared to proper service designed apps but work it will.
lithiumc Wrote:The following tut might be a good place to start: http://lime-technology.com/forum/index.php?topic=11473.0

Yessssss! People are quoting my post...

I think you can achieve what you want with your setup by a) doing the whole centralizing thing, and b) installing XBMC Library Autoupdate Script. This script will update your library at your specified interval time. You need to do it only on one machine.

The super nice thing is that if you use SABNZBD, Couch Potato and Sickbeard, you can configure and THEY will update the library once they download something. You do not need step b) above.


Another nice discovery, in CP, you can set the Movie folder SAB will put movies in. If you get a movie from someplace else, you simply copy it to this folder and without any prompting CP will copy it to where you store your media and add the metadata and artwork and updates the library.

I cannot say enough great things about CP and SB.
hernandito Wrote:Yessssss! People are quoting my post...

I think you can achieve what you want with your setup by a) doing the whole centralizing thing, and b) installing XBMC Library Autoupdate Script. This script will update your library at your specified interval time. You need to do it only on one machine.

The super nice thing is that if you use SABNZBD, Couch Potato and Sickbeard, you can configure and THEY will update the library once they download something. You do not need step b) above.


Another nice discovery, in CP, you can set the Movie folder SAB will put movies in. If you get a movie from someplace else, you simply copy it to this folder and without any prompting CP will copy it to where you store your media and add the metadata and artwork and updates the library.

I cannot say enough great things about CP and SB.

That is a fantastic post Smile

However, it's still not exactly what I'm suggesting.... Right now here's my setup:
  • UnRAID Server (Files, MySql XBMC db, Cron jobs)
  • Apple TV 2g (Upstairs)
  • Apple TV 2g (Downstairs)
  • Mac Desktop (Runs the XBMC Library updates)

So you can see I have 4 devices. The Mac only runs XBMC (minimized) just so that it can do library updates (I have sickbeard and couchpotato setup to invoke library updates on the Mac). I also have a cron job setup on my unraid server that uses curl to invoke library updates on the mac.

I think you can see where I'm going with this. I don't actually use XBMC on the mac, it's always minimized/hidden. I'd rather not have to leave my mac on 24/7, or even need it at all in the future. I'd love to be able to move this instance of XBMC onto the unraid server, and have library updates happen there.

I suppose the other way to look at it is if and when the AppleTV becomes able to do library updates on its own, I could just let both of them do updates. Issue here is I won't always have xbmc running on the AppleTV's, but it's not a huge deal, I don't mind doing updates on demand. The issue now is I can't do library updates from the Apple TV's...
But you can have one of your ATV2 do the library updates... remember your XBMC library, your XBMC and your unRAID Media (MySql, CP, and SB) are all separate. Any XBMC client can update the library.

If you have CP running in unRAID, it will update the library for you. You tell CP the IP address of one of your ATV XBMCs and when it downloads and finishes, your entire media library gets updated as its centralized. If CP did NOT download the movie, simply copy the movie to the folder specified in CP as your SAB Downloaded movies folder (not your media folder). CP will read this folder and scrape, and move the file to your media folder, AND update the XBMC library...

ATV can update the media library today... and if your library is centralized, you only do it once and all your devices get updated.
BTW thisis exactly how I am doing it... I do not have any PC or Mac with XBMC.... I do but only for trying things out first.
hernandito Wrote:But you can have one of your ATV2 do the library updates... remember your XBMC library, your XBMC and your unRAID Media (MySql, CP, and SB) are all separate. Any XBMC client can update the library.

If you have CP running in unRAID, it will update the library for you. You tell CP the IP address of one of your ATV XBMCs and when it downloads and finishes, your entire media library gets updated as its centralized. If CP did NOT download the movie, simply copy the movie to the folder specified in CP as your SAB Downloaded movies folder (not your media folder). CP will read this folder and scrape, and move the file to your media folder, AND update the XBMC library...

ATV can update the media library today... and if your library is centralized, you only do it once and all your devices get updated.

The outstanding issues thread indicates that library scanning/scraping is not stable on iOS yet? Perhaps that's outdated info?

The other issue then is what happens if none of the ATV's are running, or have XBMC running? Well then the library doesn't get updated Confused
Redth Wrote:The outstanding issues thread indicates that library scanning/scraping is not stable on iOS yet? Perhaps that's outdated info?

The other issue then is what happens if none of the ATV's are running, or have XBMC running? Well then the library doesn't get updated Confused

I have not had any issue. I have scraped my entire movie library a couple times prior to doing the MySQL centralizing. I did have my media scraped by Media Center Master originally. This put all the NFOs and fanart in the same folders with my .mkv movie file. When you scrape initially with ATV and it has that stuff there, it just reads it and does not download anything. The scrapes are already accurate and there is nothing to fix on the library.

If you centralize, you will loose that library but adding it is just as simple a process. I have over 500 movies and about 300 TV episodes.

Then when you add movies to library, it is CP or SB that takes care of the scraping They also put nfo, thumbnails, and fanart right in the movie folder as well. Then they invoke an XBMC library update on the ATV and again it reads from unRAID stored metadata.

If your XBMC device is off... library will not get updated, but the metadata is accompanying your movie. Whenever you update, it will update without scraping online.
hernandito Wrote:I have not had any issue. I have scraped my entire movie library a couple times prior to doing the MySQL centralizing. I did have my media scraped by Media Center Master originally. This put all the NFOs and fanart in the same folders with my .mkv movie file. When you scrape initially with ATV and it has that stuff there, it just reads it and does not download anything. The scrapes are already accurate and there is nothing to fix on the library.

If you centralize, you will loose that library but adding it is just as simple a process. I have over 500 movies and about 300 TV episodes.

Then when you add movies to library, it is CP or SB that takes care of the scraping They also put nfo, thumbnails, and fanart right in the movie folder as well. Then they invoke an XBMC library update on the ATV and again it reads from unRAID stored metadata.

If your XBMC device is off... library will not get updated, but the metadata is accompanying your movie. Whenever you update, it will update without scraping online.

Right, ok I do let SB and CP download the info, so that explains why it did seem to work on my Apple TV, although I found it very slow to scrape... come to think of it though I think I was running it on wifi only when I tried that, it should be faster on wired. Going to plug it in today and try again!
Pages: 1 2