Users, Groups and Permissions in Linux

Note: We Demonstrate Linux using Ubuntu Server 10.04

Info

  • Level: Intermediate
  • Presenter: Eli the Computer Guy
  • Date Created: September, 16 2010
  • Length of Class: 37 Minutes

Tracks

Prerequisites

Purpose of Class

  • This class teaches students how to manage users, groups and permissions in a Linux enviornment.

Topics Covered

  • Adding and Deleting Users
  • Editing the passwd File Which Contains User Configurations
  • Changing User Passwords
  • Adding and Deleting Groups
  • Adding and Deleting Users from Groups
  • Editing the group Configuration File
  • Understanding Permission Numbering System
  • Changing User and Group Ownership for Files and Folders

Class Notes

  1. Users
    1. Add User = sudo adduser username
    2. Change User password = sudo passwd username
    3. Delete User = sudo userdel username
    4. Edit Users Configuration File = sudo vim /etc/passwd (shows usernames, names of users, home directories)
  2. Groups
    1. Sudo groupadd groupname
    2. Sudo groupdel groupname
    3. Sudo vim /etc/group (shows groups and users)
  3. Permissions
    1. Numbers = owner/group/everyone else
    2. 4 = read, 2 = write, 1 = execute
    3. To Chanege Permissions of a File or Folder = sudo chmod 777 file/folder (-R for recursive)
  4. Changing Ownership
    1. To Change User Ownership = sudo chown -R username file/folder
    2. To Change Group Ownership =sudo chgrp –R groupname file/folder
    3. -R for Recursive for Folders

    Resources

    3 Responses to Users, Groups and Permissions in Linux

    • JOhn says:

      Hey Eli can you add a group withing a group, also i am using ubuntu 11.04 and when i do the sudo vim /etc/passwd is not working its giving me some sort of an error why would that be?

    • Eli the Computer Guy says:

      I don’t believe you can do it.

    • Robin Dong says:

      it is a supper idea to give these notes after each demo. very effecient and simple.

    Leave a Reply

    Your email address will not be published. Required fields are marked *

    *

    You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>



















    Subscribe to me on YouTube