Transmission Download Folder Permission

Status
Not open for further replies.

Frankyyyyy

Cadet
Joined
Mar 1, 2014
Messages
2
Hey guys

Having an issue that has got me a little stuck at the moment.
Have been using FreeNAS for a few days and have setup Transmission. Ran a couple downloads an have noticed that when a torrent creates a new directory in my torrent download folder, folder permissions are set to 755.

I have created the transmission user and group in FreeNAS and set the download directory group owner to transmission. Everything else seem to be working fine.

My thoughts were a umask issue, but when I set it to 000 to test I didn't see any difference... Maybe doing it wrong...

su transmission
Umask 000 when in the download/ directory.

Any help is appreciated.
 

marcevan

Patron
Joined
Dec 15, 2013
Messages
432
Do this in this order:

1. Edit your jails storage thru Storage/Volumes/View Volumes - scroll to bottom to find jail for transmission and edit permissions setting user/group to root/wheel recursively.
2. Edit your downloads and torrent files storages like above (the one's in your main dataset) and set the permissions user/group to nobody/nobody recursively
3. Go to your jails via Jails/View Jails and get the listing for all and select transmission and do command line right to thee jail.
4. Where you setup your local storage for tranmission's downloads and torrents, go there (e.g., I have /mnt/downloads and /mnt/torrentfiles, so I go to /mnt). Do an ls -l and see if it's all good. It should be but post if it's not.

For transmission, you should have set it up by turning off the plugin and editing the config.json to kill the 18 to 0 near the end. See the post you used for the guide. Save that and restart the plugin.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
this isn't a freenas specific questions so it should be directed at the transmission forums. But I'll be nice =]
Code:
"umask": 0,
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Yeah, I didn't create a new user, as the plugins natively get root/wheel.

Storage in jails is same permission as where you mount from and in my case that's nobody/nogroup.

I have transmission downloading now and I checked on command line has 777 for it's downloads directory, the download it's doing, yet it continuously cries of permissions problems.

the plugins don't run as root/wheel by default. transmission, by default runs as the user 'transmission' in the jail.
 

marcevan

Patron
Joined
Dec 15, 2013
Messages
432
My bad in explaining.

Go to the storage for the jail and that's what I meant by owner/group. It should be root/wheel. That's the freenas way. You have to see that if you change jail ownership it back changes the main volumes storage if you do it recursively. Then go back to nobody/nogroup your main /downloads and /torrentfiles.
 

Frankyyyyy

Cadet
Joined
Mar 1, 2014
Messages
2
Hey guys sorry for the delayed reply.

Thanks for your answers. After a but of sleep I came at it with a fresh mind and ended up changing the settings.json umask.

Upon checking the thread again that was what Joshua was recommending.

Working now.

Thanks again.
 

Supa

Patron
Joined
Jan 10, 2014
Messages
204
I'm having issues. But i'm not sure how to debug it. I have unmask set to 0 as well.

Main problem is once the file is completed they aren't moved to my download folder.

KWpuOFy.png



I have set the permission on the /media/torrents and /media/downloads to this: (or does it have to be root/wheel?)

CEFoORE.png

2O3uJ3q.png
0EdL4sZ.png



I'm just not sure what transmission is even doing.... or if it's even trying to move the files. Where do I view it's logs?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I'm having issues. But i'm not sure how to debug it. I have unmask set to 0 as well.

Main problem is once the file is completed they aren't moved to my download folder.

KWpuOFy.png



I have set the permission on the /media/torrents and /media/downloads to this: (or does it have to be root/wheel?)

CEFoORE.png

2O3uJ3q.png
0EdL4sZ.png



