SlideShare a Scribd company logo
1 of 1
Download to read offline
4.0 What Is Given As given, the files of source.tbz implement the following. fs33% mkfs D1
creates an initially empty file volume on the simulated disk named D1.dsk. At this point, we do
not need to discuss all the specifics anout the structure of the disk fs33% ls prints a listing, much
like the Unix ls -lisa, of all the files in the root directory of the current file volume. Here is a
stdTestScriptP1.txt. Use it as in ./P0 < stdTestScriptP1.txt . 4.1 Redirection Implement
redirection for the given shell as discussed in class. Use the operator > to redirect the output of a
command into a file on the host's file system. It is safe to assume that the redirection operator
appears only once in the command line. 4.2 Piping Implement piping as discussed in class for
commands executed on the host. For example, the command !ls | !cat executes both commands
on the host. However, the piping needs to be performed in your shell! It is sufficent if your shell
supports single piping, i.e. the concatenation of two commands. Bonus points are available if you
achieve multiple piping. 4.3 Executing in the background Allow your shell to execute commands
in the background using the &. The command prompt should return immediately after issuing the
command no matter how long the execution takes. It is safe to assume that the character & only
appears once in the command. Your shell should support the execution of all types of commands
in the background, i.e. local commands operating on the virtual file system as well as commands
running on the host. 4.4 A Simple Test Session Only the additional elements compared to the
given source code are described below. Add these appropriately to the test script. Our path name
syntax is the same as Unix path names. Obviously, not every arbitrary string is a valid path or
name. Also, the dot and the dot-dot are not permissible as arguments in some contexts below.
Nevertheless these commands must be robust. fs33% ls > test lists the contents of the current
directory of our own file system and redirects the output into the file test of the local directory of
the host's file system. fs33% ls | !cat pipes the output of ls into the local command cat. fs33%
!cat test shows the contents of the file test of the host's file system (which should contain the
output of ls if previously executed as above). fs33% !sleep 15 & waits 15 seconds (since it is
executed in the background the command prompt should be available immediately, though). 5.
Turn In

More Related Content

Similar to 4-0 What Is Given As given- the files of source-tbz implement the foll.pdf

Using Unix
Using UnixUsing Unix
Using Unix
Dr.Ravi
 
Linux presentation
Linux presentationLinux presentation
Linux presentation
Nikhil Jain
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
Cam YP Co., Ltd
 

Similar to 4-0 What Is Given As given- the files of source-tbz implement the foll.pdf (20)

50 most frequently used unix linux commands (with examples)
50 most frequently used unix   linux commands (with examples)50 most frequently used unix   linux commands (with examples)
50 most frequently used unix linux commands (with examples)
 
Using Unix
Using UnixUsing Unix
Using Unix
 
Unit 1-a-brief-history-of-unix-ppt
Unit 1-a-brief-history-of-unix-pptUnit 1-a-brief-history-of-unix-ppt
Unit 1-a-brief-history-of-unix-ppt
 
Directories description
Directories descriptionDirectories description
Directories description
 
Linux presentation
Linux presentationLinux presentation
Linux presentation
 
40 basic linux command
40 basic linux command40 basic linux command
40 basic linux command
 
40 basic linux command
40 basic linux command40 basic linux command
40 basic linux command
 
linux-lecture4.ppt
linux-lecture4.pptlinux-lecture4.ppt
linux-lecture4.ppt
 
Linux commands and file structure
Linux commands and file structureLinux commands and file structure
Linux commands and file structure
 
Unix And Shell Scripting
Unix And Shell ScriptingUnix And Shell Scripting
Unix And Shell Scripting
 
Assignment OS LAB 2022
Assignment OS LAB 2022Assignment OS LAB 2022
Assignment OS LAB 2022
 
Unix
UnixUnix
Unix
 
Linux commands
Linux commandsLinux commands
Linux commands
 
Karkha unix shell scritping
Karkha unix shell scritpingKarkha unix shell scritping
Karkha unix shell scritping
 
