CIS 191AB, UNIX/Linux System Administration

 Fall 2009
CIS 191 Home

Calendar
Outline
FAQ
Links
Grades
Instructor Home

 
 

Review Questions

This page will be used to post the knowledge and skills that you should have acquired from each lesson. Knowledge and skills both cover varying degrees of accomplishment. The following represent the three levels of accomplishment I will be looking for in your progress:
1) Competent      2) Mastery      3) Wizardry

Your knowledge will be assessed through quizes and exams.
Your skills will be assessed based on your performance in completing tasks in and outside of class.



Lesson 1: An Overview of the Unix/Linux Operating Systems

Knowledge
  1. Name four different GNU/Linux Distributions and the architectures on which GNU/Linux runs.
  2. Name three major components of the Linux Operating System.
  3. Name three different ways to obtain superuser privileges on a UNIX system.
  4. Name six subdirectories of the / directory and what types of files they contain.
  1. explain the effect using the -l, (or just - ) switch has on the su command.
  2. Describe the function of each of the major components of Linux OS, and name a file that corresponds to each component.
  3. Describe three major roles of the Linux kernel.
  4. Name the four basic types of files supported by the UNIX operating system, and what command(s) are used to create them.
  1. What do the contents of the /proc directory represent?
  2. Compare the disk utilization of the /dev directory with the /lib directory. Explain the difference.
  3. What are the meanings of the major and minor device numbers?
  4. How are character device files different than block device files?
Skills
  1. Use the su command to obtain superuser privilege and the superuser environment.
  2. Use a UNIX command to determine the kernel version of an installed Linux System.
  3. Create a device file using the mknod command.
  4. Use the ln command to create symbolic links.
  1. Identify the version of the installed Linux Distribution.
  2. Use the correct UNIX command to obtain the name (hostid) of a system.
  3. Run a UNIX command that lists out all the system daemons currently running on your system.
  4. Find what shell you are using and what shells are available for use on the system.
  1. Use the du command to analyze the disk usage of the major UNIX directories.
  2. Using UNIX commands, find the lineage of processes starting from init that lead to your login shell process.
  3. Use the info command to find out what GRUB is.

Lesson 2: Storage Devices and File Systems

Knowledge
  1. What device names are used for Linux storage devices?
  2. Given the number of cylinders, heads and sectors/track, compute the size of a disk.
  3. Name the three major components, and their purpose, of an ext file system.
  4. What is a mount point?
  1. What information is needed by the mkfs command to create a file system.
  2. What is the purpose of the lost+found directory?
  3. Describe the syntax for the commands that allow you to mount and unmount file systems.
  4. What is the file /etc/fstab used for? /etc/mtab?
  5. Distinguish between device drivers, device files, and symbolic links.
  1. What is the /dev/loop device used for?
  2. Describe the syntax of the file system configuration files: fstab and mtab.
  3. What are the three different RAID models supported by Linux?
  4. What file attributes has the ext file system added to files beyond permissions?
Skills
  1. Use the dd command to clear a storage device.
  2. Install a partition table on a storage device.
  3. Create a vfat filesystem on a storage device.
  4. Create and populate a simple root file system on a usb pendrive.
  1. Use the mount command to view which file systems are currently mounted to which devices.
  2. Edit the /etc/fstab file to add a new file system to be mounted at bootup.
  3. Mount and unmount disk, floppy, and cdrom file systems.
  1. Create a file system within a large (4MB) file and mount it to a loop device.
  2. Create an iso 9660 filesystem using the mkisofs command.
  3. Add an NTFS kernel driver so that you can view Windows NTFS file systems under Linux.

Lesson 3: Boot Loaders and Booting

Knowledge
  1. Name three boot loaders commonly used with Linux.
  2. Outline the steps, (flow of control) in booting a kernel.
  3. Name two kernel parameters you can pass to the kernel to control how it boots up.
  1. Define the structure of the MBR
  2. Where is the partition table and what information does it contain?
  3. What command is made to make an emergency boot disk in Linux?
  4. Describe the syntax of the grub.conf file
  1. Define the keywords used in the GRUB and LILO configuration files.
  2. Compare and contrast the SYSLINUX, LILO and GRUB boot loaders.
Skills
  1. Bring a UNIX/Linux system up in Single user mode.
  2. Set the active partition to the desired primary partition using fdisk.
  3. Use the dd command to save and load a copy of the master boot loader.
  1. Create an emergency boot disk using the mkbootdisk command.
  2. Use the dd command to save a copy of your partition table.
  3. Edit the /etc/lilo.conf file so that it will be loaded into a partition boot sector rather than the master boot record.
  4. Edit the boot loader's configuration file to add the ability to boot onto a usb pendrive.
  5. Create a GRUB bootable floppy and use it to boot from the hard disk.
  1. Use dd to restore a corrupted MBR.
  2. Edit the boot loader's configuration file to add the ability to boot a compressed root file system.
  3. Run the lilo command to install lilo.

