Subsonic Forum Forum Index Subsonic Forum

 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   SmartFeedSmartFeed   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to install Subsonic on FreeNAS
Goto page 1, 2, 3  Next
 
Post new topic   Reply to topic    Subsonic Forum Forum Index -> Tutorials
View previous topic :: View next topic  
Author Message
sindre_mehus



Joined: 29 Nov 2005
Posts: 1138
Location: Oslo, Norway

PostPosted: Tue Jan 13, 2009 5:49 pm    Post subject: How to install Subsonic on FreeNAS Reply with quote

This tutorial explains how to install Subsonic on the popular FreeNAS server.

The following was done with Subsonic 3.6 and FreeNAS 0.69. Note that a "full", not "embedded" FreeNAS installation is required. Make sure to allocate enough disk space on the OS partition. Java and Subsonic requires at least 150MB.

In terms of hardware requirements, you probably need at least 750MHz CPU and 180MB RAM.

Step 1: Download Java JRE (or JDK) package from http://www.freebsdfoundation.org/downloads/java.shtml

Step 2: Install dependent packages first:
Code:
$ pkg_add -v -r xtrans
$ pkg_add -v -r xproto
$ pkg_add -v -r xextproto
$ pkg_add -v -r javavmwrapper

Step 3: Install the JRE (the .tbz file is the one you downloaded in step 1)
Code:
$ pkg_add -v diablo-jre-freebsd6.i386.1.6.0.07.02.tbz

Step 4: Download Subsonic standalone version and install it in /var/subsonic/standalone, as described here.

Step 5: In the FreeNAS web interface, go to System > Advanced > Command script and add the following "PostInit" script:
Code:
/var/subsonic/standalone/subsonic.sh

Step 6: Reboot FreeNAS, and go to http://<your-freenas-server>:8080 to start using Subsonic.

Your comments are welcome!


Last edited by sindre_mehus on Thu Jan 29, 2009 9:20 am; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website
AndyD



Joined: 06 Oct 2008
Posts: 5

PostPosted: Thu Jan 29, 2009 1:17 am    Post subject: Reply with quote

Nice one Sindre.
chmod +x subsonic.sh (because I copied from windows probably)

Subsonic is asking for LAME...I can't find the LAME package for FreeBSD....can you help?
Back to top
View user's profile Send private message
AndyD



Joined: 06 Oct 2008
Posts: 5

PostPosted: Thu Jan 29, 2009 9:10 am    Post subject: Reply with quote

Oh..I knew there was something I forgot....

pkg_add -v -r javawmwrapper