Nguyễn Vũ Hưng: Basic Linux Power Tools
Nguyễn Vũ Hưng: Basic Linux Power Tools Nguyễn Vũ Hưng: Basic Linux Power Tools
Nguyễn Vũ Hưng: Basic Linux Power Tools
 
Introduction to linux day1
Introduction to linux day1Introduction to linux day1
Introduction to linux day1
 
Using the command line on macOS
Using the command line on macOSUsing the command line on macOS
Using the command line on macOS
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
 
Linux Introduction (Commands)
Linux Introduction (Commands)Linux Introduction (Commands)
Linux Introduction (Commands)
 
Linux introduction-commands2338
Linux introduction-commands2338Linux introduction-commands2338
Linux introduction-commands2338
 

More from atozsha

Suppose we are in an era in which the rate of growth of the price leve.pdf
Suppose we are in an era in which the rate of growth of the price leve.pdfSuppose we are in an era in which the rate of growth of the price leve.pdf
Suppose we are in an era in which the rate of growth of the price leve.pdf
atozsha
 

More from atozsha (20)

Suppose we have 2 teams- A and B- Each team has 4 members- They are se.pdf
Suppose we have 2 teams- A and B- Each team has 4 members- They are se.pdfSuppose we have 2 teams- A and B- Each team has 4 members- They are se.pdf
Suppose we have 2 teams- A and B- Each team has 4 members- They are se.pdf
 
Suppose you have the following table for a medical clinic- tblPatient(.pdf
Suppose you have the following table for a medical clinic- tblPatient(.pdfSuppose you have the following table for a medical clinic- tblPatient(.pdf
Suppose you have the following table for a medical clinic- tblPatient(.pdf
 
Suppose you have four classes A-B-C and D- B inherits A and D inherits.pdf
Suppose you have four classes A-B-C and D- B inherits A and D inherits.pdfSuppose you have four classes A-B-C and D- B inherits A and D inherits.pdf
Suppose you have four classes A-B-C and D- B inherits A and D inherits.pdf
 
Suppose we are in an era in which the rate of growth of the price leve.pdf
Suppose we are in an era in which the rate of growth of the price leve.pdfSuppose we are in an era in which the rate of growth of the price leve.pdf
Suppose we are in an era in which the rate of growth of the price leve.pdf
 
Suppose we are given an S-element sequence S such that each element in.pdf
Suppose we are given an S-element sequence S such that each element in.pdfSuppose we are given an S-element sequence S such that each element in.pdf
Suppose we are given an S-element sequence S such that each element in.pdf
 
Suppose you believe that TECO's 6 percent dividend growth will only ho.pdf
Suppose you believe that TECO's 6 percent dividend growth will only ho.pdfSuppose you believe that TECO's 6 percent dividend growth will only ho.pdf
Suppose you believe that TECO's 6 percent dividend growth will only ho.pdf
 
Suppose two parents- a father with the genotype AaBbCcDdee and a mothe.pdf
Suppose two parents- a father with the genotype AaBbCcDdee and a mothe.pdfSuppose two parents- a father with the genotype AaBbCcDdee and a mothe.pdf
Suppose two parents- a father with the genotype AaBbCcDdee and a mothe.pdf
 
Suppose there was an old woman who swallowed a cat to catch a bird in.pdf
Suppose there was an old woman who swallowed a cat to catch a bird in.pdfSuppose there was an old woman who swallowed a cat to catch a bird in.pdf
Suppose there was an old woman who swallowed a cat to catch a bird in.pdf
 
Take a moment to think about what the word 'integrity' means to you- a.pdf
Take a moment to think about what the word 'integrity' means to you- a.pdfTake a moment to think about what the word 'integrity' means to you- a.pdf
Take a moment to think about what the word 'integrity' means to you- a.pdf
 
T or F 51) Forests- woodlands- pastures- and rangelands together occup.pdf
T or F 51) Forests- woodlands- pastures- and rangelands together occup.pdfT or F 51) Forests- woodlands- pastures- and rangelands together occup.pdf
T or F 51) Forests- woodlands- pastures- and rangelands together occup.pdf
 
