Linux: A Getting Started Presentation

828 views
740 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
828
On SlideShare
0
From Embeds
0
Number of Embeds
8
Actions
Shares
0
Downloads
0
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Linux: A Getting Started Presentation

  1. 1. Linux: A Getting Started presentation by: Napoleon Esmundo C. Ramirez email: napoleonesmundocarpioramirez@gmail.com    
  2. 2. INTRODUCTION What is Linux? Linux is an operating system* created by Linus Torvalds, with the help of developers around the world. * An operating system is a special set of programs that manages the hardware and software resources of a computer.    
  3. 3. INTRODUCTION Why Linux? ● It's free! ● It is Open Source Software. ● It is reliable. ● Perks include: ✔ no viruses ✔ no need to restart all the time ✔ no registration/activation hassles ✔ unlimited support ✔ a large pool of applications for your preference    
  4. 4. GETTING USED TO... The File System In Linux, files and directories are organized in a hierarchical tree-like structure.    
  5. 5. GETTING USED TO... The File System (continued)    
  6. 6. GETTING USED TO... The File System (continued) ● File system entries can be files or directories e.g. file: hello.txt directory: src/ ● Entries are case-sensitive e.g. 'hello.txt' is NOT equal to 'HELLO.TXT' ● Hidden entries start with a dot '.' e.g. .bash_profile is a hidden file    
  7. 7. GETTING USED TO... The File System (continued) ● In Linux, files and directories are bound to ownership and permissions ● File system entries are owned by users ● Users may have the following permissions: ✔ read ✔ write ✔ execute/entry    
  8. 8. GETTING USED TO... The File System (continued) NOTE: The displayed Properties Dialog may vary in different window themes.    
  9. 9. Let's put it to the test! Exercise 1a    
  10. 10. INTRODUCTION TO... The Shell ● The shell is an environment and a means of communication with the operating system's kernel ● Either a GUI or CLI ● Usually pertains to the CLI    
  11. 11. GETTING TO KNOW... The CLI The command line interface (CLI) is a program that takes text input from the user that may, in turn, be used as directives to the operating system.    
  12. 12. LEARNING... File System Navigation ● ls – list contents of directory ✔ -l list in detail ✔ -a list all, including hidden files ✔ -F list, use indicators (dir: /, executable: *, link: @) ● cd – change directory ✔ ~ (user's home directory) ✔ - (previously visited directory) ✔ . (current directory) ✔ .. (parent directory) ✔ / (root directory) ● pwd – print working directory    
  13. 13. LEARNING... Creating Entries ● touch – mainly used to change timestamps of entries, it can be used to create files if specified files do not exist ● mkdir – create directory ✔ -p create parent directories, if non-existent    
  14. 14. LEARNING... Copying/Moving Entries ● cp – copy entry ✔ -r copy recursively ● mv – move entry    
  15. 15. LEARNING... Deleting Entries ● rm – delete file ✔ -r delete recursively ● rmdir – delete empty directory    
  16. 16. LEARNING... Output Pagers Pagers suppress the output of a command. This is useful if the output doesn't fit the screen. Pagers can be used by piping* the output of commands into them. ● more ● less * Piping is the passing of output of one command into another, it is denoted by the pipe character |.    
  17. 17. LEARNING... Output Commands These commands usually display output too big to fit in the screen. They are commonly used with pagers. ● echo – displays the specified text ● cat – displays the content of the specified file    
  18. 18. LEARNING... Editing Text Files Many text editors exist in every installation. The most popular are: ● vi, vim ● emacs ● joe ● pico, nano    
  19. 19. LEARNING... Setting Permissions ● chmod <mode> <entry> [-r] ✔ Recall that permissions are set for the owner/user (u), group (g), others (o) ✔ <mode> is the permissions set for any of the owner/user, group, others e.g `chmod ug+rw .bash_profile` `chmod o-rwx .bash_profile` ● Use `ls -l` to verify the changes    
  20. 20. LEARNING... Finding Files ● which – used to find executables ● locate – find indexed entries ● find – find files in the file system `find <path> -name <file>`    
  21. 21. LEARNING... Archiving Files ● gzip/gunzip `gzip <file>`, `gunzip <file>.gz` ● tar `tar cf <file>.tar <path>` `tar xf <file>.tar` ● zip/unzip `zip [-r] <file> <path>` `unzip <file>`    
  22. 22. Let's put it to the test! Exercise 1b    
  23. 23. LEARNING... Output Redirection While piping allows control of output into another program's input, redirection forwards the output to a file. ● > - output is saved into a file e.g. `echo “hello” > hello.txt` (hello.txt contains “hello”) ● >> - output is appended into a file e.g. `echo “hello again” >> hello.txt` (“hello again” is added)    
  24. 24. LEARNING... Process Control ● & - appending '&' to a command will bring the process to the background and returns the user to the prompt ● ps (process snapshot) – list processes ● fg (foreground) ● bg (background) ● kill ● top    
  25. 25. WHEN IN DOUBT... Help ● man – manual pages about commands e.g. `man <command>` ● info – information on commands e.g. `info <command>` ● -h or --help – used as arguments to a command e.g. `ls --help`    
  26. 26. THE END... Thanks! Please mail me your feedback! ---------------------------- Napoleon Esmundo C. Ramirez napoleonesmundocarpioramirez@gmail.com    
  27. 27. This work is licensed under the Creative Commons Attribution 3.0 License. To view a copy of this license, visit http://creativecommons.org/licenses/by/3.0/ or send a letter to Creative Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.    

×