0% found this document useful (0 votes)
68 views4 pages

Unix I/O and Process Management Guide

The lab assignment aims to study and implement redirecting input/output, manual help, background processing, managing multiple processes, changing process priority, and filter commands like sort, grep, sed, head, tail, cut, and paste. Specifically, it covers using sort to arrange files, grep to search files for patterns, sed to perform find/replace edits on files, and paste to join files horizontally by outputting tab-delimited lines.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
68 views4 pages

Unix I/O and Process Management Guide

The lab assignment aims to study and implement redirecting input/output, manual help, background processing, managing multiple processes, changing process priority, and filter commands like sort, grep, sed, head, tail, cut, and paste. Specifically, it covers using sort to arrange files, grep to search files for patterns, sed to perform find/replace edits on files, and paste to join files horizontally by outputting tab-delimited lines.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Lab Assignment No.

6
AIM:

To study and implement redirecting input output, manual help, background


processing, managing multiple processes, changing process priority, implement and
practice filter related commands like sort, grep, sed, head, tail, cut, paste.

Theory:

1. Sort-
SORT command is used to sort a file, arranging the records in a particular order. By
default, the sort command sorts file assuming the contents are ASCII. Using options
in sort command, it can also be used to sort numerically.
2. Grep-
The grep filter searches a file for a particular pattern of characters, and displays all
lines that contain that pattern. The pattern that is searched in the file is referred to as
the regular expression (grep stands for globally search for regular expression and
print out).

grep [options] pattern [files]


3. sed-
SED command in UNIX is stands for stream editor and it can perform lots of function
on file like, searching, find and replace, insertion or deletion. Though most common
use of SED command in UNIX is for substitution or for find and replace. By using
SED you can edit files even without opening it, which is much quicker way to find and
replace something in file, than first opening that file in VI Editor and then changing it.
4. Paste-
Paste command is one of the useful commands in Unix or Linux operating system. It
is used to join files horizontally (parallel merging) by outputting lines consisting of
lines from each file specified, separated by tab as delimiter, to the standard output.
When no file is specified, or put dash (“-“) instead of file name, paste reads from
standard input and gives output as it is until a interrupt command [Ctrl-c] is given

You might also like