1 CS3695 – Network Vulnerability Assessment & Risk Mitigation – Introduction to Unix & Linux.

Slides:



Advertisements
Similar presentations
Learning Unix/Linux Bioinformatics Orientation 2008 Eric Bishop.
Advertisements

1 Introduction to UNIX Ke Liu
NETW-240 Shells Last Update Copyright Kenneth M. Chipps Ph.D. 1.
Cosc 4750 Getting Started in UNIX Don’t be afraid of the prompt, in linux it can be your best friend. In some cases, the only way to do certain things.
Lesson 22 – Introduction to Linux Systems Administration.
Linux+ Guide to Linux Certification, Second Edition
Guide To UNIX Using Linux Third Edition
T UTORIAL OF U NIX C OMMAND & SHELL SCRIPT S 5027 Professor: Dr. Shu-Ching Chen TA: Samira Pouyanfar Spring 2015.
Lecture 01CS311 – Operating Systems 1 1 CS311 – Lecture 01 Outline Course introduction Setting up your system Logging onto the servers at OSU with ssh.
Lecture 02CS311 – Operating Systems 1 1 CS311 – Lecture 02 Outline UNIX/Linux features – Redirection – pipes – Terminating a command – Running program.
1 Some basic Unix commands u Understand the concept of loggin into and out of a Unix shell u Interact with the system in a basic way through keyboard and.
Linux Commands LINUX COMMANDS.
L INUX C OMMAND L INE I NTERFACE G UNAANBAN.G
CS 141 Labs are mandatory. Attendance will be taken in each lab. Make account on moodle. Projects will be submitted via moodle.
Using Macs and Unix Nancy Griffeth January 6, 2014 Funding for this workshop was provided by the program “Computational Modeling and Analysis of Complex.
GETTING STARTED USING LINUX UBUNTU FOR A MULTI-USER SYSTEM Team 4 Lab Coordinator Manager Presentation Prep Webmaster Document Prep Faculty Facilitator.
Help session: Unix basics Keith 9/9/2011. Login in Unix lab  User name: ug0xx Password: ece321 (initial)  The password will not be displayed on the.
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.
Linux environment ● Graphical interface – X-window + window manager ● Text interface – terminal + shell.
Unix Basics Chapter 4.
Basic unix commands that everyone should know (Even if you have a mac) Slightly more advanced:
File Permissions. What are the three categories of users that apply to file permissions? Owner (or user) Group All others (public, world, others)
Linux+ Guide to Linux Certification, Second Edition
Introduction to Unix – CS 21 Lecture 9. Lecture Overview Shell description Shell choices History Aliases Topic review.
System Administration Introduction to Unix Session 2 – Fri 02 Nov 2007 Reference:  chapter 1, The Unix Programming Environment, Kernighan & Pike, ISBN.
Session 2 Wharton Summer Tech Camp Basic Unix. Agenda Cover basic UNIX commands and useful functions.
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.
ITR3 lecture 6: intoduction to UNIX Thomas Krichel
UNIX Commands COMP 1090 Introduction to Unix Fall
Linux+ Guide to Linux Certification, Third Edition
Linux+ Guide to Linux Certification, Third Edition
Introduction to Programming Using C An Introduction to Operating Systems.
CSC414 “Introduction to UNIX/ Linux” Lecture 5. Schedule 1. Introduction to Unix/ Linux 2. Kernel Structure and Device Drivers. 3. System and Storage.
Agenda Basic Unix Commands (Chapters 2 & 3) Miscellaneous Commands: which, passwd, date, ps / kill Working with Files: file, touch, cat, more, less, grep,
Linux Commands C151 Multi-User Operating Systems.
CS 245 – Part 1 Using Operating Systems and Networks for Programmers Jiang Guo Dept. of Computer Science California State University Los Angeles.
Module 1 - Introduction to Linux. Users must log-in Linux is case sensitive File and Directories naming conventions (No spaces!) Files and Directories.
1 CS3695/M6-109 – Network Vulnerability Assessment & Risk Mitigation – Introduction to Unix & Linux.
THE UNIX SYSTEM Jan Recitation 2 Introduction to Networking.
Tony Kombol.  man  on-line user manual  man command_you_want_info_on  type q to exit  examples:  for ls (list directory) ▪ man ls  for cp (copy)
Lecture 02 File and File system. Topics Describe the layout of a Linux file system Display and set paths Describe the most important files, including.
Linux A practical introduction. 1)Background and Getting Started Linux is an operating system with multiple providers Red Hat/CentOS (our version) Ubuntu.
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.
A Brief Overview of Unix Brandon Bohrer. Topics What is Unix? – Quick introduction Documentation – Where to get it, how to use it Text Editors – Know.
Learning Unix/Linux Based on slides from: Eric Bishop.
INTRODUCTION TO SHELL SCRIPTING By Byamukama Frank
By Jonathan Rinfret UNIX/LINUX By Jonathan Rinfret
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.
Tutorial of Unix Command & shell scriptS 5027
Getting started with CentOS Linux
CS3695/M6-109 – Network Vulnerability Assessment & Risk Mitigation –
Andy Wang Object Oriented Programming in C++ COP 3330
Some Linux Commands.
C151 Multi-User Operating Systems
Tutorial of Unix Command & shell scriptS 5027
Basic UNIX OLC Training.
Introduction to UNIX.
Tutorial of Unix Command & shell scriptS 5027
Web Programming Essentials:
Tutorial of Unix Command & shell scriptS 5027
Getting started with CentOS Linux
Andy Wang Object Oriented Programming in C++ COP 3330
UNIX/LINUX Commands Using BASH Copyright © 2017 – Curt Hill.
Tutorial Unix Command & Makefile CIS 5027
Working with Mac OS and Linux
Linux Commands LINUX COMMANDS.
January 26th, 2004 Class Meeting 2
Presentation transcript:

