Transmission’s stupid uMask!

Leave a comment

September 11, 2015 by aubreykloppers

If ever you have set-up transmission (in this case on OMV), you will find a little box with 18 filled in stating umask.

What is umask?:

umask is the mask the user uses when creating a file or a folder.  In transmission’s case it is 0022, but being as cryptic possible it is actually in octal, so it is 18.  And that is all you have to know… (Trust me, I am an engineer)

The 0022 mask defined: Assigns permissions so that only you have read/write access for files, and read/write/search for directories you own. All others have read access only to your files, and read/search access to your directories.

Ok, now what, you ask?  Easy.  Log into a linux box, set your umask to 0022, create a file and a directory and it should translate to this:

# umask; umask 0022; mkdir test1; > test; ls -al
0022
total 12
drwxr-xr-x 3 root root 4096 Sep 11 10:18 .
drwx—— 4 root root 4096 Sep 11 09:06 ..
-rw-r–r– 1 root root 0 Sep 11 10:18 test
drwxr-xr-x 2 root root 4096 Sep 11 10:18 test1

To get a proper RW mask, all you have to do is set your mask to 0:

# umask; umask 0; mkdir test1; > test; ls -al
0022
total 12
drwxr-xr-x 3 root root 4096 Sep 11 10:19 .
drwx—— 4 root root 4096 Sep 11 09:06 ..
-rw-rw-rw- 1 root root 0 Sep 11 10:19 test
drwxrwxrwx 2 root root 4096 Sep 11 10:19 test1

NOTES:

  • umask – The command by itself will display your current mask…
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: