问题表现:
执行dhclient命令时抛出以下错误。
dhclient(3108) is already running - exiting. This version of ISC DHCP is based on the release available on ftp.isc.org. Features have been added and other changes have been made to the base software release in order to make it work better with this distribution. Please report for this software via the CentOS Bugs Database: http://bugs.centos.org/ exiting.
解决方法:
查找dhclient进程。
[root@localhost ~]# ps -ef | grep dhclient root 3108 1 0 04:36 ? 00:00:00 dhclient root 4140 3013 0 05:16 pts/0 00:00:00 grep dhclient
可以看到进程ID是3108,杀死他。
[root@localhost ~]# kill -9 3108
之后再次执行dhclient就正常了。
dhclient ens3
dhclient(4329) is already running – exiting.
This version of ISC DHCP is based on the release available
on http://ftp.isc.org. Features have been added and other changes
have been made to the base software release in order to make
it work better with this distribution.
Please report for this software via the CentOS Bugs Database:
http://bugs.centos.org/
exiting.
这个报错解决一下
兄弟,按照文章上写的,结束dhclient进程再重新执行就好了,或者你可以试着加-r参数重新获取IP。出这个问题是因为dhclient只能运行一个实例,一般如果你网卡设置了自启动,那么开机就会运行这个程序,你再运行就出错了。