doesn't work, I downloaded the package and did it as:
pkg_add -v javawmwrapper.tgz (or whatever it was called.

Also Subsonic doesn't auto start, I've just chmod 777 subsonic.sh to see if that works.
Back to top
View user's profile Send private message
sindre_mehus



Joined: 29 Nov 2005
Posts: 1138
Location: Oslo, Norway

PostPosted: Thu Jan 29, 2009 9:22 am    Post subject: Reply with quote

AndyD wrote:
pkg_add -v -r javawmwrapper
doesn't work


Oops, my mistake - it should be "javavmwrapper", not "javawmwrapper".

(I've corrected the typo in the original post).

Thanks for reporting it!
Back to top
View user's profile Send private message Visit poster's website
heinakenka



Joined: 01 Mar 2009
Posts: 1

PostPosted: Sun Mar 01, 2009 4:22 am    Post subject: Reply with quote

Hi,

Just some clarifying questions:
- which version of Java is right for latest FreeNAS?
- I use windows pc for browsing so what how do I get the Java to the FreeNAS machine? Copy of cource but which directory etc...?
Back to top
View user's profile Send private message
jingy



Joined: 25 Apr 2009
Posts: 1

PostPosted: Sat Apr 25, 2009 10:02 pm    Post subject: AVI,WMV, ASF streaming Reply with quote

Hi! Subsonic is awesome! Does anybody know or can give a step-by-step procedure on how to streaming video formats like avi, asf, wmv etc using freenas server? I'm a total newbie with this transcoding thing but willing to learn. Also, I know my subsonic works beacuse I can stream my mp3s.

Thanks a lot!
_________________
jingyHOMEserver
Back to top
View user's profile Send private message
Kryspy



Joined: 06 Jun 2009
Posts: 1

PostPosted: Sat Jun 06, 2009 11:19 pm    Post subject: Reply with quote

Hi,

What is the reason as to why it cannot run on a embedded install ??

Thanks

Kryspy
Back to top
View user's profile Send private message
rich0805



Joined: 17 Jun 2009
Posts: 11
Location: United Kingdom

PostPosted: Wed Jun 17, 2009 8:36 pm    Post subject: Reply with quote

I am I missing something here?

Step one says download
Step two says install
Step three says the file downloaded in one

So where do I get the files I need to install in two?

Richard
Back to top
View user's profile Send private message
sgx1



Joined: 29 Apr 2009
Posts: 19

PostPosted: Thu Jun 18, 2009 10:11 pm    Post subject: Reply with quote

Using the FreeNAS console, just type in those commands (omitting the $) to download and install the packages from the FreeBSD repository.

Quote:
pkg_add -v -r xtrans
pkg_add -v -r xproto
pkg_add -v -r xextproto
pkg_add -v -r javavmwrapper
Back to top
View user's profile Send private message AIM Address
rich0805



Joined: 17 Jun 2009
Posts: 11
Location: United Kingdom

PostPosted: Fri Jun 19, 2009 8:41 am    Post subject: Reply with quote

Thanks sgx1, I'll give that ago...This is all pretty new to me, I'm more used to DOS and Windows Embarassed

I installed FreeNAS months ago and it has worked perfectly ever since, this will be the first time I have had to go back and do anything!
Back to top
View user's profile Send private message
censu



Joined: 25 Jul 2009
Posts: 2

PostPosted: Sat Jul 25, 2009 7:14 pm    Post subject: Reply with quote

Possible noob question here, but everytime I try to complete Step 3 (installing the Java Runtime), the install begins and runs for about 30 seconds, then gets stuck in a loop prompting me for a yes or no answer to the Java license agreement. I am trying to perform the install using the Advance/Execute command interface in FreeNAS. I have uploaded the JRE .tbz to an FTP site and I am running the code "pkg_add -v <ftp address> diablo-jre-freebsd6.i386.1.6.0.07.02.tbz".

If I am going about this in the completely wrong manner, could someone please post some step by step instructions (written for an idiot Rolling Eyes ) on how to perform the installation?
Back to top
View user's profile Send private message
sgx1



Joined: 29 Apr 2009
Posts: 19

PostPosted: Sun Jul 26, 2009 5:42 pm    Post subject: Reply with quote

The Java installation cannot be done through the web configuration page. It just loops, as you've seen. There may be a way to pipe in the "y", but I've not tested.

Instead, at the FreeNAS computer, you go to the Console option and type in the same pkg_add command, which will go through the same process, but will allow you to enter a response at the prompt.

Alternatively, you can enable SSH in the FreeNAS services, and you can then use TelNet (Windows: Start > Run > CMD > "TelNet <ipaddress> 22") to get to the command line as well. Then, you can run the same pkg_add command.

I hope this helps.

Also, if you're using the newest FreeNAS based off of BSD 7, you can use the JRE for BSD 7 instead.
Back to top
View user's profile Send private message AIM Address
censu



Joined: 25 Jul 2009
Posts: 2

PostPosted: Mon Jul 27, 2009 5:14 am    Post subject: Reply with quote

Well I know I was doing something wrong! Thanks to you, I am now up and running and loving it. Thanks again!
Back to top
View user's profile Send private message
morpheus214



Joined: 27 Jul 2009
Posts: 8

PostPosted: Mon Jul 27, 2009 3:01 pm    Post subject: Reply with quote

It doesnt' work for me.

I tried to install it on FreeNAS v. 0.69.2. I installed the packages needed for java as well as diablo-jre-freebsd6.i386.1.6.0.07.02.tbz. Then i created a folder /var/subsonic/standalone/ and copied the contents from the *.tar.gz into the folder. I set the path for the *.sh file and restarted.

When i opened <myfreenas>:8080 in the browser, nothing happened, so i started the sh-file again through the command --> again nothing.

So i opened the subsonic log:

Code:
118 [main] INFO org.springframework.context.support.ClassPathXmlApplicationContext - Refreshing org.springframework.context.support.ClassPathXmlApplicationContext@34a1fc: display name [org.springframework.context.support.ClassPathXmlApplicationContext@34a1fc]; startup date [Mon Jul 27 14:21:21 GMT 2009]; root of context hierarchy
365 [main] INFO org.springframework.beans.factory.xml.XmlBeanDefinitionReader - Loading XML bean definitions from class path resource [applicationContext-deployer.xml]
Exception in thread "main" org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line 5 in XML document from class path resource [applicationContext-deployer.xml] is invalid; nested exception is org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the declaration of element 'beans'.
   at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:369)
   at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:313)
   at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:290)
   at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:142)
   at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:158)
   at org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:184)
   at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:112)
   at org.springframework.context.support.AbstractXmlApplicationContext.loadBeanDefinitions(AbstractXmlApplicationContext.java:79)
   at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:97)
   at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:411)
   at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:338)
   at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:122)
   at org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:66)
   at net.sourceforge.subsonic.booter.Main.<init>(Main.java:16)
   at net.sourceforge.subsonic.booter.Main.main(Main.java:21)
Caused by: org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the declaration of element 'beans'.
   at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source)
   at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source)
   at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
   at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
   at org.apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unknown Source)
   at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown Source)
   at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
   at org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(Unknown Source)
   at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
   at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
   at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
   at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
   at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
   at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
   at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
   at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:78)
   at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:361)


Does this mean i have the wrong java version? I have no idea what to do now... Do i have to deinstall(how?) java and install another version?

Please help me Confused
Back to top
View user's profile Send private message
sgx1



Joined: 29 Apr 2009
Posts: 19

PostPosted: Mon Jul 27, 2009 4:04 pm    Post subject: Reply with quote

That looks similar to the error message I was getting with the Subsonic 3.7 beta.

Which Subsonic package are you installing?
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    Subsonic Forum Forum Index -> Tutorials All times are GMT
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group