Linux kernel

ImprimirCitar

Linux is a mostly free kernel similar to the Unix kernel. It is one of the main examples of free and open source software. It is licensed under the GPL v2 except for the fact that it has non-free binary blobs and most of the software included in the package that is distributed on its website is free software. It is developed by contributors from all over the world. Day-to-day development takes place in the Linux Kernel Mailing List Archive.

The Linux kernel was conceived by then-Finnish computer science student Linus Torvalds in 1991. Linux quickly enlisted developers and users to adopt code from other free software projects for use with the new kernel system. today thousands of programmers from all over the world contribute to its development.

Linux is multiprogrammed, has virtual memory, memory management, network connectivity, and allows shared libraries. Linux is cross-platform and is portable to any architecture as long as it has a compatible version of GCC.

Operating system kernel

Core

The Linux readme indicates that it is a clone of the Unix operating system. Linux, however, is a kernel similar to a Unix operating system kernel. In fact, it was initially released as a Minix-like kernel, which itself was Unix-like, but with a microkernel rather than a monolithic conception.

A microkernel contains minimal functionality compared to a traditional monolithic kernel.

It's important to realize that these programs are not part of the operating system (...). The operating system is the portion of the software that runs in kernel mode (...). A trend in modern operating systems is to take this idea of moving code up into higher layers even further and remove as much as possible from the operating system, leaving a minimal kernel.
It is important to realize that these programs are not part of the operating system (...). The operating system is the portion of software running on kernel mode (...). A trend in modern operating systems is to take this idea of moving code into more distant layers and remove as much as possible from the operating system, leaving a kernel minimum.
Operating Systems Design & Implementation, Tanenbaum and Woodhull. (Referring to a micronucleus system based on the client-server model. The author repeatedly indicates that it is reasonable to argue that the functions that go on to run in user space remain part of the operating system.)

Darwin and GNU Hurd have kernels that are a version of Mach. Minix, the operating system on which Linux was initially based, is also a microkernel. All of them have in common the transfer of part of the functionality in privileged space to user space.

Operating system

ubuntu-minimal
The Ubuntu minimum installation consists of a series of software that forms a minimum distribution of GNU/Linux. The entire software ends depending on the running environment of the GNU project, the GNU library libc.

The part of an operating system that runs without privileges or in user space is the C language library, which provides the runtime environment, and a series of programs or tools that allow administration and use of the kernel. and provide services to the rest of the programs in user space, forming together with the kernel the operating system.

In a system with a monolithic kernel like Linux the C language library consists of an abstraction of access to the kernel. Some libraries, such as the GNU library, provide additional functionality to make life easier for the programmer and user or to improve the performance of programs.

On a microkernel system the C language library can manage file systems or drivers in addition to accessing the system kernel.

Operating systems running Linux are generically called Linux distributions. These consist of a collection of software that includes the Linux kernel and the rest of the programs necessary to complete an operating system. The most common distributions are in fact GNU/Linux distributions or Android distributions. Just because they share a core doesn't mean they're compatible with each other. An application made for GNU/Linux is not compatible with Android without the additional work required to make it cross-platform.

GNU/Linux distributions use Linux as the kernel along with the GNU Project runtime environment and a number of GNU Project programs and tools that ensure a minimally functional system. Most GNU/Linux distributions include additional software such as graphical environments or web browsers as well as the necessary programs to allow themselves to install. Installation programs are provided by the distribution developer. They are known as package managers. The creators of a distribution can also be in charge of adding initial configurations of the different programs included in the distribution.

Android distributions include the Linux kernel along with the runtime environment and tools from Google's AOSP project. Each phone manufacturer has its own Android distribution to which it modifies, removes, or adds extra programs: graphical interfaces, application stores, and email clients are some examples of programs that can be added, modified, or removed. In addition to distributions from phone manufacturers, there are independent developer groups that also develop Android distributions. LineageOS (formerly CyanogenMod), Replicant, and Pixel Experience are three examples of standalone Android distributions also called custom "ROMs" or unofficial firmwares.

History

Linux Release Notes 0.01

In April 1991, 21-year-old Linus Torvalds began working on some simple ideas for an operating system kernel. He began by trying to get a free Unix-like operating system kernel that would work on Intel 80386 microprocessors. He did this by building on the Minix system (a Unix clone) and making a compatible monolithic kernel that initially required Minix software to run. August 26, 1991 Torvalds wrote on the comp.os.minix newsgroup:

