CIS 90 - Lesson 6 Lesson Module Status Slides – basics Test ready and copies made - Properties - done Flash cards – No-stress quiz – done Web Calendar.

Slides:



Advertisements
Similar presentations
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 -
Advertisements

Working with Files How to create, view, copy, rename and print files.
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.
Linux+ Guide to Linux Certification, Second Edition
CS 497C – Introduction to UNIX Lecture 12: - The File System Chin-Chih Chang
CS 497C – Introduction to UNIX Lecture 16: - File Attributes Chin-Chih Chang
Guide To UNIX Using Linux Third Edition
Guide To UNIX Using Linux Third Edition
Copyrights© 2008 BVU Amplify DITM DATA BASE MANAGEMENT system Page:1 Lesson 2: The File System By Simi.
A Mini UNIX Tutorial. What’s UNIX?  An operating system run on many servers/workstations  Invented by AT&T Bell Labs in late 60’s  Currently there.
Learning basic Unix command IT 325 operating system.
COMP1070/2002/lec4/H.Melikian COMP1070 Lecture #5  Files and directories in UNIX  Various types of files  File attributes  Notion of pathname  Commands.
Guide To UNIX Using Linux Fourth Edition
1 Day 3 Directories Files Moving & Copying. 2 Case Sensitive First thing to learn about UNIX is that everything is case sensitive. Thus the files: –enda.
1 THE UNIX FILE SYSTEM By Chokechai Chuensukanant ID COSC 513 Operating System.
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.
CIS 90 - Lesson 6 Lesson Module Status Slides – basics Test ready and copies made - Properties - done Flash cards – No-stress quiz – done Web Calendar.
Linux Directory Navigation. File & Directory Commands This is a minimal list of Unix commands that you must know for file management: ls (list) mkdir.
Working with Files Chapter 5. Display a Calendar Display a calendar for a specific month – cal Display a calendar for a specific year – cal 2000.
Files & Directories Objectives –to be able to describe and use the Unix file system model and concepts Contents –directory structure –file system concepts.
CIS 90 - Lesson 15 Lesson Module Status Slides – draft Properties - done Flash cards – 1 st Minute quiz – NA Web calendar summary – done Web book pages.
CIS 90 - Lesson 14 Lesson Module Status Slides – Properties - Flash cards – No-stress quiz – Web calendar summary – Web book pages – Commands – Lab – done.
Chapter Four UNIX File Processing. 2 Lesson A Extracting Information from Files.
Guide To UNIX Using Linux Fourth Edition
Linux+ Guide to Linux Certification, Second Edition
CIS 90 - Lesson 7 Lesson Module Status Slides – draft Properties - done Flash cards – No-stress quiz – Web Calendar summary – Web book pages – done Commands.
Carnegie Mellon Linux Boot Camp Jenna MacCarley, Peter Pearson, Shashank Goyal 9/19/2015.
CIS 90 - Lesson 15 Lesson Module Status Slides – Properties - Flash cards – No-stress quiz – Web calendar summary – Web book pages – Commands – Lab – done.
INTRODUCTION TO LINUX Jacob Chan. GNU/Linux Consists of Linux kernel, GNU utilities, and open source and commercial applications Works like Unix –Multi-user.
CPSC 217 T03 Week I Part #1: Unix and HELLO WORLD Hubert (Sathaporn) Hu.
CIS 90 - Lesson 7 Lesson Module Status Slides – draft Properties - done Flash cards – No-stress quiz – Web Calendar summary – Web book pages – done Commands.
BIF703 Hard & Symbolic Links. What is a file system Link? A link is a pointer to a file. This pointer associates a file name with a number called an i-node.
Managing Files. Module 5 Managing Files ♦ Introduction “On a Linux system, everything is a file; if something is not a file, it is a process.” ♦ Topics.
Linux file system "On a UNIX system, everything is a file; if something is not a file, it is a process." Sorts of files (on a Linux system) Directories:
Introduction to Unix – CS 21 Lecture 4. Lecture Overview * cp, mv, and rm Looking into files The file command head and tail cat and more What we’ve seen.
BIF713 Basic Unix/Linux Commands Getting Help with Commands.
ITR3 lecture 6: intoduction to UNIX Thomas Krichel
Welcome to CS323 Operating System lab 1 TA: Nouf Al-Harbi NoufNaief.net.
Linux+ Guide to Linux Certification, Third Edition
Linux+ Guide to Linux Certification, Third Edition
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.
Λειτουργικά Συστήματα – Lab2 Γιάννης Πετράκης. Directory Navigation and Control  The Unix file system is set up like a tree branching out from the root.
2 Manual & Filestore Mauro Jaskelioff. Introduction Using the manual The UNIX filestore File permissions.
SUSE Linux Enterprise Desktop Administration Chapter 7 Manage Directories and Files.
PTA Linux Series Copyright Professional Training Academy, CSIS, University of Limerick, 2006 © Workshop III - Part B Shell Commands Professional Training.
Files and Directories in UNIX The first file in UNIX file system is “root” or “/”
UNIX filesystem CS 2204 Class meeting 2 *Notes by Doug Bowman and other members of the CS faculty at Virginia Tech. Copyright
Linux Stuff Last Update Copyright 2014 Kenneth M. Chipps Ph.D. 1.
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.
Learning basic Unix command It 325 operating system.
File Management commands cat Cat command cat cal.txt cat command displays the contents of a file here cal.txt on screen (or standard out).
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.
Linux Filesystem Management
Getting Started with Linux
Chapter 11 Command-Line Master Class
Commands Basic syntax of shell commands UNIX or shell commands have a basic structure command -options target command comes first (such as cd or ls) any.
Linux file system "On a UNIX system, everything is a file;
Scoutmaster, Scoutmaster he's our man. If he can't do it, nobody can.
The Command Prompt Commands are the way to “do things” in Unix
The Unix File System.
Chapter Four UNIX File Processing.
The Linux Command Line Chapter 4
Module 6 Working with Files and Directories
Lab 2: Terminal Basics.
January 26th, 2004 Class Meeting 2
The Linux Command Line Chapter 4
Presentation transcript:

