Introduction to Unix and GNU/Linux Proficiency # 25740901 Thomas J. Miller jr - Instructor 593-2481 / tjmiller@datc.tec.ut.us Kimberly K Ziebarth - Instructor 593-2446 / kkziebarth@datc.tec.ut.us Stephen C. Allen - Instructor 593-2333 / scallen@datc.tec.ut.us Credits: Written by Thos. J Miller jr, and edited with immense assistance and advice from P. Tobin Maginnis of Sair Inc, Richard Stallman of the FSF, and was formed from the gratefully accepted advice and suggestions sent to me by the Linux community in general. My greatest gratitude goes to the Linux Community at large, who toil largely without proper compensation to produce not only a better operating system, but a new and better way of doing business in the Information Age. It is to the Linux Community as a whole that this work is dedicated. Copyright/Copyleft Notice: Intro to GNU/Linux Current document version: 0.99a Release Date: 17 Jan 2000 Modified by: (none) This packet is originally copyrighted to Thomas J Miller jr (who shall be known as the Author of this document), and to the Utah Department of Education (The Authors ultimate employer). It is then Copylefted by the Author to the general public, in dedication to the further development and education of GNU/Linux. This document and/or curricula is not to be construed as any part of official Utah Department of Education policy; it is instead written under its laws and guidelines. You as the reader are perfectly allowed to modify and adapt this packet as needed. However, no school within the Utah Department of Education, nor this author, will recognize any modifications to this packet as part of the any school curricula, without a specific in-house faculty review of said modifications, by this or any school contemplating any use of this document. Other schools are encouraged to maintain the same policy of review. Professional educators within or outside of Utah, at any level of instruction, are free to modify and adapt this packet to their specific needs and curricula, so long as credit to the original author is kept intact, and that a prominent notice within the document states that the new document is a modification of the original. The author would however appreciate being notified of any unusual or innovative updates and changes made to this document (even technical corrections if necessary.) My current e-mail address is tjmiller@datc.tec.ut.us I look forward to hearing from educators who have made this document work for them and their specific programs. Anyone who modifies this document is perfectly free to sell or distribute it as desired. Student Restrictions and Privileges: Students may not distribute any version of this document under pretense of it being official school curriculum (see above), but are free to distribute copies of it just the same. Students are however free to modify this document and distribute it, in ways they think will improve an individuals understanding of GNU/Linux...so long as they do so knowing that they cannot distribute it as official curriculum of any school, either stated or implied. Students and third parties do bear one additional restriction: Students and third parties are expressly prohibited from adding anything to this document for distribution that may be construed as part of any specific Instructors classroom examination or test. This means that Students are not allowed to distribute actual (or supposed) examination test questions/answers under any circumstance, even under the pretense of Open Documentation. No other restrictions whatsoever shall be made to this particular Copyleft, and this notice shall remain intact and unchanged no matter what other modifications are made. Refer any paper-mail correspondence to: Davis Applied Technology Center c/o Thos. J Miller jr, Comp. Tech Dept 550 East 300 South Kaysville, UT 84037 About Red Hat© Software: Although we do have permission from Red Hat Software to utilize and employ their software in this class, and that we also have permission to duplicate and distribute it within the classroom under the GNU General Public License (GPL), the following must be stated: Red Hatƒ is a registered trademark of Red Hat, Inc. This distribution is not a product of Red Hat, Inc. and is not endorsed by Red Hat, Inc. This is a product procured by the Davis Applied Technical Center, and we have no relationship with Red Hat, Inc. DATC does not, and will not, use or employ any trademarked symbols or titles indicating or referring to Red Hat software directly in any of our advertisement. The only mention of Red Hat software products will be in granting credit to the original source, or within the normal course of instruction. (Example: Referring to or discussing Red Hat RPM packages when teaching students about kernel compilation.) Red Hat Inc. is not the only applicable software within this course - this course can also be applied to any other Linux distribution in existence, with only minor modifications in some instances. A copy of the permissions granted, and a copy of Red Hat Softwares Trademark policy will be kept on file, to be available for viewing at any time, in the office of TJ Miller jr, Room C-212 of the DATC complex. Also included are copies of the GNU General Public License, as well as hard copies of e-mails from Red Hat corporate representatives granting the associated permissions and setting the appropriate restrictions. DATC does not, and cannot, hold or reserve any rights deriving from this software; these belong to the original creators of the software in question. This distribution will be provided at one copy per student as part of the normal course of instruction, multiple copies can be procured by the student at the DATC bookstore, where we in turn have them procured via Linux Central: http://www.linuxcentral.com DATC assumes no responsibility for student actions or use of this software outside of DATC property. Any violations of law or the GNU GPL by the student(s) outside of DATC property are solely the responsibility of the student(s), and not DATC. Any of the aforementioned violations of law or policy committed within DATC property will be reported promptly to the appropriate local authorities, and any copyright/GPL violations will be promptly reported to the appropriate authority for disposition. Neither DATC, nor Red Hat Software, nor Linux Central, assumes or implies any warranty with this DATC distribution; the software is provided as-is. Neither party will assume any responsibility for any damages arising from the use of this software. This software is provided primarily to be used on DATC property, and any use outside of DATC property, while perfectly legal and even encouraged, is to be done at the users own risk. Table of Contents Materials List: Page 6 Instructions For Using DATC Classroom Computers Page 7 General Course Summary Page 8 Book I - Modules Module 1: Unix, GNU, and Linux Page 9 Module 2: Preparing to Install Unix: Initial Concepts Page 13 Module 3: Installation and Initialization Page 16 Module 4: Basic Commands and Concepts Page 19 Module 5: Essential Systems Management Page 22 Module 6: Filesystems and Devices Page 25 Module 7: Upgrades and Compiles Page 28 Module 8: Other Administrative Tasks Page 31 Module 9: Editors, Text Tools, Graphics, and Printing Page 35 Module 10: The X-Window System Page 37 Module 11: Windows Compatibility and Samba Page 40 Module 12: Intro to Programming Languages Page 43 Module 13: TCP/IP and PPP Page 46 Module 14: The WWW and Electronic Mail Page 49 Book II - Labs Lab1: Planning a Unix Install Strategy Page 53 Lab2: Installation of GNU/Linux Onto a Hard Drive Page 55 Lab3: LILO: Modification and Maintenance Page 62 Lab4: Mounting Filesystems Page 63 Lab5: tar and gzip: Use and Functions Page 66 Lab6: Upgrading Software Page 67 Lab7: Managing System Logs Page 72 Lab8: The Line Printer Daemon Page 74 (* Labs 9 and 10 are covered in Module 9) Lab11: Networking With Samba Page 76 Appendices and Reference: Appendix A: Traditional fdisk commands Page78 Appendix B Fdisk and install screens Page80 Appendix C: Partition Planning Worksheet Page81 Materials List for the GNU/Linux course A working copy of the Red Hat 6.1 distribution, which can be procured in the DATC bookstore, or directly from Red Hat Inc (http://www.redhat.com/) or from Linux Central (http://www.linuxcentral.com). Adults - the textbooks as required; they are all available in the bookstore downstairs, or the exact same titles can be had via Internet from the Barnes and Noble© website. You are free to do whatever you wish with these books, but there is a book buy-back program at the bookstore if you desire it. High School StudentsWe will have the textbooks available for you, but they will not leave the classroom without specific instructor permission. This course packet (available in the bookstore.) Three blank floppies: two floppies to create the initial and Labwork (LILO) boot disks, and the third to record your documents and lab results in *.txt format if need be (this way it can be read by both Windows and Unix.) A strong sense of adventure and courage, but also an eagerness to learn. While many of you will already have (or perhaps claim to have) a mountain of experience in and around UNIX GNU/Linux, there are usually gaps that will need filled, since most of you learned things OTJ or as you needed to, but nothing more. The best way to complete this course is to come in and study the entire thing afresh, as if youve never seen UNIX GNU/Linux before. Dont take shortcuts or skip material, no matter what the urge - your grades during final testing will depend on knowing as much of the course material as possible, and knowing how to apply it in given hypothetical situations. Instructions for using DATC Classroom Computers Getting Started We will first use the WindowsNT OS to get you started. This is because WinNT is the default operating system in this classroom, and you will find that Windows is prevalent on the job as well. You will discover that removing Windows and converting a given machine to (or cohabitate Windows with) Linux will actually become part of your routine within the IT industry. When you choose a workstation, you will be prompted for a user name and password in order to log onto the NT network. Once you progress beyond Chapter 2, You are urged to stick with the computers that have removable hard drives, for the practical reason that you will be using a removable hard drive during this course. On the Windows NT machines, your username will be your last name followed by your first and middle initial. For example, if your name is Karey D. Barker, your username will be barkerkd. Your password will initially be password. The first time you log onto a workstation, you will be asked to change your password, then re-type it to confirm. You should use a password that is difficult for others to find out, easy for you to remember. When you have finished working on the computer or leave the desk, you should close all programs and log off of the Win NT computer. You can do this by hitting Control + Alt + Delete and selecting the Logoff option. There is no need to power down the computer in Windows NT, since it can be used by the next student to arrive. If you are switching to the Linux drive from WinNT, do the same thing, but select Shut Down at the menu. When you are done with the Linux drive, go to a clear prompt and type shutdown -h now to shutdown the machine. Once you power down, remove the hard drive and switch it back to the WinNT drive. CBT courses Due to the fact that the CBT course only work in Windows, you will have to use the Windows NT operating system to use the CBT exercizes - simply shutdown the machine, switch to the NT hard drive, reboot into NT, and launch the CBT coursework. Performing the Online exercises There are two computers in the classroom that can access the Internet. They are workstation numbers NT-17 and NT-18, near the classroom desk. Please keep in mind that there may be other students who need to use the terminal, so only use the online resources that you need. The mandatory sites and resources are also printed and kept on file in the classroom for your convenience. Intro To GNU/Linux Course Summary Why this course is important: Even though Unix is more often a systems administrator tool, it is still quite common to find a Unix workstation at the client level. It is becoming even more common to find Linux rapidly taking the place of traditional Unix variants. The best way to learn how to administer a Unix GNU/Linux system is to learn it from the client-level perspective. If you dont know its basic operation, you cannot possibly administer it. Even if you never want to administer a Unix GNU/Linux system, you may discover that youll have to use one as a client. While we do cover quite a few sysadmin duties, they are included only because they are required for basic housekeeping on an individual Unix GNU/Linux machine, be it client or server. We concentrate on GNU/Linux for two reasons: 1.GNU/Linux is the easiest and most accessible form of Unix 2.GNU/Linux is growing rapidly in popularity within the IT and Internet communities. This is because it is just as powerful and flexible as any other form of Unix, because it is available at little or no cost, and the source code for GNU/Linux is available at no cost to anyone who has the patience to tinker with it. (Try getting Microsoft to cough up a copy of the Windows 2000 source code :) Course Information: Students will gain a competent understanding of the skills necessary to plan, install, implement, and administer Linux - both as a user and as a basic systems administrator. The student will recognize that although Linux is a complex and powerful language, it is also a powerful tool, ready to serve anyone who has the skills to use it. You will find that the packet tends to skip chapters, only to go back to them later on. This is because although all of the information is useful, the order has been rearranged to make it easier to assist you in learning how GNU/Linux and Unix work. Also, unless specifically referred to as either UNIX V or UNIX in all caps, the term Unix is only used as a generic term, not as a mark of any specific product name. Lastly, most of the information about GNU/Linux can generally be translated to most Unix varieties. Proficiency Goals: 1.Learn a basic history of Unix and GNU/Linux. 2.Plan and anticipate a typical Unix or GNU/Linux installation. 3.Then, with a blank HDD, install a basic GNU/Linux package, with full technical support if needed. 4.Log in; create user accounts, learn to find help in the system, log off, and basic system navigation. 5.Learn essential system management, since anyone who runs his or her own GNU/Linux box is in essence a system administrator for that box. 6.Learn to manage file systems and devices. 7.Learn to upgrade and even recompile a kernel when necessary 8.Know what good housekeeping is on your GNU/Linux Unix system 9.Learn and become familiar with text editors, Graphics tools, and basic printing 10.Install and configure the X Windows system 11.Learn basic user networking, and how to connect your GNU/Linux machine to other machines, including those that run DOS/Windows 12.Get a basic introduction to TCP/IP, and complete your introduction to networking, be it within a LAN, or to the Internet 13.Learn how to go beyond basic network configuration, to use the World Wide Web in GNU/Linux, configure e-mail, and to use the Internet as an actual tool, instead of a curiosity. Unix, GNU, and GNU/Linux Module # -257409011 Module Summary: Why this is Important: Unless you know the history of a movement, you wont understand exactly why it moves forward in the direction it does go. I also want to take the time to introduce you to the Open Source movement, since it is currently gaining a large following within the IT community, as well as among programmers and even corporations. While no one can confidently state the future, I can predict that the Open Source movement will become the way software companies do business in the coming years. This is because with Open Source and GNU, there is no longer any such thing as Software Piracy, Warez or cracks. You can copy the software to your hearts content. The consumer can do whatever they want (within reasonable limits) to the software they receive, and are even encouraged to improve on it by way of having the source code for that product, right there in front of them. Open Source is also a boon to industry, which would otherwise have to shell out a lot of money just for access and user licenses...these would naturally become obsolete once an upgrade (or worse, multiple upgrades) became necessary. Companies, who would otherwise be forced to conform to a standard operating system, can now move towards the more innovative option of modifying the source code and the operating system to meet the exact (and sometimes unique) aspects of their particular business. This improves productivity by a huge margin, and by extension, it would improve the market that the company serves. The following modules will increase in difficulty and complexity as we go along, but they will all follow a basic structure, which is explained in full. However, these modules are not made to overwhelm you, but instead to challenge you as you progress through the course, as the things you learn in one module will apply to the next one you study. The most important thing to have with you as you travel through these pages is a good attitude. Do not look upon the course as a chore to be done, but rather, look at it as a child would look at his or her parents automobile: Something complex, but something that he or she knows will be very useful to them some day soon... GNU/Linux, and by extension Unix, might indeed become very useful to you, especially if you intend to make computers and their use a career. But, you wouldnt be here reading this packet if you didnt know that already, no? About This Module and GNU: This module will cover philosophical and even semi-political arguments, presenting an entirely new business model and most likely shaking up everything you thought about the software industry. To be honest, the GNU GPL may even seem activist to those who are used to the idea that business should keep things proprietary. However, I can assure you that it is not activist in any way: It is merely a new way of doing business. GNU also eliminates many of the headaches that plague proprietary software: Pirating, Warez, and Counterfeiting are eliminated under the GNU business model. Fixes, patches and upgrades are faster, because more people can get to the actual source code and work on it. There is also a larger sense of community among those who practice and use the GNU business model - a sense that everyone is in this thing together. You also get a greater sense of ownership when you download and perhaps even modify software, especially because it is essentially yours to do with what you wish, within very few limits. Know that GNU/Linux is not perfect - it relies on a large community of developers and supporters to maintain and improve the code, and to provide documentation and support for the vast array of hardware configurations out there. Also know that Linux is not yet made for Joe Six-pack (or anyone else who is computer illiterate) - it will require a little more initiative and knowledge than the standard desktop OS. You will sometimes find that an application you need may not be available in Linux...this is changing rapidly, as Linux begins its inroads into the mainstream computer culture. Linux will also require more out of you than any other operating system; it will challenge you and it will sometimes vex you. However, the problems are not too tough to overcome, and you will end up educating yourself more than you ever thought possible. You will learn the ins and outs of your computer, more than you ever would with any other operating system. Finally, know that the GNU business model is most likely where the software community is heading, in spite of resistance from the larger companies such as Microsoft, who have made their fortune via proprietary (closed) software. This resistance is not ill-intentioned, but you will find that it is bothersome at times, and in some cases it will even be misleading. However, there is no such thing as a perfectly peaceful revolution, and the GNU/Open Source movement is exactly that - a revolution in how the computer industry does business. In this module, I will provide you with both sides of the story, from GNU and the Open Source point of view, to the internal opinions and an honest study of GNU/Linux from the largest software company on Earth...Microsoft. Before we begin, allow me to explain some terms that may seem unfamiliar to some, either here or to be found later on in the module: Cracks (or Crackz): A common hackers term, referring to software that allows you to crack a registration code on software otherwise protected against piracy. This includes false CD Keys, algorithm generation tools which allows you to create a forged registration on shareware products, and any other software-based device that would enable you to use protected copies of proprietary software without paying for it. These are usually available on most Warez distribution websites. Warez: A common hackers term that refers to all pirated software released for general distribution, software that is usually found on websites. FUD: Fear, Uncertainty, and Doubt. This is a term you may find in the Linux community that refers to the actions (usually attributed to Microsoft) if intentionally confusing the general public, putting a fear into the public of someone or something, or to plant the seeds of doubt in the minds of the public in general. You might find that the term is used more often than necessary in some of the web-based texts. FPU instructions: FPU = Floating Point Unit, another way of referring to the math co-processor (which was once a separate processor, but is now built into the CPU itself.) GNU: Gnus Not Unix. Many of the program names in Unix, including the UNIX name itself, were named originally as inside jokes by their creators. For example PINE (a very popular and stable text-only mail and news reader) stands for Pine Is Not Elm (ELM was the original text-based mail and news reader.) In case youre curious, even the name UNIX was a joke in and of itself The UNIX operating system is derived from Bell Labs original Operating System project known as MULTICS (uni from Multithose who know Latin real well might get the joke implied) To make it short programmers do have a sense of humor, even though the products they apply their humor to are quite serious indeed. Most of the Unix/Linux community carries this tradition on, even to today. Course Information: This module is intentionally short, to get you started comfortably, and to get you used to the modules and how theyre laid out. Proficiency goals: To learn what GNU/Linux is, and what it can do for you. To get an idea of why GNU/Linux exists, and how it got as popular as it has become today. To learn where GNU came from, and what the Open Source movement stands for. To get an idea of why people use GNU/Linux in particular Discover where it can be had, both for a slight cost and for free. Get to know a bit of comparison between GNU/Linux (or even Unix) and its closest relative, DOS. Module Checklist Check off each item as you complete it: 1. _______Study: - The module summary page in this proficiency - Chapter 1 (pg. xi to pg. 44) of Running Linux. 2. _______Online: Visit the following sites, and read through them in their entirety: http://www.faqs.org/faqs/unix-faq/faq/part6/section-2.html http://www.cab.u-szeged.hu/local/Linux/doc/lug/node14.html http://www.opensource.org/history.html http://www.linuxjournal.com/issuebg/1376.html - What is GNU/Linux http://www.gnu.org/gnu/gnu-history.html - History of the GNU Project http://www.gnu.org/gnu/manifesto.html - GNU Manifesto. Keep in mind that there is a lot of activism (and even invective) on this page. However, the section I want you to study in particular is the Copyleft concept. http://www.gnu.org/copyleft/copyleft.html - GNU Copyleft http://www.opensource.org/halloween -A copy of Microsofts Internal Study of GNU. Read the Key Quotes primarily, but feel free to peruse the rest of it (its very long, though...) (Note: if the Internet terminals are full, these pages are available as hard copies in the classroom.) 3.________ Ask any questions you may have, at anytime. If the instructor doesnt know the answer, he or she can readily find it. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Preparing to Install Unix: Initial Concepts Module # -257409012 Module Summary: Why This is Important: Unix is an operating system that is unique, powerful, and flexible. It is actually nowhere near as frightening or foreign as many would have you believe...it is no longer an operating system restricted to college comp-sci engineers, outright nerds, and hackers. It has become (and will still become) easier than ever before to learn and use Unix in your day-to-day life, either at work or at home. You do not need a mainframe or high-powered mid-tier server to install and operate GNU/Linux...in fact; just the opposite is true GNU/Linux performs better on older (and slower) PCs than any other OS on the market today. For example: Windows NT 4.0 Workstation requires (on a practical scale) at the very least 200MB of disk space for just the basic operating system and a practical swapfile*. GNU/Linux on the other hand can be run from as small a space as 20MB on a practical scale, including the swap partition. Windows NT 4.0 Workstation requires, on a practical scale, at least 16MB of RAM and a Pentium or better CPU just to operate at all. On the other hand, decent workstation performance can be had with GNU/Linux on something far less powerful, say an Intel 486SX-25 with 4MB of RAM. ** If nothing else, GNU/Linux gives you a perfect excuse to drag those dusty old 386 and 486 machines out of the broom closet at work, and put them back to work again - talk about recycling Course Information: This requires even more reading, but it will give you a good look under the hood, and to familiarize yourself with the basic GNU/Linux Kernel and, by extension, how the typical Unix kernel operates. Proficiency Goals: To learn the difference between DOS and Unix memory process handling Get a quick look into what STDIN, STDOUT is, and how they operate Take a short look into what Pipes are. Discover the concept of treating everything as a file. Learn about how Unix sorts directories See how Unix and DOS commands compare Become familiar with the Unix command-line environment Discover where it is you can get GNU/Linux, at low or no cost. Get an overview of what an installation will entail Brush up on the concept of partitions, then learn how they apply in GNU/Linux See how one would partition a DOS-loaded hard drive to accommodate more than one operating system. Windows NT Workstation requires 110MB of space minimum (on an x86 architecture CPU) for just the OS alone, according to Windows NT Core Technologies (MOC course # 922, Microsoft Press.) ** Note: By way of further comparison, this author has yet to see any useful Windows 98 installation take up less than 185MB, not counting the virtual memory swapfile. However, do know that MS-DOS version 6.22, all by itself, can be used practically on just a little more space than a small GNU/Linux installation, but with less available tools than is provided with GNU/Linux. Module Checklist Check off each item as you complete it: 1. _______Study: - Chapter 2 of the Running Linux textbook (pp.46-55) - Chapter 1 of the Unix in Plain English textbook (pp. 3-27.) 2. _______Complete: - The CBT Module UNIX: Overview 3. _______Online: - Go to the following website and read up on DOS vs. GNU/Linux: http://metalab.unc.edu/mdw/HOWTO/DOS-Win-to-Linux-HOWTO.html 4. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Installation and Initialization Module # -257409013 Module Summary: Why This is Important: While reading, testing, and memorization is adequate for a simple knowledge base on any given subject, it is preferable to give you hands-on experience with GNU/Linux. Having actual hands-on experience with an operating system not only reinforces the teaching, but will also allow you to become familiar and even comfortable with the *ix command-line environment. While most people have a bit of fear and trepidation at installing a complete operating system, especially one that seems completely foreign, there is no reason to fear this. Let it be known that the instructions are as complete as we can possible make them, and that an instructor will always be on hand to assist and advise when necessary, or even when needed. Do not worry that you will ruin any equipment ...as long as you follow the instructions completely, the worst that can happen is that you may have to re-install the operating system - that is why we provide you with a complete and empty hard disk drive to work with. This is where you begin to realize that Linux is not as easy to install as most other operating systems. However, it has become far easier recently, with the addition of Red Hats GUI install option, as well as the simple graphical installs performed by most Linux distributors. There will always be exceptions, but the Linux distributors are realizing that the easier they make an install, the more customers they attract, as GNU/Linux moves into the mainstream consumer market. I will have you use the standard text install, since not all Linux distributions will have the GUI install routine. Also, you will find that Im keeping you to the command line once the system is installed, even though many distributions can take you right to a graphical logon screen. This is because you need to know the command line environment...as a regular user, knowledge of command lines will make troubleshooting and repair far easier if your desktop goes down - as a sysadmin, it is vital that you know the command line environment since many Linux servers drop the GUI altogether; a pure command-line environment takes up less space and overhead on a server. You will find that I ask you to go back and forth between Windows and Linux throughout the course - this is because the CBTs run on a Windows OS, but by happy circumstance, it will also to put you in a position to compare the two environments side-by-side as you progress. Course Information: This will require that you plan and then install GNU/Linux onto a standard x86-architecture PC. Instructions and labs are to be read completely before attempting to install, and if there are any questions or uncertainties, you are urged to get the attention of the nearest instructor, and ask any question you want that relates to the installation. The only stupid questions will be the ones are never asked, or the ones that come up after something goes very wrong. Proficiency Goals: To plan and allocate your resources when it comes to GNU/Linux installation To work-up and prepare your PC for a GNU/Linux installation To become familiar with the installation procedure To gain proficiency in operating and loading a Unix-based operating system onto your PC. Module Checklist Check off each item as you complete it: 1._______Study: - Chapter 3 of Running Linux (pp. 56-90) - Lab 1 of this packet, Planning a Unix Install Strategy. - Lab 2 of this packet, Installation of GNU/Linux - Appendices A and B of this packet Note: Do not begin installation until you have read everything in this section! 2.______Install: - Get a blank hard disk drive from your instructor. It will be assigned to you for the duration of the course. It is to be removed and returned to the instructor at the end of each day. Follow through Lab 1 of this packet step by step. Use it to determine how you complete a copy of Appendix C, the Partition Planning Worksheet. Show the completed worksheet to the instructor before proceeding. - Follow through Lab 2 of this packet step by step. Use your planning worksheet, Appendix C, to guide you as you go through the installation. If you have questions at any time, or you are unsure about the installation, stop immediately and ask for help. 3. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Basic Unix Commands and Concepts Module # -257409014 Module Summary: Why This is Important: Once you have installed your basic GNU/Linux package, you will have an important tool for learning how to log on, log off, and learn to navigate your new world within GNU/Linux. The reason I had you set up your machines to start in the command prompt environment (as opposed to starting X-Windows immediately upon boot), is because you need to learn the command-line environment before you can effectively use the GUI environment, and to give you the confidence and skills to use a Linux machine without the GUI. While it would be ever so nice to simply fire up the machine and go straight to a Windows-like environment to get all of your work done, the reason I want you to know and perhaps get to love the command-line environment is because: There are a huge variety of GUI environments out there, and well cover some of them later, once you get the basics done. GUIs eat extra system resources, a thing sysadmins try to avoid on a server. If something goes wrong with a machine and suddenly there is no GUI, youll have to know how to fix the machine in a command-line environment. Often, it is far easier and more efficient to simply type a command than it is to go through a lot of point and click menus. Employers (and especially their sysadmins) have stated over and over again that they really couldnt care less if a user knows how to use a particular GUI. Most of them cite the fact that there are simply too many varieties of Unix GUI packages out there, and that GUI environments are rarely (if ever) used in a professional IT department. The command line environment is universal to all forms of Unix (not just Linux), and anyone who masters it will have no problems in directly demonstrating their competence in Unix to a prospective employer. Course Information: This module will require that you learn the basics of logging on, logging off, and basic navigation. You should then become comfortable with your system. Proficiency Goals: Learn how one logs into a system in more detail To learn where and how one sets and changes their own password To learn about Virtual Consoles. To learn how to move about in your new environment, via the commands ls, mount/unmount, mkfs, and basic directory navigation. Begin to learn about the differing shells available to you. Learn useful keys that will assist you in your new environment Discover how Unix helps you with shortcuts, filename expansion, and word completion. Saving your output-how to do it. Discover exactly what a command is. Learn about running background jobs and commands Need help? Youll learn how to get it instantly via the man (Manual) pages. Begin to discover file ownership and permissions Look up and learn what Startup files are for, and where to locate them Learn why directories are named such things as /bin, /boot, /usr/lib, etc and what is found within them. Find that Daemons in Unix are not only non-threatening, but that they actually serve you. Get a good solid look at processes, and what they mean to you as a user or sysadmin. Module Checklist Check off each item as you complete it: 1. _______ Start: Make sure you have an NT drive in your workstation, and log on to the network. 2._______Study: - Study chapters 2, 3 and 4 of Unix in Plain English Textbook (pp. 37- 127.) Pay particular attention to the following commands: su man passwd pwd whatis cat cd cp dircmp file find ls mkdir more mv page rm rmdir logout halt vi sort fmt col grep Study Chapter 4 of the Running Linux textbook (pp. 91-123) The CBT course: UNIX: Using the Shell 3. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Essential System Management Module # -257409015 Module Summary: Why this is Important: You will now begin to learn how it is a user and/or a sysadmin actually gets anything done on a GNU/Linux system. (Anyone who runs a GNU/Linux box for his or her own personal use is to be considered a sysadmin...after all, no one else is going to take care of that PC for you at home.) This packet is only a light look into basic administrative concepts, but it will help you to understand what one has to to just to keep housein Unix/Linux. This module also goes into what happens when you turn the power switch on, and how to control what happens when you do fire up your machine. Course Information: This module will assist you in learning how general housekeeping and management of individual machines are done within Unix, and how to run the system under normal conditions. Proficiency goals: To learn basic housekeeping and maintenance on your GNU/Linux system To learn how to run the system - literally. Booting the system - how to do it and how it can be done LILO - the boot loader that does it all for you...and how to make it serve you. System startup and initialization...what happens when you flip the power switch on? Running GNU/Linux in Single-User mode, which is separate from the default Unix state of multi-user mode. How to really shut down the system without resorting to the power switch. Discover what the /proc filesystem is, and why you should pay close attention to it Manage user accounts in the normal Unix multi-user environment Module Checklist Check off each item as you complete it: 1._______ Start: - Make sure you have your GNU/Linux drive in the workstation you are sitting at. Log on as a normal user and not root. Create an account if necessary using the adduser command. (this should have been done at installation, but still, make sure you have a normal account active. Show this account to your instructor, then complete Lab 3. - Once Lab 3 is complete, shut down your machine and load the NT drive. Log onto the classroom network, and proceed with the module 2. _______Study: - Chapter 10 of the Unix in Plain English Textbook (pp.289-307) - Chapter 5 of the Running Linux Textbook (pp. 124-159.) 3. _______Complete: - The CBT course UNIX: The User Environment. - The CBT course UNIX: Process and Data Utilities 4. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Filesystems and Devices Module # -257409016 Module Summary: Why this is Important: While most home GNU/Linux and Unix users simply set up their filesystems at installation, then forget about them as they load up with games and goodies, it bears notice that in business, things are slightly different. A sysadmin, or even the user, will be required to dive in on occasion and add new devices, or perhaps upgrade the swap partition when the RAM gets upgraded. This module will also give you a closer look into how devices and filesystems are manipulated, and how one would modify or change them as necessary. The home user will find that the information in this and other modules will be more than applicable to them as well. (After all, youre not going to keep that slow video card or those tiny chunks of RAM in that machine of yours forever, are you? Of course not - youre going to want bigger and better, just like anyone else with a computer...) This module, and the two following it, are the most important modules in this course - they will give you a close look into what actually happens behind the scenes, and how you can manipulate these happenings. While most of you will probably not go on to become Unix systems administrators, it is vital that you pay close attention to the following three modules, since they are just as vital to the home user as they are to the systems administrator. After all, what good is the worlds most powerful and flexible operating system if you dont know how to control it? Once you learn how to gain that control, you will gain quite a bit of satisfaction along with it. This is because Unix lends itself more to the independent spirit, while quite a few other operating systems are made instead for those who would prefer to have the operating system control them, as opposed to the other way round. Course Information: This is the first of three modules designed to give you a look at what is affectionately known as the guts of GNU/Linux, and by extension, Unix. Here you will gain a bit more knowledge, but it will focus primarily on hardware-related storage items, such as your hard drive and peripherals or any other devices you have bolted onto your system (like Zip drives, floppies, or any other items you might have that isnt quite standard) Proficiency goals: Get an overview on how to manage your filesystems Look at the various filesystem types, including those made for other operating systems. Discover how it is that you mount a filesystem. Learn how to mount devices automatically Want to create a new filesystem? No problem - youll learn how its done here Check and repair any damaged filesystems on the fly. Manage your swap space Get to know your devices a little more closely Module Checklist Check off each item as you complete it: 1. _______ Start: Make sure the NT drive is in your workstation. 2. _______Study: - Chapter 6 of your Running Linux textbook (pp. 159-182) 3. _______Complete: - The CBT course UNIX: Exploring The Filesystem - The CBT course UNIX: Working with Files 4._______Start: - Shutdown and install your Linux drive into the workstation. Complete Lab 4 and show your instructor the results. Once the instructor is satisfied with your work, shutdown the system and replace the drive with the NT drive. 5. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Upgrades and Compiles Module # -257409017 Module Summary: Why this is Important: Upgrades and improvements are always going to be a constant part of your experience around and with computers, whether you are at home or at work. No matter which operating system you have, youre always going to have to bring it up to the newest software (and hardware), or else your machine will slowly become old and decrepit, gathering dust in places like your garage or in some far-off closet at work somewhere. While no computer is immune to the need for upgrades, Unix has the unique ability to upgrade nearly all of its software without having to shut the machine down! While most other operating systems require a reboot (or multiple reboots, as in Windows NTs case), a Unix machine will only need a reboot under specific circumstances, most of them directly related to either hardware or kernel upgrade issues. Course Information: This module continues with basic sysadmin tasks, but this time we concentrate on upgrades, archives, compiling the kernel, and upgrading device drivers. This is the second of three vital core modules that will help you to understand what happens within Unix, and how it operates. Proficiency goals: Learn how to use archive and compression utilities to save your older versions -just in case. Learn how it is you upgrade applications and general software within GNU/Linux Unix Determine whether or not you actually need to perform an upgrade. Learn different methods, and which might be the best for you Upgrade libraries with the greatest of ease-well, relatively. Get a quick peek into how you can make your own upgrades Upgrading software that isnt directly related to your operating system Get a look into RPM (Red Hat© Package Manager) Dive into how you can compile a new kernel, upgrade an existing kernel, or replace the kernel entirely Learn how to upgrade your device drivers, separately and distinctly from the kernel Discover how to make those drivers load automatically. Module Checklist Check off each item as you complete it: 1. _______ Start: - Make sure your Linux drive is in the workstation, and that you are logged on as root. 2. _______Study: - Chapter 7 of the Running Linux textbook (pp. 183 223) - Refer to Chapter 10 of the Unix in Plain English textbook as necessary. 3._______Perform: - Lab 5, then Lab 6. show the results to your instructor for each lab before moving on to the next one. 4.Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Other Administrative Tasks Module # -257409018 Module Summary: Why this is Important: While it may seem esoteric, such things as backups, job scheduling, managing your logs, and sundry other tasks are sometimes vital to operating and securing your computer: Backups will save your data (at least most of it) if your hard drive goes kaput. Timing commands like cron make your life far easier, by running vital maintenance tasks in the wee hours of the morning (like backups for instance), without you having to be there to make sure it gets done. Managing and checking your system logs is usually the only way youll ever know if someone is trying (or has successfully tried) to break in to your machine for malicious purposes. Print services, be they for one user or for thousands, is vital to anyone who has reports to print, from homework to corporate financial statements. Also, well take a light look at what to do when things go bad, and how to recover from them Course Information: This is the third of three core modules, which details the bare-bones maintenance and upkeep of your Unix GNU/Linux system. This is also the catchall for the various sundry tasks that a sysadmin, or even a user, can do and in some cases must do, if he or she is to have a happy and healthy system. Proficiency goals: Learn the philosophy behind backups Learn the different forms and methods of backup, and how to accomplish each Schedule jobs, big and small, using cron. Manage your system logs, which records both system and security-related activity Manage your printer, from getting the right driver to using the best printer resource for your needs Learn about printer filters, and how to use them Optimize, and if necessary, troubleshoot your printer Set terminal attributes for both the console (you) and any remote or virtual terminal (them or you.) Learn what to do when things go wrong - I mean, really wrong. Module Checklist Check off each item as you complete it: 1._______ Start: - Make sure you have your GNU/Linux drive in the workstation you are sitting at. Log on as a normal user and not root. Use the su command as necessary. 2. _______Study: - Chapter 8 of the Running Linux textbook (pp. 224 275) - Refer to Chapter 10 of the Unix in Plain English textbook as necessary. 3. _______Complete: - Lab 7, then Lab 8. Show your instructor the results before proceeding. 4.Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Editors, Text Tools, Graphics, and Printing Module # -257409019 Module Summary Why this is Important: This is where you can actually get some work done. Think of your Unix machine as a car. In earlier chapters, you were just barely beginning to learn how the machine youve eventually built actually works, the principles behind its operation, and what to do with it under the hood. Now, were going to take this machine out of the garage and teach you how to actually drive the thing - that is, to put it to useful work. The beauty of Unix, and by extension GNU/Linux, is that you can make it do different things for you. Carrying our little car analogy further, we can say with confidence that a Linux-based machine can be, all at once or in turn: A sporty, yet powerful convertible (games), An 18-wheeled semi-tractor capable of heavy loads (database or application server) A minivan (word processing and other mundane, but necessary, tasks) A school bus (educational software) A tank (firewall and security-related software) A tow truck (server dedicated to network backups and restores) Or? Notice that the list is incomplete. This is because GNU/Linux, like any competent operating system, is constantly evolving and growing along with the industries (and consumers) that it serves. But let us boil it all down to this: How valuable is a computer to you, if you cant actually do anything useful with it besides keep it running for its own sake? Be it for games, reports, spreadsheets, or even as a working server within a network, a Unix machine is only as useful as the job it performs, and it is now time that you learned how to make it perform. Course Information: We will begin by introducing you to the most basic of all computer tools: Editors (programming, shell script editing, text editors, etc), Text tools (to turn that boring monospaced text into something worth reading), Graphics (to add that oomph to your text presentation), and Printing (to get the results on paper.) Proficiency goals: To learn how it is you can use basic editors to your advantage To study emacs and vi in all of its facets and aspects, since both are universal to nearly all Unix systems Learn how to process that text Discover how to write your own man page, and install it onto your system Learn quite a bit about TEX and LATEX, to finesse your words into a professional document Study up on how graphics can be used and manipulated in a command-line environment Print that document, and understand what happens to your document between the lpr command and the final paper product. Module Checklist Check off each item as you complete it: 1. _______ Start: - Make sure the NT drive is in your workstation, and that you are logged onto the classroom network. 2. _______Study: - Chapter 9 of the Running Linux textbook (pp. 276-330) - Chapter 8 of the Unix in Plain English textbook (pp. 177-275) as necessary... (optional) 3. _______Complete: - The CBT course UNIX: Using Editors 4._______Perform: - Shutdown your NT workstation, install your Linux drive, then reboot into Linux as a normal user. Use the su command as necessary. - Lab 10 (the vi exercise on page 277 of the Running Linux textbook) and a small Emacs exercise on pages 291-292 , then Lab 11 (The man exercise on pages 306-309 in the Running Linux textbook.) Show the results to your instructor before proceeding. 5.Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. The X-Window System Module # -2574090110 Module Summary Why this is Important: Now we get to the part that everyone can enjoy - X Windows. Now, much of what you will be reading within this module will have already been done for you when you originally installed your operating system...this includes setting up the video card, the system information, preferred resolution, etc. However, were going to delve into how its done on a system that does not have X-Windows installed. We will also cover the history, usefulness, and versatility of X-Windows, as well as what is required to install and operate it on a given system. Finally, were even going to show you how to customize your X environment, to make it so that it will suit your specific sense of taste and utility. Course Information: You will learn and explore the many ways and forms found within X Windows this will entail more reading than actual lab work in the beginning, since we already have X-Windows installed and operating on our system. Proficiency goals: To discover where it is that X-Windows came from Get a basic understanding of X Concepts Get only a partial tally of the hardware requirements (new hardware is being added almost weekly) Find out why it is that video cards and drivers are so important a factor in X-Windows. Learn where to locate X-Windows packages, and what all those files do. Discover how to configure an X-Windows environment Learn how to start up X-Windows Find out what happens if you get into trouble concerning X-Windows, and what to do about it Learn the basics of X customization Configure and run the fvwm Window Manager Discover and use the K Desktop Environment (KDE) Have a look at the variety of GNU-based X applications that come with your copy of X, and configure them to taste. Module Checklist Check off each item as you complete it: 1. _______Study: - Chapters 10 and 11 of the Running Linux textbook (pp. 276-330) - Chapter 12 of the Unix in Plain English textbook (pp.323-335) 2._______Explore - Look about your environment - locate and make note of all the applications and shortcuts that the Gnome environment makes available to you - such as linuxconf, icons to mount drives for you, and most of the utilities that youve used in command mode, all available in GUI format. Feel free to configure your GUI environment to suit your tastes. 3. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Windows Compatibility and Samba Module # -2574090111 Module Summary Why this is Important: Now that you have GNU/Linux all fired up and installed, there is this little problem of helping yourself to the files you have stored on a Windows machine or server within this classroom network. This is where Samba comes in. Not only can you pass files back and forth, you can also use Samba to register and log onto a Windows NT network, to access files on NTFS, FAT, and VFAT (Windows98) network partitions, and to integrate a GNU/Linux-based server into nearly any type of network environment. Why would you want to do this? Simply because there is no such thing as a pure network. Any given network in the real world will have a mixture of Windows, Unix, and perhaps something else entirely on it. Also, how would you like to be able to run some of your favorite Windows/DOS-based programs from within GNU/Linux? Youll learn how that can happen within this next module Course Information: You will learn the theory and practices behind getting GNU/Linux to play well with others, so to speak. This module will cover compatibility with Windows and other operating systems, be they on the same computer, or on another computer in a network. Proficiency goals: Learn how to share files and directories Mount DOS, VFAT, and NTFS partitions onto your local machine Use Samba to mount directories from Windows machines on your network Use Samba to serve SMB Shares Install and configure Samba Discover and use tools for Accessing DOS filesystems Learn about the various file translation utilities Learn how to share programs Discover and use the different DOS emulators: DOSEMU and xdos Learn about WINE, and how it can help you set up and run Windows-based programs Module Checklist Check off each item as you complete it: 1. _______Study: - Chapter 12 of the Running Linux textbook (pp.394-418) 2._______Complete: - Make sure your Linux drive is in the workstation and that you are logged on as a user with su privileges. Perform Lab 11 , then Lab 12. Show the instructor your results before moving on to the next module 3.Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. Intro to Programming Languages Module # -257409812 Module Summary Why this is Important: While you will probably never, ever, ever become a programmer, it is always useful to learn how programming is done. If you are a programmer already, then this module will still be useful to you, since it covers in detail how programming is done within GNU/Linux Programming under GNU/Linux (and by extension Unix) is very simple, and very elegant. It is also very powerful. While you will not have features such as test-on-the-fly, you will find far more flexibility when you program under GNU/Linux than you ever will with Visual Basic or Visual C++. As a programmer, you also get free copies of the source code for almost everything that runs in GNU/Linux, which is far more important to novice and expert alike. You will also get to interface with any part of the Linux source code, instead of being stuck with connecting to rigid Windows OS APIs. Course Information: You will get a glimpse of how not only to program under GNU/Linux, but also how programming in general gets done on an efficient basis. Proficiency goals: Take a peek at the GNU/Linux programming environment Learn quite a bit about gcc and how it operates, even to the point of building a simple program Learning the all-important Makefiles and make command. This comes in handy when compiling a kernel. Get into Shell Programming, and learn how it can make your GNU/Linux experience customizable Find out what all the shouting over Perl is about, and how an Internet language became more powerful than most folks had at first realized Learn the languages Tcl and Tk Get a taste of Java Learn what promise Java holds for you and the computer industry (Optional) learn the various tools available for programmers under GNU/Linux Module Checklist Check off each item as you complete it: 1. _______ Start: Make sure your NT drive is in the workstation, and that you are logged onto the network. 2. _______Study: - Chapter 13 of the Running Linux textbook (pp.419-470) - (Optional Reading) Chapter 14 of the Running GNU/Linux textbook (pp.471-514) 3. _______Complete: - The CBT course UNIX: Shell Programming - The CBT course An Overview of Java 4._______If Desired: - Switch to your Linux drive and try out the exercises throughout Chapter 13 of Running Linux. 5. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. TCP/IP and PPP Module # -257409813 Module Summary Why this is Important: TCP/IP is the heart and soul of the Internet...it is also the one protocol built originally for Unix and GNU/Linux - no other operating system type can run TCP/IP better, or more efficiently. Unix was the first, and is still the dominant, operating system on servers handling or running parts of the Internet (such as DNS Authoritative Servers, ISP mail servers, News servers, Web servers, etc.) If you ever decide to work for an Internet Service or Service Provider Company, thorough knowledge of Unix and TCP/IP is essential. While there are indeed Windows NT - based Internet mail servers (using Microsoft Exchange), and Windows NT based web servers (Using MS Internet Information Server), none have yet reached the simplicity and flexibility of Unix running Sendmail and/or Apache, and especially not at Unix level of efficiency. Needless to say, if youre going to network your GNU/Linux machine in any way, shape or form, youre going to need to know TCP/IP. Even if you want to logon to an Internet Service Provider (some ISPs, like AOL, are not quite compatible with GNU/Linux, at least without special software from the ISP itself. Check with your service provider in all cases, and let them know what youre doing before you connect.) Course Information: You will get a basis of knowledge in what TCP/IP is, where it came from, and how to use it to your advantage. Proficiency goals: Learn the basic concepts of networking with TCP/IP Learn to configure TCP/IP using Ethernet Discover Dial-up PPP, and how to configure and use it Learn how PPP is used over ISDN lines Discover NFS and NIS configuration, and how to put them to work Module Checklist Check off each item as you complete it: 1._______ Start: - Use the classroom clock to enter current date and time in the top of START box on the Module Completion Worksheet. 2. _______Study: - Chapter 15 of the Running Linux textbook (pp.514-554) - Chapter 6 of the Unix in Plain English textbook (pp. 141-175) 4. _______Transfer: - Information from the module Completion worksheet, onto a skill completion worksheet. 5. Ask any questions about you may have about the module in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the next module. The WWW and Electronic Mail Module # -2577409814 Module Summary Why this is Important: The World Wide Web has literally exploded over the past four years, starting as an obscure project in 1989 at CERN (A Swiss technology laboratory) to a phenomenon unlike any other. It is one that has literally transformed the civilized world into an interconnected community of ideas and concepts... no matter what operating system the person browsing the web happens to be using. Electronic Mail is a little bit older, but has become the workhorse of the Internet, transferring everything from full-length news video to gossip to cooking recipes between people that are literally separated by whole oceans and continents. Within less than a second, an important bit of news can travel from one side of the globe to the other, creating an unprecedented level of communications among entire populations of mankind. With GNU/Linux, the individual can have the same relative power and flexibility as a Unix Internet-level server, but have it at his or her fingertips. With a small investment and a bit of time, one can even set up his or her own webserver, capable of spreading a unique viewpoint, or information, to the entire world, without restriction or censorship by any government. Course Information: You will gain an understanding of how the World Wide Web works, as well as how to browse and even publish on the Web from your own GNU/Linux machine. We will then cover E-mail, and how to set up a private mail server, as well as how to get and send e-mail from your machine. Proficiency goals: Get a clear and concise history of the World Wide Web, without all the advertisement and commercial hype. Learn the concepts behind the Web, and how it works Discover how to use the copy of Netscape Navigator that comes free with each install of GNU/Linux Learn how to configure and launch your own web server, then test it within the classroom Learn quite a bit about how to write an HTML document Discover how to build interactive forms, using cgi-bin and Perl Set up and configure a mail server and Mail Transport Agent Send mail between other Linux workstations (and by extension learn to do it online) with various e-mail client programs Module Checklist Check off each item as you complete it: 1. _______Study: - Chapter 16 of the Running Linux textbook (pp.555-608) - Chapter 6 of the Unix in Plain English textbook (pp. 141-175) 2. _______Labwork: - Using pages 562-588 of the Running Linux textbook, Configure and set up a running Apache webserver. Adapt the instructions to your particular machine. This will be part of the final testing of your skills, to see if you can successfully translate the instructions and advice into a running machine, instead of being walked through it step-by-step. If you need help at this juncture, still feel free to ask your instructor to assist you as always, but strive to complete this lab using the skills youve learned throughout the course. You should already have all of the applicable programs already installed via Lab 2, so there is no need to complete any of the installation routines mentioned. If not, then contact your instructor, who will provide the needed programs for you to install, configure, and use. 4. - Prepare For the final written course exam (100 questions, multiple choice.) Ask any questions about you may have about the module and course in general, at anytime. When you have completed the above items to your instructors satisfaction, you may proceed to the final exam. Take as much time to study for the final exam as you need to I highly recommend re-doing some of the lab work and re-reading as much of the book as it takes to get you comfortable with GNU/Linux, Unix, and everything provided in this course. Your hard drive here in class makes an excellent testing ground for this, since it is far easier and less embarrassing to learn about the system here, than to do it the hard way once you get out in the IT world. You are more than free to explore your system stress test it by simulating then repairing errors and breaks, as well as re-installing and re-configuring the entire machine as many times as you desire. Just remember that there is progress being measured against a time standard, which is currently 120 hours. (This number may rise or fall as data becomes available about the average time it takes to complete this course.) Once you are ready for the test, you will have three chances to pass the written exam with an 80% or better grade, else you will have to wait 10 calendar weeks, then re-take this course in its entirety. If you pass the first time, congratulations! Skip the next paragraph :) If not, you will be forced to wait three school days before you can re-take the exam - this is not out of sadism, but instead out of a desire for you to locate and grasp the concepts you may have missed. I suggest you study the subjects that plagued you the most in those three days. Feel free to use your Linux drive and machine to assist you. Upon successful completion of the final exam, this course will be considered complete, and you will certainly be allowed to keep the DATC GNU/Linux distribution CD-ROMs that has been given to you. Feel free to take it home and use it at your leisure, but only in accordance with the policy provided with the DATC GNU/Linux distribution. You may also burn as many copies as you like, and distribute them to friends, acquaintances, etc, but only if you provide a copy of the GNU General Public License with it, and follow all applicable GNU GPL provisions. Finally, I highly recommend that you complete your proficiency in Unix and GNU/Linux by taking the next set of courses, involving Sair Inc. Linux/GNU Certification. Regards from your instructors, Thomas J Miller jr Kimberly Ziebarth Stephen Allen Book II: Appendices and Labs Lab 1: Planning a Unix Install Strategy Before you even think of shutting your computer down to flush and install a Unix operating system, you must sit down beforehand and learn about the computer youre using. Unlike Windows Plug-and-Play© or DOS universal hardware requirements, Unix is a very demanding system that requires you to know what hardware settings and parameters you use and have. Failing to know these settings, or worse, guessing at them, can lead to problems ranging from a failed install to a wrecked monitor. The reason lies in the fact that Most DOS and Windows-based operating systems will usually intercept and kill any process call that looks as if it will destroy the hardware For example - Windows NT© completely insulates hardware from any direct software manipulation by the user, as does the dynamic resource allocations found in most Plug-and-Play© compliant operating systems. Unix on the other hand does not insulate the user from the hardware. This reduces overhead, and allows more processing power to be sent towards the applications, instead of being wasted by the operating system. To put it in simple terms, Unix assumes that you know what youre doing, and wont try to second-guess you. Windows© and MS-DOS© assume that you dont know whats inside your computer at all, and acts accordingly, which, as a result, wastes extra processing cycles. In order to save yourself time and stress, it is usually wise to think ahead, and lay out exactly what you have, and what you want to do with it. During setup, you will be asked to specify partitions, including your root partition, swap-file, and data file partitions. You will also be asked what kind of video card chipset you have, the refresh rate on your monitor, and various other items that you really wont be able to look up during install. How to use the sheet: Ive built a basic planning sheet, Appendix C, to help you organize and prepare your strategy for partitioning and installation. Here is how to gather the information youll need to know, while your computer is still running Windows. First, get all the information needed For your X-Windows Video Settings: First, go to Display Properties (put the cursor on an empty part of the desktop, right-click, then select and click Properties.) Select the Settings Tab. Write down the listed Refresh Rate as indicated in the Worksheet. Select Display Type. Write down the manufacturer and the Chip Type (Chipset) information. (In this classroom, youre looking for the Trident 975 chipset) Also take note of the memory capacity. Since youd normally have to go into the box physically to determine whether or not it is AGP, I will give that part of it away these are AGP video cards. Make sure to note this fact in your worksheet by circling AGP as appropriate. The Monitor type should be written in the monitor case, right up in the corner of your monitor. Once you have the information you need, hit Cancel to insure that nothing is changed in the Registry. For the Hard Drive: Open the blank Unix classroom hard drive carriage, looking at the case of the actual HDD. Write down the information you find on the case, which includes Cylinders, Heads, and Sectors (CHS), as well as capacity. You will not need to know these immediately, but it will familiarize you with the drive that you will be using. For the Network Card: Right-click on Network Neighborhood, and select Properties. Select the Adapters tab. The name and type of NIC should be listed right there. Write it down youll use it later. Hit Cancel to back out of the window without altering anything. The Hard Drive Partitioning Schematic This graphic is put on the sheet to give you a visual tool to help you mark the proportions of HDD space used to plan your partitions. Draw in the lines marking off the different partitions youll need, according to the following mount points/ needed partitions. Use the completed drawing to form a rough estimate of each partitions size: /swp, or Swap partition. This partition should be at least as large as the amount of RAM you have in the system. Since the machines in this class have 64MB of RAM, it follows that the swap partition has to be at least 64MB large. A swap partition of up to 128 MB is possible in this configuration, but do know that any swap partition larger than twice your RAM will not improve performance by any appreciable amount. However, keep in mind that a swap partition is permanent, and if you add RAM to the machine, you wont be able to increase the size of the Swap partition without resorting to fdisk. If you dont leave enough free space in your HDD for a new (or larger) Swap partition, youll have to likely re-install GNU/Linux completely just for a RAM upgrade. A good rule of thumb is to make your swap partition as large as the maximum amount of RAM you plan to install in this particular machine (consider that the average life expectancy of a PC is about 2 3 years, before obsolescence makes hardware upgrades useless. Most companies replace their machines once every two years, on average.) /, or Root. The Root partition is exactly what it says this will be the root of your system, where the Kernel and vital operating system components will live and operate. This will also be your bootable partition, so make note of this on your worksheet. Make this partition at least 500MB large, but 1GB is a good size, to allow plenty of room for expansion. Minimum size can be as low as 150MB, but remember that you will have to operate this machine after installation, and adding components or recompiling the Kernel will leave even less free space to work with, which will affect performance greatly. /usr where your users accounts and account information is stored. However, it is best to leave room for the next partition as well. /home is the partition where users home folders reside. Here, you would have to take into account just how many users you will anticipate Make this a good-sized partition, since users will always add things to their home folders, and will rarely remove them. A good size for this class is around 500 MB or so, but in the typical network you should expect to use a general rule of 10-25MB or more per user. Most Internet Service Providers still use the OMB rule for users This means setting aside roughly OMB of space for a user to put up a WWW homepage, perhaps read and store their e-mail, etc. This is all done in the /home partition if you set one up. Once youve drawn it out Write down your estimated information in the next section, which lists partition name ( /dev/hda1-4 , since you can have only a maximum of four partitions on any hard drive. ) asks if each partition is bootable (choose your root partition.) , size (use the schematic above that youve drawn out as a guide to finalizing size in MB), type (Linux Native, or Swap File), and the mount point for that partition (as listed above) And thats it. Now take this information to the instructor for approval and to get a blank HDD to install your copy of GNU/Linux. Lab 2- Installation of GNU/Linux onto a hard drive After determining how you will partition the hard drive, the next step is to actually setup your hard drive, install GNU/Linux, and configure your machine. You will start with a blank 4.3GB (or larger) IDE hard disk drive, and will create the necessary partitions, install the mount points, install a bootable copy of the GNU/Linux Kernel and all components necessary for completion of this course. There will be a hard disk assigned to you from the instructor. Make sure you understand that, while no one else will be using it for the duration of the class, the drive is to remain here, in the classroom. You will be responsible for that hard drive during your entire time in this course. If you decide to take the advanced systems administration course, you will also use the drive youve worked on in this course, with all of the data and information intact. Before you Begin! Make sure you have enough time to install the systemit will take about 1 to 1-1/2 hours to complete. Withthat one item out of the way, you can now proceed to the install itself The Initial setup and boot process: 1)Find a computer with a removable HDD carriage in it (this carriage sits under the CD-ROM drive.) 1)Insert your GNU/Linux Kernel CD-ROM (disk #1 in the distribution.) 3)Label a blank floppy Linux Boot. Insert it in the A: drive. Locate and run rawrite.exe from the CD-ROM (\dosutils\rawrite.exe). When asked for the image source file name, type E:\images\boot.img (Assuming that e is the letter of your CD-ROM drive.) 4)Sit back and relax as rawrite burns a copy of a Linux boot disk into your floppy. 5)Shutdown the computer normally, and turn power off completely (this is done by turning off the main power switch behind the computer, by the power cord.) 6)Ask the instructor to unlock and remove the present HDD, and insert your assigned drive. It will then be locked into place (the removable drives do not work unless they are locked...a safety switch feature in the carriage prevents it.) 7)Power on the computer, booting from the DOS fdisk utility floppy. Check to make sure there are no partitions at all on your drive. If there are any, remove them completely. Have the instructor verify that your HDD is completely blank. 8)When the Linux welcome menu comes up, type text to install GNU/Linux. Allow the setup to load and detect your hardware. You will see quite a bit of text, but unless there are errors mentioned, it should not concern you immediately. These are the normal Linux boot messages. 9)Select English as your language (just hit ) and us as your keyboard style (again, ) 10)When the Welcome screen comes up (welcoming you to Linux and asking you to register), hit . 11)You will then be asked what type of system you would like to install. Since were learning about the system and not simply tossing together a typical workstation or server, use the arrow key to select Install Custom System and hit . 12)If you have a fresh hard disk, you will get a message saying that you have a bad partitiont able (you wont have a partition table at all on the new disks, which is where the error comes from.) If this is the case, select Initialize, and hit . 13)You will then be asked what type of machine you will be installing. Since we will eventually be turning this computer into a server, but will start as a workstation, use the tab key to select Custom, and hit . 14)When asked if you have any SCSI adapters, select No, and hit . The rest of this installation will be covered task by task in the following pages. At this point, you will see a menu describing Current Disk Partitions. This will be different from the older fdisk routine, but it is no cause for alarm youre using a newer version of fdisk known as Disk Druid, which allows you to set mount points and partitions at the same time. Now, take a look at the partition planning sheet you had outlined earlier in the course. This is why you took the time and trouble to write it all down before...to save you time and guesswork now, with the machine running and the command prompt cursor blinking. Repeat the following steps for each partition, using your outline as a guide. To get each partition made: Notice that no partitions are set aside or built for you. If there are, inform your instructor and he or she will correct this problem. Use the TAB key to select Add and hit . You will then see a menu pop up that says Edit New Partition. The first thing it will ask for is the name of your mount point. Were going to start with the swap partition, so there will be none in this partition. Use the TAB key to skip to Size (Megs): There should be a 1 there by default, so use the backspace key once to get rid of it, and replace it with the size (in MB) of your planned swap partition. TAB to the section that reads : Type on the right side of the window. Use the arrow key to select Linux Swap. Check to make sure your sizing is correct, then hit . This will set aside the partition and write it temporarily to your menu. Select and hit Add again. This next partition will be your boot partition. Here, next to Mount Point, youll want to add this character: / (slash) The slash alone indicates your root partition. TAB to the size field and indicate the size in MB that you want your root partition to be. Leave grow to fill disk? empty. Keep the Linux Native selection in the Type field, and go to ok, hitting to put this partition up on the main menu. Youll notice immediately that the root partition gets renamed hda1, while the swap partition gets renamed hda5. This is because your root partition is by default going to be considered as hda1 (this used to not always be the case, but standardization in Red Hat software almost demands that the root partition become hda1. The swap partition gets renamed hda5 so that it doesnt become confused with the four primary hard drive partitions. Add all other partitions accordingly. They will also be renamed, by default, as had 6, had 7, etc these are also installed as extended partitions. Double-check your partition layout. To save the partitions to the disk and move on with installation, TAB to the ok button and hit . You will get a question asking if you are sure about saving this info. If you are sure, select Yes and hit . If not, select No and fix any mistakes made. The rest of the lab will walk you through the menus, section by section. Choose Partitions To Format This next menu will ask you which partitions you want formatted. Notice how the names (hda1, hda2, etc) and the mount points are associated. To format a partition, simply highlight it and select it (They should be highlighted by default.) Next, TAB down to check for bad blocks during format, select it (using the SPACE bar), and TAB down to Ok. Hit . Notice that there will be no actual formatting yet that will happen in a few minutes. LILO Configuration Linear Mode You do not need to use Linear Mode. Enter nothing, Select Ok, and move on from here, since we have no legacy SCSI devices in these machines. Where do you want to install the bootloader? Install LILO in the master boot record, especially if you have a brand-new hard drive in your system, since there will otherwise be none. The next window asks you which partitions you want to make bootable. Choose the root partition, and then Ok. Hostname Configuration This is simply asking you want name you want to give to your machine. This name will identify your machine over a network as well, so keep it somewhat short. Otherwise, make up a name and type it in. When you are satisfied with that name, TAB to Ok and hit . Network Configuration This is where you would normally insert all of your networking info. We will be using DHCP for now, since the rest of the information is usually reserved for servers and other machines with a static IP address. You will be changing this later on in the course, so for now select Use bootp/dhcp hit OK. Mouse Selection You have a PS/2 Microsoft Intellimouse. Select it (use the arrow key to scroll down the list) , TAB to OK and hit (you have three buttons, so there is no need to emulate them.) Configure Timezones Obvious stuff select US Mountain (arrow down) TAB to Ok, and hit . Root Password Choose a root password (at least 6 characters long), type it twice (to ensure its spelled right), then OK. Add User It is always a good practice to add a normal user account as well as root. Use the same username and password as on your NT account, enter all fields, then OK. User Account Setup If you want more than one account, enter them here. Otherwise go to OK and hit . Authentication Config. TAB to ok and hit . We will stick with defaults for now Shadow and MD5 are encryption routines that keep all passwords safe from being viewed in the /etc/passwd file. There is no NIS server, so we can safely not use that option. Package Group Selection Here you will be presented with a list of software packages that will need to be installed. Highlight and select (or deselect as indicated) the following packages (if its not in this list, leave it blank. Many of the items in this list will already be selected.) Printer Support X Window System GNOME KDE (An advanced X Windows Desktop Manager) Mail/WWW/News Tools DOS/Windows Connectivity Graphics Manipulation Games Multimedia Support File Managers Networked Workstation Dialup Workstation (no modem installed, but there are some parts of it that will be useful.) News Server NFS server SMB (Samba) Server Anonymous FTP server Web Server DNS Name Server Network Management Workstaiton TeX Document Formatting Emacs Development Kernel Development Extra Documentation When done with the list, TAB down to Ok and hit . Nothing will be installed just yet, since there are a couple more questions that the systems needs to ask before installing the whole thing. X Probe Results Make sure the Video Card it lists matches the video card you have. Then hit . Bootdisk You want this a Bootdisk will allow you to boot into GNU/Linux without relying solely on your hard drives LILO (Linux Loader), or it can help you reboot and set Linux back to boot as a secondary OS if some program (Like Windows NT installation, for instance) removes LILO from your machine. Remove your boot floppy, hit , and insert a blank floppy labeled Bootdisk (LILO) when prompted. Installation to Begin You will get a note that a copy of the install log file will be kept as /tmp/install.log to be read for your pleasure after the install. Well reference it later as well. TAB to Ok and hit . Sit back and relax This is where setup writes the partitions, formats them, and installs everything in one shot. Keep an eye on progress, and if any errors pop up, alert the instructor to them immediately, noting as much of the error as you can see and record. This part of setup can take up to an hour keep an eye on the system, but feel free to, once in awhile, stand up and stretch a bit (but please do so quietly.) Now would also be a good time to hit the restroom, have a soda, etc... Notice that the filesystems are made first, then the packages added. If the system looks like its hung up, and there is no drive activity (check the HDD activity light on the box or on the HDD carriage), then alert the instructor so that steps may be taken to correct the problem. (If you suddenly have to leave class in the middle of this part, alert the instructor, so that the setup can be babysat until completion, and the computer shut down safely. Otherwise plan on having to re-install the system, since you need to learn how to install the system.) When the format and package install finally completes, proceed accordingly: Monitor Setup Youre going to be asked next what specific monitor you have. If you have an Optiquest Q71, arrow down to select it. If you have the Optiquest V75, Linux doesnt have a specific driver yet, so select Custom and TAB to Ok. Hit . For custom monitors, you will need some specifications. Hit Ok to acknowledge this, and select Super VGA, 800x600 @ 56 Hz. TAB to Ok, and hit . When asked for the Vertical Sync range on your monitor, select 50-70 (default) and TAB to Ok. Hit . Screen Configuration TAB over to Probe do keep in mind that this could lock up the system. In most cases, and on this particular machine, it will not. Hit again. Then use the default setting, selecting Use Default and hit . X Configuration Hit . You will see a screen with a window in it warning you of a timeout unless you click the Ok button. Use the mouse to quickly click the left button (Ok) . You will see a pop-up window asking if you want X Windows to boot automatically upon startup. SELECT NO! I want you to learn the command lines, and it would be a pain to have to shutdown the X Windows service every time you start up just to enter command lines. We will configure X Windows and KDE later right now you need to know the commands. If you selected yes, then you will have to clear the disk with DOS fdisk and re-install GNU/Linux all over again. You are learning the operating system itself, not just X Windows. Youre almost done! Remove the Bootdisk, and alert the instructor that you have successfully installed GNU/Linux onto your systemyou will see a screen saying that Installation is complete. In the instructors presence, hit Ok to acknowledge that setup is complete, then allow the system to reboot. Observe the reboot to ensure that there are no errors. Once you get a prompt for localhost login, enter the following: localhost login: root Password: (You set this password during setup.) After the instructor approves the configuration, type the following: shutdown -h now (include the spaces) The computer will go through the shutdown process, then the power will come off. End of Lab. Lab 3 - Installing and Using LILO Materials needed: A copy of Win98 OEM w/ boot disk LILO, or Linux Loader, is a multi-purpose tool that can load your choice of multiple operating systems on your computer at boot time. WindowsNT has a similar item known as boot.ini. LILO writes itself into the master boot record of the IDE primary master hard drive (/dev/hda1, or, if you have SCSI the drive will be SCSI ID 0 or Linux ID /dev/sda1.) and will remain there unless removed within Linux, or written over by another operating system. In this lab, we will remove the default LILO that was written in your MBR when you installed Linux, and replace it with Windows98 while Win98 is installed. After a base copy of Win98 is installed, we will then go back into Linux and re-install LILO, then edit it to include a boot option for Win98. Even though you are unlikely to use Windows 98 for the rest of this course, you will need to do so here, if only to show you how to manipulate and install LILO without damaging other operating systems that may be resident on your hard drive. If you have any questions, at any time, please get hold of an instructor immediately - do not simply assume; instead refer to material when needed, and the instructions both in this packet and in the reference books will walk you through the process. 1)Make a LILO boot floppy from the command line. Format a blank floppy with the command fdformat /dev/fd0 (do not mount the floppy beforehand.) Page 130 of your Running Linux textbook will walk you through the steps for making a boot disk. Once you have made the boot disk, then shutdown your machine and reboot, using only that disk (instead of relying on the hard drives MBR to boot for you, that is. You will basically be creating a way to get into and load your Linux partition after LILO gets wiped off of your hard drives MBR by Win98.) 2)Now, overwrite the hard drives MBR (where LILO normally resides.) We will do this as a demonstration, by taking a DOS floppy, booting with it (after shutting the machine down appropriately), and running fdisk /mbr . This will destroy your hard drives master boot record, replacing it with a copy of MS-DOS master boot record. You will not be able to boot to Linux from just the hard drive after this is done. 3)Shutdown the machine once more and remove the DOS floppy. Take your Linux boot floppy you had just created and, and boot into Linux with it. This will load the Linux kernel and launch the Linux partitions on your hard drive. Watch the boot process and make sure everything boots normally. Make sure that you do not configure LILO as a secondary boot loader, but instead make it the primary. As always, refer to the instructions in pages 132-134 of Running Linux. Further instructions are below... 4)Re-write the MBR so that LILO once again owns the MBR. Refer to page 132-134 for full details. Include both Win98 and Linux in /etc/lilo.conf. Use vi (instructions for vi are in the book Unix in Plain English, page 126-128.) Basically, type the command vi /etc/lilo.conf which will bring up the configuration file under the vi editor. To insert text, type i to insert text, using the arrow keys to move around the document as needed. Hit Esc to get out of insert mode when youre done modifying the document. Finally, when youre sure you want to finish and quit vi, make sure youre out of insert mode, then type :wq to exit vi - this will write your changes to the file and quit vi. Boot into Linux from the hard drive, then reboot into Windows 98, both by using LILO. Show the instructor your results. Lab 4: Mounting Filesytems Materials Needed: A floppy with a DOS text (*txt) file on it A CD-ROM with any title on it. This lab will walk you through the steps necessary to mount and automount filesystems as needed. You will use this lab to first learn how to manually mount removable media such as your CD-ROM and floppy drive, since Linux (and by extension Unix) requires that you notify the kernel that there is additional storage media added to the system, and to tell it what type of filesystem that media uses. This is to inform the kernel exactly what type of filesystem is being used on that media: Linux can see and access media that have been formatted in DOS, ext2 (Linux), WindowsNT NTFS partitions, and even Macintosh... By comparison, Windows currently will not allow such a thing to happen*, and Macintosh allows only limited access to DOS media, but even then only under special circumstances. In short, the payoff of mounting a filesystem manually is in the increased flexibility in the filesystems open for use in Linux. *Windows does have limited accessibility among its own proprietary filesystems: WinNT 4.0 can only access FAT16 and NTFS partitions, while Win98 can only access FAT16 and FAT32(vfat) partitions. Windows 2000 is reported to be able to access all Microsoft-specific filesystem types, but thats it. Next, you will mount and access other hard drive partitions that are foreign to Linux: In this case you will mount and access the Windows98 partition on your hard drive. Amazing as it seems, Linux can read and even write to a Windows partition without any trouble at all. This is true whether the filesystem is local, or if it is across a network. Admittedly, this wide adaptability is exactly what makes Linux the top choice for hackers, but it is also a huge leap in connectivity for the systems administrator, who would otherwise need a separate partition and reboot to access and fully use each separate operating system on his network. However, since a systems administrator can grant or revoke access to each filesystem in turn (either by user, process, or user group), security is still fully maintained within a Linux-based network. After becoming familiar with manually mounting a filesystem , you will then learn to configure your system to mount these things automatically when you load them. For example, the vast majority of CD-ROMs are formatted in ISO-9660 (Joliet) format. Therefore, why manually mount the CD-ROM drive every time you need to use it, unless you have some exotic or proprietary format on one of your CD-ROMs? Also, you can set your floppy to automatically detect and use whatever type of filesystem that particular floppy has been formatted in. But lets begin with the basics... Remember, you can initially mount/umount systems only as root, so use su to get root access. 1)Mount a CD-ROM manually. You can do this with one small command: mount -t iso9660 -r /dev/cdrom /mnt/cdrom The -t option tells the kernel exactly which filetype youre using (ISO 9660, aka the Joliet filesystem), the -r option tells the kernel to mount the device as read-only (you cant write to a simple CD-ROM), the /dev/cdrom tells the kernel which drive to use, and /mnt/cdrom is where you want the reference link to go (that way, you can enter and use the directory /mnt/cdrom when you want to do anything on the CD-ROM... it is the equivalent to /dev/hda, but is set up on a temporary basis. Verify a successful mount by entering su mode (using the root password), and then the command ls /mnt/cdrom Browse through the directories using ls and notice that you can see everything on that CD-ROM (there is no such thing as hidden files in Linux.) If you want to access anything on there, you will have to use the appropriate program to do it. Open and read some of the *.txt files using vi, since text files are universal. If you want to see more than one page of the text in vi, use CTRL-F to go forward one screen, and CTRL-B to go back one screen. Just remember that you cannot write to a file on the CD-ROM, so use the command :q to exit vi. 2)Mount an MS-DOS FAT-formatted floppy disk. Again, you can do this with only one command: mount -o conv=auto -t msdos /dev/fd0 /mnt/floppy The -o option actually means option...it is a way of letting the kernel know that youre using a special option...and the part -o conv=auto is not really necessary... it is only there to automatically convert all text files on the fly (as they are read) to a Unix format. This will not write anything to the disk, but is a helper, in case you want to print any of these files. Again, the -t option tells the kernel which filesystem youre using on the floppy (in this case FAT16, and Windows98-formatted floppies will usually work with -t vfat if they do not mount in -t msdos. Again, /dev/fd0 is the floppy driver that the kernel will use, and /mnt/floppy is where the link will go. It is important at this point to tell you that when you access /mnt and have more than one device mounted manually, you will have to further specify which device, by using /mnt/cdrom or mnt/floppy. This is why you have to further specify the devicename when you set the link in /mnt...you can use /mnt alone in your command line, but it will cause confusion later if you try and mount more than one device to it without specifying a devicename, and an error will usually spring up if you try. Again, look through some of the text files and open them in vi, using the same commands listed in the first exercise. 3)Unmount each filesystem in turn. This is far simpler: To unmount the CD-ROM, use the command umount /dev/cdrom ...thats all there is to it. Similarly, you unmount the floppy with the command umount /dev/floppy ... nothing to it. (Just remember that the command umount is missing the n on purpose.) 4)Edit /etc/fstab to allow users mount/umount privileges. This can be accomplished in whole on pages 166-167 of the Running Linux textbook. You will set permissions so that you can mount and umount only the floppy and CD-ROM as a normal user, and not root. Logout and log back in to test the changes as a normal user. Try and mount a hard drive as a normal user, and notice that it cannot be done. This is a standard permission, so that normal users cannot unmount hard drives, or add any additional hard drives to the system without the sysadmins permission. 5)Create and configure an /automount directory (Read through page 168 of the Running Linux textbook) for automatic mounting of the CD-ROM partition upon boot. Notice that now, when you stick in a CD-ROM, it will mount itself with no interaction from you. Also notice that no matter what type of floppy you use, you can get it mounted automatically, everytime. 6)Format (using mkfs) a floppy for use with MS-DOS, but do it in Linux by using the following command: mkfs -t msdos /dev/fd0 1440 (in case youre curious, the 1440 refers to the disk size - 1.44 MB.) Remove the floppy and switch to Windows 98 (reboot and choose dos at the LILO prompt) and test the disk by reading it in Windows Explorer...you should see an empty disk, but Windows 98 will not read an unformatted floppy. Copy a text file to that floppy, remove the disk, reboot into Linux at the LILO prompt, and if you set automount correctly, you should simply be able to insert the floppy, then use the command ls /mnt/floppy as a normal user (without having to use the su command.) When you have successfully completed this step, remove the floppy and it will automatically unmount itself. 7)Next, we will go into su mode (again using the root password) and create a temporary swap file using the command dd if=/dev/zero of=/swap bs=1024 count=8192. This will create a swap file 8MB in size. For a larger swap file, add 1024 bytes to count= for each additional MB of size. Now, format that swap file, using the command mkswap -c /swap 8192, again keeping in mind the size...make sure it matches the swapfile size you specified when you created the file. You must then synchronize it (sync) then enable it (swapon /swap). This will increase the size of your swapfile. 8)Finally, you can disable the temp swap file simply by typing swapoff /swap. You can then remove it by typing rm /swap. Warning: Do NOT remove the swap file until AFTER you have DISABLED it...you can easily wreck your system otherwise. Lab 5: use tar, gzip: use and functions Materials Needed: A large fake file named garbage.txt The commands tar and gzip are two of the most important commands you will need to know if you intend to add or change any of the programs on your machine, and you will have to do so on a regular basis, unless you dont want to add or change programs onto your system. These two programs are amazingly easy to use, and yet are flexible and powerful at the same time. The two programs are also universal to nearly all Unix systems in use today, so you can use it on anything from Linux to AIX to Solaris, without having to re-learn their use entirely. Tar and gzip are the workhorses when it comes to upgrading programs, especially programs downloaded from the Internet. They are very similar to the old PKZIP program, except that they are more flexible, and do not require as much accommodation. You will find that once you have a basic grasp of the tar and gzip commands, the rest will come easy. As with any other program in Linux, you can pipe the results into almost anything, and can use the command line to create a flexible method of making your compressions and backups do almost anything you want them to. But first, lets get the nuts and bolts in place... 1)Mount a floppy with a test file (garbage.txt) written to it. You can get a copy of this file from your instructor. 2)Create a file on your system named /temporary, by going into su mode, cd / , and using the command mkdir /temporary. gzip the file /mnt/floppy/garbage.txt, and save it to your /temporary directory. 3)rename the gzipped file rubbish.txt.gz : cat /temporary/garbage.txt.gz > /temporary/rubbish.txt.gz. 4)gunzip the file, but do it so that the restored file retains its original (garbage.txt) name. Instructions are on page 185 of the Running Linux textbook. 5)List the contents of your /proc directory, but pipe the result to a gzipped text file. (using the command: ls /proc | gzip > /temporary/myproc.gz Move the resulting file to a floppy disk (the command mv /temporary/myproc.gz /mnt/floppy/myproc.gz Let the instructor gunzip and view the contents from a floppy. Tar the entire contents of /boot (as su) and save the results in the /temporary directory. Use this file to walk through the exercises in pages 187-194. Lab 6: Upgrading Software Materials: an updated set of libraries for libc an updated gcc compiler an RPM patch (desktop images in this case) an updated kernel source First: Upgrade the main Linux C library (ls -l /lib/libc), by doing the following: (note: make sure the major version numbers of the old and new libc images match) 1)Untar and compile the glibc package (glibc-2.1.2.tar.gz) Make sure you are in the untarred glibc-2.1.2 directory, and compile with two commands in succession First, run the command: configure enable-add-ons (a shell script with a full functionality argument) and when complete, run make install 2)Make sure the new glibc.a file is in the /lib directory; if not, put it there (you will be able to find it in the glibc-2.1.2 directory otherwise.) 2)Make sure the new glibc.so. file is in the /lib directory; if not, put it there. 3)Run ln -sf /lib/glibc.so. /lib/glibc.so. to change all symbolic links and to update them. (note: replace with the full version number. Replace with just the major version number alone. 4)Confirm this again with ls -l /lib/glibc , then remove the old libc image file. 6)Run ldconfig to regenerate the library cache and to update ld.so (reference: pp 198-199) Second: To upgrade your gcc compiler and related utilities, by doing the following: 1)Determine which version of the gcc compiler you have, with the command gcc v 2)Unpack the new version as root, and replace the older versions of these files in accordance with the README (in the gcc tar file) and page 200 of your Running Linux textbook. Third: To upgrade using an RPM package (additional desktop backgrounds in this case), by doing the following: 1)Locate the packages to be installed. 2)Get a list of the package contents by using the command: rpm -qp1 3)Use the command rpm -ivh .rpm (the -ivh switch installs, uses verbose mode so that you can see the install in progress via h, or hash marks which are similar to dots describing the installs progress.) 4)Thats it - now verify that the package has been installed by using -ls in the appropriate directories. References: pp 203-206 Finally: To rebuild the kernel completely, by doing the following: 1)Refer to pages 207 - 219 as needed. 2)Get a copy of the updated kernel source from the CD-ROM available within the class. 3)Check your current kernel version with the command uname -a be sure that it is an earlier version than the one you are rebuilding (check the front of the CD-ROM...the version number will be written there.) Go into su mode at the prompt. 4)Deposit the kernel tar file into /usr/src. Unpack the source in the same place with the following commands, in order: cd /usr/src mv linux linux.old tar xzf (replace with the name of the new kernel file) 5)Do NOT move or remove the old kernel itself yet... 6)Study the README file that came with the upgrade package carefully. (it is usually located at /usr/src/linux/README. Use vi to read it.) 7)Run cd /usr/src/linux Run make config Answer the following questions carefully (if you want to learn more, simply answer with ? Which will answer any questions you may have about the terminology or questions you may have: Prompt for experimental drivers, etc? N Processor Family? PPro6x86MX (This should be defaulted.) Maximum Physical Memory? 1GB (default) Math Emulation? N MTRR (Memory Type Rage Register Support?) Y Symmetric Multiprocessing support? N Enable Loadable Module Support? Y Set version information on all symbols for modules? N Kernel Module Loader? Y Networking Support? Y PCI support? Y PCI Access Mode? Any (default) PCI quirks? Y Backwards compatible /proc/pci? Y MCA (microchannel) support? N SGI visual workstation support? N System V IPC? Y BSD Process Accounting? Y Sysctl support? Y Kernel support for a.out binaries? Y Kernel support for ELF binaries? Y Kernel support for MISC binaries? Y Parallel port support? Y Lab 6, cont: PC-style hardware? Y Support foreign hardware? N Advanced Power Management BIOS support? N Plug and Play support? Y Autoprobe for parallel ports? Y Normal Floppy Disk support? Y Enhanced IDE.... ? Y Use old disk-only driver on primary interface? N Include IDE/ATA-2 disk support? Y Include ATAPI CD-ROM support? Y Include IDE/ATAPI tape support? Y Include IDE/ATAPI floppy support? Y SCSI emulation support? Y CMD640 chipset bugfix/support? Y CMD640 enhanced support? Y RZ1000 chipset bugfix/support? Y Generic PCI/IDE chipset support? Y Generic PCI busmaster DMA support? Y boot offboard chipsets first support? N Use DMA by default when available? N Other IDE chipset support? Y Generic 4 drives/port support? Y ALI M14XX support? N DTC-2278 support? N Holtec HT6560B support? N QDI QD6580 support? Y UMC -8672 support? N Loopback Device Support? Y Network block device support? N Multiple devices (RAID) driver support? N RAM disk support? N XT hard disk support? N Mylex...PCI RAID support? N Parallel port IDE device support? (Zip drives, etc) Y Compaq SMART2 support? N Packet socket? Y Kernel/User netlink socket? Y Routing messages? N Netlink device emulation? Y Network firewalls? N Socket filtering? N Unix domain sockets? Y TCP/IP networking? Y IP multicasting? N IP advanced router? N IP kernel level autoconfiguration? N IP optimize as router not host? N IP tunneling? N GRE tunnels over IP? N Lab 6 cont: GRE tunnels over IP? N IP multicast routing? N IP aliasing support? N TCP syncookie support? Y After this point you will see a notice saying it is safe to leave these untouched. Simply hit one line at a time to use the defaults for the next few questions, until you see a notice telling you that the kernel config is finished. You will still have lots of drivers in there that will not run on your system, but the point is to 1) show you that you can manage and trim down your kernel by an almost infinite degree, unlike Microsofts Windows© series of operating systems, and 2) That you must be rather familiar with your machine to know exactly which card chipsets and items you do have. When in doubt, always answer ? and read the help file on that question...in some cases, you might need it, in others, you might not. Still in others, you will receive information on any additional items you may have to enable later on to enable the option you just selected. 8)Next, you need to run make dep. Wait for the command prompt to reappear. Make sure youre not running anything else at this point (you shouldnt be), then run make bzImage (the kernel in this exercise will be too large for a standard make zImage, but the change will not affect the operation of the kernel. Note that the make bzImage command can only be used on newer machines.) when this is complete, go to /boot 9)Next, cd /usr/src/linux/arch/i386/boot/ Then run rdev to make sure that the kernel boot partition is listed as being the same device that was originally there (in this case /dev/hda2.) 10)Now, copy the new bzImage to /boot with cp bzImage /boot (make sure that you do not get an overwrite file? error message - if you do, answer n, change directory into /boot and rename bzImage there to bzImage.old. This should not happen in your installation, since you have not compiled the kernel before now. ) 11) Fire up the vi editor for lilo.conf ( vi /etc/lilo.conf ) and change the image = to reflect /boot/bzImage (make very sure you pay attention to the case sensitivity.) Once you have edited lilo.conf, run /sbin/lilo to reflect these changes in LILO itself. Now comes the last and most exciting part: Reboot the system and make sure it reboots correctly. Have your boot disk (made in Lab 3) ready just in case. If something goes wrong at this point: If nothing happens, or the kernel panics during boot (that is, it wont start at all and loops endlessly or locks up), shutdown the machine with the power switch. Use your boot floppy to reboot the system, and re-edit /etc/lilo.conf on the hard drive to reflect the old kernel. Then go through the steps once again to rebuild the kernel completely. If the second rebuild still doesnt do it, you may have to re-install the whole system. If you see some error messages during boot relating to System.map, you will have to make the update manually: Once you have rebooted completely, go to su mode, then cd /boot . Change the name of System.map to System.old . Once this is done, use the following command and drag out the new System.map and put it into place: cp /usr/src/linux/System.map /boot You will be asked if you want to overwrite the present System.map in /boot...answer y and the new .map file will be moved in. Reboot again to insure that the new map no longer produces any System.map-related errors. The system map, during boot, lets the kernel know where everything is in a basic system. If you see an error during boot concerning module dependencies, you will have to manually build and set these dependencies. Create a directory known as /lib/modules// copy the module.dep file from the old /lib/modules/ to the directory you have just created. You will notice that this will erase the old directory. Once the file is copied, go to the new /lib/modules/ directory and issue the command depmod -a . Once this is done, reboot the system and the error should be gone. This error refers to a lack of module dependencies (you shouldnt have any modules loaded), because the kernel looks for these dependencies during boot time. Modules are explained further in Chapter 7 of the Running Linux textbook under Loadable Device Drivers. Lab 7: Managing system logs Materials: None - they are already on your system. 1.Start your machine and log in as your usual account. You will need to log in as su to perform many of the next steps, so it is safe to do so and remain as su during the entire lab. The system logs require root login specifically because this prevents anyone without root access from changing the log to hide any activities they might have performed without permission. 2.Type vi /var/log/syslog.conf and notice that you have more than one log present...this is where you can also add or remove the items that you want to see logged. Since were not going to change anything here, you can get out of vi at any time by typing :q , which will quit vi without making any changes to it. 3.Change to the directory /var/log. Then peek at the messages log using vi messages . Use the pageup/pagedown buttons to scroll through the various shutdown and startup messages - you can see from this log that messages contains all notices and messages sent to or from the kernel for the past few days, even longer. You will notice -MARK- listed every 20 minutes, if your machine has truly sit at idle, say, overnight. You can tell when your system was restarted by the simple message: syslogd 1.3.3: restart The very first thing that init starts (after the kernel starts it) is the system logs - this is to provide all diagnostics information you might need in case things go wrong. You will also notice that there is a whole lot more listed than what you had seen during boot, in addition to all boot messages that you have seen on the console during startup. Finally, you will notice the exact time in which you gained su access, and whether it was successful or not (though it obviously must have been successful for you to access the log, the log also records unsuccessful attempts as well. This comes in handy when checking for hacking attempts, since hackers need root access in order to actually do anything on your system.) 4.Back out of vi (:q) , create a directory called /oldlogs, and archive your old messages log by the command: cp /var/log/messages /oldlogs/messages.1 Now, get rid of the current logs contents with the command: cp /dev/null to /var/log/messages ...when asked if you want to overwrite the file, say y . This will literally remove the log messages and get the file ready to receive more entries. It does this by overwriting the doomed log file with a new file of 0 bytes. 5.Now, back out of su mode, then try to go back into su mode with a bad password. Then logoff, and log in as root, but use a bad password again. Now, log on with the correct normal username and password, then use vi to open /var/log/messages again. Notice that all the previous entries had been erased from the current log back when you copied /dev/null to it. However, you will notice that your failed attempts to login as su and as root are recorded. If you notice a large number of failed logon attempts into root or su, then it certainly warrants further investigation, since this is an obvious sign of a brute-force break-in attempt. 6.Once you have updated your logs, you may notice that the old logs are no longer needed or used by the system itself. From here, you can either keep the old logs in the folder /oldlog (or any other name you may choose to create), or you can let it sit on your hard drive for, say, a month, then move them wholesale to a backup device, be it a tape, CD-R, or whatever you use to backup your system. This will free up space that can be used by other logs that have been outdated, or by anything else. As a practical rule, backing up your logs this way (all of the logs) once per week is the best method, depending on how busy the machine in question is. Finally, know that you can automate this log update routine through crond or anacrond, simply by having cron refer to a script that combines these commands for you. Scripting is covered in deeper detail in Scheduling Jobs Using cron, earlier in Chapter 8 - Use this section to create a simple script that will do exactly this for you, and to compress the log files for you as well - show the instructor your results: Prove the script by having it run once within 10 minutes of setting crontab. The example on page 239 is an excellent place to start. Lab 8: The Line Printer Daemon Materials Needed: A small Linux-compatible printer (HP DeskJet) provided by the instructor A Bi-directional printer parallel cable The power supply for the printer, as well as paper and etc. material This lab will help you through what most people consider to be the toughest part of running a Unix system - the lpd or Line Printer Daemon. In reality, Linux has made the job much easier, though you may find that there are more helper tools installed in Linux than there are the fully flexible tools one would find in other flavors of Unix, such as Unix V or AIX. First: Before you do anything, shutdown your machine entirely, and turn the power off. Plug in the printer, and make sure it comes online. Make sure there is paper in the tray, and that the printer cycles through its normal power-up sequence. Once you are satisfied, turn the computer on, and pay close attention to the boot messages - youre looking for a successful startup of the lpd, what port it is using, and you may even see the specific type of printer the kernel has detected. If you miss anything, you can always use vi to open /var/log/messages and look through the boot process more carefully. Take special note to see if your printer was detected (or started) on lp0 or lp1 ( lp# = Line, Parallel 0 /1. Serial printers will hook up on s0 or s1, otherwise known as Serial (line) 0/1) Before you configure: Give your printer a quick self-test by the simple command: lptest > /dev/lp0 If you see text come out of the printer, then you can be rest assured that your hardware works perfectly. If not, inform your instructor. 1)Go into su mode. Check the /var/spool/lpd directory to make sure you have a subdirectory listing a printer within it (usually a short name like dj or lp.) if it does not exist, then make note of it for now. Next, open /etc/printcap with vi - look at the following field: sd= (or lp.) This line defines where the spool directory will be for this printer - take careful note of the full path name to that file. Make sure that the field lp=/dev/lp0 matches the printer port you had found and checked for during boot. Next, back out of vi (:q) and make sure printcap is owned only by root, but is read-only to everyone else, with the following commands: chown root /etc/printcap chmod 644 /etc/printcap 2)If it doesnt exist, create the subdirectory for the print spool - replace lp with whatever name is given in the sd= field of /etc/printcap...the path listed below is only an example, and the proper filters may be elsewhere: mkdir /var/spool/lpd/lp chown root.daemon /var/spool/lpd /var/spool/lpd/lp chmod ug=rwx,o=rx /var/spool/lpd /var/spool/lpd/lp 3)The default filter installed during your initial install should work for your system. You need to create the proper subdirectory for the spooler, give root and daemon ownership of the filter, then make sure the filter is executable by everyone. You do this with the following commands: chown root.daemon chmod ug=rwx,o=rx 4)Create the .seq file, then issue the following commands to make sure these files have their proper permissions and ownership: cd /var/spool/lpd/lp touch .seq errs status lock chown root.daemon .seq errs status lock chmod ug=rw,o=r .seq errs status lock At this point, all you need do is to restart the lpc service ( lpc restart all ) and then print a sample file, using the following command: ls -l | lpr -Plp ( lp = the printer name as defined in /etc/printcap) If you get a listing of the directory youre currently in, your printer works, and you are well on your way to running a printer the hard way. It bears saying that there are today far easier ways of getting your printer up and running. However, this method works on most Unix systems, and the helpers arent always available when you need them... Lab 11: Networking with Samba (SMB) Materials Needed: An NT network to connect to, or at least a mixed Windows (or perhaps Novell) / Unix environment. Here, you will learn to network your single computer into the rest of a network, and have it operate as an integral part of the network at large. You will turn your standalone computer into a server that can be accessed by a Windows NT machine, and in turn allow you to access the same NT machines. You will find a large number of options and configuration varieties, but you will find that once properly set up, the system will run much easier than you think. First: You should already have Samba installed and compiled on your system - this was one of the installation options. Second, we will delve into setting up Samba... 1)Locate the file smb.conf - it will be sitting in /etc . Use vi to open it. 2)We will look through the options in turn...(use vi INSERT mode to make changes) Under the option workgroup, change the default MYGROUP to the name NTDOMAIN2, which is the name of our NT classroom domain. Change the server string option to reflect whatever description youd like for your server. Under the option hosts allow, use the following IP string to reflect the classroom address pool and the loopback address: 192.168.212 and 127 .This will allow everyone in the classroom network to get basic access to your machine. Notice we didnt complete the IP address - it is only necessary to use the subnet ID as the filter - everything else will be excluded. Make sure you activate this by removing the ; symbol at the beginning of the line. Under the printer options, you will not have a printer attached, so it would make more sense to not use them - simply put a # symbol at the front of the two printer option lines. The same goes with the printing system type option. Know that in a real network, you really dont want guest access. Leave this line as it is, since it will remain out of use. Move down to security mode - you will want to uncomment this (remove the ; symbol) to let NT authorized domain users into the parts of your server that you want to share. Replace with Ntserver. This is the name of the server in the classroom network. Leave the Password Level as it is - it should remain commented. Scroll past all other options (taking note of what each does) until you see the comment: Use this only if you have an NT server on your network that has been configured at install time to be a Primary Domain Controller. Since we already have a PDC on the classroom network, uncomment this line and change the name to Ntserver. Continue scrolling further, again studying the function of each (if you have any questions about them, please feel free to ask.) Continue down until you see the header Share Definitions. In this section, you will find the configuration set just like a typical Microsoft .ini file. Your home directories will already be listed, and these will be the only parts of your computer that the rest of the network will see. 3) Once you are satisfied with the configuration of smb.conf, make sure the changes have been written to it, then take not of the hostname for your computer, which you can get from the prompt itself. Mine (in su mode) looks like this: [root @ millertj spark ] # The prompt is divided into [Username @ Hostname Directory] Youre going to want to know the hostname. Using that hostname, typing it all in caps when you do, enter the following command: nmblookup (of course, replace with your actual hostname, all in caps.) The results should look much like the example on page 402, where your networking information (IP address, broadcast address, subnet mask) is added to the Samba configuration, then a query is then broadcast to your subnetwork to discover who else is out there. 4)If you dont get the configuration results, then check page 402 of the Running Linux textbook to determine what you may have missed, or may even need to add. If all goes well, run through the two tests given on pages 402 - 403 (smbclient and testparm) to further test out your Samba server. You need not continue with the configuration listed in the book, because smb.conf is already built for you. 5)Once all is configured and running, then leave your machine on, and head on over to a WindowsNT machine. Log into it, then browse through Network Neighborhood > Entire Network. See if you can locate your machine on it - you should see it in the list. Now, go to your machine and log into it - you will see a Windows dialog box asking you for a username and password - then enter your normal account username and password. Appendix A: Traditional fdisk installation commands fdisk commands (Table 1.1) command Action a Toggles a partition as bootable c Toggles DOS Compatibility d Deletes a Partition l Lists partition types ( see Tab. 1.3) m Displays this table n Creates New Partition p Displays current partition table q Quits without saving changes t Changes a partitions system ID u Changes display/entry units v Verifies the partition table w Writes the table to disk and exits x Expert Mode do not invoke (yet) =========================================== GNU/Linux Partition Types (Table 1.3) Reference Number (Hex) Type 0.Empty 1.DOS 12-bit FAT 2.XENIX root 3.XENIX usr 4.DOS 16-bit < 32MB 5.Extended (Generic) 6.DOS 16-bit >= 32MB 7.OS/2 HPFS 8.AIX 9.AIX Bootable Partition a.OS/2 Boot Manager 40...Venix 80286 51...Novell? (Old Novell) 52...Microport 63...GNU HURD 64...Novell 75...PC/IX 80...MINIX 81...MINIX/Linux 82...Linux Swap Partition 83...Linux Native 93...Amoeba 94...AmoebaBBT a5...BSD / x86 b7...BSDI file system c7...BSDI swap partition db...Syrinx e1...DOS Access e3...DOS R/O f2...DOS Secondary ff.BBT Appendix B Traditional fdisk and install screens Table 1.4 fdisk screen showing blank HDD Disk /tmp/hda: 255 heads, 63 sectors, 524 cylinders Units = cylinders of 16065 * 512 Device Boot Start End Blocks Id System Command (m for help): Table 1.5 fdisk screen showing fully and properly partitioned HDD Disk /dev/hda: 255 heads, 63 sectors, 524 cylinders Units = cylinders of 16065 * 512 bytes Device Boot Start End Blocks Id System /dev/hda1 1 9 72261 82 Linux swap /dev/hda2 * 10 137 1028160 83 Linux /dev/hda3 138 265 1028160 83 Linux /dev/hda4 266 524 2080417+ 83 Linux Command (m for help): Appendix C Installation Planning Worksheet Hard Drive: Size: __________________ MB GB Cylinders: ______________ Heads:_________________ Video: Card Chipset: ____________________ Manufacturer (optional):_____________ Bus: AGP ISA PCI Monitor manufacturer/model: ________________ Refresh Rate: ________ Hz Memory: ________MB Network Card: Manufacturer and model: ___________________________ (Example: Linksys 590x) Hard Drive Partitioning Schematic (Roughly sketch and label with the appropriate names (/dev/hda/*), sizes and mount points.) 0 50% 100% Partition name Make it bootable? Size (in MB) Partition type Mount Point Name /dev/hda ____ Y N __________ ___________ __________ /dev/hda ____ Y N __________ ___________ __________ /dev/hda ____ Y N __________ ___________ __________ /dev/hda ____ Y N __________ ___________ __________ Include the following mount points: /swp (swap file): Also known as Partition Type 82, or Linux Swap. Some Unix systems label the mount point as /swp, but Linux merely uses fdisk to label the partition, as opposed to using a mount point. / (Root): Youll always need a root partition. Notice that there are also other named mount points, such as /var (variables), /lib (libraries), and /etc, but these are optional items, and some distributions of Linux doesnt allow some of these to be made into partition-level mount points. Got enough Space left over? Leave about 1GB of empty space for any future additions - you will need it in this class to install Windows 98 as part of Lab 3 and beyond.