Home  >  Article  >  Operation and Maintenance  >  What is linux used for?

What is linux used for?

藏色散人
藏色散人Original
2023-03-09 10:17:403261browse

Linux is a UNIX-like operating system that is free to use and spread freely; the Linux operating system is embedded with the TCP/IP protocol stack, and the protocol software has routing and forwarding functions; routing and forwarding relies on the installation of multiple blocks in the host as a router. Network card, when a certain network card receives a data packet, the system kernel will query the routing table according to the destination IP address of the data packet, and then send the data packet to another network card based on the query results, and finally send the data packet out through this network card.

What is linux used for?

#The operating environment of this tutorial: linux5.9.8 system, Dell G3 computer.

What is linux used for?

Linux, the full name is GNU/Linux, is a UNIX-like operating system that is free to use and spread freely. Its kernel is composed of First released by Linus Benedict Torvalds on October 5, 1991, it is mainly inspired by the ideas of Minix and Unix. It is a POSIX-based multi-user, multi-tasking, support Multi-threaded and multi-CPU operating systems. It supports 32-bit and 64-bit hardware and can run major Unix software tools, applications and network protocols.

Linux inherits the network-centric design philosophy of Unix and is a multi-user network operating system with stable performance. There are hundreds of different Linux distributions, such as Debian and Archlinux based on community development, and Red Hat Enterprise Linux, SUSE, Oracle Linux, etc. based on commercial development.

On November 20, 2022, Linux submitted the last batch of drm-intel-next function patches, and Linux 6.2 will usher in official support for Intel Sharp independent graphics.

Main features

Basic idea

The basic idea of ​​Linux has two points: first, everything is a file; second, every file All have definite uses. The first one is that everything in the system is boiled down to a file, including commands, hardware and software devices, operating systems, processes, etc. For the operating system kernel, they are all regarded as files with their own characteristics or types. . As for Linux being based on Unix, it is largely because the basic ideas of the two are very similar.

Completely free

Linux is a free operating system. Users can obtain it for free through the Internet or other channels, and can modify its source code at will. This is something other operating systems cannot do. It is precisely because of this that countless programmers from all over the world have participated in the modification and writing of Linux. Programmers can change it according to their own interests and inspirations. This allows Linux to absorb the essence of countless programmers and continue to grow.

Fully compatible with POSIX1.0 standard

This makes it possible to run common DOS and Windows programs through corresponding emulators under Linux. This lays the foundation for users to switch from Windows to Linux. When many users consider using Linux, they think about whether programs that were previously common under Windows can run normally, and this eliminates their doubts.

Multi-user, multi-tasking

Linux supports multiple users. Each user has its own special rights for its own file device, ensuring that users do not affect each other. Multitasking is one of the most important features of modern computers. Linux can enable multiple programs to run simultaneously and independently.

Good interface

Linux has both character interface and graphical interface. In the character interface, users can input corresponding instructions through the keyboard to perform operations. It also provides an X-Window system similar to the Windows graphical interface, which users can operate using the mouse. The X-Window environment is similar to Windows. It can be said to be a Linux version of Windows.

Support multiple platforms

Linux can run on a variety of hardware platforms, such as platforms with x86, 680x0, SPARC, Alpha and other processors. In addition, Linux is an embedded operating system that can run on handheld computers, set-top boxes or game consoles. The Linux 2.4 kernel released in January 2001 has fully supported the Intel64-bit chip architecture. At the same time, Linux also supports multi-processor technology. Multiple processors work at the same time, greatly improving system performance.

System advantages

Code open source

Linux is composed of many microkernels, and its source code is completely open source;

The network function is powerful

.Linux inherits the characteristics of Unix and has very powerful network functions. It supports all Internet protocols, including TCP/IPv4, TCP/IPv6 and link layer topology programs, etc., and can utilize the Unix network Features develop a new protocol stack;

system tool chain is complete

Linux system tool chain is complete, a suitable development environment can be configured with simple operations, which can simplify the development process and reduce simulation during development Tool obstacles make the system highly portable;

System functions

System kernel routing and forwarding

Linux operating system has TCP embedded /IP protocol stack, the protocol software has routing and forwarding functions. Routing and forwarding rely on multiple network cards installed in the host as a router. When a certain network card receives a data packet, the system kernel will query the routing table based on the destination IP address of the data packet, and then send the data packet to another network card based on the query results. , and finally the data packet is sent out through this network card. The processing process of this host is the core function completed by the router.

The routing function is implemented by modifying the Linux system kernel parameter ip_forward. The system uses the sysctl command to configure and display the kernel parameters in the /proc/sys directory. First, enter: cat /proc/sys/net/ipv4/ip_forwad on the command line to check whether the IP forwarding function is enabled in the Linux kernel. If the result is 1, it indicates that the routing forwarding function has been enabled; if the result is 0, it indicates that it has not been enabled. For security reasons, the Linux kernel prohibits packet routing and forwarding by default. In Linux systems, there are two ways to enable the forwarding function: temporary and permanent.

Temporarily enable: This method only works for the current session and will no longer be enabled after the system restarts. Temporarily enabled command format: sysctl–wnet.ipv4.ip_forward=1.

Permanently enabled: To permanently enable the IP forwarding function, change the statement line "net.ipv4.ip_forward=0" in the configuration file /etc/sysctl.conf to "net.ipv4. ip_forward=1", save the configuration file and execute the command sysctl–p/etc/sysctl.conf, the configuration will be enabled immediately.

Related recommendations: "Linux Video Tutorial"

The above is the detailed content of What is linux used for?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn