资源描述
Introduction to Linux 1.1 History 1.1.1 UNIX In order to understand the popularity of Linux,we need to travel back in time,about 30 years ago.Imagine computers as big as houses,even stadiums.While the sizes of those computers posed substantial problems,there was one thing that made this even worse:every computer had a different operating system.Software was always customized to serve a specific purpose,and software for one given system didnt run on another system.Being able to work with one system didnt automatically mean that you could work with another.It was difficult,both for the users and the system administrators.Computers were extremely expensive then,and sacrifices had to be made even after the original purchase just to get the users to understand how they worked.The total cost of IT was enormous.Technologically the world was not quite that advanced,so they had to live with the size for another decade.In 1969,a team of developers in the Bell Labs laboratories started working on a solution for the software problem,to address these compatibility issues.They developed a new operating system,which was simple and elegant written in the C programming language instead of in assembly code able to recycle code.The Bell Labs developers named their project UNIX.The code recycling features were very important.Until then,all commercially available computer systems were written in a code specifically developed for one system.UNIX on the other hand needed only a small piece of that special code,which is now commonly named the kernel.This kernel is the only piece of code that needs to be adapted for every specific system and forms the base of the UNIX system.The operating system and all other functions were built around this kernel and written in a higher programming language,C.This language was especially developed for creating the UNI X system.Using this new technique,it was much easier to develop an operating system that could run on many different types of hardware.The software vendors were quick to adapt,since they could sell ten times more software almost effortlessly.Weird new situations came in existence:imagine for instance computers from different vendors communicating in the same network,or users working on different systems without the need for extra education to use another computer.UNIX did a great deal to help users become compatible with different systems.Throughout the next couple of decades the development of UNIX continued.More things became possible to do and more hardware and software vendors added support for UNIX to their products.UNIX was initially found only in very large environments with mainframes and minicomputers(note that a PC is a micro computer).You had to work at a university,for the government or for large financial corporations in order to get your hands on a UNIX system.But smaller computers were being developed,and by the end of the 80s,many people had home computers.By that time,there were several versions of UNIX available for the PC architecture,but none of them were truly free.1.1.2 Current application of Linux systems Today Linux has joined the desktop market.Linux developers concentrated on networking and services in the beginning,and office applications have been the last barrier to be taken down.We dont like to admit that Microsoft is ruling this market,so plenty of alternatives have been started over the last couple of years to make Linux an acceptable choice as a workstation,providing an easy user interface and MS compatible office applications like word processors,spreadsheets,presentations and the like.On the server side,Linux is well-known as a stable and reliable platform,providing database and trading services for companies like Amazon,the well-known online bookshop,US Post Office,the German army and such.Especially Internet providers and Internet service providers have grown fond of Linux as firewall,proxy-and web server,and you will find a Linux box within reach of every UNIX system administrator who appreciates a comfortable management station.Clusters of Linux machines are used in the creation of movies such as Titanic,Shrek and others.In post offices,they are the nerve centers that route mail and in large search engine,clusters are used to perform internet searches.These are only a few of the thousands of heavy-duty jobs that Linux is performing day-to-day across the world.It is also worth to note that modern Linux not only runs on workstations,mid-and high-end servers,but also on gadgets like PDAs,mobiles,a shipload of embedded applications and even on experimental wristwatches.This makes Linux the only operating system in the world covering such a wide range of hardware.1.2 The user interface 1.2.1 Is Linux difficult?Whether Linux is difficult to learn depends on the person youre asking.Experienced UNIX users will say no,because Linux is an ideal operating system for power-users and programmers,because it has been and is being developed by such people.Everything a good programmer can wish for is available:compilers,libraries,development and debugging tools.These packages come with every standard Linux distribution.The C-compiler is included for free,all the documentation and manuals are there,and examples are often included to help you get started in no time.It feels like UNIX and switching between UNIX and Linux is a natural thing.In the early days of Linux,being an expert was kind of required to start using the system.It was common practice to tell a beginning user to RTFM(read the manuals).While the manuals were on every system,it was difficult to find the documentation,and even if someone did,explanations were in such technical terms that the new user became easily discouraged from learning the system.The Linux-using community started to realize that if Linux was ever to be an important player on the operating system market,there had to be some serious changes in the accessibility of the system.1.2.2 Linux for non-experienced users Companies such as RedHat,SuSE and Mandrake have sprung up,providing packaged Linux distributions suitable for mass consumption.They integrated a great deal of graphical user interfaces(GUIs),developed by the community,in order to ease management of programs and services.As a Linux user today you have all the means of getting to know your system inside out,but it is no longer necessary to have that knowledge in order to make the system comply to your requests.Nowadays you can log in graphically and start all required applications without even having to type a single character,while you still have the ability to access the core of the system if needed.Because of its structure,Linux allows a user to grow into the system:it equally fits new and experienced users.New users are not forced to do difficult things,while experienced users are not forced to work in the same way they did when they first started learning Linux.While development in the service area continues,great things are being done for desktop users,generally considered as the group least likely to know how a system works.Developers of desktop applications are making incredible efforts to make the most beautiful desktops youve ever seen,or to make your Linux machine look just like your former MS Windows or MacIntosh workstation.The latest developments also include 3D acceleration support and support for USB devices,single-click updates of system and packages,and so on.Linux has these,and tries to present all available services in a logical form that ordinary people can understand.1.3 Does Linux have a future?1.3.1 Open Source The idea behind Open Source software is rather simple:when programmers can read,distribute and change code,the code will mature.People can adapt it,fix it,debug it,and they can do it at a speed that dwarfs the performance of software developers at conventional companies.This software will be more flexible and of a better quality than software that has been developed using the conventional channels,because more people have tested it in more different conditions than the closed software developer ever can.The Open Source initiative started to make this clear to the commercial world,and very slowly,commercial vendors are starting to see the point.While lots of academics and technical people have already been convinced for 20 years now that this is the way to go,commercial vendors needed applications like the Internet to make them realize they can profit from Open Source.Now Linux has grown past the stage where it was almost exclusively an academic system,useful only to a handful of people with a technical background.Now Linux provides more than the operating system:there is an entire infrastructure supporting the chain of effort of creating an operating system,of making and testing programs for it,of bringing everything to the users,of supplying maintenance,updates and support and customizations,etcetera.Today,Linux is ready to accept the challenge of a fast-changing world.1.3.2 Ten years of experience at your service While Linux is probably the most well-known Open Source initiative,there is another project that contributed enormously to the popularity of the Linux operating system.This project is called SAMBA,and its achievement is the reverse engineering of the Server Message Block(SMB)/Common Internet File System(CIFS)protocol used for file-and print-serving on PC-related machines,natively supported by MS Windows NT and OS/2,and Linux.Packages are now available for almost every system and provide interconnection solutions in mixed environments using MS Windows protocols:Windows-compatible(up to and including Win2K)file-and print-servers.Maybe even more successful than the SAMBA project is the Apache HTTP server project.The server runs on UNIX,Windows NT and many other operating systems.Originally known as A PAtCHy server,based on existing code and a series of patch files,the name for the matured code deserves to be connoted with the native American tribe of the Apache,well-known for their superior skills in warfare strategy and inexhaustible endurance.Apache has been shown to be substantially faster,more stable and more feature-full than many other web servers.Apache is run on sites that get millions of visitors per day,and while no official support is provided by the developers,the Apache user community provides answers to all your questions.Commercial support is now being provided by a number of third parties.In the category of office applications,a choice of MS Office suite clones is available,ranging from partial to full implementations of the applications available on MS Windows workstations.These initiatives helped a great deal to make Linux acceptable for the desktop market,because the users dont need extra training to learn how to work with new systems.With the desktop comes the praise of the common users,and not only their praise,but also their specific requirements,which are growing more intricate and demanding by the day.The Open Source community,consisting largely of people who have been contributing for over half a decade,assures Linux position as an important player on the desktop market as well as in general IT application.Paid employees and volunteers alike are working diligently so that Linux can maintain a position in the market.The more users,the more questions.The Open Source community makes sure answers keep coming,and watches the quality of the answers with a suspicious eye,resulting in ever more stability and accessibility.1.4 Properties of Linux 1.4.1 Linux Pros A lot of the advantages of Linux are a consequence of Linux origins,deeply rooted in UNIX,except for the first advantage,of course:Linux is free:As in free beer,they say.If you want to spend absolutely nothing,you dont even have to pay the price of a CD.Linux can be downloaded for free from the internet.No registration fees,no costs per user,free updates,and freely available source code in case you want to change the behavior of your system.Most of all,Linux is free as in free speech:The license commonly used is the GNU Public License(GPL).The license says that anybody who may want to do so,has the right to change Linux and eventually to redistribute a changed version,on the one condition that the code is still available after redistribution.In practice,you are free to grab a kernel image,for instance to add support for teletransportation machines or time travel and sell your new code,as long as your customers can still have a copy of that code.Linux is portable to any hardware platform:A vendor who wants to sell a new type of computer and who doesnt know what kind of OS his new machine will run(say the CPU in your car or washing machine),can take a Linux kernel and make it work on his hardware,because documentation related to this activity is freely available.Linux was made to keep on running:As with UNIX,a Linux system expects to run without rebooting all the time.That is why a lot of tasks are being executed at night or scheduled automatically for other calm moments,resulting in higher availability during busier periods and a more balanced use of the hardware.This property allows for Linux to be applicable also in environments where people dont have the time or the possibility to control their systems night and day.Linux is secure and versatile:The security model used in Linux is based on the UNIX idea of security,which is known to be robust and of proven quality.But Linux is not only fit for use as a fort against enemy attacks from the Internet:it will adapt equally to other situations,utilizing the same high standards for security.Your development machine or control station will be as secure as your firewall.Linux is scalable:From a Palmtop with 2 MB of memory to a petabyte storage cluster with hundreds of nodes:add or remove the appropriate packages and Linux fits all.You dont need a supercomputer anymore,because you can use Linux to do big things using the building blocks provided with the system.If you want to do little things,such as making an operating system for an embedded processor or just recycling your old 486,Linux will do that as well.The Linux OS and Linux applications have very short debug-times:Because Linux has been developed and tested by thousands of people,both errors and people to fix them are found very quickly.It often happens that there are only a couple of hours between discovery and fixing of a bug.1.4.2 Linux Cons There are far too many different distributions:Quot capites,tot rationes,as the Romans already said:the more people,the more opinions.At first glance,the amount of Linux distributions can be frightening,or ridiculous,depending on your point of view.But it also means that everyone will find what he or she needs.You dont need to be an expert to find a suitable release.When asked,generally every Linux user will say that the best distribution is the specific version he is using.So which one should you choose?Dont worry too much about that:all releases contain more or less the same set of basic packages.On top of the basics,special third party software is added making,or example,TurboLinux more suitable for the small and medium enterprise,RedHat for servers and SuSE for workstations.However,the differences are likely to be very superficial.The best strategy is to test a couple of distributions;unfortunately not everybody has the time for this.Luckily,there is plenty of advice on the subject of choosing your Linux.One place is LinuxJournal,which discusses hardware and support,among many other subjects.The Installation HOWTO also discusses choosing your distribution.Linux is not very user friendly and confusing for beginners:In light of its popularity,considerable effort has been made to make Linux even easier to use,especially for new users.More information is being released daily,such as this guide,to help fill the gap for documentation available to users at all levels.Is an Open Source product trustworthy?How can something that is free also be reliable?Linux users have the choice whether to use Linux or not,which gives them an enormous advantage compared to users of proprietary software,who dont have that kind of freedom.After long periods of testing,most Linux users come to the conclusion that Linux is not only as good,but in many cases better and faster that the traditional solutions.If Linux were not trustworthy,it would have been long gone,never knowing the popularity it has now,with millions of users.Now users can influence their systems and share their remarks with the community,so the system gets better and better every day.It is a project that is never finis hed,that is true,but in an ever changing environment,Linux is also a project that continues to strive for perfection.第 1 页 共 6 页 关于 Linux 的介绍 1.1 历史 1.1.1 UNIX 为了了解 Linux 的历史,我们需要追溯到 30 年前。想象一下像房子甚至体育馆一样大的计算机。除了电脑的体积带来的问题,有一件事情让这些变得更糟糕,那就是每个计算机都有一个不同的操作系统。软件定制服务一直是一个给定系统的特定目标,软件无法在另一个系统上运行。能够在一个系统下工作并不意味着也可以自动同另一个系统共事。这些无论对于用户还是系统管理员都是非常困难的。由于计算机非常昂贵,所以人们不得不为之付出,即使购买计算机那也只是为了让用户了解他们是如何工作的。但是 IT 的总成本还是非常巨大的。世界上的技术还没有那么先进,因此他们不得不和如此大的计算机共同再度过十年。在 1969 年,贝尔实验室的开发团队人员们开始研究,为解决软件问题,更好的完善兼容性。他们开发出一种新的操作系统,就是这个。简单巧妙 用 C 语言设计代替汇编码 能够循环利用的代码。贝尔实验室开发的项目把它命名为“UNIX 操作系统。”该代码循环的功能是非常重要的。在此之前,所有商用计算机系统是写在一个专门为系统开发的代码中。而 UNIX 只需要有一组特殊的代码,也就是现在俗称小片的内核。这个内核的代码是唯一的一块,需要为每一个特定的系统和各种形式的 UNIX 系统基础改编。操作系统和所有其他所有功能,都围绕这个核心,用更高级编程语言所编写的,C.这种语言是专为创造 UNIX 系统而发展的。使用这种新技术,更易于开发可以运行在不同类型硬件上的操作系统。软件供应商们很快就意识到这一点,因为他们可以几乎毫不费力的售出超过原来软件十倍的销量。一个新奇的情况出现了:不同供应商生产的计算机可以连接到同一个网络,并且用户操作不同的操作系统无需再利用额外的时间去学习使用另一台计算机。UNIX 帮助用户大大改善了不同系统兼容问题。UNIX 在未来持续几十年的不断发展中。更多的东西成为可能,并且硬件和软件的供应商们也增加了他们对 UNIX 产品的重视。第 2 页 共 6 页 最初的 UNIX,只为大背景环境下的大型机和小型机所使用(pc 只是微型机)。如果你想使用 UNIX,那么你必须在大学、政府或者大型金融公司工作。但是小的电脑也正在发展,80 年代末,很多人家里都有电脑。在那个时候,有好几个版本的 UNIX 架构的 PC 可用,但其中没有一个是真正的开源。1.1.2 Linux 系统的应用现状 今天,Linux 已经加入了台式机市场。Linux 开发人员集中在开始网络和服务环节,办公应用程序的最后障碍已经被拆除。我们不得不承认,微软已经占据了大部分市场,因此大量的人们开始选择替代品,在过去几年这种情况使 Linux 成为了一个可接受的工作站,它提供了一个简单的用户界面,文字处理软件兼容微软 Office 应用程序,试算表,简报等等。在服务器端,Linux 是众所周知的一个稳定和可靠的平台,像著名的网上书店亚马逊,美国邮政总局,德国军队和这些公司的数据库以及交易服务。特别是互联网服务提供商和互联网服务供应商已经开发出成熟的 Linux 防火墙,代理服务器和 Web 服务器,你会发现在每一个 UNIX 系统管理员都会赞赏管理站已经成为到一个舒适的工作平台。在电影创作中也使用了 Linux 集群机,如“泰坦尼克号”,“怪物史莱克”等。在邮局,他们是路由邮件和大型的搜索引擎的中枢系统,集群机还用来执行互联网搜索.这些只是在日日夜夜成千上万工作的linux 中的一部分。还值得指出,现代的 Linux 不仅仅只在工作站上运行,还在中、高端服务器,也在像掌上电脑的,手机,船货的嵌入式应用,甚至对手表实验的“小玩意”上使用。这使 Linux 成为世界上唯一一个广泛应用的操作系统。1.2 用户界面 1.2.1 Linux 难吗?Linux 是否难学,取决于你问的人。有经验的 UNIX 用户会说不,因为 Linux是电力用户和程序员理想的操作系统,因为这些人已经使用并且正在开发它。一个好的程序员都希望编译器,库,开发和调试工具是可用的。这些软件包来源于所有的标准Linux 发行版。其中包括免费的 C 语言编译器,所有的文件和程序手册。并且举例内容也能帮助您在任何时间开始。感觉就像 UNIX,并且可以在 第 3 页 共 6 页 UNIX 和 Linux 之间自然的转换。在早期的 Linux,成为一个专家需要从开始就使用它。这是一个普通的练习,用来告诉新的用户来“RTFM”(阅读手册)。虽然每个系统都有手册,但是找到文件仍然很难,即使有人做到了,解释了这样的技术术语,但是对于新用户的学习变得容易气馁。Linux 的使用社区开始意识到,如果 Linux 是以往任何时候成为操作系统市场上重要的成员,必须在该系统的亲和力上做大量的修改。1.2.2 Linux 的非经验的用户 如 RedHat,SuSE 和 Mandrake 的公司如雨后春笋般涌现,提供打包的 Linux发行版更适合大众消费。他们综合了大量的图形用户界面(GUI),由社区发展,以缓解方案和服务的管理。今天你作为一个 Linux 用户,你知道了你得到了系统的一切手段,但现在它不再有必要让用户了解这种知识,只为了使系统符合您的要求。现在你可以登录图形和启动,甚至无需输入一个单一的字符,而你仍然有能力来访问该系统的核心。由于其结构,Linux 允许用户发展系统:不论你是新手还是有经验的用户。当他们第一次开始学习 Linux 操作系统时,新用户不会被强迫做难度很大的事情,有经验的用户不会被迫以同样的方式工作。而在服务方面的发展,对于桌面用户更好的事情已经发生。桌面应用程序的努力开发令人难以置信,使你见到你见过的最美丽的台式电脑,或使你的 Linux机器,就像你以前的 MS Windows 或 Macintosh 工作站。最新的发展情况也有 3D加速支持和 USB 设备支持,通过单击更新系统和数据包,等等。Linux 有这些,并试图开发所有人们所了解的并且在逻辑上可以实现的服务。1.3 Linux 是否有前途?1.3.1 开放源码 开放源码软件背后的想法很简单:当程序员可以读取,分发和修改代码,代码将变得更成熟。人们能够适应它,解决它,调试时间,他们能够以软件开发公司同样的速度的处理他的性能。该软件将比曾经任何一个开发过的软件更加灵活,质量更好,因为相比于以往任何时候都在封闭的软件开发人员来说,能够 第 4 页 共 6 页 有更多的人有在不同测试条件下完善它。开放源码的开始对于商务的世界更轻的清晰,而且更慢。商业供应商也开始明白这一点。虽然许多学者和技术人员已经被说服了20 年来,但现在仍然要走这条路。商业供应商像互联网应用一样,使他们意识到他们可以从开源获取利润。现在 Linux 已经度过了它的成长阶段,它几乎完全是一个学术体系,对于控制唯一有用的一点就是有技术背景。现在Linux 提供的东西比操作系统更多:有一个完整的基础设施支持建立一个连锁的经营体系,并且制作和测试它,它能给用户带来一切方需要的,提供维修,更新和支持还有自定义,今天,Linux 已经准备好接受一个迅速变化的世界的挑战。1.3.2 十多年的经验为您服务 尽管 Linux 可能是最知名的倡议开放源码,但是还有另外一个项目,极大地促进了 Linux 操作系统的普及。这个项目被称为 Samba,其成就是逆向工程的服务器消息块(SMB)/通用互联网文件系统(CIFS)协议用于文件和打印对本地的MS Windows NT 支持的个人电脑相关设备,服务和 OS/2 和 Linux。现在一整套东西为几乎每个系统提供在混合环境中使用 MS Windows 协议互连解决方案:Windows 兼
展开阅读全文