Linux system boot from: Init upstart SYSTEMD

Source: Internet
Author: User

As an excellent engineer or architect, we must have a very good understanding and mastery of Linux systems. Here is an introduction to ordering a lot of people confused Linux self-booting.

At present, there are 3 kinds of initialization system of Linux, according to the time of occurrence is init, upstart and SYSTEMD.

Introduction to 3 Systems 1. Init

Init is Sysvinit, which is the result of System V and is extended to other UNIX systems. Common init commands and/ETC/INIT.D belong to it.

The benefits of Init come from the service serial start, which guarantees the sequence of script execution, as well as the convenience of debugging and troubleshooting. But because of the long system boot time caused by serial booting, this drawback becomes a big problem after Linux is applied to the mobile side. Also init needs to write a complex startup script, you can find a file in the INIT.D to see

2. Upstart

Upstart speeds up execution through parallel booting, but concurrently initiates for interdependent services. It also supports dynamic start and unload when hardware is hot-swappable.

3.Systemd

The concurrency of SYSTEMD is more aggressive because it also starts at the same time for interdependent services. And its on-demand boot is better than upstart.

Upstart replaced the once brilliant init, and SYSTEMD will replace upstart

Two core issues

In fact, the two issues that we care about most are how to determine which initialization system is used by a Linux system, and how to determine which system the service is initialized by or which system it should choose to initialize.

1. Judging the initialization system

The initialization process is the first process that kernel starts, and its PID is always 1, so we use Stat/proc/1/exe to view

or the existence of the 3 directories according to/USR/LIB/SYSTEMD/USR/SHARE/UPSTART/ETC/INIT.D to determine

Note Because Systemd and upstart are backwards compatible, multiple initialization systems may be installed in one system

2. Determine which system the server is initialized on

In fact, Init will turn the boot service over to upstart, and upstart to SYSTEMD.

Linux system boot from: Init upstart SYSTEMD

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.