How to check if dhcp is closed in linux

WBOY
Release: 2022-06-09 14:12:21
Original
4321 people have browsed it

Method: 1. Use "/etc/init.d/dhcpd status", this statement can check the service status of dhcp; 2. Use the "ps aux" command, this command can check the process information in the system , the syntax is "ps aux | grep dhcp | grep -v grep".

How to check if dhcp is closed in linux

#The operating environment of this tutorial: linux7.3 system, Dell G3 computer.

linux check if dhcp is closed

Check the service status

/etc/init.d/dhcpd status
Copy after login

How to check if dhcp is closed in linux

Check whether the dhcp service is running :

ps aux | grep dhcp  |grep -v grep
Copy after login

ps aux command

The process on Linux has 5 states:

1. Running (running or waiting in the run queue)

2. Interrupted (sleeping, blocked, waiting for a certain condition to form or receiving a signal)

3. Uninterruptible (does not wake up and cannot run when receiving a signal, the process must wait until there is an interrupt) Occurrence)

4. Zombie (the process has terminated, but the process descriptor exists until the parent process calls the wait4() system call and is released)

5. Stop (the process receives SIGSTOP, SIGSTP , SIGTIN, SIGTOU signals to stop running)

Extended knowledge:

1. Check whether the startup setting is set

chkconfig --list | grep dhcpd
Copy after login

2. Check whether the port is open

netstat -anulp | grep :67
Copy after login

3: Close dhcpd

/etc/init.d/dhcpd   stop
Copy after login

4: Enable hdcpd

/etc/init.d/dhcpd   start
Copy after login

Recommended learning: Linux video tutorial

The above is the detailed content of How to check if dhcp is closed in linux. 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