Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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

image text in transcribed

image text in transcribed

displayinfo

image text in transcribed

greeting

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. Run the displayinfo.sh script we provided on the Blackboard and report the result. 2. Made a simple modification to the greeting.sh script we provided - the script only shows a greeting message when it's morning, aftenoon, or evening; please make a simple code modification to show a greeting message "Hello [your login name]!" when it's other than morning, (Use if conditions and environment variables rather than just printing out a constant string as your login name) afternoon, or evening 3. Run the modified greeting.sh script on the Oak machine and report the result. 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 ( wait0 system calls to implement this program. process IDs) and exit You should consider to use fork0 and 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 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. Run the displayinfo.sh script we provided on the Blackboard and report the result. 2. Made a simple modification to the greeting.sh script we provided - the script only shows a greeting message when it's morning, aftenoon, or evening; please make a simple code modification to show a greeting message "Hello [your login name]!" when it's other than morning, (Use if conditions and environment variables rather than just printing out a constant string as your login name) afternoon, or evening 3. Run the modified greeting.sh script on the Oak machine and report the result. 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 ( wait0 system calls to implement this program. process IDs) and exit You should consider to use fork0 and 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

The Database Experts Guide To SQL

Authors: Frank Lusardi

1st Edition

0070390029, 978-0070390027

More Books

Students also viewed these Databases questions