How To Set Umask In Linux?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The umask (user file-creation mask) is a command in Linux and other Unix-like operating systems that determines which file permissions are set for newly created files. The umask command sets the default permissions for newly created files and directories.
To set umask in Linux, first open a terminal window and type umask followed by the desired permissions and press enter. For example, to set the umask to 022, type:
umask 022
The umask is now set to 022. To verify, type umask again and press enter:
umask
022
The umask is now successfully set to 022.