Table4- Measure tnt of size (diameter for cocci- lenath for bacilli) a.pdf
Table4- Measure tnt of size (diameter for cocci- lenath for bacilli) a.pdfTable4- Measure tnt of size (diameter for cocci- lenath for bacilli) a.pdf
Table4- Measure tnt of size (diameter for cocci- lenath for bacilli) a.pdf
 
Suppose there is a lion in the bushes- Arrange the pattem of the pathw.pdf
Suppose there is a lion in the bushes- Arrange the pattem of the pathw.pdfSuppose there is a lion in the bushes- Arrange the pattem of the pathw.pdf
Suppose there is a lion in the bushes- Arrange the pattem of the pathw.pdf
 
4- Govan and Milica were studying for their physiology final exam- The.pdf
4- Govan and Milica were studying for their physiology final exam- The.pdf4- Govan and Milica were studying for their physiology final exam- The.pdf
4- Govan and Milica were studying for their physiology final exam- The.pdf
 
4- From the perspective of the causes of extinction- a reduction in th.pdf
4- From the perspective of the causes of extinction- a reduction in th.pdf4- From the perspective of the causes of extinction- a reduction in th.pdf
4- From the perspective of the causes of extinction- a reduction in th.pdf
 
4- Conclude with an analysis of the results of the Project- 4a- What b.pdf
4- Conclude with an analysis of the results of the Project- 4a- What b.pdf4- Conclude with an analysis of the results of the Project- 4a- What b.pdf
4- Conclude with an analysis of the results of the Project- 4a- What b.pdf
 
4- Newspaper vending machines are designed so that once you have paid.pdf
4- Newspaper vending machines are designed so that once you have paid.pdf4- Newspaper vending machines are designed so that once you have paid.pdf
4- Newspaper vending machines are designed so that once you have paid.pdf
 
4- Choose ONE of the following three research methods- Thoroughly expl.pdf
4- Choose ONE of the following three research methods- Thoroughly expl.pdf4- Choose ONE of the following three research methods- Thoroughly expl.pdf
4- Choose ONE of the following three research methods- Thoroughly expl.pdf
 
4- Depending on whether or not organisms use O2 as an oxidant- they ar.pdf
4- Depending on whether or not organisms use O2 as an oxidant- they ar.pdf4- Depending on whether or not organisms use O2 as an oxidant- they ar.pdf
4- Depending on whether or not organisms use O2 as an oxidant- they ar.pdf
 
5- Consider the bases and the backbone- Which part is more hydrophobic.pdf
5- Consider the bases and the backbone- Which part is more hydrophobic.pdf5- Consider the bases and the backbone- Which part is more hydrophobic.pdf
5- Consider the bases and the backbone- Which part is more hydrophobic.pdf
 
4- Let X and Y be two discrete random variables with joint density fun.pdf
4- Let X and Y be two discrete random variables with joint density fun.pdf4- Let X and Y be two discrete random variables with joint density fun.pdf
4- Let X and Y be two discrete random variables with joint density fun.pdf
 

Recently uploaded

Call Girls in Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in  Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7Call Girls in  Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPSSpellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
AnaAcapella
 

Recently uploaded (20)

Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
 
How to Add New Custom Addons Path in Odoo 17
How to Add New Custom Addons Path in Odoo 17How to Add New Custom Addons Path in Odoo 17
How to Add New Custom Addons Path in Odoo 17
 
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
80 ĐỀ THI THỬ TUYỂN SINH TIẾNG ANH VÀO 10 SỞ GD – ĐT THÀNH PHỐ HỒ CHÍ MINH NĂ...
 
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdfFICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
FICTIONAL SALESMAN/SALESMAN SNSW 2024.pdf
 
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
 
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptxBasic Civil Engineering first year Notes- Chapter 4 Building.pptx
Basic Civil Engineering first year Notes- Chapter 4 Building.pptx
 
