What is the Open Source hype all about? Nearly every week a seminar in some part of the world is being held on Open Source technologies. Every year (at least the last 2-3 ) we are confronted with reports which state that certain open source software have increased their's market share at the expense of already established proprietary software.
Is Linux really better than Windows? Is Apache really the better web-server? Does MySQL really have what it takes for a good database engine? Is Open Source going to take over the World?
The word 'better' when applied to software is an ambiguous term. In this article the word better will mean: "A Software which has a superior performance, stability and less prone to software bugs coupled with ease of use when compared to it's equivalents and given that it satisfies user requirements"
Armed with this redefinition of the word 'better' we will seek the answers to the questions we posed.
The Origins and Heavyweights of The Open Source Movement
The Open Source movement separated from the Free Software Movement and earned a separate identity in 1998. It's sole purpose initially was "to act as a marketing strategy for Free Software". The leaders of the Open Source Movement recognized that the term 'free' in the business world is synonymous with 'free of cost' where as the term 'free' in Free Software meant 'free as in freedom, not cost', the word itself was seen as a hurdle for market acceptance of free software. Thus to present free software to the commercial world, the term Open Source was coined in order to avoid the name ambiguity problem.
The Open Source community for large parts is identical to the Free Software Community except for it's inclination towards commercialization, whereas the latter is concerned with ethical reasons for usage of the software. The most renowned Open Source evangelists are Eric Raymond, Bruce Perens, and Tim O'Reilly. In order to provide Free Software better marketing. They formed the Open Source Initiative (OSI) to
* promote the pragmatic benefits to the business community, and
* certify free/open source licenses that meet the Open Source Definition.
One of the earliest success of the Open Source movement was On January 22nd, 1998, when Netscape announced that it would open the source code for Netscape Navigator 5.0. Their announcement gave the free/open source software community a great boost in credibility in the eyes of business community.
Open Source Initiative's evangelism paid off. Following Netscape's announcement, several additional vendors announced support for Linux, including Oracle, IBM, and Corel. Intel and Netscape invested in Red Hat, the largest English language Linux distributor. Novell in a change of business strategy bought the German Linux Distribution SuSE, and various other Linux-related firms including Ximian to make a niche for itself in the Linux World.
Since the founding of OSI, numerous Open Source support organizations have been formed, one of the latest one is the Open Source Development Labs, founded by a consortium consisting of Industry Heavyweights such as IBM, Sun, Intel, Oracle, Corel, Novell, RedHat. The OSDL is the single largest non-profit organization supporting Open Source Development, and is located in Portland, USA. More significantly, many large corporations are now migrating to open source. Earlier this year, the European arm of automobile giant Ford decided to ditch Microsoft as its desktop operating systems provider and move to open source. Likewise in June, the U.S. Defense Information Systems Agency announced that it plans to standardize with StarOffice.
What's different in Open Source software
As mentioned that the Open Source movement was conceived from the Free Software movement. The Free Software movement itself has its roots in the "hacker" culture of U.S. computer science laboratories ( at Berkeley, Carnegie Mellon, and MIT) in the 1960's and 1970's.
This community came to an end par se in the 1980s when commercial companies hired away most of the staff in the U.S. computer science laboratories. The companies protected their source code with special 'non-disclosure agreements' where the programmers didn't't own their code but the company owned it and they were obliged to not discuss or show it to anyone.
Richard Stallman, a programmer at the MIT's AI-Lab, revolted against this new-order which had destroyed the hacker-culture, by starting the GNU project which's aim was to produce a "Free" Operating System. The GNU project reinvigorated the hacker-culture, an they became united in Stallman's pursuit.
The GNU project spawned and entire software development methodology based on hacker ethics:
The community of programmers was closely-knitted. Code passed back and forth between the members of the community--if you made an improvement you were expected to submit your code to the community of developers. To withhold code was considered gauche--after all, you benefited from the work of your friends, you should return the favor.
With this methodology an entire Operating System, and it's accompanying application was built that operating system is called GNU/Linux. After the successful development of the operating system, an entire new array of application dawned. Open Source scripting languages like PERL, PHP were built, Open Source Web-server known as Apache was built, Database Suites, security tools, desktop multimedia applications etc.
Currently Open Source has a respectable and vast array of software to offer, and most of it at virtually no cost, but is it really better?
Yes and no, most people think!
Yes, because of the particular way these software are developed, where a multitude of people have access to the source code, and multiple programmers are contributing. Very few software companies can attract such a pool of talent as a single open source project can. In Sourceforge.net, the largest repository of Free/Open Source software, the average number of developers per application is 10, but the big open source applications such as the Linux kernel, Apache, MySQL have more than hundreds of people working on them.
Because of co-operating between working developers the time to release the software is reduced, bugs are spotted by end-users. It's a way that many individuals can collaborate on a product that none of them could achieve alone. It's the rapid bug-fixes and the changes that the user asks for, done to the user's own schedule. Another benefit of open source software is that the software can be customized by the user according to his or her requirements as the source code is freely available and there is no restriction in changing it and customizing for oneself.
Proprietary software such as the ones developed by Microsoft. Allow access to source code to only a few programmer which have exclusive rights to develop, maintain and debug the software. Source code of the software is thus hidden from the users and the users only receive the executable binaries. These software are generally general-purpose to achieve the maximum user-base, and thus are not customized for individual requirements, this leads to the user adjusting himself to the software instead of adjusting the software to his requirements, which is impractical in some cases.
Open source development methodology also leads to a more reliable software. Where-as proprietary software are released only to a minor community of pre-selected beta testers, open source software are tested by thousands and thousands of people before a concrete version is released, often open source development cycles produce software at speeds that even software giants face difficulty compete with.
The open-source model also means increased security; because code is in the public view it will be exposed to extreme scrutiny, with problems being found and fixed instead of being kept secret until the wrong person discovers them. Thus this leads to a more reliable software.
However the problem with most of open source software is that it's not easy to use, most open source software was made for fellow 'hackers' not for the normal user as a consequence generally higher level of technical knowledge required to install and maintain open source software. This is certainly an obstacle to wider adoption of open source software. However distributors like Red Hat and Mandrake have begun to offer user-friendly shrink-wrapped installations of Linux. But users who migrate to open source applications still face a steep learning curve.
For this reason, the implementation of open source solutions today tends to be restricted to infrastructure and other "invisible" applications such as servers, where techies are responsible for their installation and management. Currently, for instance, around 60 percent of the world's Web sites run on Apache.
Open source software also have terrible user documentations. A couple of years ago only sources of applications where available with little, if any, installations instructions. This situation was a consequence of the fact that only technical people used to use the software, thus developers rarely cared for documentation. Now fortunately the situation has improved. The Linux Documentation Project is a project dedicated to produce How-Tos, FAQs and Tutorials for users of Linux systems, covering topics has diverse as Artificial Intelligence programming in Linux to how to upgrade you Hard Disk. Open source developers now often maintain 'wikis' (which resemble blogging sites) where user of the software make contributions and these wikis act as a knowledge base for users of the software, often these wikis take the role of user-documentation.
Another major problem with open source software is that since their source codes are freely available, proprietary software companies can study the methods used and if they find a method which has already been 'patented', they can pursue legal action against the project. This often leads to destruction of the entire project, since no one takes responsibility. Software patents are a serious and are adversely affecting software development across the world.
However help on this front is on the way. Bruce Perens, open source evangelist and leader of the famous Debi an GNU/Linux distribution founded the Open Source Securities which sells legal protection to users (mostly mid-level companies) of open source software.
So does open Source software qualify for the "better software title"? Depends for whom you are answering! Although open source software matches most of the criteria we set, it still misses somewhat the mark when it comes to usage, which mainly affects the desktop users, however the technical users may regard open source software as the superior platform, that's why desktop users have been so far shy to adopt open source software whereas technical ones are porting to open source in droves. However since usage is improving with the advent of GUI environments for Linux, and graphical front ends to nearly every open source program, we can say that open source software are improving to match their proprietary counterparts especially on desktop, whereas in the back-office, open source technology has mostly already taken over.
The Future of Open Source
Although Open source software is considered to be more secure and less vulnerable to the many viruses now circulating on the Internet, this is not the reason why everyone is porting to Open Source: The most compelling feature is that, although there may be some distribution and setup costs, open source software is essentially free, Open Source is a way to avoid millions of license costs which would come with proprietary software deployment.
The ultimate test of open source will doubtless lie in its ability to become more user-friendly and to capture the desktop. But this will be an uphill struggle. Today Microsoft has a 95-percent monopoly of the PC operating system market, a 96-percent share of the office applications suite business, and an 84-percent share of the browser market.
On the positive side, there are new GUI-like desktop environments available for Linux PCs, including KDE and GNOME. And Microsoft's competitors are working hard to provide open source alternatives to mainstream applications, such as OpenOffice, which is derived from Sun's StarOffice and is emerging as an open source competition to Microsoft Office. There are also Linux versions of Netscape browser, and its celebrated derivative, FireFox.
Resources:
Open Source Initiative
http://www.osi.org
Free Software Foundation
http://www.fsf.org
Open Source Development Labs
http://www.osdl.org
GNU Project
http://www.gnu.org
Linux Documentation Project
http://www.tldp.org
digg_url = "http://digg.com/linux_unix/Is_Open_Source_Software_really_better";
1. About This Document
This document explains a way to add a system call to linux kernel catered to the linux 2.4.x series. It is based on the guide by Worcester Polytechnic Institute available at here. The guide is for linux 2.2.x, some changes where to the cotents to make it a guide for linux 2.4.x. The reference kernel in this guide is linux 2.4.31
A system call is the standard way an OS service is exported to a user program. For example, to provide users a new semaphore like synchronization method, some system calls need to be provided to access it. Likewise, a system call may be used to give users access to internal information of a file system such as superblock or inodes. The following description is based on linux kernel version 2.2.14 on i386 machine architecture. Also, it is assumed that readers are familiar with Building Linux Kernel.
2. Preparing for A New System Call
A system call cannot be called directly from a user process. Instead, they are called indirectly via an interrupt and looked up in an interrupt table. Thus, when you define a new system call you insert a new entry in this table. You do this by editing the file linux/arch/i386/kernel/entry.S. Inside, you should see lines like:
.data
ENTRY(sys_call_table)
.long SYMBOL_NAME(sys_ni_syscall) /* 0 - old "setup()" system call*/
.long SYMBOL_NAME(sys_exit)
.long SYMBOL_NAME(sys_fork)
.long SYMBOL_NAME(sys_read)
.long SYMBOL_NAME(sys_write)
..
..
.long SYMBOL_NAME(sys_ni_syscall) /* sys_set_tid_address* /
After the "sys_ni_syscall" line, add your entries for your new system calls, with the words "sys_" prepended. For example, you might add the following line for your new system call "myservice":
.long SYMBOL_NAME(sys_myservice) /*259 */
You also need to generate a system call "stub" so that an ordinary user program can invoke your system call. You do this by editing the file linux/include/asm/unistd.h (In linux sources) where you will find lines like:
#define __NR_exit 1
#define __NR_fork 2
...
#define __NR_exit_group 252
You should add #defines for your new system calls at the end, with the prefix "__NR_" in front of it. For example, you might add the line:
#define __NR_myservice 259
3. Places for Your System Call Source Files
After inserting your new system call entry in the interrupt table and preparing a stub for it, you will need to define (or implement) the system call. It will be easiest to have the system call definitions in your own source code files, say myservice.h and myservice.c.
In general, header files for machine architecture independent system calls and functions are kept under linux/include/linux/ and machine architecture dependent ones are kept in linux/include/asm/. Therefore, it would be a good idea to follow this convention. For example, the header file for the system calls for your new synchronization method, of which the implementation is machine architecture specific, would be placed in linux/include/asm/, while the header file for your machine architecture independent system call that access the superblock of one or more of your file systems would be placed under linux/include/linux.
The place for actual implementation file (myservice.c in this example) could vary. For example, if you are implementing a new process synchronization method, linux/ipc/ would be the best place for it. If you are implementing a file system related one, linux/fs/ would be the best place.
Remember that you will need to modify the Makefile in the directory you placed your .c file so that your code gets compiled and linked in properly. Modify the Makefile line to have a .o of your source code. For example, adding myservice.o in linux-2.4.31/mm/
obj-y := memory.o mmap.o filemap.o mprotect.o mlock.o mremap.o vmalloc.o slab.o bootmem.o swap.o vmscan.o page_io.o page_alloc.o swap_state.o swapfile.o numa.o oom_kill.o shmem.o myservice.o
The rest of the Makefiles can remain untouched (Makefile changes will be similar if you choose to add your code elsewhere).
4. System Call Source File Basics
In order to be linked properly, your system calls need the word "asmlinkage" prepended to their function header and "sys_" prepended to the name. For example, you would have:
asmlinkage int sys_myservice(int arg1, char* arg2) {
/* implementation of myservice */
}
Also, you will have to have #include so the compiler will recognize the word "asmlinkage".
Lastly, the user "stub" can be automatically generated so that a user program can use your system call. There are some macros defined for this in . The format is "_syscallN(return type, function name, arg1 type, arg1 name ...)" where "N" is the number of parameters. For example, you might have the line:
_syscall2(int, myservice, int, arg1, char*, arg2);
to generate the stub (in this case, the 2 is for 2 arguments). Note, that your call to generate the stub (as above) should be put it in your header file for users(myservice-user.h). Also, you need to #include in myservice-user.h to make this work. A user program could then just call myservice() as they do other system calls.
Here is an example myservice.h, myservice.c, myservice-user.h and user-app.c assuming myservice.h is under linux/include/linux/ and myservice-user.h is under /usr/include/sys/
myservice.h (used within kernel only)
#ifndef __LINUX_MYSERVICE_H#define __LINUX_MYSERVICE_H#include
#endif |
myservice.c (system call implementation)
include asmlinkage int sys_myservice (int arg1, char* arg2) {printk("My Service Called");
return(1);
}
|
myservice-user.h (for user application)
#include #include_syscall2(int, myservice, int, arg1, char*, arg2);
|
user-app.c (user application)
#include main() {myservice(1, "hi");
|
This is my first article, and I was forced to write in response to a post in a local newspaper's (Dawn.com) Computer section, in 2004
The editor of the paper's Computer section had decieved a potential linux user, by replying negatively to his queries, saying such things such as :"Linux doenst have MSN support", "Linux doesnt support much hardware", "Linux has virtually no Software".
I was shocked, and wrote this article to address some of the most common misperceptions about linux in Pakistan and around the world in general.
////////////////////////////////////////////////////////////////////////////////////////
This article is about tackling the most common myths regarding Linux desktop distributions head on. These myths not only spread misinformation about Linux in general but also discourage potential users.
Introduction: Linux is just 'another' operating system, what's all the fuss about it?
Precisely Linux is not an operating system; rather it is the kernel of an operating system. A kernel is software that enables communications between computer applications and hardware, providing system services like file management, virtual memory, device I/O, scheduling and more. A complete operating system can be built using the Linux kernel, such an operating system is termed as a Linux distribution (popularly called 'distro'). Many flavors of Linux distributions have been built, ranging from high end super computer operating systems, to PC desktop operating systems. Although the uptake of Linux in enterprise and scientific circles has been promising, Linux suffers from certain myths spread by people who have never used it nor have any significant experience of Linux whatsoever. This article is intended to dispel the most popular myths about Linux desktop distributions. As a convention from now Linux will not refer to the kernel but to a general Linux desktop (PC) distribution such as Mandrake Linux, Red Hat Linux, Slackware etc.
Why use Linux anyway?
IBM studies on TCO (Total Cost of Ownership) show that Linux-based solutions are approximately twice less costly than Microsoft Windows-based solutions in a broad range of situations. Other studies from IBM show a Linux-based system's down-time(the time while a system is down) is approximately ten times lower than a Microsoft Windows-based system.
These studies are very interesting because Microsoft Windows and Linux run on the same hardware, allowing a very significant comparison of the operating systems.
Linux is often seen as a secure operating system as it does not suffer from the frequent Trojan, worm and virus attacks on the web, which can target Microsoft Windows Systems only. As a matter of fact last year Microsoft released a number security patches for there many of there Windows operating system, of which quite a few were critical updates, and many came after a major attack had been perpetuated.
Linux security is not perfect, but the new versions of Linux are immensely secure partly due to the United States National Security Agency’s project called SELinux (Security Enhanced Linux) which aims at creating a secure operating system for the United States Army and it’s sister branches currently SELinux version 2 is available. But according to philosophy a change in Linux kernel has to be returned to the community of the benefit of all. SELinux Security code has been in-cooperated into standard Linux kernel and distributions, and can be used to secure your home computer system.
Generally 8 points sum the 'Linux Advantage' up:
* Linux source code is freely distributed. Tens of thousands of programmers and various organizations have reviewed the source code to improve performance, eliminate bugs, and strengthen security. No other operating system has ever undergone this level of review.
* Linux has the best technical support available. Linux is supported by commercial distributors, consultants, and by a very active community of users and developers. In 1997, the Linux community was awarded InfoWorld's Product of the Year Award for Best Technical Support over all commercial software vendors.
* Linux has no vendor lock-in. The availability of source code means that every user and support provider is empowered to get to the root of technical problems quickly and effectively. This contrasts sharply with proprietary operating systems, where even top-tier support providers must rely on the OS vendor for technical information and bug fixes.
* Linux runs on a wide range of hardware. Most Linux systems are based on standard PC hardware, and Linux supports a very wide range of PC devices. However, it also supports a wide range of other computer types, including Alpha, Power PC, 680x0, SPARC, and Strong Arm processors, and system sizes ranging from PDAs (such as the PalmPilot) to supercomputers constructed from clusters of systems (Beowulf clusters).
* Linux is exceptionally stable. Properly configured, Linux systems will generally run until the hardware fails or the system is shut down. Continuous up-times of hundreds of days (up to a year or more) are not uncommon. Leading Internet Search Engine Google.com uses Linux to power its systems.
* Linux has the tools and applications you need. Programs ranging from the market-dominating Apache web server to the powerful GIMP graphics editor are included in most Linux distributions. Free and commercial applications included in most distributions are available to meet most application needs.
* Linux has a low total cost of ownership. Although the Linux learning curve is significant, the stability, design, and breadth of tools available for Linux result in very low ongoing operating costs.
* The Linux Philosophy: ``all for one and one for all´´ All changes one makes in Open Source software will benefit each and everyone, all over the world. Without exceptions or constraints.
Myth 1: Linux is too hard to use for the novice user or Linux is difficult to install!
To be honest any operating system being installed for the first time always seems difficult, we think Microsoft Windows is easy to install, because we all have done it so many times. Popular distributions such as Mandrake, SuSE, Red Hat, Lycoris DesktopLX or Elx offer complete graphical installations, with plenty of help at each screen and form, it is worth noting that even popular operating systems such Microsoft Windows XP and Apple MacOSX do not have a complete graphical installations. Some distributions such as Gentoo, SuSe and Slackware have complete near automated installers where all the user needs to do is keep pressing the enter button, because the installer sets default values it self.
As of ease of use is concerned Linux began as a programmer's operating system, written by and for those that like to get their hands dirty, so to speak, with the bits and bytes that make things happen on computers. Perhaps because of this beginning, ease of use has only recently become a consideration. Recently thanks to the GUI environments of Gnome and KDE which have been developed by thousands of volunteers across the world, Linux users enjoy the benefit of one of the best graphical interfaces. KDE is the most popular Linux GUI; it has numerous features which surpass even that of popular operating systems, while preserving the evolutionary stability Linux is loved for.
Myth 2: Linux has no technical support!
I am astonished to hear such notions; I believe that Linux has one of the most open help systems used by any operating system. Linux support comes in form of 200 MB documentation which comes with nearly all popular distributions such as Knoppix, and Slackware. A plethora of Usenet groups, IRC channels, and online help sites are available.
LinuxQuestions.org is one such site and claims the membership of one hundred thousand unique members, at an average a query, what ever the sophistication, is answered within 2 hours. See the end of the article for some help sites.
Myth 3: Linux has limited hardware support!
Modern distributions such as Knoppix and Redhat ( and its latest version called Fedora), and Mandrake have state of the art hardware detections, although support for Generic hardware, (hardware that is not attributed to any specific manufacturer) is limited. Win-modems are another problem; win-modems are modems where the manufacturers make Microsoft Windows drivers only. But branded hardware is fully supported, and furthermore as Linux spreads, USB Robotics, ATI, nVidia, Asus and other companies have started to issue Linux drivers for there respective hardware, even a Linux driver is available for Pentium 4 motherboards from Intel.
Although Most Linux systems are based on standard PC hardware, and Linux supports a very wide range of PC devices. However, it also supports a wide range of other computer types, including Alpha, Power PC, 680x0, SPARC, and Strong Arm processors, and system sizes ranging from PDAs (such as the PalmPilot) to supercomputers constructed from clusters of systems (Beowulf clusters).
Myth 4: There is not much software available for Linux
Linux enjoys multiple large online repositories of Linux specific software. As a matter of fact there is a Linux equivalent for nearly every Microsoft Windows software (except for those antivirus softwares since they are not required because for Linux the number of virus which have been created is nearly null), if not it is surely being developed, even MSN Messenger, Microsoft Office, Adobe Photoshop equivalents are available.
But most of these softwares are in the form of source codes, but this is one of the Linux advantages. Software coming in source code, or Open Source software, creates confidence of the user using the software, since he knows what the software is directly intended to do (sure you'll have to know the language in which the program is programmed, but fake programs are never found online). Advanced user may even improve the software and send if back to the community.
User-site compiled software also performs better since the compiler compiles the source using optimizations which support only your processor instruction set. Generally, Closed Source software (nearly all Microsoft Windows software), where only the executable file is available, are only optimized for Intel processors, but people using AMD Athlon or K6 processors are at a disadvantage since there processors are not being completely supported.
Myth 5: You cannot run Microsoft Windows programs or MacOSX programs on Linux
Generally there is no need to run programs from alien operating system in Linux however
Linux uses Microsoft Windows emulators such as VMware, Win4Lin and WINE which can run any Microsoft Windows software on Linux.
Vmware is capable of running any operating system in a window in Linux be it BeOS, JavaOS, MacOSX or Microsoft Windows. It is even possible to run four or more different operating systems at the same time, if your system hardware allows it. An extension of WINE, called WineX, is capable of running Microsoft DirectX based games on Linux at near Microsoft Windows speeds. OpenGL support in Linux is native. Heavy 3D animation software such as Maya is available for Linux and used by graphics professional’s world wide. The animation work for the movie Titanic was done in Redhat Linux, a popular Linux distribution with the help of Maya for Linux.
VmWare and Win4lin are commercial programs, with free trial downloads. WINE however is completely free.
Final Comments
After reading this article if some of these above mentioned myths have been dispelled in your mind, try out a Linux distribution, If you need to know more about Linux before trying it, check some of the links appended at the end of the article. If you want to try Linux but are concerned about installing another operating system to your computer, try one of the distributions that runs from a cd, without installing permanent files to your hard drive. Two of these are the Knoppix and DemoLinux.
General Software Sites
http://www.sourceforge.net
http://www.gnu.org
http://www.savannah.net
http://www.kde-apps.net
http://www.kde.org (a popular Linux GUI, found in most Distributions)
http://www.winehq.com (The Free WINE Windows Emulator)
Distributions
http://www.distrowatch.com
http://www.nsa.gov/selinux (The NSA’s SELinux, the homepage of one the most secure operating system)
http://www.slackware.com (my favorite distribution)
http://www.knoppix.com (a popular distributions which runs from a CD, no installation required, excellent for trying)
http://www.linuxISO.org (a site where CD images of most popular Linux distributions are available to download)
Help
http://www.linuxquestions.org
http://www.tldp.com (The Linux Documentation Project, visit here to get the most genuine help)
http://www.linuxpakistan.net (A local Linux site)
With increasing usage of Linux in various computing environments, a lot of security vulnerabilities are being discovered in GNU/Linux-based systems. Due to the open nature of application development in the Open Source world, a lot of vulnerabilities are being addressed very quickly. But, it may happen that a patch is not addressed in a timely manner, and in the meantime, all the systems running the application are exposed. Malicious users can possibly gain root privileges and wreak havoc with these systems. This is where the Linux Intrusion Detection System (LIDS) comes to the rescue.
Read the full article on Linux Journal
Traditional Linux package management systems such as RPM, Debian's dpkg, and Slackware's pkgtool present several problems for users. Users who want optimized packages often have problems finding them, different package repositories have conflicting naming conventions, and binary packages are often not available for packages in a timely fashion. However, for users willing to stray from the beaten path, there are alternatives. Two projects have taken up the challenge of making a package management system that overcomes these shortcomings.
Check the full article on Linux.com