Lesson 4: System Startup and Runlevels

Knowledge
  1. Bringing up a UNIX/Linux system involves what two basic steps, and what is accomplished in each of those steps?
  2. What UNIX/Linux program is responsible for starting and stopping all other system programs?
  3. What is meant by a runlevel? What is runlevel 1 used for? Which runlevels are pre-defined by UNIX convention?
  1. How can a user reboot a Linux system from the login prompt?
    How would you disable this capability?
  2. What is the role of the init.d directory?
  3. What are the three components of an rc script name and what does each signify?
  4. Why should a system administrator use the shutdown command rather than init to bring down a multi-user system?
  1. What are the four fields that make up a record in the /etc/inittab file?
  2. Name three actions that every daemon or subsystem rc script should be able to handle.
  3. In what stage of booting are non-root file systems mounted?
Skills
  1. Reboot a Linux system from the command line
  2. Shutdown a Linux system giving users 5 minutes to save their files and log off.
  3. Bring a Linux system up in single user mode.
  1. Configure a system to boot up in runlevel 3 with 10 virtual ttys
  2. Add an rc script to init.d and have that script startup in runlevel 5 only. It should be shut down at any other runlevel.
  3. Disable the ability to bring a system down with ctrl-alt-del
  1. Configure the system so that X windows does not start unless a user logs on to tty6.
  2. Add a service to runlevel 3 that displays the current month's calendar on the console tty.
  3. Prevent the security loophole that allows a user to enter single user mode without entering a password.

Lesson 5: Installing UNIX/Linux Operating Systems

Knowledge
  1. Describe the minimum and recommended hardware requirements for a Linux installation in terms of CPU, memory, storage and supported peripherals.
  2. Define and explain the terms: MasterBootRecord, and partition boot sector.
  3. Name five decisions you must make when installing a Linux System
  4. Describe how LILO/GRUB boots a Linux Operating System
  1. Name three Linux commands useful for determining your hardware specifications.
  2. Describe how the acronyms CHS and LBA relate to hard disk geometry.
  3. What is the minimum number of partitions required for installing Linux and what partition types must they be.
  4. Define the meaning of the following keywords used in a lilo.conf file:
    boot, default, timeout, image, other, label, root
    or a grub.conf file:
    default, timeout, title, kernel, root, chainloader
  1. Name the four I/O parameters that often cause hardware conflicts during installations.
  2. Define the structure of the MBR
  3. Itemize which installation issues can be deferred until after the installation.
  4. Describe the role of the following files in the boot process:
    boot.b initrd.img vmlinuz
Skills
  1. What commands allow you to probe the existing hardware configuration of a system?
  2. What files contain information needed to complete a pre-installation checklist?
  3. Install a Linux Distribution from CD-ROM on an Intel Computer.
  1. Generate a kickstart file for purposes of performing an unattended installation.
  2. Create an installation boot floppy, (or cdrom) from a distribution image.
  3. Be able to configure a lilo.conf or grub.conf file to dual boot between two or more operating systems and/or two or more kernel configurations.
  1. Perform a network install of a recent distribution from an installation server.
  2. Install a Linux distribution across multiple hard disks.
  3. Compare a minimal Linux installation to a full installation.

Lesson 6: Package Managers and Software Management

Knowledge
  1. What is a tarball, and what utility is used to manipulate them?
  2. Define a package and name three popular Linux package managers.
  3. Name four different modes in which package managers may be run.
  4. Identify the package information contained in the name of an RPM package.
  1. Describe the advantages and disadvantages of using package managers
  2. Name the package managers for: Slackware, Red Hat, and Debian Linux
  3. List and describe the three types of shared libraries.
  1. Describe the main benefits of using APT
  2. Describe the naming conventions for shared object libraries
  3. Describe the use of the ldconfig and ldd utilities.
  4. What is the alien command used for, and when should it be used?
Skills
  1. Compress and extract a group of files using the tar command.
  2. Create a compressed file archive using the tar command
  3. Use gzip and gunzip to compress and uncompress files.
  4. Use a package manager to find out what software packages you have iinstalled on a system.
  1. Install the mtoolspackage using one of the package managers
  2. Query and verify the files from an installed package.
  3. Uninstall the mtools package
  4. Use the ldd command to find out what shared libraries are required for common UNIX commands.
  1. Update a package such as linuxconf or gcc with the latest release.
  2. Install the alien package and use it to convert the pkzip package from RPM format to .tgz
  3. Perform a kernel update.

Lesson 7: The UNIX/Linux X Window System

Knowledge
  1. What is the name of the configuration file for the Xserver, and where is it located?
  2. Where was X first developed?
  3. What are the two main components of the X Window System?
  4. Name three ways to start the X server.
  1. What is the purpose of the "--" option when running xinit or startx?
  2. In which directory are the fonts available to X located?
  3. Name three options supported by nearly all X clients.
  4. What are the three parts to a fully specified display?
  5. What is the name of the X font server?
  1. What logical device is normally used for PS2 mouse devices?
  2. What is the first step in configuring X? What program would you use?
  3. Where would you find the X client programs like window and file managers?
  4. What keystrokes will terminate a running X server?
Skills
  1. Start the X server and bring it back down.
  2. Start a single X session at your terminal while in runlevel 3.
  3. Run an X-client on a remote server.
  1. Use redhat-config-xfree86 to configure an X server.
  2. Configure which destop you would like to use (Gnome or KDE) and which Window Manager you want to run.
  1. Edit the /etc/X11/XF86Config file to reconfigure mouse settings from serial to PS2
  2. Write a custom .xinitrc file in your home directory to customize your desktop environment.

Lesson 8: Administrative Responsibilities and Getting Help

Knowledge
  1. List at least five responsibilities of a System Administrator
  2. Describe the importance of a log book and why such information should not be kept online.
  3. Name 5 sources of help, 3 of which are on the computer itself.
  1. Describe three levels of configuration available to the system administrator on most desktop systems.
  2. Name three ways an administrator can obtain root privileges from a normal login account.
  3. Explain the differences between the man pages and the info pages.
  1. What is the relationship betwwen the UNIX man Pages and the info pages?
  2. List three types of documentation found at the Linux Documentation Project
Skills
  1. Be able to log in and log out of a Linux system using both a CLI shell and a graphical shell.
  2. Be able to edit a previously typed command line for re-execution
  3. Be able to view the last 100 commands you have entered.
  4. Be able to run a process in the background.
  1. Be able to set which editor (vi or emacs) you would like your shell to use for command editing.
  2. Use the bash shell to move user processes from foreground to background and back to foreground.
  3. Be able to start up your own X window session with Xclients of your choosing.
  1. Be able to identify the Window Manager, Desktop Manager, and File Manager being used by a particular graphic session.
  2. Be able to customize your graphic session using hidden configuration files in your home directory.
  3. Use mtool commands to copy UNIX files to DOS floppy disks and vice versa.

Lesson 9: Administering User Accounts and Groups

Knowledge
  1. Name three files in the /etc directory that contain account information, and specify which information is kept in each file
  2. Name the three commands used for creating, modifying and deleting user accounts
  3. What command is used to change a user's password?
  1. Define the seven fields within a record of the /etc/passwd file.
  2. How are the files in /etc/skel used?
  3. Explain the purpose of the newgrp command.
  4. What command is used to lock and unlock a user account?
  1. Describe the use and format of the /etc/default/useradd file.
  2. Describe how the /etc/skel directory hierarchy can be configured to support different shell environments for different user groups.
  3. Describe how you check to see if disk quotas have been enabled on a system?
Skills
  1. Create a new group with a specific gid
  2. Create a user account with a specific uid and gid
  3. Set a password for the above account.
  1. Modify the location of the home directory of an existing account.
  2. Lock and unlock a user account
  3. Delete a user account
  1. Change the uid of an existing account, and change all existing files owned by that user to the new uid.
  2. Change the password expiration date for a given user to be 1 week hence.
  3. Change the system-wide defaults for creating user accounts so that the group CIS191 is the default group.

Lesson 10: File Systems

Knowledge
  1. Name the three components of a UNIX/Linux file. And Name three components of the EXT file system implementation.
  2. Name some of the more popular file systems being used on Linux systems today.
  3. Name the three commands that allow you to create a file system, mount a file system, and unmount a file system.
  4. Name two commands for managing disk usage of file systems.
  1. Name four functions of a file system.
  2. What is the file /etc/fstab used for? /etc/mtab?
  3. What command is used to check and repair a corrupted file system?
  4. What is the purpose of the lost+found directory?
  5. What error message can you get when trying to unmount a file system, and what can you do about it?
  1. What operations are performed on a file system while it is not mounted.
  2. Name four attributes (extended permissions) that the chattr command can give to a file.
  3. Describe what each of the following e2fsprogs suite utilities does:
    1. dumpe2fs
    2. resize2fs
    3. tune2fs
    4. e2fsck
Skills
  1. Use the lsattr and chattr commands to view and change the extended permissions of a file
  2. Mount and unmount the floppy and cdrom devices
  3. Make an ext2 file system on a floppy disk
  4. Format a floppy disk
  1. Use the stat and dumpe2fs commands to view an i-node and file system respectively. Be able to determine what the logical block size is for that file system.
  2. Add a home filesystem to your system using a logical volume in the the extended partition. Configure the system so that this file system will be mounted to the /home directory upon booting.
  3. Use fsck to check or fix a corrupted file system
  1. Change how often the root filesystem should be checked so that it is checked every 10th time it is mounted.
  2. Edit the /etc/fstab file so that disk file systems are referenced by filesystem labels rather than device names.
  3. Recover a deleted file

