From the course: Cert Prep: LPIC-1 Exam 101 (Version 5.0)
Unlock the full course today
Join today to access over 22,500 courses taught by industry experts or purchase this course individually.
Default permissions using umask - Linux Tutorial
From the course: Cert Prep: LPIC-1 Exam 101 (Version 5.0)
Default permissions using umask
- [Instructor] When files are created, default permissions are applied automatically. These permissions are calculated based on a bitmask called umask. To see a umask type into a terminal umask and hit enter. We can also view the umask in symbolic notation by using the -S option. Type in umask -S and hit enter. We can see that my umask is 0002, which equates to rwx for the user, rwx for the group and rx for other. Centos has different umasks for root and regular users. That's su the root and check the umask again. Type in su - root and hit enter. Type in root's password and hit enter again. Type in umask and hit enter again. You can see that root's umask is 0022, and my user's umask is 0002. Type in exit to go back to your user. Notice that the umask isn't the same format as numeric permissions such as 754, but is rather upside down. To calculate default permissions, we'll have to subtract the umask from maximum…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
-
-
-
-
-
(Locked)
Create and delete local user accounts4m 27s
-
(Locked)
Modify local user accounts4m 57s
-
(Locked)
Manage user passwords4m 15s
-
(Locked)
What is a file?2m 10s
-
(Locked)
Get file attributes3m 41s
-
(Locked)
Get extended attributes4m 13s
-
(Locked)
About standard Linux permissions1m 47s
-
(Locked)
File and directory modes1m 19s
-
(Locked)
File ownership4m 34s
-
(Locked)
Set permissions using numeric method3m 13s
-
(Locked)
Set permissions using symbolic method5m 16s
-
(Locked)
Default permissions using umask5m 51s
-
(Locked)
Special file bits: SUID and SGID3m 49s
-
(Locked)
Special directory bits: SGID and Sticky6m 26s
-
(Locked)
-
-