RH030 Linux Computing Essentials

Slides:



Advertisements
Similar presentations
Chapter 11: The X Window System Guide To UNIX Using Linux Third Edition.
Advertisements

RH030 Linux Computing Essentials
Linux commands exercise 1. What do you need, if you try to these at home? You need to download and install Ubuntu Linux from the Internet – DVD is need.
A Guide to Unix Using Linux Fourth Edition
Jump to first page Unix Commands Monica Stoica Jump to first page Introduction to Unix n Unix was born in 1969 at Bell Laboratories, a research subdivision.
Chapter One The Essence of UNIX.
NETW-240 Shells Last Update Copyright Kenneth M. Chipps Ph.D. 1.
The Unix File System. What are the three parts of every file on a Unix filesystem? And where is each stored? Filename - stored in directories Inode -
Introducing the Command Line CMSC 121 Introduction to UNIX Much of the material in these slides was taken from Dan Hood’s CMSC 121 Lecture Notes.
Chapter 2 Accessing Your System and the Common Desktop Environment.
Linux+ Guide to Linux Certification, Second Edition
Chapter 5 Accessing Files and Directories. How Directories Get Created OS installation: usr, dev, etc, export, kernel and others places to store installation.
More Shell Basics CS465 - Unix. Unix shells User’s default shell - specified in /etc/passwd file To show which shell you are currently using: $ echo $SHELL.
UNIX Chapter 00 A “ Quick Start ” into UNIX Operating System Mr. Mohammad Smirat.
Guide To UNIX Using Linux Third Edition
Linux Shell. 2 Linux Command-Line Interface ■ Linux shells: A shell is a command interpreter that allows you to type commands from the keyboard to interact.
L INUX C OMMAND L INE I NTERFACE G UNAANBAN.G
Linux Installation and Administration Lesson 2 Tutor: George Papamarkos.
1. This presentation covers :  User Interface Administration  Files System and Services Management 2.
Introduction to Linux Operating System Tutorial 1
EMT 2390L Lecture 2 Dr. Reyes. Outline What is the Shell Basic commands Linux Filesystem System commands.
The file structure and related utilities CS240 Computer Science II.
Unix Primer. Unix Shell The shell is a command programming language that provides an interface to the UNIX operating system. The shell is a “regular”
Lesson 7-Creating and Changing Directories. Overview Using directories to create order. Managing files in directories. Using pathnames to manage files.
Chapter 9 Part II Linux Command Line Access to Linux Authenticated login using a Linux account is required to access a Linux system. The Linux prompt will.
Introduction to Unix/Linux Chapter One The Essence of UNIX.
Guide to Linux Installation and Administration, 2e1 Chapter 8 Basic Administration Tasks.
Agenda User Profile File (.profile) –Keyword Shell Variables Linux (Unix) filters –Purpose –Commands: grep, sort, awk cut, tr, wc, spell.
CENT 305 Information Systems Security Linux Introduction.
Chapter 2: Getting Started Logon to Logout. In this chapter … Logging on The Shell Superuser Getting Help Logging off.
Linux+ Guide to Linux Certification Chapter Four Exploring Linux Filesystems.
Linux+ Guide to Linux Certification, Third Edition
Session 2 Wharton Summer Tech Camp Basic Unix. Agenda Cover basic UNIX commands and useful functions.
Week 3 Exploring Linux Filesystems. Objectives  Understand and navigate the Linux directory structure using relative and absolute pathnames  Describe.
UNIX Commands. Why UNIX Commands Are Noninteractive Command may take input from the output of another command (filters). May be scheduled to run at specific.
Chapter 0 A “Quick-Start” into the UNIX Operating System.
1 Operating Systems and Using Linux Topics What is an Operating System? Linux Overview Frequently Used Linux Commands Reading None.
Unix/Linux cs3353. The Shell The shell is a program that acts as the interface between the user and the kernel. –The shell is fully programmable and will.
Lesson 2-Touring Essential Programs. Overview Development of UNIX and Linux. Commands to execute utilities. Communicating instructions to the shell. Navigating.
BIF713 Basic Unix/Linux Commands Getting Help with Commands.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: whereis, which, whoami, finger, passwd, cal, date Working with Files: cat, more, less.
Lab 3 + Using the Terminal 1. "Under Linux there are GUIs (graphical user interfaces). where you can point and click and drag, and hopefully get work.
Introduction to Programming Using C An Introduction to Operating Systems.
Manage Directories and Files in Linux Part 2. 2 Identify File Types in the Linux System The file types in Linux referred to as normal files and directories.
Advanced Programming in the UNIX Environment Hop Lee.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: which, passwd, date, ps / kill Working with Files: file, touch, cat, more, less, grep,
Lesson 3-Touring Utilities and System Features. Overview Employing fundamental utilities. Linux terminal sessions. Managing input and output. Using special.
CSE 374 Programming Concepts & Tools Hal Perkins Fall 2015 Lecture 2a – A Unix Command Sampler (Courtesy of David Notkin, CSE 303)
Module 1 - Introduction to Linux. Users must log-in Linux is case sensitive File and Directories naming conventions (No spaces!) Files and Directories.
1 © 2001 John Urrutia. All rights reserved. Chapter 2 Getting Started.
Linux+ Guide to Linux Certification, Second Edition Chapter 4 Exploring Linux Filesystems.
1 Introduction to Unix. 2 What is UNIX?  UNIX is an Operating System (OS).  An operating system is a control program that helps the user communicate.
The Kernel At a high level, the kernel in an operating system serves as the bridge between applications and the actual data processing of the hardware.
1 CS3695 – Network Vulnerability Assessment & Risk Mitigation – Introduction to Unix & Linux.
Linux Tutorial Lesson Two *Getting Help in Linux *Data movement and manipulation *Relative and Absolute path *Processes Note: see chapter 1,2,3 from Linux.
Assignprelim.1 Assignment Preliminaries © 2012 B. Wilkinson/Clayton Ferner. Modification date: Jan 16a, 2014.
CMSC 104, Version 9/011 Operating Systems and Using Linux Topics What is an Operating System? Linux Overview Frequently Used Linux Commands Reading None.
UNIX To do work for the class, you will be using the Unix operating system. Once connected to the system, you will be presented with a login screen. Once.
A “Quick-Start” into the UNIX Operating System
Linux Commands Help HANDS ON TRAINING Author: Muhammad Laique
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands:
Chapter 1 The Essence of UNIX and Linux
(Chapter 2) John Carelli, Instructor Kutztown University
Unix : Introduction and Commands
Operating Systems and Using Linux
Web Programming Essentials:
Introduction Paul Flynn
A shell is a user interface.
Presentation transcript:

