0% found this document useful (0 votes)
35 views20 pages

Intro to Linux for Beginners

The document provides an introduction to Linux including what Linux is, the different components that make up Linux like the kernel and distributions, advantages of using Linux, and some basic Linux commands and directories. Key topics covered include the Linux kernel, distributions, shells, navigating directories, and common commands.

Uploaded by

sofiyas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
35 views20 pages

Intro to Linux for Beginners

The document provides an introduction to Linux including what Linux is, the different components that make up Linux like the kernel and distributions, advantages of using Linux, and some basic Linux commands and directories. Key topics covered include the Linux kernel, distributions, shells, navigating directories, and common commands.

Uploaded by

sofiyas
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 20

EEGR788:Seminar I

Babatunde Olubando D.Eng.


September 2020
Introduction to Linux
What is Linux?
• It is an Operating System(O.S)
• A collection of software that manages hardware resources
• Unix based, but written from scratch

• Environment where applications can work


• Store information
• Interact with users
• Interact with external peripherals

• It is also a Kernel
• Core of the OS
What is Linux ?
• Acts as intermediary/ middleware
• It includes system libraries, graphical user
interface(s), web browsers,…

• Created by Linus Torvalds in 1991


• Unix based
• First version released in 1994

• FOSS (Free /Open Source Software)


• Can be modified as long as the source code is
shared.
What is Linux?
• Linux Distribution (a.k.a Distro/ Flavor)
• Linux Distro = Linux Kernel + Applications

• Each distro has a different focus

• Applications = open source curated software that can be changed


• Free distros with no support
• Commercial distros ( license purchase required with support)
• Desktop/server focus, research/ science focus, media focus, security focus
Linux Distros
• Fedora
• Red Hat Enterprise Linux (RHEL)
• Banks, airlines, telecom, healthcare
• Ubuntu
• Startups, SaaS, Social networks, cloud based systems
• Debian
• OpenSuSE
• SuSE Linux Enterprise Server(SLES)
• Linux Mint
• Kali Linux Source: Most Popular Linux Distros (2017)
Why Linux ?
• Platform agnostic
• Can run on many hardware platforms
• Mobile devices, embedded devices (IOTs), PCs, super computers, servers vs.
• Unix flavors that are platform specific
• HPUX (HP devices), AIX (IBM), Solaris (Sun[Oracle])

• Small footprint
• Stable ,reliable and secure
• Long Term Support ( for commercial distros)

• Great for servers/ desktops


• Not as costly as proprietary Unix Oses
• Linux concepts are mostly universal
Virtual box + Linux distro
• Installing Virtualbox

• Downloading Linux Distro (Ubuntu)

• Initial setup of Linux distro


Linux Directory structure
• Common Directories
• / (directory separator)
• / “Root”, top of the file system hierarchy
• /bin Binaries and other executable programs or files
• /etc System configuration files
• /home User home directories
• /opt Optional or third party software
• /tmp Temporary space(typically cleared on reboot)
• /usr User related programs
• /usr/local/
• /var Variable data (most notably log files)
Some other directories
• /boot Files needed to boot the operating system
• /cdrom Mount point for CD-ROMs
• /cgroup Control group hierarchy
• /dev Device files (typically controlled by OS and sys admins)
• /export Shared file systems
• /lib System libraries
• /lib64 System libraries (64bit)
• /lost+found Used by system to store recovered files after file systems check has been performed
• /media Used to mount removable media like CD-ROMs
• /mnt Used to mount external file systems
• /proc Provides info about running processes
Linux Shell
• Default interface to Linux
• If connecting to Linux machine over the network (S_ _?)
• Text-based login prompt

• The GUI is also referred to as a graphical shell.

• An application that accepts user commands and executes them.

• Also known as a Command Line Interpreter


Command Line Interface (CLI) vs. GUI
• There will always be a command line

• The command line is more powerful


• Batch commands can be easily accomplished vs. with a GUI

• Most Linux server distributions do not include GUIs

• Desktop distributions have both GUIs & CLIs


Types of Linux/ Unix Shells
• bash+ (Bourne Again Shell)

• ksh+ (Korn Shell)

• tcsh (derived from csh, Berkely Unix C shell)

• zsh

• fish (Friendly Interactive Shell)


Shell Prompt
• Once a shell is started
• Initialization
• Waiting for command
• Prompt gives useful information

Logged in User machine Logged in machine System connected to


System connected to
a regular user User a super user

* This root is different from the file system root


Superuser, root
• Root is all powerful* ( do not leave this account open)
• Similar to administrator account on Windows

• Normal user accounts can only do a subset of the functions root can do.

• Root access may be required to


• Install programs
• Start/ stop an application
• Change/ access configuration files
Different ways the prompt can presented
user@mece_svr $ ~user -----> /home/user

[user@mece_svr /tmp]$ ~user2 -----> /home/user2

mece_svr: /home/user> ~root -----> /root

user@mece_svr:~> ~ftp -----> /srv/ftp (services)


How to customize the shell will be covered in latter sections
Linux commands
• Commands are case sensitive
Ls ≠ ls ≠ LS
• ls – list directory contents
• cd – change the current directory
• pwd – display the present working directory
• cat – concatenates and display files
• echo – Display arguments to the screen.
• man – Display the online manual
• exit – Exits the shell or your current session
• clear – Clears the screen
**Most commands have additional arguments(options) you can add**
Linux commands- navigating the man pages
• Enter – Moves down one line

• Space – Move down one page

• g – Move to the top of the page

• G – Move to the bottom of the page

• q – Quit

man [command]
Linux commands- $PATH environment variable
• An Environment variable is a name/value pair
• Typically upper case
• Can be accessed by ‘echo $VAR_NAME’

• $PATH is an essential environment variable


• It stores the command search path
• Allows you to run commands without having to navigate to the full path
• Contains a list of directories, separated by :

• ‘which [command]’shows location/ full path of command


Linux commands
• [command]--help or [command]-h, gives more info on
particular command
• Sometimes doesn’t work (use man instead then)

• man –k [SEARCH_TERM], for when you are not sure of the


command to use)

You might also like