1 CS3695 – Network Vulnerability Assessment & Risk Mitigation – Introduction to Unix & Linux

2 Know basic Linux commands, such as: ls, cd,|, more, mkdir, rmdir, touch, rm, cp, su, vi, chmod, w, who, finger Know commands are case sensitive Know the difference between ssh and telnet Introduce vi as an editor Know how permissions work Objectives

3 Linux/Unix What you should know –Linux/Unix commands are arcane and cryptic and often silly looking –Linux command are case sensitive! –Some commands have flags for additional optional control like this: …ls -al or rm -r –You can put multiple commands on the same line: …ls ; pwd –You can auto-complete commands with the tab key –You can correct a bad command with ^^

Linux Distributions

Linux Live CD-ROMs A LiveCD is an operating system (usually containing other software as well) stored on a bootable CD-ROM that can be executed from it, without installation on a hard drive Knoppix Live CDs are widely used in the Linux community It is completely customizable Source: Copyright © by EC-Council EC-Council

6 Connecting to Linux You can telnet or ssh if you want

7 You can get help with the man man for manual pages

Working with Man man [command] –Within man: spacebar/f = forward b = back q = quit / = search forward ? = search backward n = repeat search 8

Reading Files 9

10 Linux ls You can list directories with ls

11 More on ls Permissions Ownership And group membership Size Date of last Mod Time or year of last Mod Filename Text # of Links First Bit - = file l = link d = directory b = block device (disk drive) c = character device (serial port or terminal)

12 Ownership and Permissions Three levels of ownership and permissions –User –Group –Everyone Within these groups you can specify permissions: Read Write execute File access levels Permissions

13 Who owns what?

14 Change the group association of files and directories chgrp chgrp –R To change the group association of a directory and all of its contents us the –R switch

15 You can change ownership! chown chown –R The –R switch again

16 Change permissions

17 Or Use chmod Or use the chmod command to set the individual levels: --- 7=rwx, 3=-wx, 1=--x

18 Change directories with cd and find yourself with pwd You can change directories and find yourself… –cd to change directory, pwd to display your current directory

19 You can Pipe I/O | and more = one screen at a time

20 The redirect > It doesn’t have to go to the screen.

21 You can make a directory with mkdir mkdir creates directory

22 You can “touch” Make a file with touch

23 You can copy cp is used to copy a file

24 You can move files and directories mv is used to move (or rename) a file

25 You can remove files and directories rm and rmdir You must remove everything from the directory to use rmdir

26 What about that shell? Common Unix shells –Sh: This shell, the original, often called the Bourne shell, not too flexible, great for scripting –Csh and tcsh: The family of shells adds great interactive uses but discards the popular scripting support that sh offers. It favors C “programming” like type syntax –Ksh, bash, zsh: These provide a good mix of scripting and interactive capabilities, bash is very similar to sh and is often referred to as “Bourne again shell”…hence bash

27 What is my shell? Echo $shell

28 I think you should change your identity su: substitute user –When: to log in as a different user or to start a new login shell To login as a different user –su asr To start a new login shell –su – rharkins {the hyphen will force a new login shell} To return to the previous shell –exit Use su without anything else to get to root (you will be prompted for the root password) –su To perform a single task as root use sudo –sudo tcpdump

29 What editor should I use VI: Powerful but very cranky editor. It is universally available, and therefore a good reason to learn it at some time. Literally no help while in the editor so you just have to know it. Two modes…input and command…get used to it. You could …”man vi”…to read help

30 VI Notice all the nice help you get in this editor!

31 Some VI Help One command to help with vi –As soon as you open vi, use the command :set showmode –This displays which mode you are in…

USE THE vi Cheat Sheet! 32

33 Other Editors PICO: One of the newer UNIX/LINUX editors. Popular because it is easy to use. Usually ships with the pine program…so if you have pine you should have PICO.

34 PICO Much better huh?

35 System info The uname command

36 To snoop with who, w, finger Who is logged on to system

grep is Your Friend grep searches the named input FILEs for lines containing a match to the given PATTERN. By default, grep prints the matching lines –grep –grep host zone.txt 37