Networking Chapter 8 Homework Command1 Describe The Syntax The Restore Command2 Note That Default Restore Copies

subject Type Homework Help
subject Pages 9
subject Words 2547
subject Authors Michael Palmer

Unlock document.

This document is partially blurred.
Unlock all pages and 1 million more documents.
Get Access
page-pf1
A Guide to Unix Using Linux, Fourth Edition 8-1
Chapter 8
Exploring the UNIX/Linux Utilities
At a Glance
Instructor’s Manual Table of Contents
Overview
Objectives
Teaching Tips
Quick Quizzes
page-pf2
A Guide to Unix Using Linux, Fourth Edition 8-2
Lecture Notes
Overview
In this chapter, you learn more about the utilities in UNIX/Linux. First, you
survey the categories of UNIX/Linux utilities, including file-processing utilities,
system status utilities, network utilities, communications utilities, security
utilities, programming utilities, source code management utilities, and miscellaneous
utilities. Details and examples are provided for a selection of these utilities: dd, df, du,
top, uptime, free, ps, kill, ispell, cmp, groff, dump, restore, mail, ifconfig, ping,
traceroute, netstat, and service.
Chapter Objectives
Understand many of the UNIX/Linux utilities that are available and how they are
classified
Use the dd utility to copy and convert files
Monitor hard disk usage
Use system status utilities
Monitor and manage processes
Check the spelling of text in a document
Teaching Tips
Understanding UNIX/Linux Utilities
1. Note that UNIX/Linux utilities are classified into the following categories (briefly
describe each):
a. File processing
b. System status
page-pf3
A Guide to Unix Using Linux, Fourth Edition 8-3
Classifying UNIX/Linux Utilities
1. Tables 8-1 through 8-8 provide a comprehensive listing of UNIX/Linux utilities for
each of the eight categories listed before. Describe a few utilities from each of these
Using the dd Command
1. Describe the use and syntax of the dd command.
Specifying block size, an optional requirement, speeds copying, especially when
Checking Hard Disk Usage
1. Explain that there are some basic strategies that can be used to maintain adequate free
space:
a. Be vigilant against running dangerously low on free space. This can be done
page-pf4
A Guide to Unix Using Linux, Fourth Edition 8-4
Using the df Utility
2. Note that if you just enter df without specifying a file system, this shows information for
all mounted file systems.
3. Use Figure 8-1 to illustrate how df works.
Using the du Utility
1. Describe the syntax of the du utility.
3. Stress that by default, the output of du is in the number of 512-byte blocks.
Removing Garbage Files
1. Introduce the terms garbage file and core file. Provide a few examples of garbage files
that you may want to delete from your system to free disk space.
Quick Quiz 1
1. When you need to copy a file and change the format of the destination, you should use
the ____________________ command instead of cp.
2. The ____________________ utility reports the number of 1024-byte blocks that are
allocated, used, and available; the percentage used; and the mount pointfor mounted
file systems.
3. The ____________________ utility summarizes disk usage.
4. A(n) ____________________ file is created when an executing program attempts to do
something illegal, such as access another user’s memory.
page-pf5
A Guide to Unix Using Linux, Fourth Edition 8-5
Using System Status Utilities
2. Explain that you can redirect the output of these commands to a file, which can later be
printed or forwarded to the system administrator.
Using the top Command
1. Describe the syntax and use of the top command.
Using the uptime Command
1. Describe the syntax of the uptime command.
Using the free Command
2. Use Figure 8-3 to show how to use this command.
Forwarding top and free Output
Managing Processes
2. Note that UNIX and Linux offer utilities to manage how a program is run, how to
monitor processes, and how to kill processes.
Running Processes in the Background
1. Use an example to show how you can use the & character to run a process in the
page-pf6
A Guide to Unix Using Linux, Fourth Edition 8-6
Monitoring Processes
1. Describe the syntax of the ps command.
3. Use Figure 8-4 to show how to use this command.
Killing Processes
2. Provide some examples of situations in which the system would want to kill a user’s
process as well as situations in which a user would like to kill one of his/her processes.
Checking the Spelling of a Document
1. Describe the syntax and use of the ispell utility.
Comparing Files
1. Describe the syntax of the cmp command.
Formatting Text in UNIX/Linux
1. Describe the syntax of groff. Table 8-9 shows a sample of groff embedded commands.
2. Explain how this command can be used to create your own man files.
Note that depending on your operating system and how security is configured,
page-pf7
A Guide to Unix Using Linux, Fourth Edition 8-7
Archiving and Backing up Files
1. Stress the importance of archiving and backing up files.
If possible, provide real-life examples of the problems associated with not
2. Briefly describe how a GUI tool can be used to back up files to a CD or DVD.
Using the dump Command
1. Describe the syntax of the dump command. Explain the role of the dump levels (0-9).
Using the restore Command
1. Describe the syntax of the restore command.
3. Use an example to show how to use this command. For example: restore -r -f
Explain that if you have lost a disk drive and you need to restore a partition,
Quick Quiz 2
1. The ____________________ command displays a listing of the most CPU-intensive
tasks, such as the processor state, in real time (the display is updated every five seconds
by default).
page-pf8
2. The ____________________ command displays the amount of free and used memory
in the system.
3. To run a program in the background, you append the ____________________ character
to the end of the command used to start the program.
4. When you need to back up lots of files and directories or you want to do a full system
backup, you can use the ____________________ utility from the command line.
Using mail to Send Mail
2. Briefly explain how to use mail to receive and send mail. Illustrate with Figure 8-6.
Figure 8-7 shows how to use mail to access mail.
Using Networking Utilities
1. UNIX and Linux offer many utilities to accommodate a connection to the network:
Using the ifconfig Utility
1. Describe the syntax of the ifconfig utility. Introduce the terms Internet protocol (IP) and
IP address.
Using the ping Utility
1. Describe the syntax of the ping utility.
2. Walk through a couple of examples to illustrate how to use this utility.
page-pf9
A Guide to Unix Using Linux, Fourth Edition 8-9
Using the traceroute Utility
2. Provide examples of situations in which traceroute is useful.
Using the netstat Utility
1. Describe the syntax of the netstat utility.
2. Note that the information provided by netstat includes:
a. Network protocol communications
Sharing Resources Using Network File System
2. Stress that the resources to be shared must be hosted on a UNIX/Linux computer.
3. Briefly describe each of three versions of NFS currently supported: v2, v3, and v4.
4. Describe the role of Remote Procedure Roles (RPCs) in NFS client-host
communication.
6. Use one or more examples to show how to mount a remote partition.
page-pfa
A Guide to Unix Using Linux, Fourth Edition 8-10
Accessing Microsoft Windows Systems through Samba
2. Stress that Samba allows users to share resources between UNIX/Linux and Windows
3. Note that the typical Samba configuration file is /etc/samba/smb.conf.
4. Describe how you can (graphically) access Windows shared drives in several Linux
distributions.
Quick Quiz 3
1. The____________________ utility enables you to send and receive mail through your
computer or server.
2. The ____________________ utility can be used to configure your computer’s
connection to the network.
3. The ____________________ utility can be used to determine the network path between
point A and point B, such as the path between your computer and the computer of an
associate who is in another city or state or across the Internet.
4. The ____________________ utility gathers statistics and information about IP
communications on a computer.
Class Discussion Topics
1. Students may have previous experience using ping. Ask them to describe the types of
page-pfb
2. Have students used any GUI utilities equivalent to the command-line utilities
introduced in this chapter? Ask them to share their experiences in class.
Additional Projects
1. Ask students to use traceroute to find the path to a server from computers located in
different networks (e.g., your lab, a library, their homes). How long is the common path
in these routes?
Additional Resources
1. I Want A Linux/Unix Utility To...:
Key Terms
core file A type of garbage file created when an executing program attempts to do
something illegal, such as accessing another user’s memory.
garbage file A temporary file, such as a core file, that loses its usefulness after
several days.
Network File System (NFS) Enables file transfer and other shared services that
involve computers running UNIX/Linux.
process id (PID) An identification number that the operating system assigns to a
process for managing and tracking that process.
page-pfc
A Guide to Unix Using Linux, Fourth Edition 8-12
remote procedure calls (RPCs) Enable services and software on one computer to
use services and software on a different computer.
Technical Notes for Hands-On Projects
Students should complete these projects using the command line, such as from a terminal
window, using the Bash shell. Unless instructed otherwise, they should use their own accounts
and home directories. Additional project requirements are listed below.

Trusted by Thousands of
Students

Here are what students say about us.

Copyright ©2022 All rights reserved. | CoursePaper is not sponsored or endorsed by any college or university.