Solution to the problem that centos cannot be shut down: 1. Use the command "ps -aux" to check whether there is a background process running; 2. Shut down through the shutdown, halt or poweroff commands.
The operating environment of this article: centOS7 system, DELL G3 computer
What should I do if centos cannot be shut down?
CentOS 7 Correct shutdown and restart
Linux is mainly used in the server field, and executing a service on the server is never-ending unless it encounters Special circumstances, otherwise it will not shut down. Unlike Windows, under Linux systems, many processes are executed in the background. Behind the screen, there may be many people working at the same time. If you press the power button directly, other people's data may be interrupted. What's more serious is that if you shut down improperly, in serious cases, the file system may be damaged, resulting in data loss.
If you want to shut down, you must ensure that no other users in the current system are logging in to the system. We can use the who command to see if there are other people logged in, or use the command ps -aux to see if there are any background processes running. Shutdown, halt, and poweroff are all shutdown commands. We can use the command man shutdown to view its help documentation. For example, we run the following command to shut down.
Of course, if you learned it from CentOS 6.5, init 0 and init 6 are applicable to CentOS 7.
Init is divided into 7 levels. The meanings of these 7 levels are as follows.
The default startup runlevel is configured in /etc/inittab. The default value depends on the system release version: Debian and Ubuntu use runlevel 2, Red Hat and Fedora use runlevel 3 or 5, CentOS and Gentoo use runlevel 3
For each runlevel, there is a separate directory rc0.d ... rc6.d in the /etc directory, which contains many points to the /etc/init.d directory Symbolic link, so the service startup script is placed in the /etc/init.d directory.
Recommended: "centos usage tutorial"
The above is the detailed content of What should I do if centos cannot be shut down?. For more information, please follow other related articles on the PHP Chinese website!

To efficiently monitor PyTorch running status on CentOS system, you can adopt the following strategies to choose the appropriate solution for different needs: GPU monitoring (nvidia-smi): If you use NVIDIAGPU and have CUDA and cuDNN installed, the nvidia-smi command is an ideal tool for monitoring GPU resource utilization, memory footprint and temperature. Real-time monitoring can be used with the watch command: watch-n1nvidia-smi This will update the GPU status display once a second. System-level process monitoring (htop): htop is an interactive process viewer that can intuitively display the resource consumption of all processes, including you

CentOSStream8 Firewall Management Guide: Use firewalld to finely control network access CentOSStream8 system uses firewalld as a dynamic firewall management tool, which defines the security level of different network traffic using the concept of "zones". This guide will gradually explain the basic configuration and management methods of firewalld. 1. Install firewalld If firewalld is not installed, please execute the following command: sudodnfinstallfirewalld 2. Start and status check Start the firewalld service: sudosystemctlstartfi

Guide to Backup and Recovery of ZooKeeper Data in CentOS System This article explains how to safely and reliably backup and restore ZooKeeper data in CentOS system, mainly relying on ZooKeeper's own data backup mechanism and tools. ZooKeeper data backup mechanism ZooKeeper uses the following mechanism to ensure data security: Snapshot: ZooKeeper regularly copies the data state in memory to the snapshot file on disk. This is a full backup of the data. TransactionLog: Records all transaction operations for data recovery and state reconstruction. Backup tool commonly used backup tool kit

Managing HDFS (HadoopDistributedFileSystem) storage on CentOS involves many aspects, including installation, configuration, monitoring, permission management, etc. Here are some key steps and strategies: Install Hadoop with HDFS Installation and Configuration: First, you need to install Hadoop on CentOS. You can refer to official documents or third-party tutorials to download and install the appropriate version. Configure Hadoop environment variables: edit /etc/profile file, add Hadoop-related environment variables,

Implementing data synchronization of Zookeeper on CentOS usually involves the following steps: 1. Install Zookeeper First, you need to install Zookeeper on CentOS. You can download the latest version of Zookeeper from ApacheZookeeper's official website and install it according to the official documentation. Download and unzip wgethttps://archive.apache.org/dist/zookeeper/zookeeper-3.7.0

The storage solution of GitLab on the CentOS platform is detailed. The storage strategy of GitLab is deployed on the CentOS system. Its storage strategy covers the following key aspects: Code repository storage: By default, the OmnibusGitLab installation package will save the code repository data in the /var/opt/gitlab/git-data/repositories directory. You can customize the path to the git-data directory by modifying the /etc/gitlab/gitlab.rb configuration file. Database: GitLab's core database uses PostgreSQL, a high-performance, scalable relational database management system that ensures

Efficiently running PyTorch on CentOS systems requires considerations from hardware configuration to code optimization. This article summarizes practical skills to improve PyTorch's performance in CentOS, covering hardware selection, performance bottleneck analysis, data loading optimization, and model training strategies. 1. Hardware configuration recommended processor (CPU): Choose CPU with high main frequency, large cache, and multi-core CPUs to ensure data processing capabilities. Graphics Card (GPU): A GPU with large video memory is especially important when handling large BatchSize training. Memory (RAM): At least 64GB of memory. It is recommended to use 4 16GB memory sticks to increase memory bandwidth. Motherboard: Choose a master with excellent performance

Updating PhpStorm on CentOS system, follow these steps: Prepare to back up existing configurations: Before updating, be sure to back up PhpStorm's configuration files and plug-ins to prevent data loss due to failure. Download the latest version: Download the latest version of PhpStorm for Linux system from the official website of JetBrains. Update step Unzip the installation package: Unzip the downloaded installation package to the specified directory (for example, /opt/). Command example: tar-zxvfPhpStorm-2024.1.tar.gz-C/opt/(Please replace PhpStorm-2024.1.tar.gz


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

DVWA
Damn Vulnerable Web App (DVWA) is a PHP/MySQL web application that is very vulnerable. Its main goals are to be an aid for security professionals to test their skills and tools in a legal environment, to help web developers better understand the process of securing web applications, and to help teachers/students teach/learn in a classroom environment Web application security. The goal of DVWA is to practice some of the most common web vulnerabilities through a simple and straightforward interface, with varying degrees of difficulty. Please note that this software

WebStorm Mac version
Useful JavaScript development tools

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

mPDF
mPDF is a PHP library that can generate PDF files from UTF-8 encoded HTML. The original author, Ian Back, wrote mPDF to output PDF files "on the fly" from his website and handle different languages. It is slower than original scripts like HTML2FPDF and produces larger files when using Unicode fonts, but supports CSS styles etc. and has a lot of enhancements. Supports almost all languages, including RTL (Arabic and Hebrew) and CJK (Chinese, Japanese and Korean). Supports nested block-level elements (such as P, DIV),

PhpStorm Mac version
The latest (2018.2.1) professional PHP integrated development tool