TAILIEUCHUNG - Module Linux essentials - Module 15: Ownership and permissions

Module Linux essentials - Module 15 introduce ownership and permissions in Linux. This module include content: Ownership, identity information, changing file and group ownership, permissions, chmod command, umask command. | Module 15 Ownership and Permissions Exam Objective Managing File Permissions and Ownership Objective Summary File and directory permissions and owners Ownership Viewing Ownership (ls -l) To view the ownerships of a regular file, you can use the ls –l command: [sysadmin@localhost ~]$ ls -l /etc/ -rw-r-----. 1 root named 1163 May 13 10:27 /etc/ To view the ownerships of a directory file, you can use the ls -ld command: [sysadmin@localhost ~]$ ls -ld /etc/named drwxr-x---. 2 root named 4096 Mar 28 2013 /etc/named user owner group owner user owner group owner Viewing Ownership (stat) Another command that allows you to view ownership information in a more detailed way is the stat command: [sysadmin@localhost ~]$ stat /etc/named File: `/etc/named' Size: 4096 Blocks: 8 IO Block: 4096 directory Device: fd00h/64768d Inode: 153995 Links: 2 Access: (0750/drwxr-x---) Uid: ( 0/ root) Gid: ( 25/ named) Access: 2013-10-28 16:21: -0700 Modify: 2013-03-28 15:18: -0700 Change: 2013-05-13 09:56: -0700 user owner group owner File Ownership Every file is owned by a user and a group. If a user creates a file, they will be the user owner of that file. The chown command can change user ownership of a file, but it can only be used by the root user. Although most commands will show the user's account name as the owner, the operating system is actually associating that user’s UID as the file owner. Group Ownership When a file is created, the user's primary group is the group owner of the file. The user can use the chgrp command to change the group owner of a file the user owns, to a group that the user is a member. The root user can use the chgrp command to change the group owner of any file to any group. While most commands will show a group name as the group owner, the system actually tracks group ownership by the GID of the group. Orphaned Files If a user is deleted, or has their UID changed, their former UID will show as the .

TỪ KHÓA LIÊN QUAN
TAILIEUCHUNG - Chia sẻ tài liệu không giới hạn
Địa chỉ : 444 Hoang Hoa Tham, Hanoi, Viet Nam
Website : tailieuchung.com
Email : tailieuchung20@gmail.com
Tailieuchung.com là thư viện tài liệu trực tuyến, nơi chia sẽ trao đổi hàng triệu tài liệu như luận văn đồ án, sách, giáo trình, đề thi.
Chúng tôi không chịu trách nhiệm liên quan đến các vấn đề bản quyền nội dung tài liệu được thành viên tự nguyện đăng tải lên, nếu phát hiện thấy tài liệu xấu hoặc tài liệu có bản quyền xin hãy email cho chúng tôi.
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.