Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

In this programming assignment, you are asked to experience shell, shell programming, and system programming on Linux platform. This assignment assists you for better understanding

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

In this programming assignment, you are asked to experience shell, shell programming, and system programming on Linux platform. This assignment assists you for better understanding of Unix/Linux shell, system programming, and enhancing programming skills and experiencing with programming on a Unix-like environment. Part 1. Shell Experiences and Programming You are asked to experience Unix/Linux shell in this part of assignment. Requirements: 1. 2. Run the displayinfo.sh script we provided on the Blackboard and report the result. Made a simple modification to the greeting.sh script we provided - the script only shows a greeting message when it's morning, afternoon, or evening; please make a simple code modification to show a greeting message "Hello [your login name!" when it's other than morning, afternoon, or evening. (Use if conditions and environment variables rather than just printing out a constant string as your login name) Run the modified greeting.sh script on the Oak machine and report the result. 3. Part 2. System Programming and Process Management You are asked to experience basic system programming including process creation and termination on a Linux platform in this part of programming assignment. You are asked to create multiple children processes to work under one parent process. In theory, children processes can do their own work separately or cooperatively to accomplish a task. In this assignment, these children processes simply print out a "hello" message together with their PIDs (process IDs) and exit. You should consider to use fork0 and wait0 system calls to implement this program. Requirements: 1. Take the number of children processes as an argument when the parent process creates children processes. This argument can be hard coded and defined (with #define) in the program or can be passed through a command line argument

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

Modern Database Management

Authors: Jeff Hoffer, Ramesh Venkataraman, Heikki Topi

13th Edition Global Edition

1292263350, 978-1292263359

Students also viewed these Databases questions