Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Linux Intro Week 12 Practice 2. Discovery Exercises 1. Name the command that can be used to do each of the following: a. Create

image text in transcribedimage text in transcribed

Linux Intro Week 12 Practice 2. Discovery Exercises 1. Name the command that can be used to do each of the following: a. Create an alias called mm that displays only those filesystems that are mounted and contain an ext4 filesystem. b. Create and export a variable called NEWHOME that is equivalent to the value contained in the HOME variable. c. Find all files that start with the word "host" starting from the /etc directory and save the Standard Output to a file called file1 and the Standard Error to the same file. d. Display only the lines from the output of the set command that have the word "bash" in them. This output on the terminal screen should be sorted alphabetically. e. Display only the user name (first field) in the colon-delimited /etc/passwd file and save the output to a file called users in the current directory. Show the current day by printing just the first field of output from 'date' (don't use 'date's builtin formatting codes). 3. 4. Filter out all non-commented lines of /etc/services that represent UDP services (the center column is "portnumber/protocol"), then convert "udp" to uppercase with 'sed'. Save the results to a file called udpservices.txt. Sort the output of `ps aux by VSZ (virtual memory size - how much has been allocated for the process, not necessarily used in RAM) using 'sort' (not the `ps options), from highest to lowest. 5. Starting with the output of 'last', build a pipeline that counts the number of times the system was rebooted. (reboot logins) 6. vmstat shows memory usage statistics. Display just the amount of swap in use (3rd row, 3rd column). 7. Find all files in the /etc directory ending with a .conf extension, substitute ".CONF" for ".conf" in each filename in the list (do not change the actual files), and save the altered list of names to a file called "bigconf.txt" 8. Make a copy of /etc/resolv.conf in /tmp. Edit /tmp/resolv.conf in place with 'sed', making a backup with a ".bak" extension and replacing all instances of "10.6.8" with "192.5.7". (WARNING: be sure you edit the copy in /tmp or you'll lose network connectivity.)

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

Computer Networking A Top-Down Approach

Authors: James Kurose, Keith Ross

7th edition

978-0133594140

More Books

Students also viewed these Computer Network questions