Unix/Linux Go Back    

UNIX for Beginners Questions & Answers If you're not sure where to post a Unix or Linux question, post it here. All unix and Linux beginners welcome in this forum!

Scripting Homework, need help

UNIX for Beginners Questions & Answers

Thread Tools Search this Thread Display Modes
Old Unix and Linux 4 Weeks Ago   -   Original Discussion by arbogastcarl
arbogastcarl's Unix or Linux Image
arbogastcarl arbogastcarl is offline
Registered User
Join Date: May 2018
Last Activity: 26 May 2018, 7:13 PM EDT
Location: 32.6245° N, 115.4523° W
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Scripting Homework, need help

Hi I just started scripting in my Unix class, but can't understand it and have trouble with homework. This is my homework:

Dean needs a daily written report of the status of his Unix computer. He wants to obtain certain information about users and processes that are only accessible by executing utility commands. He does not want to have to execute these commands every day and has asked you to help him write a script that employs these utilities to obtain the information he needs. He would also like the results of the execution script to be saved to a file.

Step 1: Open the vi editor to create a script called Information. Add the contents from the following table to the script.

Headings Utilities
Today's date is: date
The current users logged into the system are: who , cut or awk, sort, uniq
My current startup directory is: pwd
Today's identification information is: id
The processes running on my system are: ps

Step 2: Save the script and exit to the shell. Make the script executable and proceed to run the Information script. Submit your script to Canvas.

Step 3: Redirect the output of the Information script to a file named DailyInfo that Dean can access daily.

can somebody guide on how to do it.
Sponsored Links
Old Unix and Linux 4 Weeks Ago   -   Original Discussion by arbogastcarl
Scrutinizer's Unix or Linux Image
Scrutinizer Scrutinizer is online now Forum Staff  
Join Date: Nov 2008
Last Activity: 22 June 2018, 10:57 AM EDT
Location: Amsterdam
Posts: 11,834
Thanks: 545
Thanked 3,455 Times in 3,045 Posts
Do not post classroom or homework problems in the main forums. Homework and coursework questions can only be posted in this forum under special homework rules.

Please review the rules, which you agreed to when you registered, if you have not already done so.

More-than-likely, posting homework in the main forums has resulting in a forum infraction. If you did not post homework, please explain the company you work for and the nature of the problem you are working on.

If you did post homework in the main forums, please review the guidelines for posting homework and repost.

Thank You.

The UNIX and Linux Forums.
Sponsored Links

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Linux More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Perl Scripting issue - homework valhalla Homework & Coursework Questions 2 05-17-2011 03:54 AM
Perl scripting or shell scripting? Anna Hussie Web Programming 1 04-20-2011 04:08 AM
Call Shell scripting from Perl Scripting. anupdas Shell Programming and Scripting 2 02-12-2010 07:07 AM
Unix Scripting Question (Homework) pitdark Shell Programming and Scripting 1 01-07-2010 08:14 AM
scripting guru's pls help me with scripting on AIX thatiprashant Shell Programming and Scripting 1 01-20-2006 06:58 PM

All times are GMT -4. The time now is 11:02 AM.