[Solved] Upload Permission errors on non-root subsonic user

Need help? Post your questions here.

Moderator: moderators

[Solved] Upload Permission errors on non-root subsonic user

Postby jaquense » Mon Mar 14, 2011 4:19 am

Ok, I am sure there is a simple fix here and im just not seeing it...

I'm getting a Permission denied: /var/music/subsonic/unsorted_music/uploaded/blah.mp3 error after switching my subsonic server (stand alone linux) from a root user to it's own user/group (subsonic/subsonic)

I had assumed (and still do...) that it was a permission error at the upload location which was set to my main user. I have since changed the /var/music folder to the subsonic group (chown -R :subsonic /var/music) figuring that would fix it but to no avail. Looking at the permissions everything looks good as far as I can tell, but I'm still new to Linux and the strict permissioning paradigm is still new to me so i could be off...

Thoughts?

SOLUTION

Ok after all my thoughts about it being Linux permissions related it was actually a Subsonic Limitation. My "upload" directory was not located in one of my music folders, which is apparently a safety feature, or rather a security feature built into SS. SO when I added said folder into my subsonic music folders I got it to work.

I understand the limitation and it's reason since you are exposing the upload path to the user you must at least impose some limits so they don't go trying to upload stuff elsewhere on my computer. BUT wouldn't the better solution be to obscure the path from Users and run SS on a "jetty" user for standalone Linux installs?
Last edited by jaquense on Wed Apr 06, 2011 4:29 pm, edited 1 time in total.
jaquense
 
Posts: 47
Joined: Tue Dec 28, 2010 7:06 pm

Postby 3R3 » Tue Mar 15, 2011 2:27 pm

Try to change user AND group ownage on your upload/music path like so:
Code: Select all
chown -R user:group /your/path/

And of course make sure the user that SS logs in as/is executed from is the same as the owner of the folder you're trying to upload to.
User avatar
3R3
 
Posts: 332
Joined: Mon May 04, 2009 2:09 pm
Location: Germany

Postby Skidd » Tue Mar 15, 2011 6:50 pm

You also need to make sure the group has write privileges on your directory.

Code: Select all
chmod -R ug+rw /var/music/subsonic/unsorted_music/uploaded/


That will give the directory both read and write privs to the users and groups of that path.

But, what you might do is set that var folder to be owned by the subsonic user, and then grant any users who need rw in that folder access to the group.

chown -R subsonic:subsonic /var/music/subsonic

Then, if you need to grant any local users access to that folder, just add them to the subsonic system group
Skidd
 
Posts: 15
Joined: Wed Mar 09, 2011 10:07 pm

Postby jaquense » Fri Apr 01, 2011 8:04 pm

Ok I'm back at this issue which I THOUGHT I had fixed.

I now have a more or less vanilla subsonic server running on an Apache2 Tomcat6 combo

I have set the permissions to the /var/music/unsorted_music/uploaded folder to full rwx on both the owner and group, them being tomcat6:tomcat6

I have tried combos of permissions and user:groups but no dice!

This is weird, considering I am having no problems with permissions on anything else server related
jaquense
 
Posts: 47
Joined: Tue Dec 28, 2010 7:06 pm

Postby jaquense » Mon Apr 04, 2011 6:37 pm

shameless bump!
jaquense
 
Posts: 47
Joined: Tue Dec 28, 2010 7:06 pm


Return to Help

Who is online

Users browsing this forum: No registered users and 27 guests