Home > Operation and Maintenance > CentOS > The difference between centos6 and 7

The difference between centos6 and 7

王林
Release: 2020-03-16 14:28:19
Original
5334 people have browsed it

The difference between centos6 and 7

1. Evolution of system initialization technology - boot process

CentOS 6: Adopting INIT technology, the entire boot process is self-checking BIOS - MBR boot - GRUB loads - loads the kernel - starts the INIT process - reads the INITTAB configuration file and starts the process services in order according to the mode specified in the configuration file. INIT technology makes the startup process very clear and relies on SHELL scripts. Because the processes are started one by one in sequence, the speed is slow and the system startup may be affected because a certain service is stuck.

CentOS 7: Using systemd technology. This is a new technology that replaces INIT. It uses a parallel method to start the process, so the startup speed is faster, and it is compatible with INIT commands to reduce migration costs.

PS: You can know the technology used by the current system by viewing the process with PID 1 through the ps command.

(Recommended tutorial: centos usage tutorial)

2. Changes in network setting methods

The familiar ipconfig in CentOS 6 is used in CentOS 7 was replaced by the ip command; the graphical network configuration tool nmtui replaced setup

3. Host name and character set

In CentOS 6, you can modify the host name by editing /etc/ sysconfig/network file, but this method has been abandoned in CentOS 7, and the /etc/hostname file is used. The method of temporarily modifying the host name remains unchanged, and the hostname command is still used. And a new hostname management tool hostnamectl has been added to CentOS 7 (the file name modifications made by this tool are permanent).

For the modification of the character set, CentOS 7 uses the new configuration file /etc/locale.conf to replace /etc/sysconfig/i18n. If you want to temporarily modify the character set, the method remains the same, modify the LANG variable, such as LANG=zh_CN.UTF-8. A new character set management tool, localectl, has the same effect as hostnamectl.

4. Compatible with /etc/rc.local

The /etc/rc.local file records commands that need to be automatically executed after booting. Although this file has been abandoned in CentOS 7, However, it can also be used with compatibility. You only need to give the file executable permissions:

chmod +x /etc/rc.d/rc.local
Copy after login

5. The difference between runlevels

The /etc/inittab file in CentOS 6 is based on init technology. , so naturally it cannot be used in CentOS 7, but the file is still retained, but the content has been replaced with boot content to let users know how to switch run levels now. Since this is not commonly used, I will not continue to describe it.

6. Service Management

This is the most unpleasant modification for users. It adds the systemctl tool and integrates the functions of service and chkconfig commands. See the figure for specific usage:

The difference between centos6 and 7

Related video tutorial sharing: linux video tutorial

The above is the detailed content of The difference between centos6 and 7. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template