"I am making an operating system (free, just a hobby, it will be nothing big or professional like GNU) for AT 386(486). I've been on it since April and it's starting to be ready. I would like to know your opinion about the things you like or upset at minix, as my SO has some resemblance to it.[...] I have currently carried bash(1.08) and gcc(1.40), and it seems that things work. This means I will have something practical within a few months..."

After that message, many people helped with the code. In September 1991 version 0.01 of Linux was released. It had 10,239 lines of code. In October of that year (1991), version 0.02 of Linux came out; then in December version 0.11(1991) was released. This version was the first to be self-hosted. That is, Linux 0.11 could be compiled by a computer running Linux 0.11, while earlier versions of Linux were compiled using other operating systems. When he released the next version, Torvalds adopted the GPL as his own draft license, which does not allow redistribution of it under any license other than the GPL. Prior to this change, charging for source code distribution was prevented.

The ubiquity of kernel Linux

A newsgroup called alt.os.linux was started and on January 19, 1992 the first post (post) was published in that group. On March 31, alt.os.linux became comp.os.linux. XFree86, an implementation of the X Window System, was ported to Linux, kernel version 0.95 being the first to be able to run it. This huge jump in versions (from 0.1x to 0.9x) was due to the feeling that a finished 1.0 version didn't seem far off. However, these forecasts turned out to be a bit optimistic: from 1993 to early 1994, 15 different versions of 0.99 were developed (going to version 0.99r15).

On March 14, 1994, Linux 1.0.0 was released, consisting of 176,250 lines of code. In March 1995 Linux 1.2.0 was released, which already consisted of 310,950 lines of code.

  • May 1996: Torvalds decided to adopt the Tux penguin as a pet for Linux.
  • June 9, 1996: Linux version 2 was released, with a positive reception.
  • 25 January 1999: Linux 2.2.0 was launched with 1,800.847 code lines.
  • December 18, 1999: IBM Mainframe patches were published for 2.2.13, thus allowing Linux to be used on corporate computers.
  • January 4, 2001: Linux 2.4.0 was launched with 3,377,90, code lines.
  • December 17, 2003: Linux 2.6.0 was launched with 5.929.913 code lines.
  • May 19, 2008: The Free Software Foundation publishes Linux-libre, a Linux fork that does not include in its distribution any proprietary BLOBs, such as device firmware.
  • December 24, 2008: Linux 2.6.28 was released with 10,195,402 code lines.
  • October 20, 2010: Linux 2.6.36 was launched with 13,499,457 code lines.
  • May 30, 2011: Linus Torvalds announced that the kernel version will jump to 3.0 in the next publication.
  • July 21, 2011: Torvalds published in his profile on the Google+ social network that the 3.0 kernel was ready with the phrase "3.0 Pushed Out".
  • 22 July 2011: the 3.0 kernel version was launched at http://www.kernel.org
  • 12 May and 13 May 2012: versions 3.3.6 and 3.4-rc7 of the kernel were launched at http://www.kernel.org respectively.
  • February 2, 2015: version 3.19 was launched.
  • April 12, 2015: Version 4.0 was launched.
  • March 27, 2019: version 5.05 was launched.
  • 2 August 2020: version 5.8 is announced. Linux Kernel 5.8: “one of the greatest releases of all time”

Its source code is available for download on the official website: http://www.kernel.org

Technical aspects

Linux provides drivers, schedulers, virtual memory managers, file systems, and network protocols such as IPv4 and IPv6. It is also available for multiple hardware architectures and is designed to facilitate portability to newer architectures.

Architecture

Core diagram 2.4.0.

Linux is currently a monolithic hybrid kernel. Device drivers and kernel extensions typically run in a privileged space known as ring 0 (ring 0), with unrestricted access to the hardware, although some run in user space. Unlike traditional monolithic kernels, device drivers and kernel extensions can be easily loaded and unloaded as modules, while the system continues to function without interruption. Unlike traditional monolithic kernels, drivers can also be pre-dumped (momentarily stopped by more important activities) under certain conditions. This ability was added to correctly handle hardware interrupts and to improve symmetric multiprocessing support.

The fact that Linux was not developed following the design of a microkernel (which, at the time, was considered the most appropriate design for a kernel by many computer theorists), was the subject of a famously heated discussion between Linus Torvalds and Andrew S. Tanenbaum.

Virtual Machine Architecture

The Linux kernel can run on many virtual machine architectures, either as a host to the operating system or as a client. The virtual machine usually emulates the Intel x86 family of processors, although in some cases PowerPC or ARM processors are also emulated.

Debugging

