Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In C code, please whole code In C code ( UNIX C CODE), please Write a program called minishell that creates two child processes: one

In C code, please whole code In C code ( UNIX C CODE), please

Write a program called minishell that creates two child processes: one to execute 'ls' and the other to execute 'sort'. After the forks, the original parent process waits for both child processes to finish before it terminates. The standard output of 'ls' process should be piped to the input to the 'sort' process. Make sure you close the unnecessary open files for the three processes.

---

Carefully study the examples provided: fork.c, myls.c, myshell.c, etc. You need to know how they work in order for you to finish this assignment; the examples

fork.c (link where to find the example) https://drive.google.com/file/d/0B9b80md_Miu5bTN0cV9ndkZ5T1k/view?usp=sharing

myls.c (link where to find the example) https://drive.google.com/file/d/0B9b80md_Miu5N0ZvaGlRZDdRWjA/view?usp=sharing

myshell.c (link where to find the example) https://drive.google.com/file/d/0B9b80md_Miu5N0xyUFk0bGdDXzQ/view?usp=sharing

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Concepts

Authors: David M Kroenke, David J Auer

6th Edition

0132742926, 978-0132742924

More Books

Students also viewed these Databases questions