Chapter 9 Basic File Processing. Displaying File Contents cat, cat w/append tac nl pr more less head tail.

Slides:



Advertisements
Similar presentations
I/O & Perintah Dasar Linux Onno W. Purbo
Advertisements

UNIX Chapter 09 Basic File Processing Mr. Mohammad Smirat.
1 CSE 390a Lecture 2 Exploring Shell Commands, Streams, and Redirection slides created by Marty Stepp, modified by Josh Goodwin
CIS 240 Introduction to UNIX Instructor: Sue Sampson.
Chapter 6 Basic Directory and File Management. Command Line Control Characters Control-s - Stops screen output - rarely used Control-q - Resumes screen.
Lecture 01CS311 – Operating Systems 1 1 CS311 – Lecture 01 Outline Course introduction Setting up your system Logging onto the servers at OSU with ssh.
Grep, comm, and uniq. The grep Command The grep command allows a user to search for specific text inside a file. The grep command will find all occurrences.
UNIX Command-line Introduction Terence Parr. Navigating  cd  pwd  ls  pushd/pod  cd  pwd  ls  pushd/pod.
Embedded Programming and Robotics Lesson 13 Basic Linux 1.
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.
Review for Exam 1 Exam 1 on June 24 CSC 3320.
Learning basic Unix command IT 325 operating system.
Advanced File Processing
CHAPTER 1 UNIX FOR NONPROGRAMMERS By U ğ ur Halıcı.
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.
Linux environment ● Graphical interface – X-window + window manager ● Text interface – terminal + shell.
Dedan Githae, BecA-ILRI Hub Introduction to Linux / UNIX OS MARI eBioKit Workshop; Nov , 2014.
File Permissions. What are the three categories of users that apply to file permissions? Owner (or user) Group All others (public, world, others)
Jozef Goetz, expanded by Jozef Goetz, 2009 Credits: Parts of the slides are based on slides created by UNIX textbook authors, Syed M. Sarwar, Robert.
System Administration Introduction to Unix Session 2 – Fri 02 Nov 2007 Reference:  chapter 1, The Unix Programming Environment, Kernighan & Pike, ISBN.
INTRODUCTION TO LINUX Jacob Chan. GNU/Linux Consists of Linux kernel, GNU utilities, and open source and commercial applications Works like Unix –Multi-user.
Advanced File Processing. 2 Objectives Use the pipe operator to redirect the output of one command to another command Use the grep command to search for.
Chapter Five Advanced File Processing Guide To UNIX Using Linux Fourth Edition Chapter 5 Unix (34 slides)1 CTEC 110.
Chapter Five Advanced File Processing. 2 Objectives Use the pipe operator to redirect the output of one command to another command Use the grep command.
Next Unix Topics Tuesday, 2/11 & 18/2014. Change Password (by 2/14/14) ssh to account on – faclinux.cse.ohio-state.edu – stdlinux.cse.ohio-state.edu passwd.
Introduction to UNIX Road Map: 1. UNIX Structure 2. Components of UNIX 3. Process Structure 4. Shell & Utility Programs 5. Using Files & Directories 6.
L&T Infotech1 UNIX – Getting Started - Aneesh Ramani.
November 5, 2015CIS 118 Intro to UNIX What’s a Unix? Unix is an Operating System Designed for high-traffic usage Many variants –Linux, BSD: free versions.
Linux Essentials Programming and Data Structures Lab M Tech CS – I 2014 Arijit Bishnu Ansuman Banerjee Debapriyo Majumdar.
Chapter Five Advanced File Processing. 2 Lesson A Selecting, Manipulating, and Formatting Information.
Chapter 4 LINUX Shells. Table 4.1 Shell Locations and Program Names.
CSE 374 Programming Concepts & Tools Hal Perkins Fall 2015 Lecture 2a – A Unix Command Sampler (Courtesy of David Notkin, CSE 303)
Linux Stuff Last Update Copyright 2014 Kenneth M. Chipps Ph.D. 1.
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.
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.
The Unix File sytem. Introduction Tree structure …
Basic Unix Commands. Listing files and directories ● ls:command is used to list the files and ● directories in present working directory ● ls command.
Lecture 1: Introduction, Basic UNIX Advanced Programming Techniques.
Learning basic Unix command It 325 operating system.
CIT 140: Introduction to ITSlide #1 CSC 140: Introduction to IT File Processing.
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).
Learning Unix/Linux Based on slides from: Eric Bishop.
1 Linux Commands. 2 Path You specify a file or directory by its path name:  the full, or absolute, path name or the one relative to a location. The full.
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.
Getting started with CentOS Linux
Andy Wang Object Oriented Programming in C++ COP 3330
Some Linux Commands.
Eric Shook Department of Geography Kent State University
Chapter 6 Filters.
CSE 374 Programming Concepts & Tools
Tutorial of Unix Command & shell scriptS 5027
Tutorial of Unix Command & shell scriptS 5027
Introduction to Linux Week 0 - Thursday.
The Linux Command Line Chapter 6
Guide To UNIX Using Linux Third Edition
Tutorial of Unix Command & shell scriptS 5027
Operating Systems Lecture 5.
The Unix File System.
Getting started with CentOS Linux
Andy Wang Object Oriented Programming in C++ COP 3330
The Linux Command Line Chapter 4
Module 6 Working with Files and Directories
The Linux Command Line Chapter 4
Presentation transcript:

Chapter 9 Basic File Processing

Displaying File Contents cat, cat w/append tac nl pr more less head tail

Table 9.1 Some Useful less Commands

Table 9.1 More less Commands

File Location Commands cp mv ln rm mkdir rmdir

Figure 9.1 Current directory before and after command cp temp temp.bak

Figure 9.2 Current directory before and after command mv temp backups/temp.old

Figure 9.3 Current directory before and after command rm temp backups/temp.old

File Statistics Commands ls –l wc

Comparing Files cmp, zcmp diff, zdiff – Output is a set of commands that can be used with the ed (or vi) editor to convert the first file into the second file – Often used to send out upgrades

Table 9.2 File Conversion Instructions Produced by diff

Removing Repeated Lines uniq command Intended for use on sorted files Produces an output file with only one copy of any repeated consecutive lines

Table 9.3 Printing