RH030 Linux Computing Essentials Workbook 1 Quicktour And more basic’s RH030 Linux Computing Essentials

Linux+ Guide to Linux Certification, 2e Objectives Usage of some basic commands Become familiar with UNIX command line structure Become familiar with UNIX command line syntax Understanding how the UNIX commands works with options and arguments. Getting help with the man pages to learn about commands and their options. Become familiar with displaying the contents of directories and files. Running multiple commands on a single command -line Use of the Redirection Symbols. Workbook 1 covers 1. Logging In 2. The Kernel, Programs, and Processes 3. Examining the Filesystem 4. Running Commands 5. Managing Terminals 6. Getting Help Linux+ Guide to Linux Certification, 2e

2 Types of Unix/Linux users Superuser # = There is only one system administrator account, created during installation They always log onto the system as root. Regular User $ = These are created by the superuser All accounts have a home directory. The hierarchical filesystem starts from the top of the tree “ / ” which is called the “root” directory . Immediately under which are the system directories. 2 of these are: /root directory which is the home directory for the superuser /home directory which contains a separate home directory for each of the regular user accounts.

You have to Login to Linux Multiuser environments require you to have a users account. You can log in thru command-line interface or a GUI interface. The Command-line interface is always available. You need to install the GUI interface during installation to use it. Login will also require a password. Linux+ Guide to Linux Certification, 2e

Switching Between User Accounts You can switch to another user’s account with the su (“Switch User”) command. su [-] username Once switched, you are subject to the same constraints as the user you are now logged in as. The ‘-‘ puts you in the new user’s home directory and reads their profile or initialization files. If no username is given, root is assumed. The ‘-‘ can still be used (su - ). exit Type exit to log out as the new user. Puts you back into your own account. Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e Changing Directories ~ Refers to your home directory . Refers to the current directory .. Refers to the parent directory - 1 level up pwd Displays your current location in the directory tree cd Change the current directory in the directory tree tab This is called Tab-completion: It is used to automatically list items within the directory. You just put the first letter of the item you want. Then if you press the Tab key it fills in remaining characters of a unique filename or directory name or lists your options. You can also use it to complete pathnames. This is a feature of the BASH shell. Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e cd command Used to navigate thru the Directory Tree Structure Remember there are many ways to use this command. cd - moves you directly to your home directory cd ~ - also moves you directly to your home directory cd .. - moves you automatically up 1 directory level cd <directory> - moves you down into the directory named cd / - moves you directly to the top of the tree structure. cd .. - this moves you up 1 directory level cd ../.. - this moves you up 2 directory level cd ../../.. - this moves you up 3 directory level & so on ….. Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e Even after you login Linux still offers the user many choices for their Interfaces 1. Command-line using shell There are multiple CL screens available for the use of the user. You access them by using the Crtl+Alt+F key combinations to change to separate terminal screens. 2. Graphical Interface using Xwindows You can start a GUI interface on any of these multiple screens . You can access a GUI interface with the Crtl+Alt+F7 key combination You can use the Crtl+Alt+Bkspace key to shutdown the GUI You can have access to both GUI & CL interfaces. Load the GUI by default and use terminal program for CL Or load CL by default and switch to a GUI by typing startx This will start a GUI environment on top of the shell Linux+ Guide to Linux Certification, 2e

