Question: 1 . Create a shell script containing the ` echo ` , ` whoami ` , ` groups ` , and ` pwd ` commands.
Create a shell script containing the echowhoamigroups and pwd commands. It should produce output similar to the following:
You are:
root
You are a member of the following groups:
root bin daemon sys adm disk wheel
Your current working directory is:
tmp
Be sure to include the following:
a An appropriate hashpling line
b A comment with your name and when the script was created
c The commands required to perform the desired result
Create a shell script containing the echowhoamigroups and pwd commands. It should produce output similar to the following:
You are:
root
You are a member of the following groups:
root bin daemon sys adm disk wheel
Your current working directory is:
tmp
Be sure to include the following:
a An appropriate hashpling line
b A comment with your name and when the script was created
c The commands required to perform the desired result
Change the permissions on your script so it is executable as a command by any user on the system but is only writable by the owner.
Run your script.
Create another shell script containing the id and groups commands. Use a named variable in your script to represent the user name your script will get info about. You can set the value of the variable in the script, by prompting the user, or best by copying the value of the appropriate command line argument passed into your script. Sample output should look something like this:
user@mdfc ~$ myscript root
root's UID is:
root is a member of these groups:
root : root bin daemon sys adm disk wheel
user@mdfc ~$ myscript sam
sam's UID is:
sam is a member of these groups:
sam : sam sales
Test your script by setting the appropriate permissions and running itsame as # and # not scored
Mount the exportsexam share from the NFS server on mntnfsexamHint: What do you need to do first if the mount point doesn't exist?
Verify that the remote storage is now mounted by displaying all currently mounted filesystems.
Create a file with your name in mntnfsexam on the remote server
View the contents of the mntnfsexam directory. The file you just created should appear. not scored
Disconnect from the exam share on the NFS server.
Verify that the storage is no longer mounted. same as # not scored
View the contents of the mntnfsexam directory. The file you just created should no longer appear. Why?
A second hard disk has been added to your VM It should appear as devsdb Partition devsdb into two primary partitions of equal size. Set the appropriate partition type number if needed.
Format the first partition on devsdb with the Ext filesystem. Leave the second partition alone.
Mount the newly formatted partition on mntdisk
Verify that the newly formatted filesystem is now mounted by displaying all currently mounted filesystems. same as # not scored
What file do you need to edit to make your machine mount mntdisk each time it boots?
Provide the exact line of configuration you would need to add to that file to make your machine mount mntdisk each time it boots. Hint: See p of your text.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