Lesson 11: System Backup and Restore

Knowledge
  1. Name three backup methodologies and the advantages/disadvantages of each
  2. Name three UNIX/Linux utilities used for backing up file systems
  3. Name three popular Open Software Backup applications that run on Linux
  1. Describe the issues with symbolic links and relative vs. absolute file names when it comes to backing up and restoring files.
  2. What cpio command line would you use to backup all files owned by guest to a tape device named /dev/rmt0
  3. What tar command line would you use to extract a tar archive from a floppy?
  4. What dump command line would you use to perform an epoch backup of the /home filesystem onto /dev/hda7?
  5. What is stored in the /etc/dumpdates file?
  1. What are sparse files and what challenge do they create for backup utilities?
  2. What is backup ghosting, and how does it affect restored file systems?
  3. How can you make tar backup the data to which any symbolic links point?
  4. What do 'block sizes' have to do with tape reading problems?
Skills
  1. Use the tar command to backup your home directory to the file myhome.tar
  2. Use the gzip and the compress commands to compress your myhome.tar file
  3. Extract the myhome.tar file into the /tmp directory
  1. Use either dump, tar or cpio to backup your /home filesystem.
  2. remove your /home file system, and restore it from the backup.
  3. Create a crontab file that would use the dump utility to do a level 0 backup on the first of each month; a level 1 backup every Sunday; and a level 2 backup every weekday at 11:00pm. Assume a tape device of /dev/rmt0
  1. Backup your entire system to an empty partition.
  2. Run the command rm -rf / as root, and then restore the system from your backup.

Lesson 12: System Process Monitoring

Knowledge
  1. What is the name of the daemon that keeps track of what error messages are logged where? Where are most error messages logged?
  2. What is the name of the command that allows you to add and remove tasks for the cron daemon?
  3. What are the roles of the six fields in a cron file?
  4. Name four commands that may be used to monitor system processes.
  5. Name two commands to monitor system storage space.
  1. What are the roles of the three fields in a record of the syslog.conf file?
  2. When would the following command be executed by crond?
    0,30 * 30 2 1-5 /usr/bin/search groundhog
  3. Name four resources for which processes are in competition.
  1. Name three locations to where system messages may be written.
  2. Describe the steps that must be taken for a user to schedule a batch job of commands to be run on the first of every month.
  3. What conditions will cause a process to be swapped out of RAM?
Skills
  1. Kill a hung process.
  2. Start a cron job and remove a cron job.
  3. Identify the offending processes when a system is under a load.
  1. Create a cron file that will record the number of files on the system once a week, and write it to a log file.
  2. Identify the 10 largest processes in memory at any point in time.
  3. Alleviate a full file system by adding additional storage, (a new partition).
  1. Configure the system to display all kernel error messages to the system console and to have all other logs rotate on a monthly basis.
  2. Use process accounting to track what commands users are using.
  3. Gather system data to determine where a system bottleneck resides.

Lesson 13: The Linux Kernel

Knowledge
  1. Name three components of the Linux kernel. Which component is "closest" to the hardware?
  2. In what directory is the kernel stored on most Linux Distributions?
  3. What is the full pathname of start of the linux kernel source tree?
    i.e. the directory that contains the master Makefile
  4. How do you determine the version of the kernel you are currently running?
  1. In what directory are dynamic kernel modules installed?
  2. What is the name of a newly created compressed kernel and in which directory is it stored?
  3. What choices does a kernel builder have to determine which modules are included or excluded from the kernel build?
  4. After a new kernel is built and installed, what must be done before booting this kernel?
  1. What command is used to make a new kernel from a source code tree?
  2. From where can you obtain the latest Linux kernel source code, and when should you download a source tree versus a patch?
  3. Name the six targets of the Makefile that must be run to build a new kernel.
  4. How can you arrange it so that you don't lose the default kernel options that are preselected for a generic kernel?
Skills
  1. Download the latest kernel source tree from www.kernel.org
  2. Extract and uncompress the source tree archive
  3. Run the make commands that will build a new kernel
  1. Use xconfig to select and exclude relevant and irrelelvant kernel modules
  2. Save your selected kernel options to a file
  3. Install a new kernel in the appropriate directory
  4. Update the lilo.conf file and run lilo to boot the new kernel
  1. Download and apply a patch to an existing kernel source tree.
  2. Configure lilo.conf to allow you to select which kernel you want to boot.
  3. Use insmod and rmmod to load and remove modules from a running kernel