Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Example Analysis of Boot Operation Mode run level in CentOS7.1

2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces the example analysis of boot mode run level in CentOS7.1, which is very detailed and has certain reference value. Friends who are interested must finish it!

In most linux distributions, there are usually 8 runlevel

Runlevel System State

0 Halt the system

1 Single user mode

2 Basic multi user mode

3 Multi user mode

5 Multi user mode with GUI

6 Reboot the system

S, s Single user mode

Can be viewed in the file / etc/inittab

[root@wode003 ~] # cat/etc/inittab

-bash: cat/etc/inittab: there is no such file or directory

[root@wode003 ~] # cat / etc/inittab

# inittab is no longer used when using systemd.

#

# ADDING CONFIGURATION HERE WILL HAVE NO EFFECT ON YOUR SYSTEM.

#

# Ctrl-Alt-Delete is handled by / usr/lib/systemd/system/ctrl-alt-del.target

#

# systemd uses' targets' instead of runlevels. By default, there are two main targets:

#

# multi-user.target: analogous to runlevel 3

# graphical.target: analogous to runlevel 5

#

# To view current default target, run:

# systemctl get-default

#

# To set a default target, run:

# systemctl set-default TARGET.target

#

/ / get-default

[root@wode003 ~] # systemctl get-default

Graphical.target

/ / set-default

[root@wode003 ~] # systemctl set-default multi-user.target

Rm'/ etc/systemd/system/default.target'

Ln-s'/ usr/lib/systemd/system/multi-user.target''/ etc/systemd/system/default.target'

[root@wode003 ~] # systemctl get-default

Multi-user.target

[root@wode003 ~] #

The above is all the contents of the article "sample Analysis of boot mode run level in CentOS7.1". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report