jangjong's Subsonic (4.8) Plugin


Recommended Posts

Hi Guys!

 

If you guys have been following this thread: http://lime-technology.com/forum/index.php?topic=17092.0 for the Subsonic thread, you probably have noticed that the OP hasn't really updated the plugin for a couple months.

 

The plugin was good and it worked "out of the box", but it still had some major issues that need to be addressed. I tried to fix these issue.. and ended up rewriting a lot of the plugin! Here is what my plugin offers over ajax's subsonic :

 

Features:

  • ffmpeg: Ajax had alien build of ffmpeg 0.6. Although this is probably the simplest ffmpeg for slackware, it didn't work with video, so I had to update it to something else. With a lot of tries and errors, I found out that Slacky build of ffmpeg 0.8.11 worked the best. This made flac files or video files to work "out of the box". No need for 2 steps encoding
  • Unicode Support: Added the script to use UTF-8 for the language settings. This enables non-english title music and some special characters in the title
  • Auto Restart on Boot: Rewrote the plugin to start when the server boots up
  • Using Google Code for Hosting: I'm using Google Code for hosting, so there shouldn't be any problems with broken links.
  • HTTPS Option: Added an option to use HTTPS port
  • Run as nobody by default: 4.6 doesn't have this message, but 4.7 beta 2 does not recommend using 'root' user to run subsonic. It is better to use nobody to run the plugin anyway, so i made this default
  • JRE included: Instead of installing jre plugin, I have included JRE in the plugin so it will install initially. If you don't have any other plugins using JRE and if you're coming from the old subsonic plugin, it's safe to delete the jre plugin.

 

I tried to make my plugin to be compatible with ajax's plugin as much as possible so the upgrade can be simple as replacing the plg file, but I may have missed something, so if you're having some problem, I suggest deleting /boot/config/plugin/subsonic/subsonic.cfg and reinstall the plugin.

 

Also, if you're having problems with opening Subsonic page even after few minutes of starting it, disable it and enable it again to restart it. This may happen if you were trying to upgrade from the older plugin that has different cfg settings.

 

Installation:

  • Save plugin as: /boot/config/plugins/subsonic-4.8-6.0jj.plg
  • If you're upgrading from an older version, make a back up of the current installation folder.
  • Type via putty or command line: installplg /boot/config/plugins/subsonic-4.8-6.0jj.plg
  • Subsonic may not start right away, so please give a minute or two for it to initialize and run

 

 

Download:

Version 4.8 (NEWEST): https://unraid-subsonic-plugin.googlecode.com/files/subsonic-4.8-6.0jj.plg

Version 4.7: https://unraid-subsonic-plugin.googlecode.com/files/subsonic-4.7-5.1jj.plg

 

 

Supersonic (See https://github.com/Mach5/supersonic for more info):

http://unraid-subsonic-plugin.googlecode.com/files/supersonic-4.7b1-1.0jj.plg

 

Changelog:

07/09/2012 3.0 - Rewrote Ajax's Subsonic plug in.

08/23/2012 3.1 - Replaced 4.7 beta 2 with beta 3.

09/17/2012 4.0 - Upgraded it to use Subsonic 4.7

09/18/2012 4.1 - Fixed it to extract the right file

02/07/2013 5.1 - Fixed it to use sh command to run sh to avoid the permission issue

04/21/2014 6.0 - Upgraded to Version 4.8

 

Please let me know if there are any problems.

Link to comment
  • Replies 219
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Posted Images

I wanted to let you know that I just test this plugin and it is working great for me. I installed 4.7 beta 2 on 5.0-rc4.

 

I had an issue where FLAC and m4a files would not download to completion on my android devices. Probably had something to do with ffmpeg versions. Either way, after using your plugin the issue cleared up and I'm back to trouble free subsonic-ing.

 

UTF-8 addition is also making my life 10x better. Thank you for that. I don't have to go file spelunking to change all my song names.

Link to comment

I wanted to let you know that I just test this plugin and it is working great for me. I installed 4.7 beta 2 on 5.0-rc4.

 

I had an issue where FLAC and m4a files would not download to completion on my android devices. Probably had something to do with ffmpeg versions. Either way, after using your plugin the issue cleared up and I'm back to trouble free subsonic-ing.

 

UTF-8 addition is also making my life 10x better. Thank you for that. I don't have to go file spelunking to change all my song names.

 

Ah! Finally! A comment from a user.. this was what I was waiting for all day lol

Yea.. I started fixing the plugin mainly because of UTF-8 usage.. I had too many songs that just won't display correctly... but then ended up writing the whole thing lol

 

Anyway, I am glad you're enjoying it!

Link to comment

Thanks for the updated install script. I updated successfully to Subsonic 4.7b2 from 4.6

 

ffmpeg 0.8.11 replaced ffmpeg-0.10.2 that I used to use which worked with Subsonic. I will keep ffmpeg 0.8.11 since it did not break anything on my server.

Link to comment

Slight issue, though it could have been my fault. I installed your plugin, updated to 4.7b2, and then started subonic, but subsonic wasn't actually updated. So I tried stopping it, and it says it's not running, but it actually is.

 

It might have been my fault because I didn't stop subsonic before updating the plugin. I haven't tried rebooting yet. Is that my next step?

Link to comment

Great work! I've been using a hacked up version of the old plugin myself to run the 4.7 betas so its nice to see it in a plugin!

 

It all seems to be working fine (and the ffmpeg fix of running .8 is great, i thought id tried every version, up to .11 and i still had to do the two step flac encoding so great work there!)

 

One slight problem though is the unicode characters, i have the letter "ä" in a few of my files, and they still come up unplayable (unless i change it to just "a" of course) Should this not be happening? perhaps ive done something wrong? (Had installed it ontop of previous plugin version - So just pointed it to the same directory)

 

Great work either way! Subsonic is one of my most used applications on my unraid box, so its nice to see it being supported actively!

Link to comment

Sorry for the late reply.. I just moved in to a new apt and does not have internet for now lol. so I had to wait till I came to work..

 

Good to see people are having good result with my plugin!

 

Great work! I've been using a hacked up version of the old plugin myself to run the 4.7 betas so its nice to see it in a plugin!

 

It all seems to be working fine (and the ffmpeg fix of running .8 is great, i thought id tried every version, up to .11 and i still had to do the two step flac encoding so great work there!)

 

One slight problem though is the unicode characters, i have the letter "ä" in a few of my files, and they still come up unplayable (unless i change it to just "a" of course) Should this not be happening? perhaps ive done something wrong? (Had installed it ontop of previous plugin version - So just pointed it to the same directory)

 

Great work either way! Subsonic is one of my most used applications on my unraid box, so its nice to see it being supported actively!

 

That's interesting.. I will look into it and see what i can do

Link to comment

Sorry for the late reply.. I just moved in to a new apt and does not have internet for now lol. so I had to wait till I came to work..

 

Good to see people are having good result with my plugin!

 

Great work! I've been using a hacked up version of the old plugin myself to run the 4.7 betas so its nice to see it in a plugin!

 

It all seems to be working fine (and the ffmpeg fix of running .8 is great, i thought id tried every version, up to .11 and i still had to do the two step flac encoding so great work there!)

 

One slight problem though is the unicode characters, i have the letter "ä" in a few of my files, and they still come up unplayable (unless i change it to just "a" of course) Should this not be happening? perhaps ive done something wrong? (Had installed it ontop of previous plugin version - So just pointed it to the same directory)

 

Great work either way! Subsonic is one of my most used applications on my unraid box, so its nice to see it being supported actively!

 

That's interesting.. I will look into it and see what i can do

 

Just a quick update, it seems to be all unicode characters are continuing to not show up properly  (Showing up as folders instead + unknown characters.

 

E.g:

 

03 Basshunter - Strand Tyl??sand.mp3

05 Basshunter - Hall?? d??r.mp3

06 Basshunter - Mellan oss tv??.mp3

07 Basshunter - Var ??r jag.mp3

08 Basshunter - Utan stj??rnorna.mp3

 

Alias.S01E05.Doppelg??nger.SD.DVD.avi

 

just a few examples from places i remember the problem files being (however there are more, can get a more extensive list if it helps)

 

Still, can you think of any possible reason as to the fault? i have JRE 1.7.0_02 if that could possibly be an issue too.

 

Seems strange that the encoding wouldn't work! Has anybody else had issues with unicode support?

Link to comment

Just a quick update, it seems to be all unicode characters are continuing to not show up properly  (Showing up as folders instead + unknown characters.

 

E.g:

 

03 Basshunter - Strand Tyl??sand.mp3

05 Basshunter - Hall?? d??r.mp3

06 Basshunter - Mellan oss tv??.mp3

07 Basshunter - Var ??r jag.mp3

08 Basshunter - Utan stj??rnorna.mp3

 

Alias.S01E05.Doppelg??nger.SD.DVD.avi

 

just a few examples from places i remember the problem files being (however there are more, can get a more extensive list if it helps)

 

Still, can you think of any possible reason as to the fault? i have JRE 1.7.0_02 if that could possibly be an issue too.

 

Seems strange that the encoding wouldn't work! Has anybody else had issues with unicode support?

 

Very strange.. That's the problem that my plug in should have fixed.

 

Try this and see if this helps at all..

 

Connect to your unRAID server via telnet or ssh.. then

 

/etc/rc.d/rc.subsonic stop

export LANG="en_US.utf8"
export LANGUAGE="en_US.utf8"
export LC_CTYPE="en_US.utf8"

/etc/rc.d/rc.subsonic start

 

This is what I had to do to get the unicode working on the older subsonic plug in. This script should be already in my plugin but I'm wondering if there are any other plug ins that you use is reverting the setting some how.

 

Also, JRE shouldn't really matter as I have included that version in my plug in.

 

I'm guessing you're having problem with 'Diaeresis' http://en.wikipedia.org/wiki/Diaeresis_(diacritic)

 

Are you having the problem with any other characters?

 

--Edit

 

I just tried 'Doppelgänger' as a file name for one of my video file and it's working fine.. Let me know if above script helps at all.

Link to comment

Very strange.. That's the problem that my plug in should have fixed.

 

Try this and see if this helps at all..

 

Connect to your unRAID server via telnet or ssh.. then

 

/etc/rc.d/rc.subsonic stop

export LANG="en_US.utf8"
export LANGUAGE="en_US.utf8"
export LC_CTYPE="en_US.utf8"

/etc/rc.d/rc.subsonic start

 

This is what I had to do to get the unicode working on the older subsonic plug in. This script should be already in my plugin but I'm wondering if there are any other plug ins that you use is reverting the setting some how.

 

Also, JRE shouldn't really matter as I have included that version in my plug in.

 

I'm guessing you're having problem with 'Diaeresis' http://en.wikipedia.org/wiki/Diaeresis_(diacritic)

 

Are you having the problem with any other characters?

 

--Edit

 

I just tried 'Doppelgänger' as a file name for one of my video file and it's working fine.. Let me know if above script helps at all.

 

Hm, yeah i just tried that and its still having the same problems. Quite an odd little problem. I can't remember ever setting a location or anything in unraid but it couldn't be messed up by the en_US when not using 'US' - Only saying this because i've had this problem before using another linux distro (However i don't think unraid has any others like en_GB etc and defaults at US i assume?)

 

It's really quite strange that it doesn't do it, just to check that the plugin hadn't defaulted back to the old one the SSL port works perfectly fine, so its definitely following the plugin design fine.

 

Is there any files leftover perhaps from the ajax3712 version that could perhaps have interfered with this bit? Like an old rc.d file or something like that? (I deleted the old .plg, turned subsonic off and deleted the /plugins/subsonic/ folder before installation of new version)

 

However it did install to my old subsonic dir, so using my old database etc. Is the encoding set inside here perhaps? (And thats why its messing up?)

 

 

I'm not too familiar with unraids code etc so i'm not really sure where to start looking for this! Either way like i said before, great work on the plugin working flawlessly for me apart from this issue, and it seems im the only one with this issue (somehow! :P Same OS with everyone, yet i still get a weird bug! Just my luck! haha :D)

Link to comment

Hm, yeah i just tried that and its still having the same problems. Quite an odd little problem. I can't remember ever setting a location or anything in unraid but it couldn't be messed up by the en_US when not using 'US' - Only saying this because i've had this problem before using another linux distro (However i don't think unraid has any others like en_GB etc and defaults at US i assume?)

 

It's really quite strange that it doesn't do it, just to check that the plugin hadn't defaulted back to the old one the SSL port works perfectly fine, so its definitely following the plugin design fine.

 

Is there any files leftover perhaps from the ajax3712 version that could perhaps have interfered with this bit? Like an old rc.d file or something like that? (I deleted the old .plg, turned subsonic off and deleted the /plugins/subsonic/ folder before installation of new version)

 

However it did install to my old subsonic dir, so using my old database etc. Is the encoding set inside here perhaps? (And thats why its messing up?)

 

 

I'm not too familiar with unraids code etc so i'm not really sure where to start looking for this! Either way like i said before, great work on the plugin working flawlessly for me apart from this issue, and it seems im the only one with this issue (somehow! :P Same OS with everyone, yet i still get a weird bug! Just my luck! haha :D)

 

Strange. This may sound stupid.. but have you rebooted your server?

 

It is possible that some how rc.d file got mixed up, but that's only if you haven't restarted the machine. I recommend restarting the machine if you haven't already.

 

Now.. let me get some more info about your server.

 

While you have Subsonic enabled.. connect to telnet/ssh and type in

 

locale -a

 

What do you get?

 

also.. what do you get when you run this

 

echo $LANG

 

 

--Edit

What you could also try is..

 

Instead of en_US, you can try to use en_GB like this

 

/etc/rc.d/rc.subsonic stop

export LANG="en_GB.utf8"
export LANGUAGE="en_GB.utf8"

/etc/rc.d/rc.subsonic start

See if this works too

 

 

Make sure you re-scan media folders too.. In 4.7 beta 2, it's under Settings -> Media Folders -> Scan media folders now

Link to comment

Strange. This may sound stupid.. but have you rebooted your server?

 

It is possible that some how rc.d file got mixed up, but that's only if you haven't restarted the machine. I recommend restarting the machine if you haven't already.

 

Now.. let me get some more info about your server.

 

While you have Subsonic enabled.. connect to telnet/ssh and type in

 

locale -a

 

What do you get?

 

also.. what do you get when you run this

 

echo $LANG

 

 

--Edit

What you could also try is..

 

Instead of en_US, you can try to use en_GB like this

 

/etc/rc.d/rc.subsonic stop

export LANG="en_GB.utf8"
export LANGUAGE="en_GB.utf8"

/etc/rc.d/rc.subsonic start

See if this works too

 

 

Make sure you re-scan media folders too.. In 4.7 beta 2, it's under Settings -> Media Folders -> Scan media folders now

I had rebooted the server since, however to be safe i did it again.

 

Upon new boot up $LANG was showing as en_US.UTF-8 (not en_US.utf8) so i changed it with export LANG="en_US.utf8" however it still seems fine.

 

 

You mentioned rescanning,

Could it be possibly leftover from the old scanning of the media files though? Since these files have been here the whole time? Could it be it recognizes them and just doesn't update them in the db since they're already there? (And thus not update with the actual name.) Is there a way to delete the db of files from subsonic so they're all scanned again (Without loosing my users preferably! :P)

 

 

Edit:

 

Yes, it seems any old encodings are left inside the subsonic.data file in the db folder, i deleted this file and restarted the server and rescanned my media and now they are coming up properly! Hallelujah! :P So anybody updating from the old plugin version and keeping their old files may also experience this same problem

 

Link to comment

Edit:

 

Yes, it seems any old encodings are left inside the subsonic.data file in the db folder, i deleted this file and restarted the server and rescanned my media and now they are coming up properly! Hallelujah! :P So anybody updating from the old plugin version and keeping their old files may also experience this same problem

 

Oh very good! :D Thanks for the info too!

 

I will update my OP with this information later for people that's upgrading from the older version

Link to comment
  • 3 weeks later...

hi all, plugin had been working great now i keep getting error, which is persistent after stop/start of plugin and also reboot of whole server and i am at a loss even though i am sure it is something simple

error msg =

 

HTTP ERROR: 503

 

SERVICE_UNAVAILABLE

 

RequestURI=/

 

Powered by jetty://

 

any ideas?

please let me know if you need more information or logs, thanks

 

edit: in the mean time i just created a new install folder and all is working from there, but i would rather use old folder with all of my settings

Link to comment

hi all, plugin had been working great now i keep getting error, which is persistent after stop/start of plugin and also reboot of whole server and i am at a loss even though i am sure it is something simple

error msg =

 

HTTP ERROR: 503

 

SERVICE_UNAVAILABLE

 

RequestURI=/

 

Powered by jetty://

 

any ideas?

please let me know if you need more information or logs, thanks

 

edit: in the mean time i just created a new install folder and all is working from there, but i would rather use old folder with all of my settings

 

Can you post the content of your subsonic.cfg file?

 

Also, did you upgrade from the older subsonic plugin? or was it fresh install

 

Edit---------

 

http://forum.subsonic.org/forum/viewtopic.php?t=3054)#p32465

 

I found this. Looks like it could possibly be corrupted db file. Try that and see if it helps at all.

 

Did you have a power failure recently by any chance? or did you try going back and forth with 4.6 and 4.7 beta 2? I think going from 4.7 beta 2 to 4.6 may cause some problem. Not too sure about going from 4.6 to 4.7 beta 2 though.

Link to comment

any plans to update this to 4.7b3 or just waiting for the final version?

 

I did not realize that came out.

 

I barely have any time to work on anything these days because of some family matter.. but when I get free, I will definitely work on this.

 

Hopefully by next week.

Link to comment

any plans to update this to 4.7b3 or just waiting for the final version?

 

I did not realize that came out.

 

I barely have any time to work on anything these days because of some family matter.. but when I get free, I will definitely work on this.

 

Hopefully by next week.

 

thanks for the update.  i hope that your family matter is better or resolved.

Link to comment

Hi there, I just found out about subsonic and was hoping to install it on my unraid server having never used it before, I followed the instructions as per the first post for installation and upon doing so get this error

 

root@unRAID:~# installplg /boot/config/plugins/subsonic-4.6-3.0jj.plg

installing plugin: subsonic-4.6-3.0jj

 

Warning: simplexml_load_file(): I/O warning : failed to load external entity "/b

oot/config/plugins/subsonic-4.6-3.0jj.plg" in /usr/local/sbin/installplg on line

13

xml parse error

root@unRAID:~#

 

any advice on how to proceed?

 

Regards

Link to comment

Hi there, I just found out about subsonic and was hoping to install it on my unraid server having never used it before, I followed the instructions as per the first post for installation and upon doing so get this error

 

root@unRAID:~# installplg /boot/config/plugins/subsonic-4.6-3.0jj.plg

installing plugin: subsonic-4.6-3.0jj

 

Warning: simplexml_load_file(): I/O warning : failed to load external entity "/b

oot/config/plugins/subsonic-4.6-3.0jj.plg" in /usr/local/sbin/installplg on line

13

xml parse error

root@unRAID:~#

 

any advice on how to proceed?

 

Regards

 

Where did you save this plg file? Did you put it here: \\tower\flash\config\plugins ?

 

That error comes up when you try to run installplg with a wrong path. for example, when i just type some random path, i get the similar message:

 

root@VTower:~# installplg /boot/config/lalalala.plg

installing plugin: lalalala

 

Warning: simplexml_load_file(): I/O warning : failed to load external entity "/boot/config/lalalala.plg" in /usr/local/sbin/installplg on line 13

xml parse error

root@VTower:~#

 

 

So please check where you saved the file and what you saved it as.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.