To verify the correct functioning of the kernel it provides the possibility to compile against the fictitious architecture under "User Mode Linux" (UML). By compiling Linux for the UML, the kernel starts to run as another user process running on the Linux kernel of the host system. It can also serve as virtualization or to isolate processes, among other uses.

Supported binary formats

Linux 1.0 supported only the a.out binary format. The next stable series (Linux 1.2) added the use of the ELF format, which simplifies the creation of shared libraries (used extensively by current desktop environments such as GNOME and KDE). ELF is the format used by default by GCC since around version 2.6.0. The a.out format is currently not used, making ELF the binary format used by Linux today.

Linux has the ability to allow the user to add handling of other binary formats. Also binfmt_misc allows running the program associated with a data file.

Directory hierarchy

In Linux there is a file system that loads and contains all directories, networks, programs, partitions, devices, etc. that the system knows how to recognize, or at least identify. This system of files and directories is based on the character (/); That same character is also used to mark directories, such as: "/home/username/image.jpg". The directory specified by a path consisting only of this character contains the entire hierarchy of directories that make up the entire system. This directory is often called the root directory. In Linux, drives are not assigned a letter as in Windows (e.g. "C:"), but are instead assigned a directory from the root directory hierarchy (/), such as: "/media/floppy". It is common practice in the Linux file system to use several sub-hierarchies of directories, depending on the different functions and styles of use of the files. These directories can be classified as:

  • Static: Contains files that do not change without the admin (root) intervention, however, they can be read by any other user. (/bin, /sbin, /opt, /boot, /usr/bin...)
  • Dynamics: Contains files that are changing, and can be read and written (some only by their respective user and root). They contain configurations, documents, etc. For these directories, it is recommended a backup often, or better yet, should be mounted on a separate partition on the same disk, such as, for example, mounting the /home directory on another partition of the same disk, independent of the main partition of the system; thus, the system can be repaired without affecting or erasing the documents of the users. (/var/mail, /var/spool, /var/run, /var/lock, /home...)
  • Shared: Contains files that can be found on one computer and used on another, or even shared between users.
  • Restricted: Contains files that cannot be shared, they are only modified by the administrator. (/etc, /boot, /var/run, /var/lock...)

Kernel panic

Kernel panic.

On Linux, a panic is an almost always fatal system error detected by the kernel as opposed to similar errors detected in userland code. It is possible for kernel code to indicate these conditions by calling the panic function located in the header sys/systm.h file. However, most alerts are the result of exceptions in the kernel code that the processor cannot handle, such as invalid memory address references. Generally this is an indicator of a bug somewhere in the alert chain. They can also indicate a hardware failure such as a RAM failure or errors in arithmetic functions in the processor, or a software error. In many cases it is possible to properly restart or shutdown the kernel using a key combination such as ALT+SysRq+REISUB.

Programming languages

Linux is written in the C programming language, in the variant used by the GCC compiler (which has introduced a number of extensions and changes to standard C), along with a few small sections of code written in assembly language. Through the use of its extensions to the language, GCC was for a long time the only compiler capable of correctly building Linux. However, Intel claimed to have modified its C compiler in a way that would allow it to compile correctly.

Many other languages are also used in some form, basically in connection with the kernel build process (the method by which bootable images are created from source code). These include Perl, Python, and various shell scripting languages. Some drivers can also be written in C++, Fortran, or other languages, but this is not recommended. The Linux build system officially only supports GCC as the kernel and driver compiler.

Portability

iPod running a Linux kernel.

Although Linus Torvalds did not originally devise Linux as a portable kernel, it has evolved in that direction. Linux is now, in fact, one of the most widely ported kernels, and it runs on very diverse systems ranging from iPAQ (a handheld) to a zSeries (a massive mainframe). Linux has become the primary operating system for IBM's Blue Gene supercomputers, which has reduced costs and greatly increased performance.

However, it's important to note that Torvalds' efforts were also aimed at a different kind of portability. From his point of view, portability is the ability to easily compile applications from the most diverse sources on a system; thus, the original popularity of Linux was due in part to the little effort required to get everyone's favorite applications running, be they free software or open source.

The main architectures supported by Linux are DEC Alpha, ARM, AVR32, Blackfin, ETRAX CRIS, FR-V, H8, IA64, M32R, m68k, MicroBlaze, MIPS, MN10300, PA-RISC, PowerPC, System/390, SuperH, SPARC, x86, x86 64 and Xtensa

Linux has a fictitious architecture called "User Mode Linux" (UML). This architecture allows Linux to run as another process in user space. Processes executed under UML have the vision of their own machine available to them.