Philosophy of china and it's charactistics
Philosophy of china and it's charactisticsPhilosophy of china and it's charactistics
Philosophy of china and it's charactistics
 
Call Girls in Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in  Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7Call Girls in  Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
Call Girls in Uttam Nagar (delhi) call me [🔝9953056974🔝] escort service 24X7
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & Systems
 
21st_Century_Skills_Framework_Final_Presentation_2.pptx
21st_Century_Skills_Framework_Final_Presentation_2.pptx21st_Century_Skills_Framework_Final_Presentation_2.pptx
21st_Century_Skills_Framework_Final_Presentation_2.pptx
 
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
TỔNG ÔN TẬP THI VÀO LỚP 10 MÔN TIẾNG ANH NĂM HỌC 2023 - 2024 CÓ ĐÁP ÁN (NGỮ Â...
 
Graduate Outcomes Presentation Slides - English
Graduate Outcomes Presentation Slides - EnglishGraduate Outcomes Presentation Slides - English
Graduate Outcomes Presentation Slides - English
 
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPSSpellings Wk 4 and Wk 5 for Grade 4 at CAPS
Spellings Wk 4 and Wk 5 for Grade 4 at CAPS
 
This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.This PowerPoint helps students to consider the concept of infinity.
This PowerPoint helps students to consider the concept of infinity.
 
Exploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptx
Exploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptxExploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptx
Exploring_the_Narrative_Style_of_Amitav_Ghoshs_Gun_Island.pptx
 
How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17
 
Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)Accessible Digital Futures project (20/03/2024)
Accessible Digital Futures project (20/03/2024)
 
On National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan FellowsOn National Teacher Day, meet the 2024-25 Kenan Fellows
On National Teacher Day, meet the 2024-25 Kenan Fellows
 
Google Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptxGoogle Gemini An AI Revolution in Education.pptx
Google Gemini An AI Revolution in Education.pptx
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 

4-0 What Is Given As given- the files of source-tbz implement the foll.pdf

  • 1. 4.0 What Is Given As given, the files of source.tbz implement the following. fs33% mkfs D1 creates an initially empty file volume on the simulated disk named D1.dsk. At this point, we do not need to discuss all the specifics anout the structure of the disk fs33% ls prints a listing, much like the Unix ls -lisa, of all the files in the root directory of the current file volume. Here is a stdTestScriptP1.txt. Use it as in ./P0 < stdTestScriptP1.txt . 4.1 Redirection Implement redirection for the given shell as discussed in class. Use the operator > to redirect the output of a command into a file on the host's file system. It is safe to assume that the redirection operator appears only once in the command line. 4.2 Piping Implement piping as discussed in class for commands executed on the host. For example, the command !ls | !cat executes both commands on the host. However, the piping needs to be performed in your shell! It is sufficent if your shell supports single piping, i.e. the concatenation of two commands. Bonus points are available if you achieve multiple piping. 4.3 Executing in the background Allow your shell to execute commands in the background using the &. The command prompt should return immediately after issuing the command no matter how long the execution takes. It is safe to assume that the character & only appears once in the command. Your shell should support the execution of all types of commands in the background, i.e. local commands operating on the virtual file system as well as commands running on the host. 4.4 A Simple Test Session Only the additional elements compared to the given source code are described below. Add these appropriately to the test script. Our path name syntax is the same as Unix path names. Obviously, not every arbitrary string is a valid path or name. Also, the dot and the dot-dot are not permissible as arguments in some contexts below. Nevertheless these commands must be robust. fs33% ls > test lists the contents of the current directory of our own file system and redirects the output into the file test of the local directory of the host's file system. fs33% ls | !cat pipes the output of ls into the local command cat. fs33% !cat test shows the contents of the file test of the host's file system (which should contain the output of ls if previously executed as above). fs33% !sleep 15 & waits 15 seconds (since it is executed in the background the command prompt should be available immediately, though). 5. Turn In