CIS 90 - Lesson 6 Lesson Module Status Slides – basics Test ready and copies made - Properties - done Flash cards – No-stress quiz – done Web Calendar summary – done Web book pages – done Commands – done Skills pacing - NA Lab – done Supplies – NA Class PC's – NA

CIS 90 - Lesson 6 ObjectivesAgenda Be able to create, copy, move, remove and link files Planning survey Housekeeping Test Managing files Wrap up  = hands on exercise for topic Managing Files

CIS 90 - Lesson 5 Housekeeping

CIS 90 - Lesson 6 Previous material and assignment 1.Planning survey by "trained assistant" 2.Questions on previous material or labs?

Test CIS 90 - Lesson 6 / You may use: One 8.5" x 11" crib sheet Local access to the Red Hat VM Remote access to Opus What are the three elements of a UNIX file? What are two commands you can use to read through long text files? How do you distinguish between relative and absolute paths?

CIS 90 - Lesson 6 Managing Files

Managing the UNIX/Linux File System Objectives CIS 90 - Lesson 6 / Name the three elements of a Unix file, and where each is stored. Be able to manage the files in your home directory using: mkdir cp mv rmdir rm ln

CIS 90 – Lesson 6 UNIX Files The three elements of a file /home/cis90/simmsben/Poems $ ls ant Blake nursery Shakespeare twister Yeats /home/cis90/simmsben/Poems $ ls -l twister -rw-r--r-- 1 simmsben cis Jul twister /home/cis90/simmsben/Poems $ cat twister A tutor who tooted the flute, tried to tutor two tooters to toot. Said the two to the tutor, "is it harder to toot? Or to tutor two tooters to toot?"