I'm just not sure what transmission is even doing.... or if it's even trying to move the files. Where do I view it's logs?


  • I assume it's logs would be in /usr/pbi/transmission-amd64/etc/transmission/Home/, though I don't know for sure.
  • I suggest you verify the config actually have your settings saved, they should be in "/usr/pbi/transmission-amd64/etc/transmission/Home/settings.json". One issue that FreeNAS' transmission plugin has is if you change settings while the service is running, FreeNAS will overwrite them. The only way I have around this is changeing available settings in the FreeNAS WebUI, then changing unavailable settings in the config file while transmission is off. In my opinion this is a bug cause it forces users to the command line when there normally easier ways.
  • another suggestions is you don't move files between datasets after completion. because of the way torrents work you are missing out on just having the file renamed to the new location. Your setup transmission wanting to move the download to a different filesystem (which is a read-write operation) when a simple move (metadata change) would work.
/media/downloads/transmission/incomplete
/media/downloads/transmission/complete/*category
/media/*category
the media folder is the dataset. no unnecessary read-write operations.
 

Supa

Patron
Joined
Jan 10, 2014
Messages
204
  • I assume it's logs would be in /usr/pbi/transmission-amd64/etc/transmission/Home/, though I don't know for sure.
  • I suggest you verify the config actually have your settings saved, they should be in "/usr/pbi/transmission-amd64/etc/transmission/Home/settings.json". One issue that FreeNAS' transmission plugin has is if you change settings while the service is running, FreeNAS will overwrite them. The only way I have around this is changeing available settings in the FreeNAS WebUI, then changing unavailable settings in the config file while transmission is off. In my opinion this is a bug cause it forces users to the command line when there normally easier ways.
  • another suggestions is you don't move files between datasets after completion. because of the way torrents work you are missing out on just having the file renamed to the new location. Your setup transmission wanting to move the download to a different filesystem (which is a read-write operation) when a simple move (metadata change) would work.
/media/downloads/transmission/incomplete

/media/downloads/transmission/complete/*category
/media/*category
the media folder is the dataset. no unnecessary read-write operations.



Yeah that must be it. I had to reinstall the plugin and was only doing the changes in the gui. Forgot that it doesn't overwrite the transmission config file. This is the 2nd setup I've done and I only made multiple datasets because that one guide mentioned to do so. I'll see if this works and if not i'll just go back to one dataset.


I orignally had 1 dataset.. but my permissions got messed up once I recursively set them because the jails were there.
 

marcevan

Patron
Joined
Dec 15, 2013
Messages
432
Should always let the owner/group of the jail dataset be (as per defauly) root/wheel.

Then the storage in the jail and the original dataset you clone/mount should be guest/guest in most cases (like CIFS guest usage).
 

JKman

Explorer
Joined
Mar 23, 2014
Messages
52
it has been said before but guest/guest permissions are not a good idea. most of the posts i see on here propose, and many say bad idea. no one offers an alternative so i will provide a brief explanation of how i figured out a better way.

i have setup transmission, sabnzbd, and sickbeard so far using this method.

1) in freenas setup a user:group called media:media with both ID's set to 816 (as this is what the plugin jails setup internally as).
2) then setup a transmission user:group with ID's 921, then make it an auxillary group member of media. (also add the media user to transmission group -- don't know if this is necessary but did it anyways).
3) setup a media dataset with owner:group to media:media, tick read and execute boxes for all, tick write boxes for only owner and group. (this is important as it will not let guest accounts delete files!!!!! this is what you want! YEAAAAAA). Also tick set permissions recursively.
4) setup all your plugins (wont go into detail here as there are many posts on the subject). for transmission go into the jail, service stop transmission, go into the settings.json and change unmask to 2, then service start transmission (otherwise settings.json won't save properly).
5) finally, do a reboot just to make sure it all sticks. i had to because i did things out of order, but i think this order will not require one.

note: i think sabnzbd might be changing the directory permissions on my downloads/incomplete folder. looking for a suggestion on how to fix that setting, as otherwise it might mess up the transmission downloading.
 

Tenek

Explorer
Joined
Apr 14, 2014
Messages
97
Can someone please give a bit more information media (816) user and group. From where it is coming?
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
Can someone please give a bit more information media (816) user and group. From where it is coming?
It's a arbitrary name and UID for a user I create with several of the freenas plugins. many of the plugins use it to run by default, but this can be changed in a jail's rc.conf.
 
Status
Not open for further replies.
Top