MyiHome - Installing in Linux

From NMTWiki

Jump to: navigation, search

Image:Yellowvsmall.jpg Medium difficulty requiring some technical skills, or some parts require more than basic knowledge.

Installing myiHome in Linux

(The following specifically refers to Ubuntu/Debian systems. Please feel free to add your own distro's details!)


Download myiHome for Linux

from http://www.networkedmediatank.com/download/myihome_download_note.html.

Note that Linux (and Mac) versions seem to lag behind Windows. This is normally due to java versions not being available for Mac or Linux OS.


Unpack it

Right-click on the icon and choose Extract Here.


Open a console window

Type...

 java -version

to determine what version you're running. According to the latest docs (v5.0.2) you need either Java 1.5 or 1.6.

WARNING, WARNING: Under Ubuntu you'll get a return something like;

 java version "1.5.0"
 gij (GNU libgcj) version 4.3.2

GIJ is not true Java and myiHome doesn't seem to work with it!

(GIJ is the GNU Interpreter for Java, a free bytecode interpreter. Because "real" Java requires you agree to a license agreement, it's often not included by default in Linux distributions.)

Before you rush off and install Java, try this as you may already have a usable version installed;

 sudo update-alternatives --config java

Here's what I got under a default Ubuntu install; There are 2 alternatives which provide `java'.

 Selection    Alternative
 ------------------------
         1    /usr/bin/gij-4.3
 *+      2    /usr/lib/jvm/java-gcj/jre/bin/java
 
 Press enter to keep the default[*], or type selection number: 

Nothing there suggests a Sun version of Java, so I need to install it


Install Java

To install Java, enter this in the console window...

 sudo apt-get install sun-java6-jre

and follow the prompts.


Select the correct alternative

Now retry

 sudo update-alternatives --config java

This time there are 3 alternatives...

 Selection    Alternative
 ---------------------------------------------
         1    /usr/bin/gij-4.3
 *+      2    /usr/lib/jvm/java-gcj/jre/bin/java
         3    /usr/lib/jvm/java-6-sun/jre/bin/java
 
 Press enter to keep the default[*], or type selection number: 

Ah ha! Number 3 looks a likely candidate. To double-check, retry...

 java -version
 java version "1.6.0_10"
 Java(TM) SE Runtime Environment (build 1.6.0_10-b33)
 Java HotSpot(TM) 64-Bit Server VM (build 11.0-b15, mixed mode)

We're there!


Start myiHome

Still in the console, go into the myiHome folder you unpacked in step 2. Type

 ./startserver.sh

to start myiHome. (Don't forget intelligent tab-completion in Linux means you really only have to type "./st" plus the Tab key.)


Stop it again

myiHome should now start by throwing up a bunch of messages concluding something like;

 [Server@53ad085]: To close normally, connect and execute SHUTDOWN SQL
 [Server@53ad085]: From command line, use [Ctrl]+[C] to abort abruptly

Hit [Ctrl]+[C] to shut it down.


Set your own libraries

Part of its first-time start-up process creates a preferences folder in ~/Library/myiHome/preference.xml. Open it with the command...

 gedit ~/Library/myiHome/preference.xml

or in KDE...

 kate ~/Library/myiHome/preference.xml
Add the locations of your video, music and photo files in the following format;
 <?xml version="1.0" encoding="UTF-8"?>
 
 <config>
   <key name="Theme" value="deepblue"/>
   <key name="VideoPath" value="/home/user/tv"/>
   <key name="AudioPath" value="/home/user/mp3"/>
   <key name="PhotoPath" value="/home/user/photos"/>
 </config>


You're away!

Simply restart myiHome. Go to your NMT, give it a few seconds and hit the Source button on the remote. Your myiHome server should now show up!

Personal tools