It's not a secret anymore!*
The moose likes Linux / UNIX and the fly likes Mask 022 and 077 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Engineering » Linux / UNIX
Bookmark "Mask 022 and 077" Watch "Mask 022 and 077" New topic
Author

Mask 022 and 077

Enge Chall
Ranch Hand

Joined: Nov 22, 2005
Posts: 30
Can anyone explain the mask 022 and 077 in the .profile on AIX.
How to mask and unmask in AIX ?


Not everything that counts can be counted, and not everything that can be counted counts.
Roy Ben Ami
Ranch Hand

Joined: Jan 13, 2002
Posts: 732
If i'm not mistaken its like the umask command in linux.

Basically it tells the system with which permissions to create new files.
For example, in linux for each file there is a number (several actually) that show the permission of the owner, group and everyone else to read/write and execute the file.
In numbers it is: read=4 write=2 and exec=1

So the number 7 indicates you can read write and exec the file.
The number 5 means you can only read and exec and you get the idea...

The umask is the minus number that gets applied to all new files. So if usally a file is created with 666 permissions (everybody can read and write to it) then a umask of 022 means that the real number it gets created with is 644 - so only you can read/write and the rest can only read.

Hope it made sense and that it is correct for AIX as well.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Mask 022 and 077
 
Similar Threads
Never say die
WA #1.....word association
Upgrade Exam..
Problems with Ant "copy".
Multiplication Table