umask problems with daemon version

Ask for help and report issues not specific to either the Mac OS X or GTK+ versions of Transmission
Post Reply
dpstyles
Posts: 1
Joined: Sun Aug 16, 2009 9:09 pm

umask problems with daemon version

Post by dpstyles »

Hi

Why is my umask setting of 0 being ignored by my transmission-daemon...?

I have upgraded to 1.73 from my original 1.5 deb version on Ubuntu 9.04 as I really wanted umask support. I think I have set up everything correctly but the downloaded files ignore the umask setting. I have set my transmission_home to the dir with the settings file in it. It appears to load this file correctly as transmission-daemon -d shows me:

.....
"rpc-whitelist-enabled": 0,
"speed-limit-down": 100,
"speed-limit-down-enabled": false,
"speed-limit-up": 100,
"speed-limit-up-enabled": false,
"umask": 0,
"upload-limit": 50,
"upload-limit-enabled": 1,
"upload-slots-per-torrent": 14
}

I am still using the default init.d script that 1.5 deb installs and it is run under the debian-transmission user and group. However my problem is that umask 0 seems to be ignored. What am I doing wrong?

Thanks in advance
Jordan
Transmission Developer
Posts: 2312
Joined: Sat May 26, 2007 3:39 pm
Location: Titania's Room

Re: umask problems with daemon version

Post by Jordan »

I don't have a Debian based system, but I've heard that Debian/Ubuntu have the daemon script keep its settings in /var/lib/transmission-daemon. You might try editing the config.json file found in there.
volenin
Posts: 16
Joined: Sat Feb 07, 2009 5:44 pm

Re: umask problems with daemon version

Post by volenin »

The same problem here. The daemon setting USED to work (I believe in 1.72), but once 'umask' setting in the settings file got introduced, the daemon setting is seemed to be ignored.

Startup string for daemon with UMASK set:

Code: Select all

    start-stop-daemon --chuid $USERNAME --start --pidfile $PIDFILE --make-pidfile \
            --exec $DAEMON --background --umask $DUMASK --test -- -f $TRANSMISSION_ARGS > /dev/null \
            || return 1
The $DUMASK setting used to work with previous version of the Transmission. Now, it seems to be ignored. Also, whenever I try to set 'umask' in the settings.json file, the daemon either doesn't start:

Code: Select all

"umask": "002",
Or the setting is ignored

Code: Select all

"umask": 2,

Has anyone else run into the same issue with Ubuntu/Linux headless release of the transmission?
LastMile
Posts: 2
Joined: Wed May 06, 2009 11:39 pm

Re: umask problems with daemon version

Post by LastMile »

I have the same problem running the 1.74 ikpg of Transmission on a QNAP NAS.

I edit settings.json, restart the daemon and unmask is back at the default 18.
olmari
Posts: 3
Joined: Tue Sep 15, 2009 12:19 pm

Re: umask problems with daemon version

Post by olmari »

Me too have this umask problem with transmission-daemon and Ubuntu (server 9.04) + stable repository of "deb http://ppa.launchpad.net/transmissionbt/ubuntu jaunty main" which contains transmission-daemon version 1.74 (8994) at the moment...

If I put

Code: Select all

"umask": 022,
to the /etc/transmission-daemon/info/settings.json I get following error when running "/etc/init.d/transmission-daemon start"

Code: Select all

 * Starting bittorrent daemon transmission-daemon
[15:18:44.115] JSON parser failed in /var/lib/transmission-daemon/info/settings.json at line 52, column 15: "22, 
    "upload"
Also additionally whole settings.json is like messed up after that... It starts to have settings a) totally diffirently than they was before and b) diffirent than per default they was...

Also if I put (with quotes)

Code: Select all

"umask": "022",
transmission-daemon says it starts succesfully, no error this time, but yet webinterface is unavailable, thus it isn't working either...

So something really is messed up there... From what I could intrepet I think it messes up with that zero and next line in question...

Code: Select all

line 51: "speed-limit-up-enabled": false,
line 52: "umask": 18,
line 53: "upload-limit": 100,
and error is referring to line 52, the umask option and to term "upload" which is part of next line... If this was any help :)
Jordan
Transmission Developer
Posts: 2312
Joined: Sat May 26, 2007 3:39 pm
Location: Titania's Room

Re: umask problems with daemon version

Post by Jordan »

json doesn't allow octal notation. Use 18 instead; octal 22 == decimal 18
olmari
Posts: 3
Joined: Tue Sep 15, 2009 12:19 pm

Re: umask problems with daemon version

Post by olmari »

Hmm... Does it read somewhere at the wiki? I didn't seem to notice it but that wouldn't be new...
LastMile
Posts: 2
Joined: Wed May 06, 2009 11:39 pm

Re: umask problems with daemon version

Post by LastMile »

LastMile wrote:I edit settings.json, restart the daemon and unmask is back at the default 18.
It would help if I killed transmission-daemon before trying to edit the setting.json. Edited and reloaded settings.json while Transmission wasn't running and everything works fine.
Post Reply