20,99 €
Manage files, set up networks, and go online with UNIX!
UNIX For Dummies has been the standard for beginning UNIX references for nearly ten years, and this latest edition continues that tradition of success. This unparalled resource is updated to cover the latest applications of UNIX technology, including Linux and Mac desktops as well as how UNIX works with Microsoft server software
Thorough coverage of how to handle:
Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:
Seitenzahl: 587
Veröffentlichungsjahr: 2011
by John R. Levine and Margaret Levine Young
UNIX® For Dummies®, 5th Edition
Published byWiley Publishing, Inc.111 River St.Hoboken, NJ 07030-5774www.wiley.com
Copyright © 2004 by Wiley Publishing, Inc., Indianapolis, Indiana
Published by Wiley Publishing, Inc., Indianapolis, Indiana
Published simultaneously in Canada
No part of this publication may be reproduced, stored in a retrieval system or transmitted in any form or by any means, electronic, mechanical, photocopying, recording, scanning or otherwise, except as permitted under Sections 108 or 109 of the 1976 United States Copyright Act, without either the prior written permission of the Publisher, or authorization through payment of the appropriate per-copy fee to the Copyright Clearance Center, 222 Rosewood Drive, Danvers, MA 01923, (978) 750-8400, fax (978) 646-8700. Requests to the Publisher for permission should be addressed to the Legal Department, Wiley Publishing, Inc., 10475 Crosspoint Blvd., Indianapolis, IN 46256, (317) 572-3447, fax (317) 572-4447, e-mail: [email protected].
Trademarks: Wiley, the Wiley Publishing logo, For Dummies, the Dummies Man logo, A Reference for the Rest of Us!, The Dummies Way, Dummies Daily, The Fun and Easy Way, Dummies.com, and related trade dress are trademarks or registered trademarks of John Wiley & Sons, Inc. and/or its affiliates in the United States and other countries, and may not be used without written permission. UNIX is a registered trademark of UNIX Systems Laboratories, Inc. All other trademarks are the property of their respective owners. Wiley Publishing, Inc., is not associated with any product or vendor mentioned in this book.
LIMIT OF LIABILITY/DISCLAIMER OF WARRANTY: While the publisher and author have used their best efforts in preparing this book, they make no representations or warranties with respect to the accuracy or completeness of the contents of this book and specifically disclaim any implied warranties of merchantability or fitness for a particular purpose. No warranty may be created or extended by sales representatives or written sales materials. The advice and strategies contained herein may not be suitable for your situation. You should consult with a professional where appropriate. Neither the publisher nor author shall be liable for any loss of profit or any other commercial damages, including but not limited to special, incidental, consequential, or other damages.
For general information on our other products and services or to obtain technical support, please contact our Customer Care Department within the U.S. at 800-762-2974, outside the U.S. at 317-572-3993, or fax 317-572-4002.
Wiley also publishes its books in a variety of electronic formats. Some content that appears in print may not be available in electronic books.
Library of Congress Control Number available from publisher.
ISBN: 0-7645-4147-1
Manufactured in the United States of America
10 9 8 7 6 5
5O/TR/RQ/QX/IN
John R. Levine was a member of a computer club in high school — before high school students, or even high schools, had computers — where he met Theodor H. Nelson, the author of Computer Lib/Dream Machines and the inventor of hypertext, who reminded us that computers should not be taken seriously and that everyone can and should understand and use computers.
John wrote his first program in 1967 on an IBM 1130 (a computer somewhat less powerful than your typical modern digital wristwatch, only more difficult to use). He became an official system administrator of a networked computer running UNIX at Yale in 1975. He began working part-time (for a computer company, of course) in 1977 and has been in and out of the computer and network biz ever since. He got his company on Usenet (the Internet’s worldwide bulletin-board system) early enough that it appears in a 1982 Byte magazine article on a map of Usenet, which then was so small that the map fit on half a page.
Although John used to spend most of his time writing software, now he mostly writes books (including UNIX For Dummies and Privacy For Dummies, both published by Wiley Publishing, Inc.) because it’s more fun and he can do so at home in the tiny village of Trumansburg, New York, where he is the sewer commissioner (Guided tours! Free samples!) and can play with his small daughter when he’s supposed to be writing. John also does a fair amount of public speaking. (Go to www.johnlevine.com to see where he’ll be.) He holds a BA and a PhD in computer science from Yale University, but please don’t hold that against him.
In high school, Margaret Levine Young was in the same computer club as her big brother, John. She stayed in the field throughout college against her better judgment and despite John’s presence as a graduate student in the computer science department. Margy graduated from Yale and went on to become one of the first PC managers in the early 1980s at Columbia Pictures, where she rode the elevator with big stars whose names she wouldn’t dream of dropping here.
Since then, Margy has co-authored more than 25 computer books about the topics of the Internet, UNIX, WordPerfect, Microsoft Access, and (stab from the past) PC-File and Javelin, including Dummies 101: The Internet For Windows 98, UNIX For Dummies, and WordPerfect For Linux For Dummies (all published by Wiley Publishing, Inc.), and Windows XP: The Complete Reference and Internet: The Complete Reference (published by Osborne/McGraw-Hill). She met her future husband, Jordan, in the R.E.S.I.S.T.O.R.S. (that computer club we mentioned). Her other passion is her children, along with music, Unitarian Universalism (www.uua.org), reading, and anything to do with eating. She lives in Vermont (see www.gurus.com/margy for some scenery).
John and Margy both dedicate this book to their dad, wherever he is. When last sighted, he was traveling somewhere in China finding out just how great the wall is, unless he was at the beach here in the U.S. — he’s a man who knows how to live!
The authors thank Antonia Saxon, Jordan Young, Sarah Willow Levine Saxon, Meg Young, and Zac Young for putting up with us while we updated this book. Thanks also go to our Internet providers: Finger Lakes Technologies Group and the Trumansburg Home Telephone Company (Trumansburg, NY), the Shoreham Telephone Company (Shoreham, VT), and SoVerNet (Bellows Falls, VT).
We thank Peter Seebach for research and revisions (you can guess what that really means) on KDE and GNOME in Chapters 4 and 17, and Nancy McGough for helping make our comments on Linux bear at least some relation to reality.
Chris Morris patiently shepherded the text from our hazy scribblings (electronically speaking) to a printed book with a blend of patience and midnight wit. He got lots of help, of course, from all the folks listed on the other side of this page.
We’re proud of this book; please send us your comments through our online registration form located at www.dummies.com/register/.
Some of the people who helped bring this book to market include the following:
Acquisitions, Editorial, and Media Development
Project Editor: Christopher Morris
(Previous Edition: Rebecca Whitney)
Acquisitions Editor: Steven Hayes
Copy Editor: Rebecca Senninger
Technical Editor: James F. Kelly
Editorial Manager: Kevin Kirschner
Permissions Editor: Laura Moss
Media Development Specialist: Travis Silvers
Media Development Manager: Laura VanWinkle
Media Development Supervisor: Richard Graves
Editorial Assistant: Amanda Foxworth
Cartoons: Rich Tennant (www.the5thwave.com)
Production
Project Coordinator: Courtney MacIntyre
Layout and Graphics: Seth Conley, Andrea Dahl, Lauren Goddard, Stephanie D. Jumper, Barry Offringa, Heather Ryan, Mary Gillot Virgin, Melanie Wolven
Proofreaders: Laura Albert, Andy Hollandbeck, Kathy Simpson, TECHBOOKS Publishing Services
Indexer: TECHBOOKS Publishing Services
Publishing and Editorial for Technology Dummies
Richard Swadley, Vice President and Executive Group Publisher
Andy Cummings, Vice President and Publisher
Mary C. Corder, Editorial Director
Publishing for Consumer Dummies
Diane Graves Steele, Vice President and Publisher
Joyce Pepple, Acquisitions Director
Composition Services
Gerry Fahey, Vice President of Production Services
Debbie Stailey, Director of Composition Services
Title
Introduction
About This Book
Conventions Used in This Book
Foolish Assumptions
How This Book Is Organized
Icons Used in This Book
Where to Go from Here
Authors’ Note
Part I : Before the Beginning
Chapter 1: Log Me In, UNIX!
Turning Your Computer On and Off
Hey, UNIX! I Want to Log In
Logging In: U(NIX) Can Call Me Al
Password Smarts
Ciao, UNIX!
Chapter 2: What Is UNIX, Anyway?
Why Do We Ask Such Dumb Questions?
How Can You Tell?
Cracking the Shell
Are Any Good Programs On?
Finally! You’re Ready to Work
Chapter 3: A Few Lines on Linux
Out of the Frozen North
What’s Old, What’s New
Where’s Linux?
A Whole Lotta Kinds of Linux
Part II : Some Basic Stuff
Chapter 4: Opening Windows on UNIX
UNIX Gets All GUI
Stupid Window Manager Tricks
CDE: A Desktop for All Seasons
What’s the “K” Stand For?
You Mean the Little Guys with the Hats?
Terminal Happenings
Chapter 5: Files for Fun and Profit
What Files Do You Have?
Roger, I Copy
Nuking Files Back to the Stone Age
What’s in a Name (Reprise)
Looking at the Guts of a File
Is This a Printout I See Before Me?
Who Goes There?
Chapter 6: Directories for Fun and Profit
Good News for Windows Users
What Is a Directory?
Divide and Conquer
There’s No Place Like Home
Putting Your Ducks in a Row
Putting Your Ducks on the Web
A Map of UNIX
Chapter 7: The Shell Game
This Output Is Going to Havana: Redirection
Gurgle, Gurgle: Running Data through Pipes
Wild and Crazy Wildcards
History Repeats Itself
Do I Have to Type the Same Things Every Time I Log In?
Terminal Options
Chapter 8: Where’s That File?
The Search Is On
What to Do with Files after You Find Them
Searching Is Slow!
A File by Any Other Name
Chapter 9: Printing (The Gutenberg Thing)
Printing Stuff: Daemons at Work
Finding Your Printout
“Help! I’ve Printed, and It Won’t Shut Up!”
Prettying Up Your Printouts
Troff, Nroff, Groff!
Printing for the PostScript-Challenged
Part III : Getting Things Done
Chapter 10: Writing Deathless Prose
UNIX Has Its Way with Words
Shy vi, the Princess of Text Editors
A Novel Concept in Editing: emacs Makes Sense
A Peek at pico
Talk to Mr. ed
Chapter 11: Umpteen Useful UNIX Utilities
Comparing Apples and Oranges
Assorted Files
Time Is Money — Steal Some Today!
Squashing Your Files
What’s in That File?
Chapter 12: Installing Software Can Be Tricky
The Software Stork
You Too Can Be a Script Writer
Borrowing Other People’s Programs
Stealing Software from the Network
Real Software Installation
Chapter 13: Juggling a Bunch of Programs
So What Is a Process, Anyway?
Any Processes in the House?
Starting Background Processes
The Magic of Job Control
Chapter 14: Taming Linux
Congratulations! You’re a System Administrator!
A Pride of Linuxes
“I Need Help!”
Part IV : UNIX and the Net
Chapter 15: Your Computer Is Not Alone
You Don’t Need to Be In Who’s Who to Know What’s What
Finding Out Who’s on Your Computer
Finding Out Who’s on Other Computers
Chatting with Other People on Your Computer
Getting On the Net
Chapter 16: Across a Crowded Network
On a Computer Far, Far Away
Telnet It Like It Is
3270: The Attack of the IBM Terminals
ssh: The Lazy Man’s Remote Login
scp: Blatting Files across the Network
NFS: You’ll Never Find Your Stuff
The UNIX/Windows Accords
Chapter 17: Automating Your Office Gossip
What You Need in Order to Use Local E-Mail
Addressing the Mail
Sending Stuff Other Than Text
Exchanging Gossip by Using Pine
What You Need in Order to Use Remote E-Mail
Mail Bonding with Mozilla
Kool! It’s KMail
E-Mail with Evolution
Chapter 18: Web Surfing for UNIX Users
What’s a Browser?
Browsing with Pictures: Mozilla and Konqueror
Surfing with Your Browser
Windows on the World
My Favorite Things
Filling In Forms
What Should I Look At?
Chapter 19: Grabbing Files from the Net
You’re a Copying Machine
Files with Finesse
No Names, Please
Mouse-Centric Approaches to FTP
Great Stuff on FTP
Chapter 20: Now Serving the Internet
The Internet, at Your Service
Serving Yourself
Getting Served
Web Servers Galore
Daemons Run Amok
A Few Tips for Webmasters
Part V : Help!
Chapter 21: Disaster Relief
“My Computer Won’t Turn On”
“My Mouse Is Acting Glitchy”
“The Network Is Gone”
“These Aren’t My Files!”
Wrecked X
“It’s Not Listening!”
“I Give Up”
Chapter 22: The Case of the Missing Files
How You Clobber Files
Ways to Try to Get Files Back
Three Ways Not to Lose Files
Chapter 23: Some Programs Just Won’t Die
Why Killing Is Sometimes Justified
What Process? (Reprise)
Fifty Ways to Kill Your Process
Dirty Deeds, Done Dirt Cheap
When X Goes Bad
Chapter 24: “My Computer Hates Me”
Part VI : The Part of Tens
Chapter 25: Ten Common Mistakes
Believing That It Will Be Easy
Mistyping Commands
To Press Enter, or Not to Press Enter
Working in the Wrong Directory
Not Keeping Backup Copies
Not Keeping Files Organized
Turning Off Your Computer
Writing Your Password on a Sticky Note
Sending Angry Electronic Mail (Flaming)
Chapter 26: Ten Times More Information Than You Want about UNIX
Let’s Hear It from the man
Scanning the Networks
Other Sources of Information
Welcome to UNIX For Dummies, 5th Edition! Although lots of good books about UNIX are out there, most of them assume that you have a degree in computer science, would love to learn every strange and useless command UNIX has to offer (and there are plenty), and enjoy memorizing unpronounceable commands and options. This book is different.
Instead, this book describes what you really do with UNIX — how to get started, what commands you really need, and when to give up and go for help. And we describe it all in plain, ordinary English.
We designed this book to be used when you can’t figure out what to do next. We don’t flatter ourselves that you are interested enough in UNIX to sit down and read the whole thing. When you run into a problem using UNIX (“I thought I typed a command that would copy a file, but it didn’t respond with any message . . .”), just dip into the book long enough to solve your problem.
We have included sections about these kinds of things:
Typing commands
Copying, renaming, or deleting files
Printing files
Finding where your file went
Using the Internet from UNIX
Storing and updating a Web site on a UNIX computer
Connecting and communicating with people on other computers
In this fifth edition, we updated the information about Linux (the popular free version of UNIX), beefed up the information about the new KDE and GNOME window systems, and added information about Internet applications and hosting an Internet site on your own (or someone else’s) UNIX computer.
Use this book as a reference. (Or use it as a decorative paperweight — whatever works for you.) Look up your topic or command in the table of contents or the index; they refer to the part of the book in which we describe what to do and perhaps define a few terms, if absolutely necessary.
When you have to type something, it appears in the book like this:
cryptic UNIX command to type
Type it just as it appears. Use the same capitalization we do — UNIX cares deeply about CAPITAL and small letters. Then press the Enter or Return key (we call it Enter throughout this book). The book tells you what happens when you give each command and what your options are. Sometimes part of the command is in italics; the italicized stuff is a sample name, and you have to substitute the actual name of the file, computer, or person affected.
Chapter 24 lists error messages you may run into, and Chapter 25 lists common user mistakes. You may want to peruse the latter to avoid these mistakes before they happen.
In writing this book, we have assumed these things about you:
You have a UNIX computer or remote access to one.
You want to get some work done on it.
Someone has set it up so that, if you turn it on (in many cases, it’s left on all the time) or connect, you are talking to UNIX.
You are not interested in becoming the world’s next great UNIX expert.
This book has six parts. The parts stand on their own — you can begin reading wherever you want. This section lists the parts of the book and what they contain.
This part tells you how to get started with UNIX, including figuring out which kind of UNIX you’re using. (You need to know this information later because commands can differ from one type of UNIX to another.) You find out how to log in, type UNIX commands, and ask for help. For Linux users, we include a short chapter on what it’s all about, why Linux is cool, and how to get more information about Linux.
Like most computer systems, UNIX stores information in files. This part explains how to deal with files — creating, copying, and getting rid of them. It also talks about directories so that you can keep your files organized, finding files that have somehow gone astray, and printing files on paper.
This part talks about getting some work done in UNIX. It gives step-by-step instructions for using the most common text editors to create and change text files, running several programs at the same time (to get confused several times as fast), and making your Linux system behave, and gives you directions for a bunch of other useful UNIX commands.
Most UNIX systems are connected to networks, and many are connected to the biggest network of them all: the Internet. This part prepares you for the world of communications, including instructions for sending and receiving electronic mail, for transferring files over the network, for logging in to other computers over the Internet, and for surfing on the World Wide Web. For those of you with some intestinal fortitude, we include an updated chapter on how to have your Internet site run on your very own UNIX computer.
If disaster strikes, check this part of the book. It includes information about what to do if something bad happens, what to do about backups, and what to do when you see common UNIX error messages.
This part is a random assortment of other tidbits about UNIX, including common mistakes and how to get online help — all organized into two convenient ten-item lists, sort of.
Some particularly nerdy, technoid information is coming up, which you can skip (although, of course, we think that it’s all interesting).
A nifty little shortcut or time-saver is explained, or a piece of information you can’t afford to be without.
Yarrghhh! Don’t let this happen to you!
Information that applies only if your computer is on a network. If it is not, you can skip to the next section.
Something presented in an earlier section of the book or something you need to remember to do.
The friendly penguin alerts you to information specifically about Linux (see Chapter 3 to find out what Linux is).
That’s all you need to know to get started. Whenever you hit a snag in UNIX, just look up the problem in the table of contents or index of this book. You will have the problem solved in a flash — or you will know to find some expert help.
Because UNIX is not designed to be particularly easy to use, don’t feel bad if you have to look up a number of topics before you feel comfortable using the computer. Most computer users, after all, never have to face anything as daunting as UNIX (point this out to your Windows and Macintosh user friends)!
If you have comments about this book and your computer can send electronic mail via the Internet, you can send them to our friendly mail robot, which will write back, at [email protected]. (We authors also read your messages and write back if time permits.) Also visit our Web site, with book info and updates, at http://net.gurus.com. For information about the For Dummies books in general, write to [email protected] or surf on by www.dummies.com.
Because we practice what we preach, the manuscript for this book was updated and edited using the free OpenOffice.org word processor on FreeBSD UNIX. We also used NetBSD and SuSE Linux for the KDE and GNOME examples, and a Web application on the Apache Web server on BSD/OS to pass around edited chapters among the authors and our editors. The net.gurus.com and www.dummies.com Web sites both run on Apache servers on UNIX; our UNIX mail server handles the mail at gurus.com; and our publisher’s three UNIX mail servers handle the mail at wiley.com. None of that expensive Pacific Northwest software for us, thanks.
In this part . . .
Yikes! You have to learn how to use UNIX! Does this mean that you’re about to get inducted, kicking and screaming, into a fraternity of hard-bitten, humorless nerds with a religious dedication to a 30-year-old operating system from the phone company? Well, yes and no. We hope that we’re not humorless.
If you’re like most UNIX users, a zealot stopped at your desk, connected your terminal or workstation, gave you five minutes of incomprehensible advice, demonstrated a few bizarre games (like roaches that hide behind the work on your screen), and disappeared. Now you’re on your own.
Don’t worry. This part of the book explains the absolute minimum you need to know to get your UNIX system’s attention, persuade it that you are allowed to use it, and maybe even accomplish something useful.
Turning your computer on and getting its attention
Persuading your computer to let you use it
Using usernames, passwords, and all that
Logging out when you finish
If you read the exciting introduction to this book, you know that we make some Foolish Assumptions about you, the reader. Among other things, we foolishly assume that someone else has installed and set up UNIX for you so that all you have to do is turn your computer on and tell UNIX that you’re there, or that a computer running UNIX is somewhere on the network that you have access to.
If you don’t have UNIX already set up on a computer, the best thing you can do for yourself is find a local UNIX guru or system administrator who is willing to get you up and running. Unless you really know what you’re doing, installing and setting up UNIX can be painful, frustrating, and time-consuming. We recommend that you find something more enjoyable to do, such as cleaning out the grease trap under your kitchen sink or performing urgent home surgery on yourself. (You can learn how to administer a UNIX system with some patience and perseverance, but explaining how is way beyond the scope of this book because each version of UNIX has its own procedures.)
If you think that turning your computer on and off is easy, you may be wrong. Because UNIX runs on so many almost-but-not-quite-compatible computers — all of which work somewhat differently — you first must figure out which kind of UNIX computer you have before you can turn it on.
A workstation is a computer with a big screen, a mouse, and a keyboard. You may say, “I have a PC with a big screen, a mouse, and a keyboard. Is it really a workstation?” Although UNIX zealots get into long arguments over this question, for our purposes, we say that it is. Most current UNIX systems are workstations.
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!
Lesen Sie weiter in der vollständigen Ausgabe!