top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

How can a user change default file creation permission ?

+1 vote
340 views

Is there any way to change default permission of file creation in linux ?

posted Nov 17, 2015 by Vikram Singh

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

0 votes

In Linux/Unix shells (bash or sh) we have umask which controls the file creation permission. Say you set the umask to 022 as

$ umask 022

New files created would be with the permission of 755 (777 & !022)

answer Nov 18, 2015 by Salil Agrawal
Similar Questions
+2 votes

What happens if I am installing over an existing system. I have a directory on its own /home partition

/home/username

During installation it ask to set an Administrator user. One of the options is "Create a home directory for this user". What happens here if the directory already exist, will it be erased? Or will the installer use the existing directory?

...