Great Deal! Get Instant $10 FREE in Account on First Order + 10% Cashback on Every Order Order Now

CS 140U Homework 6 ================== Term: XXXXXXXXXXSpring 2020 Instructions: XXXXXXXXXXCreate a document named "homework_6" in your home directory on Linux XXXXXXXXXXthat contains the answers to...

1 answer below »
CS 140U Homework 6
==================
Term: XXXXXXXXXXSpring 2020
Instructions:
XXXXXXXXXXCreate a document named "homework_6" in your home directory on Linux
XXXXXXXXXXthat contains the answers to the questions below.
XXXXXXXXXXThis homework assignment references chapters 1 through 4 of the text.
XXXXXXXXXXWhen you have completed your file (and entered all of your answers)
XXXXXXXXXXemail your homework_6 file to me (doug.jones) using the command:
XXXXXXXXXXmailx -s"140u homework_6" -a homework_6 doug.jones < /dev/null
XXXXXXXXXXALSO transfer your homework_6 file to your desktop and upload it to
XXXXXXXXXXthe Desire2Learn dropbox for this assignment.
XXXXXXXXXXThis assignment is due no later than 11:30pm on Friday, June 5th, 2020
XXXXXXXXXXYour email must be received by that time.
XXXXXXXXXXBe sure to clearly label each of your answers clearly so that I
XXXXXXXXXXknow what question is being addressed.
Questions:
XXXXXXXXXXWrite a bash script to display the arithmetic sum of the command line
XXXXXXXXXXarguments. You may assume all arguments are digits.
XXXXXXXXXXWrite a bash script that accepts a file glob specification on the command
XXXXXXXXXXline, and moves each of the matching files to the cu
ent user's
XXXXXXXXXXlogin home directory.
XXXXXXXXXXWrite a bash script that accepts a file glob specification on the command
XXXXXXXXXXline, and creates a tar archive file that contains the matching files.
XXXXXXXXXXThe tar archive file name should include the name of the cu
ent use
XXXXXXXXXXand the date and time the archive file was made.
XXXXXXXXXXWrite a bash script that will kill all processes owned by the cu
ent
XXXXXXXXXXuser, except for those processes that are ancestors of the process
XXXXXXXXXXthat is executing script.
XXXXXXXXXXWrite a bash script that will accept a list of user names on the command line,
XXXXXXXXXXand for each user in the list report if the user is logged in (or not).
XXXXXXXXXXWrite a bash script that will accept a file glob specification on the
XXXXXXXXXXcommand line, and report if all files have the same inode number.
XXXXXXXXXXWrite a bash script that will accept a file name on the command line,
XXXXXXXXXXand then list the names (and full path) of all files with the same inode
XXXXXXXXXXnumber. Do not display any e
or messages or other information - just
XXXXXXXXXXdisplay the names and full path of the matches.
XXXXXXXXXXWrite a bash script that will accept the name of a text file on the
XXXXXXXXXXcommand line, and then display the number of digits XXXXXXXXXXfound in
XXXXXXXXXXthe contents of the file. Do not use sed, grep, awk, or vim.
XXXXXXXXXXWrite a bash script that will accept the name of a text file on the
XXXXXXXXXXcommand line, and then remove all blank lines from the file.
XXXXXXXXXXDo not use sed, grep, awk, or vim. You may create temporary files
XXXXXXXXXXif you wish.
XXXXXXXXXXWrite a bash script that will accept the name of a text file on
XXXXXXXXXXthe command line, and then remove all lines that begin with a
XXXXXXXXXXvowel (a, e, i, o, u). Do not use sed, grep, awk, or vim. You may
XXXXXXXXXXcreate temporary files if you wish.
Answered Same Day May 27, 2021

Solution

Sandeep Kumar answered on May 31 2021
155 Votes
4.sh#!
in
ash
pkill -u $USER
5.sh#!
in
ash
ead -p 'Enter username to check: ' use
if who -u | grep -q "^$user "; then
top -u "$user"
else
echo "User $user is not logged in"
fi
6.sh#!
in
ash
stat -c '%i' * > ino
#sort ino | uniq -c
uniq -d ino
7.sh
#!
in
ash
ead -p...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here