Loading presentation...

Present Remotely

Send the link below via email or IM


Present to your audience

Start remote presentation

  • Invited audience members will follow you as you navigate and present
  • People invited to a presentation do not need a Prezi account
  • This link expires 10 minutes after you close the presentation
  • A maximum of 30 users can follow your presentation
  • Learn more about this feature in our knowledge base article

Do you really want to delete this prezi?

Neither you, nor the coeditors you shared it with will be able to recover it again.


Introduction to linux

No description

Abdullah Albahdal

on 6 February 2013

Comments (0)

Please log in to add your comment.

Report abuse

Transcript of Introduction to linux

By: Abdullah Albahdal Introduction to Linux Linux User Interfaces An open source Linux distribution.
One of the most popular Linux distributions.
Built based on Debian system by Mark Shuttleworth (Canonical Ltd.) to overcome weaknesses in other Linux distributions.
Built to be:
easy to use,
completely free, and
compete with other operating systems.
Provides Graphical User interface (GUI) along with the Command line Interface (CLI). Where to get help Linux manual pages:
Through http://www.linuxmanpages.com
man command ->(e.g. man mkdir)
apropos command ->(e.g. apropos browser)
help command ->(help cd)
--help option ->(mkdir --help)
Google definitely will help you!! File Management and Navigation Users Permissions Graphical User interface (GUI) We will be using Ubuntu for Today's tutorial Why do you need Linux? Start here and Command Line interface (CLI) What Linux distribution we're gonna to use? What type of user interface should we use? Is learning one of them enough? Why CLI? Text Editing I/O Redirection Processes Management ps ---> lists running processes
kill ps_id/job# ---> kills processes by their process ID or job number
jobs ---> lists user's processes
bg ---> put a process in the background
fg ---> put a process in the forground
ctrl-z ---> stop a process Installing packages Let's learn something important before we learn our first command!! Additional Resources http://linuxcommand.org/lc3_learning_the_shell.php http://www.tldp.org/LDP/intro-linux/intro-linux.pdf Tutorial web site: http://books.openlibra.com/pdf/Getting-Started-with-Ubuntu-12.10.pdf Video tutorial: Ubunto manual: E-book: Why text editor is an important tool in Linux? Examples of available text editors:
vim, vi, nano, emacs, gedit, and many others... VIM An open source text editor
Based on vi text editor
Powerful text editor
Most popular Linux text editor
Provides both GUI and CLI interfaces
Widely used between programmers VIM Cheat Sheets Linux and Programming Write your program using a text editor (e.g. vim)
Compile your program using a compiler
Link your object files produced by compiler Navigation pwd ---> print working directory
cd ---> change directory
ls ---> list directories or files Demo & Examples... Linux File System Handling Files & Directories cp ---> copy files and directories
mv ---> move or rename files and
rm ---> remove files and directories
mkdir ---> create a new directory
Use the -r option with directories Wildcards Demo & Examples... * ---> match any characters
? ---> match any single character
[chars] ---> match one of these characters
[!chars] ---> match with any characters
excepts these characters Files permissions Change file permissions Chmod permissions# file_name

chmod 777 my_file.txt
chmod 755 my_file.txt Directoires Permissions Directoires permissions Similar to file permission, but:

r ---> allows listing the content of the directory if x is also set.
w ---> allows creating, deleting, and renaming the content of the directory if x is also set
x ---> allows entering the directory (e.g cd dir) Change Directory permissions Chmod permissions# directory_name

chmod 777 my_dir/
chmod 755 my_dir/ Changing File Ownership To change a file/directory "user" ownership:
chown user_name file_name

To change a file /directory "group" ownership:
chgrp group_name file_name Demo & Examples... Demo & Examples... Demo & Examples... Demo & Examples... Redirecting Output Output must not be always displayed to the screen !! Redirecting output to a file with rewriting:
command > file_name

Redirecting output to a file with appending:
command >> file_name Demo & Examples... Redirecting Input Input must not be always from the keyboard !! Redirecting input from a file:
command < file_name

Redirecting both output and input:
command < input_file_name > output_file_name Demo & Examples... Pipelining Pipelining allows you to connect more than one command together command 1 | command2 | command3 .... Demo & Examples... Filtering sort file_name ---> sorts the list provided by the file. if the file_name is not provided, the standard input will be used
grep pattern file_name ---> searches the file and outputs files that matches the pattern
head file_name ---> retrieves the first few lines of the file
tail file_name ---> retreives the last few lines of the file Demo & Examples... Demo & Examples... apt-get command can be used to install, remove, and upgrad software packages
apt refers to the Advance Package Tool (APT)
It can be also used to upgrade the whole system apt-get install package_name ---> installs the package_name
apt-get remove package_name ---> removes (uninstalls) the package_name
apt-get update ---> updates the package index file (does not update any package!!)
apt-get upgrade ---> upgrades system's packages to the newest available versions GNU Compiler Collection (GCC) Includes compiler and linker
supports C, C++, Objective-C, Java, fortran, Ada, and GO To compile:
gcc -c file_name.c ---> it will produce the object file file_name.o
To link:
gcc file_name.o -o file_name ---> -o option indicates the output file name. file_name is the executable file
To run:
./file_name Super User (Root User) root user is has full control over Linux
the administrative tasks requires root permessions
sudo command ---> allows executing the command as the root user
sudo -s ---> open a new root session
Full transcript