Linux Standalone startup

Frequently asked questions.

Moderator: moderators

Linux Standalone startup

Postby Xenstar » Thu Oct 16, 2008 10:42 pm

Hi,

Has anyone had success in getting the standalone version of subsonic to start on bootup on a linux box?

I have tried a few things with /etc/init.d scripts but it always seem to cause problems. I can start the subsonic app from a shell with no problems otherwise.

If you have I would be most appreciative if you could share your findings

Ideally I'm not wanting to use the Tomcat version.
Xenstar
 
Posts: 2
Joined: Thu Oct 16, 2008 10:39 pm

Postby jigsaw » Sat Oct 18, 2008 3:00 pm

If you can start the standalone version from shell, than it should be merely a matter of configuration to make it start at boot up. I'm running the tomcat version myself and am happy with it, but I can't imagine it should be too much of work to set it up.

If init-scripts seems to fail then maybe the environment is different in your user-shell than when the init-script is run? Also if you have your music on mounted drives it is important to do the mounting before launching subsonic.

Can you think of anything else that's different when launching from shell, that may help you to identify the problem.
Hope that helps.. :)
Currently without Subsonic due to hardware failure :(
User avatar
jigsaw
 
Posts: 242
Joined: Sat Oct 13, 2007 12:01 pm
Location: Stavanger, Norway

Postby Xenstar » Sat Oct 18, 2008 5:02 pm

Hi thanks for the advice.

Thus far I can get the script to start from init.d, but no matter what I try it does not kickoff as a background process, therefore causing the whole bootup to halt. I have tried adding & after the subsonic.sh statement, but it still doesn't work.

I think I may try the Tomcat version after all. It will make startup a lot more simple.

Thanks again
Xenstar
 
Posts: 2
Joined: Thu Oct 16, 2008 10:39 pm

Postby jigsaw » Sun Oct 19, 2008 12:45 am

How did you set up your init.d?
If you create the configuration file for subsonic in init.d correctly and add it to chkconfig it should start at boot up in the background automatically.. Usually it's wise to start it up as one of the last scripts.
Which OS are you running?
Currently without Subsonic due to hardware failure :(
User avatar
jigsaw
 
Posts: 242
Joined: Sat Oct 13, 2007 12:01 pm
Location: Stavanger, Norway

Postby Matts » Sat Nov 15, 2008 3:22 pm

Hi,

I personally launch Subsonic on Debian with a line in /etc/rc.local :

Code: Select all
daemon -u www-data --name=subsonic -D /var/subsonic/launcher /var/subsonic/launcher/subsonic.sh


Works for me, hope this helps.
Matts
 
Posts: 18
Joined: Sat Nov 15, 2008 2:07 pm

Postby tfruitz » Sat Nov 29, 2008 3:13 am

I used debian's (etch) "startup programs" Found in the "Sessions" menu. To do so just add the command to run subsonic from there. etc, "sh /path/to/subsonic.sh"

A few tweaks necessary in subversion.sh file for this to work:
1) In the first line, add "cd /path/to/", the path to subsonic-something.jar file.
2)For version 3.5, the line in subsonic.sh is missing a "\" character just after "-Dsubsonic.home=${SUBSONIC_HOME}"
3)Then add the line, "-Djava.awt.headless=true \" below so that subsonic can run without X11.
tfruitz
 
Posts: 6
Joined: Thu Nov 27, 2008 10:51 pm

Postby pino_otto » Sun May 24, 2009 10:04 am

I solved the problem simply using the "nohup" command in front of the start command (/var/subsonic/standalone/subsonic.sh) in the file /etc/rc.local:

nohup /var/subsonic/standalone/subsonic.sh
exit 0

I hope this can help you.
________
Last edited by pino_otto on Thu Feb 03, 2011 5:25 am, edited 1 time in total.
pino_otto
 
Posts: 8
Joined: Sun May 24, 2009 9:57 am

Postby pouriaalmassi » Tue Dec 01, 2009 4:55 pm

the following worked for me. using ubuntu 9.10. should work on any *nix.

open terminal
$ crontab -e

add the following to the end:
#start subsonic at boot
@reboot /var/subsonic/subsonic.sh
pouriaalmassi
 
Posts: 1
Joined: Tue Dec 01, 2009 4:45 pm

autostart inOpenSuse 11.2

Postby daniell » Fri Jan 15, 2010 4:53 pm

I still have problems with autostart of subsonic.sh in OpenSuse 11.2
Cant find where to put the startup routine..
Anybody.. pls..
daniell
 
Posts: 90
Joined: Fri Nov 13, 2009 6:44 am
Location: Stavanger, Norway

OpenSuSE initscript

Postby touchstone » Mon Mar 15, 2010 12:19 am

I previously posted the initscript I'm using with OpenSuSE 11.1 here. It's not perfect, but works for me.
touchstone
 
Posts: 2
Joined: Mon Feb 15, 2010 11:02 pm

Postby widgeteye » Sun Jan 30, 2011 4:24 pm

pouriaalmassi wrote:the following worked for me. using ubuntu 9.10. should work on any *nix.

open terminal
$ crontab -e

add the following to the end:
#start subsonic at boot
@reboot /var/subsonic/subsonic.sh



WINNER! for the best and simplest idea.

"and what does he win Johnny?"

"A BRAND NEW CARRRR!!!" :D
widgeteye
 
Posts: 20
Joined: Wed Dec 29, 2010 1:38 am


Return to FAQs

Who is online

Users browsing this forum: No registered users and 12 guests