CIS 90 - Lesson 6 Partition Boot Sector Data Master Boot Record (MBR) Partition Boot Sector Data Partition Boot Sector Data Partition Boot Sector Data Unused Boot Sector Data Unused Boot Sector File Systems Linux Superblock Inode Table ext2 file system Data Blocks

CIS 90 - Lesson 6 Superblock Inode Table ext2 file system Data Blocks ~]$ls -il letter rw-r--r-- 1 simmsben cis Jul letter Hello Mother! Hello Father! Here I am at Camp Granada. Things are very entertaining, and they say we'll have some fun when it stops raining. All the counselors hate the waiters, and the lake has alligators. You remember Leonard Skinner? He got ptomaine poisoning last night after dinner. Now I don't want this to scare you, but my bunk mate has malaria. You remember Jeffrey Hardy? Their about to organize a searching party. Take me home, oh Mother, Father, take me home! I hate Granada. Don't leave me out in the forest where I might get eaten by a bear! Take me home, I promise that I won't make noise, or mess the house with other boys, oh please don't make me stay -- I've been here one whole day. Dearest Father, darling Mother, how's my precious little brother? I will come home if you miss me. I will even let Aunt Bertha hug and kiss me! Wait a minute! It's stopped hailing! Guys are swimming! Guys are sailing! Playing baseball, gee that's better! Mother, Father, kindly disregard this letter. Alan Sherman bigfile bin letter bigfile bin letter simmsben cis Pointer(s) to data blocks inode number Type Number of links User Group Size Modification time Access Time change time Pointer(s) to data blocks rw-r—r-- Permissions

Managing the UNIX/Linux File System Creating CIS 90 - Lesson 6 / Commands: touch creates an empty ordinary file(s), or if the file already exists, it updates the time stamp. mkdir creates an empty directory(s) options: -p echo "string" > new file Creates or overwrites a text file

Managing the UNIX/Linux File System Copying CIS 90 - Lesson 6 / Commands: cp or cp or cp options: -i –r i = warns before overwriting r = recursive (copies all sub folders)

Managing the UNIX/Linux File System Moving CIS 90 - Lesson 6 / Commands: mv or mv or mv options: -i i = warns before overwriting

Managing the UNIX/Linux File System Renaming CIS 90 - Lesson 6 / Commands: mv

Managing the UNIX/Linux File System Removing CIS 90 - Lesson 6 / Commands: rm... options: -i -r –f i = prompt before overwrite r = recursive (delete subdirectories) f = force (never prompt) rmdir Directories must be empty for this to work

Managing the UNIX/Linux File System Linking CIS 90 - Lesson 6 / Commands: ln options: -s s = symbolic link (like Windows shortcut)

CIS 90 - Lesson 6 Class Exercise Managing Files  In your home directory, create a directory named oct  Change into the new directory  Create four files named zero, one, two, three, and four, each containing the digit according to the name of the file. E.g echo 1 > one  Rename the zero file so that it is a hidden.  Print the first line of each file with one command.  Create a new directory inside oct named numbers.  Copy all the files into the directory numbers.  How about.zero? Copy that file too into numbers.  Remove the four files from the oct directory.  change into the numbers directory and move the files there back up to the parent directory.  Hard link one to uno, two to dos, three to tres, and four to cuatro  Make symbolic links 1 to one, 2 to tow, 3 to three and 4 to four.  Remove the numbers directory.  Explain everything in ls –li output to a partner.

CIS 90 - Lesson 6 Wrap up

CIS Lesson 6 New commands: cpcopy files lnlink files mkdirmake directory mvmove or rename files rmremove files rmdirremove directory touchmake/modify a file

CIS 90 - Lesson 6 Next Class Assignment: Check Calendar Page on web site to see what is due next week: Quiz questions for next class: What command is used to rename a file? If two files are hard linked do they have the same or different inode numbers? What option for the rm command provides confirmation when deleting files?

CIS 90 - Lesson 6 Backup