1 / 19

Chapter 8 Files and User Information Utilities

Chapter 8 Files and User Information Utilities. Logical Partitions. referred to as file systems like a drive in windows world $ df (display filesystems) shows your logical partitions most common are /usr , where binary and executables are stored

Download Presentation

Chapter 8 Files and User Information Utilities

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 8 Files and User Information Utilities

  2. Logical Partitions referred to as file systems like a drive in windows world $ df (display filesystems) shows your logical partitions most common are /usr, where binary and executables are stored /opt, where third party applications are usually located root (/), where the files that pertain to the operation of the system are kept

  3. Finding Files -name filename -type filetype -mtime [+|-]n -atime [+|-]n -user loginid -group groupid -perm mode -size [+|-]n[c]

  4. Finding Files

  5. Finding Files

  6. grep Command search for pattern "rose” inside of text file “flowers” $ grep rose flowers looks for who is on server by piping who output to pattern search for user2 $ who | grep user2

  7. CDE Finding Files much like find on other GUI systems specify where you want to search what you want to search for criteria much the same as with command line - "content" criteria is like grep command

  8. Sorting

  9. who Command who by default displays information about all users currently logged on the local system lists user’s name, terminal, login time, elapsed time since the last activity on the terminal line, and the machine (host) name who -H prints headers above the info who -q only lists users currently logged on and the total number

  10. Switching Users su (switch user) username switches to another user but doesn't change directory location if you're root, you don't need the password su - takes you into the user's environment - system reads new user's initialization files as administrator, you can experience trouble AS the user to help troubleshoot

  11. User ID Real User ID (RUID) - initial login Effective User ID (EUID) - who you are after the switch who am i (only unix command with spaces in it) displays RUID with login info - if switched, still displays real user ID whoami displays only the login name of the EFFECTIVE user id displays the effective user name id -a identifies the effective user name, user ID, and user’s groups

  12. Labs/Assessment Lab 8.2.4 – File Processing Commands (find, grep, sort) Lab 8.3.3 – User Identification Commands chapter 8 assessment

  13. Chap 8 Exercises 1. find any files in your home directory named dante:

  14. Chap 8 Exercises 1. find any files in your home directory named dante: $ find . -name dante ./dante $ find ~/ -name dante /export/home/user2/dante

  15. Chap 8 Exercises 2. look in this file: /etc/passwd for user2 home directory info

  16. Chap 8 Exercises 2. look in this file: /etc/passwd for user2 home directory info $ grep user2 /etc/passwd user2:x:1001:10::/export/home/user2:/bin/ksh

  17. Chap 8 Exercises 3. sort the output of the long listing of your home directory

  18. Chap 8 Exercises 3. sort the output of the long listing of your home directory $ ls -l | sort

More Related