Security

It has an interface for creating security modules called Linux Security Module. With this interface you can create modules to apply Mandatory Access Control (MAC, Mandatory Access Control).

Versions

Linux Nucleus Infographic

In addition to developing his own code and integrating changes made by other programs, Linus Torvalds continues to release new versions of the Linux kernel. These are called “vanilla” kernels, which means they haven't been modified by anyone.

Numbering

The original Linux kernel version consisted of four issues. For example, let's assume the version number is made up like this: A.B.C[.D] (eg: 2.2.1, 2.4.13 or 2.6.12.3).

  • Number A denotes the kernel version. It is the one that changes less frequently and only does it when there is a great change in the code or the concept of the kernel. Historically it has only been modified five times: in 2004 (version 1.0), in 2006 (version 2.0), in 2011 (version 3.0), in 2015 (version 4.0) and in 2019 (version 5.0).
  • Number B denotes the subversion of the core.
Before the Linux 2.6.x series, the pair numbers indicated the “stable” version released. For example one for production use, such as 1.2, 2.4 or 2.6. The odd numbers, however, such as the 2.5.x series, are development versions, that is, they are not considered to be production.
Starting with the Linux 2.6.x series, there is no big difference between the pair or odd numbers regarding the new tools developed in the same kernel series. Linus Torvalds ruled that this will be the model in the future.
  • Number C indicates a further revision in the core. In the previous form of versions with three numbers, this was changed when security patches, bugfixes, new features or drivers were implemented in the kernel. With the new policy, it is only changed when new controllers or features are introduced; minor changes are reflected in the number D.
  • Number D occurred when a serious error, which requires an immediate settlement, was found in the NFS code of version 2.6.8. However, there were no other changes to launch a new review (which would have been 2.6.9). Then released version 2.6.8.1, with the error fixed as the only change. With 2.6.11, this was adopted as the new version policy. Bug-fixes and security patches are currently managed by the fourth number leaving major changes for the number C.

Also, sometimes after the versions there might be some letters like “rc1” or “mm2”. The “rc” stands for release candidate and indicates an unofficial release. Other letters usually (but not always) refer to the person's initials. This indicates a fork in core development by that person, eg ck refers to Con Kolivas, ac to Alan Cox, while mm refers to Andrew Morton.

The development model for Linux 2.6 was a significant change from the development model for Linux 2.5. Previously there was a stable branch (2.4) where minor and safe changes had been made, and an unstable branch (2.5) where major changes were allowed. This meant that users always had a fail-safe, state-of-the-art, and almost bug-free version of 2.4, even if they had to wait for features in the 2.5 branch. The 2.5 branch was eventually declared stable and renamed 2.6. But rather than open an unstable 2.7 branch, the kernel developers chose to continue adding changes to the "stable" 2.6 branch. This way you didn't have to keep maintaining an old but stable branch and you could make new features quickly available and you could do more testing with the latest code.

However, the development model of the new 2.6 also meant that there was no stable branch for those who expected security and bug fixes without needing the latest features. The fixes were only in the latest version, so if a user wanted a version with all known bugs fixed he would also have the latest features, which had not been well tested. A partial fix for this was the aforementioned four-issue version (y in 2.6.x.y), which meant point releases created by the stable team (Greg Kroah-Hartman, Chris Wright, and perhaps others). The stable team only released updates for the most recent kernel, however this did not fix the problem of a missing stable kernel set. Linux distributors, such as Red Hat and Debian, maintain the kernels that come out with their releases, so a solution for some people is to follow a distribution's kernel.

In response to the lack of a stable kernel and people to coordinate the bugfix collection, in December 2005 Adrian Bunk announced that he would continue to release 2.6.16 kernels even if the stable team will release 2.6.17. He also thought about including driver updates, making maintenance for the 2.6.16 series much like the old maintenance rules for stable series like 2.4. Kernel 2.6.16 will soon be replaced by 2.6.27 as a stable kernel under maintenance for several years.

Given the new development model, which kept subversion 2.6 fixed, after the Linux Kernel Summit that year, Linus Torvalds decided to modify the numbering system. The first two numbers have been replaced with a single number, so Linux 2.6.39 was followed by Linux 3.0

Dates of publication

The first version of the Linux kernel (0.01) was released on September 17, 1991. After more than 30 years of development, the latest stable version currently corresponds to 5.16, released on February 9, 2022.

8 Top Developers