Using the Multiple Virtual Console Interfaces You access the different interface screens by using the Crtl+Alt+F key combinations to change to the separate terminal screens. Each screen acts as a completely separate environment. You can be logged into them with different user accounts. Linux+ Guide to Linux Certification, 2e

The Kernel controls all Virtual Consoles Because each acts as a completely separate environment. Each is allocated it’s own shell from the kernel. Figure 3-27: Shells, terminals, and the kernel Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e ls Command Gives a listing of the contents of a directory. Syntax: ls [-option(s)] [pathname(s)] With no options you get a “brief /wide” listing. Sorted alphabetically by default. Options most commonly used. ls –l ls –a ls –F ls –r ls –R Linux+ Guide to Linux Certification, 2e

Displaying Hidden Files Any file whose name begins with a ‘.’ is a hidden file in Unix. Not shown with ls by default. The links to ‘.’ and ‘..’ are hidden files. To see hidden files in Unix, use ls –a to show “all” files. Use ls –A to show all files except ‘.’ and ‘..’. Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e Displaying File Types Use ls –F to get a “wide” listing with indicators as to the type of each file. Linux+ Guide to Linux Certification, 2e

Displaying a Detailed/ Long Listing ls –l This gives a “detailed” listing of directory contents. Shows all information relevant to item. Sorted alphabetically by default. Can use ls –lt to sort by time. Linux+ Guide to Linux Certification, 2e

Listing Individual Directories and Subdirectories Use ls –ld to find out information about a directory itself, not the contents of it. You can use the “recursive” option with ls, ls –R to list a directory and all of its subdirectories. Can produce a lot of output. -r and –R are used with many Unix commands. Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e More Basic Commands Table 3-3: Some Common Linux commands Linux+ Guide to Linux Certification, 2e

User Commands for what other users are on the system. who gives detailed information on every user logged onto the system. finger gives the same info as who, but can give more detailed information on individual users. It also gives this info whether the user is logged onto the system or not. Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e Getting Help Linux contains 1000,s commands And many different text configuration files. You can get help on all these – thru the “man pages”. Which is the default command-line help program for Linux. Available in all UNIX / Linux versions At the command prompt, type “man” followed by the item which you want help on. $ man <command name> man whoami man –k usb (need to run makewhatis once to use) Linux+ Guide to Linux Certification, 2e

Linux+ Guide to Linux Certification, 2e Getting Help There are also other common types of help also available. whatis whereis info pages apropos --help help PLUS ....... Excellent help on the Internet = HOWTO documents Linux+ Guide to Linux Certification, 2e

Command Summary login passwd $ # su exit pwd date cd ~ . .. cat ls ls –a ls -l * ? > [ ] metacharacters man man –k whatis info apropos --help crtl+alt+F? shutdown clear reset finger who w whoami id Directory Navigation To gain access to particular files, you have to be able to move through directories to find them. Here are a few useful commands which will allow you to do this :- cd path Changes working directory to path. Allows you to change directory but only if you can see it in your directory listing. Example : current directory is : /home/zoman ; type $ cd thesis new location is : /home/zoman/thesis cd /path Changes working directory to /path. Allows you to change directory based on the given absolute path. Example : $ cd /etc new location is : /etc cd / This will put you into the UNIX root directory. Example: $ cd / new location is : / cd .. This will put you into the previous (parent) directory in the hierarchy. Example : current directory is : /home/zoman/thesis ; type $ cd .. new location is : /home/zoman cd This will put you into your personal home directory. Example: current directory is : / ; type $ cd

Linux+ Guide to Linux Certification, 2e remote - telnet ssh putty bash csh ksh bourne ps aux ls cat > ~ . .. ps who --help -h -? which ls -s --size -w -r --width=40 control sequences ctrl+c … etc cal tab cat wc ttyn ttySn ptsn :0 ls -R fg man man -k -a info pinfo /usr/share/<filename> .filename = hidden Linux+ Guide to Linux Certification, 2e