How To Setup Default umask Under Linux?

Umask is the number subtracted from the standard permissions when creating a file. Example: each new folder is by default created with 777, so when umask is set to 022, the result is that the permissions will be 777 – 022 = 755.

Most of the time umask will already be set by your distro to 022 but you can change it if you like. You can see what umask value is set with:

# umask

If you want to change umask for temporally,

# umask 0044

Note: These value will stay until you log out and then return to its default value.
To make it permanent, edit /etc/bashrc or to your ~/.bash_profile.

For more information Click here


  1. hi...Im student from Informatics engineering nice article,
    thanks for sharing :)

  2. Ты мудак чтоли? Смотри википедию говно!

  3. to make it global isnt it /etc/login.defs not bashrc?

  4. but how to edit? What caracter I have add???