Position 2012 2013 2017
1Red HatGoogleIntel
2IBMLinaroRed Hat
3Texas InstrumentsSUSELinaro
4BroadcomIBMUnknown
5NokiaSamsungIBM
6SamsungRed HatConsultants
7OracleVision Engraving Systems ConsultantsSamsung
8GoogleWolfson MicroelectronicsSUSE

Linux Timeline


Distributions

Sharp Zaurus, a pocket computer with Linux.

A Linux distribution is a set of software accompanied by the Linux kernel that is focused on meeting the needs of a specific group of users. In this way there are distributions for homes, companies and servers.

Distributions are assembled by individuals, companies, or other organizations. Each distribution may include any number of additional software, including software that facilitates system installation. The software base included with each distribution includes the Linux kernel, in most cases the GNU tools, to which a multitude of software packages are also often added.

The tools that are usually included in the distribution of this operating system are obtained from various sources, and especially from free software projects, such as: GNU, GNOME (created by GNU) and KDE. Utilities from other projects such as Mozilla, Perl, Ruby, Python, PostgreSQL, MySQL, Xorg are also included, almost all of them licensed under the GPL or compatible with it (LGPL, MPL).

Usually the X.Org Server platform, based on the old XFree86, is used to support the graphical interface.

Linux-libre

Linux is mostly free software as distributed from its web and Git repository. However, there are pieces of proprietary code that are used to make the devices of a computer work. For this reason Linux could not be integrated as a GNU package. The Latin American Free Software Foundation decided to create and maintain a completely free fork called Linux-libre. This version of Linux does not include any closed source plugins or obfuscated functions that embed binaries in their code. The inclusion of these binaries in the Linux code does not violate the GPL Version 2 license used by Linux. This license was updated to avoid this type of proprietary use of the license, similar to what happens with TiVo devices. The new license is the GPL Version 3.

All rights reserved

Initially, Torvalds distributed Linux under the terms of a license that prohibited commercial exploitation. But this license was replaced, shortly after, by the GNU GPL (version 2 only). The terms of this latter license allow distribution and sale of copies or even modifications, but require that all copies of the original work and works of authorship derived from the original be published under the same terms, and that the source code always be obtainable by the same medium as the licensed program.

Torvalds has referred to licensing Linux under the GPL as "the best thing I ever did" (in English, "the best thing I ever did").

However, the official version of the Linux kernel contains closed-source firmware, so the FSFLA-sponsored Linux-libre Project publishes and maintains modified versions of the Linux kernel that have all the hardware removed. non-free software.

Brand

To this day, Linux is a registered trademark of Linus Torvalds in the United States.

Until 1994, no one registered the Linux trademark in the United States. On August 15, 1994, when William R. Della Croce, Jr. registered the Linux trademark, he requested royalty payments from Linux distributors. In 1996, Torvalds and some affected organizations sued Della Croce and in 1997 the case was closed and the brand was assigned to Torvalds.

Since then, the Linux Mark Institute has managed the mark. In 2005 the LMI sent some letters to Linux distribution companies demanding the payment of a fee for the commercial use of the name. This is so because US legislation requires the owner of a brand to defend it, so money had to be asked for using the Linux brand, some companies have voluntarily complied with this requirement, knowing that said money will be was going to use for charity or defend the Linux brand.

Criticism

Hardware support

The Linux kernel has often been criticized for lacking drivers for certain desktop computer hardware. However, the progressive increase in the adoption of Linux on the desktop has improved hardware support by third parties or by the manufacturers themselves, causing compatibility problems to decrease in recent years.

Companies such as IBM, Intel Corporation, Hewlett-Packard, Dell, or MIPS Technologies have programmers on the Linux kernel developer team who maintain drivers for the hardware they make. This group of programmers is also joined by those who provide large distributors of Linux solutions such as Novell or Red Hat.

Monolithic architecture

Andy Tanenbaum wrote on January 29, 1992:

...Linux is a monolithic system. This is a giant step back to the 1970s. It's like taking an existing program written in C and rewriting it in BASIC. For me, writing a monolithic system in 1991 is truly a poor idea.

Contenido relacionado

MediaWiki:Clearyourcache

Note: After saving, you must refresh your browser's cache to see the changes. Internet Explorer: hold Ctrl while pressing Refresh. Firefox: while holding down...

Zilog Z80

The Zilog Z80 is an 8-bit microprocessor whose architecture is halfway between the accumulator and general register organization. If we consider the Z80 as a...

Processor

The term "Processor" may refer to the following...
Más resultados...
Tamaño del texto:
Copiar